Lines Matching defs:adev

31 static int acpi_get_rc_addr(struct acpi_device *adev, struct resource *res)
33 struct device *dev = &adev->dev;
41 ret = acpi_dev_get_resources(adev, &list,
79 struct acpi_device *adev;
91 ret = acpi_bus_get_device(handle, &adev);
95 ret = acpi_get_rc_addr(adev, res);
98 dev_name(&adev->dev));
828 struct acpi_device *adev;
831 adev = container_of(context, struct acpi_device, wakeup.context);
832 root = acpi_driver_data(adev);
940 struct acpi_device *adev;
948 adev = ACPI_COMPANION(&dev->dev);
949 if (!adev && !pci_dev_is_added(dev)) {
950 adev = acpi_pci_find_companion(&dev->dev);
951 ACPI_COMPANION_SET(&dev->dev, adev);
954 if (adev && acpi_device_power_manageable(adev))
965 adev = ACPI_COMPANION(&root->dev);
971 if (!adev && !pci_dev_is_added(root))
972 adev = acpi_pci_find_companion(&root->dev);
975 if (!adev)
978 fwnode = acpi_fwnode_handle(adev);
987 struct acpi_device *adev = ACPI_COMPANION(&dev->dev);
988 return adev ? acpi_device_power_manageable(adev) : false;
993 struct acpi_device *adev = ACPI_COMPANION(&dev->dev);
1004 if (!adev || acpi_has_method(adev->handle, "_EJ0"))
1019 error = acpi_device_set_power(adev, state_conv[state]);
1031 struct acpi_device *adev = ACPI_COMPANION(&dev->dev);
1041 if (!adev || !acpi_device_power_manageable(adev))
1044 state = adev->power.state;
1053 struct acpi_device *adev = ACPI_COMPANION(&dev->dev);
1055 if (adev && acpi_device_power_manageable(adev))
1056 acpi_device_update_power(adev, NULL);
1086 struct acpi_device *adev = ACPI_COMPANION(&dev->dev);
1098 if (!adev || !acpi_device_power_manageable(adev))
1101 if (adev->wakeup.flags.valid &&
1102 device_may_wakeup(&dev->dev) != !!adev->wakeup.prepare_count)
1108 return !!adev->power.flags.dsw_present;
1246 struct acpi_device *adev = ACPI_COMPANION(dev);
1248 if (!adev)
1251 pci_acpi_optimize_delay(pci_dev, adev->handle);
1255 pci_acpi_add_pm_notifier(adev, pci_dev);
1256 if (!adev->wakeup.flags.valid)
1270 acpi_device_power_add_dependent(adev, dev);
1275 struct acpi_device *adev = ACPI_COMPANION(dev);
1278 if (!adev)
1282 pci_acpi_remove_pm_notifier(adev);
1283 if (adev->wakeup.flags.valid) {
1284 acpi_device_power_remove_dependent(adev, dev);