This function will be called from the upcoming bfetch command to reference an unexported bus.
Signed-off-by: Ahmad Fatoum <a.fat...@barebox.org> --- drivers/base/bus.c | 3 ++- include/linux/device/bus.h | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/base/bus.c b/drivers/base/bus.c index 2595c22209b4..7ee5959e8b9f 100644 --- a/drivers/base/bus.c +++ b/drivers/base/bus.c @@ -4,13 +4,14 @@ */ #include <common.h> +#include <linux/device/bus.h> #include <driver.h> #include <errno.h> #include <of.h> DEFINE_DEV_CLASS(bus_class, "bus"); -static struct bus_type *get_bus_by_name(const char *name) +struct bus_type *get_bus_by_name(const char *name) { struct bus_type *bus; diff --git a/include/linux/device/bus.h b/include/linux/device/bus.h index 2364645bad4a..678a7ffa8a4f 100644 --- a/include/linux/device/bus.h +++ b/include/linux/device/bus.h @@ -22,6 +22,7 @@ struct bus_type { int bus_register(struct bus_type *bus); int device_match(struct device *dev, const struct driver *drv); +struct bus_type *get_bus_by_name(const char *name); extern struct class bus_class; -- 2.39.5