Lines Matching refs:zdev

52 	struct zpci_dev *zdev = get_zdev_by_fid(ccdf->fid);  in __zpci_event_error()  local
58 if (zdev) in __zpci_event_error()
59 pdev = pci_get_slot(zdev->zbus->bus, zdev->devfn); in __zpci_event_error()
77 static void zpci_event_hard_deconfigured(struct zpci_dev *zdev, u32 fh) in zpci_event_hard_deconfigured() argument
79 zdev->fh = fh; in zpci_event_hard_deconfigured()
83 zpci_bus_remove_device(zdev, true); in zpci_event_hard_deconfigured()
87 if (zdev->dma_table) in zpci_event_hard_deconfigured()
88 zpci_dma_exit_device(zdev); in zpci_event_hard_deconfigured()
89 if (zdev_enabled(zdev)) in zpci_event_hard_deconfigured()
90 zpci_disable_device(zdev); in zpci_event_hard_deconfigured()
91 zdev->state = ZPCI_FN_STATE_STANDBY; in zpci_event_hard_deconfigured()
96 struct zpci_dev *zdev = get_zdev_by_fid(ccdf->fid); in __zpci_event_availability() local
104 if (!zdev) { in __zpci_event_availability()
105 zdev = zpci_create_device(ccdf->fid, ccdf->fh, ZPCI_FN_STATE_CONFIGURED); in __zpci_event_availability()
106 if (IS_ERR(zdev)) in __zpci_event_availability()
110 if (zdev->state != ZPCI_FN_STATE_STANDBY) in __zpci_event_availability()
112 zdev->state = ZPCI_FN_STATE_CONFIGURED; in __zpci_event_availability()
114 zpci_scan_configured_device(zdev, ccdf->fh); in __zpci_event_availability()
117 if (!zdev) in __zpci_event_availability()
120 zdev->fh = ccdf->fh; in __zpci_event_availability()
123 if (zdev) { in __zpci_event_availability()
127 if (zdev->state != ZPCI_FN_STATE_CONFIGURED) in __zpci_event_availability()
129 zdev->fh = ccdf->fh; in __zpci_event_availability()
130 zpci_deconfigure_device(zdev); in __zpci_event_availability()
134 if (zdev) { in __zpci_event_availability()
138 if (zdev->state == ZPCI_FN_STATE_CONFIGURED) in __zpci_event_availability()
139 zpci_event_hard_deconfigured(zdev, ccdf->fh); in __zpci_event_availability()
141 if (!clp_get_state(zdev->fid, &state) && in __zpci_event_availability()
143 zpci_device_reserved(zdev); in __zpci_event_availability()
152 if (!zdev) in __zpci_event_availability()
154 zpci_device_reserved(zdev); in __zpci_event_availability()