summaryrefslogtreecommitdiffstats
path: root/drivers/base/devcon.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-09-03 17:11:07 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-09-03 17:11:07 +0200
commitc5c0283a9db1c7ba5881f956a1faf2ebc3dfe70e (patch)
treea4d44768f1591f40374c87eea9a28df8faccc103 /drivers/base/devcon.c
parenta31f01777bc54a0a9d57628956d05f8d454d3418 (diff)
parent36f3313d6bff91ab2a9e47698c27d15363640a4e (diff)
downloadlinux-c5c0283a9db1c7ba5881f956a1faf2ebc3dfe70e.tar.bz2
Merge generic_lookup_helpers into usb-next
The lookup helpers are needed here. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/base/devcon.c')
-rw-r--r--drivers/base/devcon.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/base/devcon.c b/drivers/base/devcon.c
index 986ad89de2f9..14e2178e09f8 100644
--- a/drivers/base/devcon.c
+++ b/drivers/base/devcon.c
@@ -152,19 +152,13 @@ static struct bus_type *generic_match_buses[] = {
NULL,
};
-static int device_fwnode_match(struct device *dev, const void *fwnode)
-{
- return dev_fwnode(dev) == fwnode;
-}
-
static void *device_connection_fwnode_match(struct device_connection *con)
{
struct bus_type *bus;
struct device *dev;
for (bus = generic_match_buses[0]; bus; bus++) {
- dev = bus_find_device(bus, NULL, (void *)con->fwnode,
- device_fwnode_match);
+ dev = bus_find_device_by_fwnode(bus, con->fwnode);
if (dev && !strncmp(dev_name(dev), con->id, strlen(con->id)))
return dev;