From: Simon Glass Date: Wed, 16 Dec 2020 08:25:00 -0700 Subject: [PATCH 12/18] dm: core: Only include simple-bus devicetree id when needed In-Reply-To: <20201216152506.119900-1-sjg@chromium.org> References: <20201216152506.119900-1-sjg@chromium.org> Message-ID: <20201216152506.119900-8-sjg@chromium.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de This is not needed when of-platdata is in use. Update it. Signed-off-by: Simon Glass --- drivers/core/simple-bus.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/core/simple-bus.c b/drivers/core/simple-bus.c index c45212a0d3a..7dbcbecd948 100644 --- a/drivers/core/simple-bus.c +++ b/drivers/core/simple-bus.c @@ -50,15 +50,17 @@ UCLASS_DRIVER(simple_bus) = { .per_device_plat_auto = sizeof(struct simple_bus_plat), }; +#if !CONFIG_IS_ENABLED(OF_PLATDATA) static const struct udevice_id generic_simple_bus_ids[] = { { .compatible = "simple-bus" }, { .compatible = "simple-mfd" }, { } }; +#endif U_BOOT_DRIVER(simple_bus) = { .name = "simple_bus", .id = UCLASS_SIMPLE_BUS, - .of_match = generic_simple_bus_ids, + .of_match = of_match_ptr(generic_simple_bus_ids), .flags = DM_FLAG_PRE_RELOC, }; -- 2.29.2.684.gfbc64c5ab5-goog