ACPI / bind: Rework struct acpi_bus_type
Replace the .find_device function pointer in struct acpi_bus_type with a new one, .find_companion, that is supposed to point to a function returning struct acpi_device pointer (instead of an int) and takes one argument (instead of two). This way the role of this callback is more clear and the implementation of it can be more straightforward. Update all of the users of struct acpi_bus_type (PCI, PNP/ACPI and USB) to reflect the structure change. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Tested-by: Lan Tianyu <tianyu.lan@intel.com> # for USB/ACPI
This commit is contained in:
@@ -412,7 +412,7 @@ struct acpi_bus_type {
|
||||
struct list_head list;
|
||||
const char *name;
|
||||
bool (*match)(struct device *dev);
|
||||
int (*find_device) (struct device *, acpi_handle *);
|
||||
struct acpi_device * (*find_companion)(struct device *);
|
||||
void (*setup)(struct device *);
|
||||
void (*cleanup)(struct device *);
|
||||
};
|
||||
|
Reference in New Issue
Block a user