aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2020-10-03 11:31:23 -0600
committerSimon Glass <sjg@chromium.org>2020-10-29 14:42:17 -0600
commitc14732984759d64634350d01d58daca8cf44d23f (patch)
tree6c282151f69a04f14082d487ac08308c0c68658a /drivers
parent627988f9f9b5533cedb3e9d2de0e0b905bb3f45f (diff)
downloadu-boot-c14732984759d64634350d01d58daca8cf44d23f.zip
u-boot-c14732984759d64634350d01d58daca8cf44d23f.tar.gz
u-boot-c14732984759d64634350d01d58daca8cf44d23f.tar.bz2
sandbox: Drop ad-hoc device declarations in SPL
Since sandbox's SPL is build with of-platadata, we should not use U_BOOT_DEVICE() declarations as well. Drop them. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/serial/sandbox.c3
-rw-r--r--drivers/sysreset/sysreset_sandbox.c2
2 files changed, 5 insertions, 0 deletions
diff --git a/drivers/serial/sandbox.c b/drivers/serial/sandbox.c
index f09d291..db2fbac 100644
--- a/drivers/serial/sandbox.c
+++ b/drivers/serial/sandbox.c
@@ -267,6 +267,7 @@ U_BOOT_DRIVER(sandbox_serial) = {
.flags = DM_FLAG_PRE_RELOC,
};
+#if !CONFIG_IS_ENABLED(OF_PLATDATA)
static const struct sandbox_serial_platdata platdata_non_fdt = {
.colour = -1,
};
@@ -275,4 +276,6 @@ U_BOOT_DEVICE(serial_sandbox_non_fdt) = {
.name = "sandbox_serial",
.platdata = &platdata_non_fdt,
};
+#endif
+
#endif /* CONFIG_IS_ENABLED(OF_CONTROL) */
diff --git a/drivers/sysreset/sysreset_sandbox.c b/drivers/sysreset/sysreset_sandbox.c
index 69c22a7..71cabd1 100644
--- a/drivers/sysreset/sysreset_sandbox.c
+++ b/drivers/sysreset/sysreset_sandbox.c
@@ -130,7 +130,9 @@ U_BOOT_DRIVER(warm_sysreset_sandbox) = {
.ops = &sandbox_warm_sysreset_ops,
};
+#if !CONFIG_IS_ENABLED(OF_PLATDATA)
/* This is here in case we don't have a device tree */
U_BOOT_DEVICE(sysreset_sandbox_non_fdt) = {
.name = "sysreset_sandbox",
};
+#endif