OSDN Git Service

bus: vexpress-config: simplify config bus probing
authorRob Herring <robh@kernel.org>
Wed, 29 Apr 2020 20:58:22 +0000 (15:58 -0500)
committerRob Herring <robh@kernel.org>
Wed, 13 May 2020 17:42:46 +0000 (12:42 -0500)
commita5a38765ac79b27d53e45a283418e75c0b57c1bb
tree710c90de1808fd5cb95068049cf4c6458aaefa22
parentd06cfe3f123c50449a0c3ece21bc16668289c50f
bus: vexpress-config: simplify config bus probing

The vexpress-config initialization is dependent on the vexpress-syscfg
driver probing. As vexpress-config was not a driver, deferred probe
could not be used and instead initcall ordering was relied upon. This is
fragile and doesn't work for modules.

Let's move the config bus init into the vexpress-syscfg probe. This
eliminates the initcall ordering requirement and the need to create a
struct device and the "vexpress-config" class.

Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Cc: Linus Walleij <linus.walleij@linaro.org>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Reviewed-by: Sudeep Holla <sudeep.holla@arm.com>
Acked-by: Liviu Dudau <liviu.dudau@arm.com>
Signed-off-by: Rob Herring <robh@kernel.org>
drivers/bus/vexpress-config.c