From: Christian Gromm Date: Tue, 21 Nov 2017 14:04:45 +0000 (+0100) Subject: staging: most: core: add a match function for the bus X-Git-Tag: v4.16-rc1~112^2~574 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=921c80c52b7440a0f5c5c542d40a3295d525276b;p=linux.git staging: most: core: add a match function for the bus This patch adds the function most_match. It is needed to accociate registered devices and drivers with the bus. Signed-off-by: Christian Gromm Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/most/core.c b/drivers/staging/most/core.c index 7f7d6b65d76f..ce063a1597c3 100644 --- a/drivers/staging/most/core.c +++ b/drivers/staging/most/core.c @@ -756,11 +756,20 @@ static const struct attribute_group *aim_attr_groups[] = { * ___C O R E___ */ +int most_match(struct device *dev, struct device_driver *drv) +{ + if (!strcmp(dev_name(dev), "most")) + return 0; + else + return 1; +} + /** * Instantiation of the MOST bus */ static struct bus_type most_bus = { .name = "most", + .match = most_match, }; /**