All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/1] riscv: allow building w/o DHCP, SCSI, VIRTIO
@ 2022-07-03 11:28 Heinrich Schuchardt
  2022-07-03 12:09 ` Heinrich Schuchardt
  2022-07-04  9:50 ` Bin Meng
  0 siblings, 2 replies; 7+ messages in thread
From: Heinrich Schuchardt @ 2022-07-03 11:28 UTC (permalink / raw)
  To: Bin Meng; +Cc: u-boot, Heinrich Schuchardt

Consider which boot devices are enabled in the definition of the
BOOT_TARGET_DEVICES() macro.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
---
 include/configs/qemu-riscv.h | 25 ++++++++++++++++++++++---
 1 file changed, 22 insertions(+), 3 deletions(-)

diff --git a/include/configs/qemu-riscv.h b/include/configs/qemu-riscv.h
index f462895fb5..427da69d3f 100644
--- a/include/configs/qemu-riscv.h
+++ b/include/configs/qemu-riscv.h
@@ -33,11 +33,30 @@
 /* Environment options */
 
 #ifndef CONFIG_SPL_BUILD
+
+#if defined(CONFIG_CMD_DHCP)
+#define BOOT_TARGET_DEVICES_DHCP(func) func(DHCP, dhcp, na)
+#else
+#define BOOT_TARGET_DEVICES_DHCP(func)
+#endif
+
+#if defined(CONFIG_SCSI)
+# define BOOT_TARGET_DEVICES_SCSI(func) func(SCSI, scsi, 0)
+#else
+# define BOOT_TARGET_DEVICES_SCSI(func)
+#endif
+
+#if defined(CONFIG_CMD_VIRTIO)
+# define BOOT_TARGET_DEVICES_VIRTIO(func) func(VIRTIO, virtio, 0)
+#else
+# define BOOT_TARGET_DEVICES_VIRTIO(func)
+#endif
+
 #define BOOT_TARGET_DEVICES(func) \
 	func(QEMU, qemu, na) \
-	func(VIRTIO, virtio, 0) \
-	func(SCSI, scsi, 0) \
-	func(DHCP, dhcp, na)
+	BOOT_TARGET_DEVICES_VIRTIO(func) \
+	BOOT_TARGET_DEVICES_SCSI(func) \
+	BOOT_TARGET_DEVICES_DHCP(func)
 
 #include <config_distro_bootcmd.h>
 
-- 
2.36.1


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2022-07-04 11:02 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-03 11:28 [PATCH 1/1] riscv: allow building w/o DHCP, SCSI, VIRTIO Heinrich Schuchardt
2022-07-03 12:09 ` Heinrich Schuchardt
2022-07-04  9:55   ` Bin Meng
2022-07-04 11:02     ` Heinrich Schuchardt
2022-07-04  9:50 ` Bin Meng
2022-07-04 10:07   ` Heinrich Schuchardt
2022-07-04 10:16     ` Bin Meng

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.