Lines Matching refs:zdev

25 	struct zpci_dev *zdev = container_of(hotplug_slot, struct zpci_dev,  in enable_slot()  local
29 mutex_lock(&zdev->state_lock); in enable_slot()
30 if (zdev->state != ZPCI_FN_STATE_STANDBY) { in enable_slot()
35 rc = sclp_pci_configure(zdev->fid); in enable_slot()
36 zpci_dbg(3, "conf fid:%x, rc:%d\n", zdev->fid, rc); in enable_slot()
39 zdev->state = ZPCI_FN_STATE_CONFIGURED; in enable_slot()
41 rc = zpci_scan_configured_device(zdev, zdev->fh); in enable_slot()
43 mutex_unlock(&zdev->state_lock); in enable_slot()
49 struct zpci_dev *zdev = container_of(hotplug_slot, struct zpci_dev, in disable_slot() local
54 mutex_lock(&zdev->state_lock); in disable_slot()
55 if (zdev->state != ZPCI_FN_STATE_CONFIGURED) { in disable_slot()
60 pdev = pci_get_slot(zdev->zbus->bus, zdev->devfn); in disable_slot()
67 rc = zpci_deconfigure_device(zdev); in disable_slot()
69 mutex_unlock(&zdev->state_lock); in disable_slot()
77 struct zpci_dev *zdev = container_of(hotplug_slot, struct zpci_dev, in reset_slot() local
86 if (!mutex_trylock(&zdev->state_lock)) in reset_slot()
90 if (zdev->state != ZPCI_FN_STATE_CONFIGURED) in reset_slot()
98 rc = zpci_hot_reset_device(zdev); in reset_slot()
100 mutex_unlock(&zdev->state_lock); in reset_slot()
106 struct zpci_dev *zdev = container_of(hotplug_slot, struct zpci_dev, in get_power_status() local
109 *value = zpci_is_device_configured(zdev) ? 1 : 0; in get_power_status()
128 int zpci_init_slot(struct zpci_dev *zdev) in zpci_init_slot() argument
131 struct zpci_bus *zbus = zdev->zbus; in zpci_init_slot()
133 zdev->hotplug_slot.ops = &s390_hotplug_slot_ops; in zpci_init_slot()
135 snprintf(name, SLOT_NAME_SIZE, "%08x", zdev->fid); in zpci_init_slot()
136 return pci_hp_register(&zdev->hotplug_slot, zbus->bus, in zpci_init_slot()
137 zdev->devfn, name); in zpci_init_slot()
140 void zpci_exit_slot(struct zpci_dev *zdev) in zpci_exit_slot() argument
142 pci_hp_deregister(&zdev->hotplug_slot); in zpci_exit_slot()