diff options
author | Jacek Anaszewski <jacek.anaszewski@gmail.com> | 2019-07-30 22:36:31 +0200 |
---|---|---|
committer | Jacek Anaszewski <jacek.anaszewski@gmail.com> | 2019-07-30 22:36:31 +0200 |
commit | be7fc2cc86170bea31e1db8d596f35df52254971 (patch) | |
tree | 31ca140aec74decbf18dfce1a7869aeeb8dcbf84 /drivers/fpga/fpga-mgr.c | |
parent | leds: netxbig: Add of_node_put() in netxbig_leds_get_of_pdata() (diff) | |
parent | platform: Add platform_find_device_by_driver() helper (diff) | |
download | linux-dev-be7fc2cc86170bea31e1db8d596f35df52254971.tar.xz linux-dev-be7fc2cc86170bea31e1db8d596f35df52254971.zip |
Merge tag 'generic_lookup_helpers' into for-next
Generic Device Lookup Helpers
Persistent tag for others to pull this branch from
Based on patch series from Suzuki K Poulose <suzuki.poulose@arm.com>
with Subject: [PATCH v3 0/7] drivers: Add generic device lookup helpers
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* tag 'generic_lookup_helpers':
platform: Add platform_find_device_by_driver() helper
drivers: Add generic helper to match any device
drivers: Introduce device lookup variants by ACPI_COMPANION device
drivers: Introduce device lookup variants by device type
drivers: Introduce device lookup variants by fwnode
drivers: Introduce device lookup variants by of_node
drivers: Introduce device lookup variants by name
Diffstat (limited to 'drivers/fpga/fpga-mgr.c')
-rw-r--r-- | drivers/fpga/fpga-mgr.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/fpga/fpga-mgr.c b/drivers/fpga/fpga-mgr.c index c3866816456a..e05104f5e40c 100644 --- a/drivers/fpga/fpga-mgr.c +++ b/drivers/fpga/fpga-mgr.c @@ -482,11 +482,6 @@ struct fpga_manager *fpga_mgr_get(struct device *dev) } EXPORT_SYMBOL_GPL(fpga_mgr_get); -static int fpga_mgr_of_node_match(struct device *dev, const void *data) -{ - return dev->of_node == data; -} - /** * of_fpga_mgr_get - Given a device node, get a reference to a fpga mgr. * @@ -498,8 +493,7 @@ struct fpga_manager *of_fpga_mgr_get(struct device_node *node) { struct device *dev; - dev = class_find_device(fpga_mgr_class, NULL, node, - fpga_mgr_of_node_match); + dev = class_find_device_by_of_node(fpga_mgr_class, node); if (!dev) return ERR_PTR(-ENODEV); |