[PATCH 1/1] riscv: allow building w/o DHCP, SCSI, VIRTIO

Bin Meng bmeng.cn at gmail.com
Mon Jul 4 12:16:22 CEST 2022


On Mon, Jul 4, 2022 at 6:07 PM Heinrich Schuchardt
<heinrich.schuchardt at canonical.com> wrote:
>
> On 7/4/22 11:50, Bin Meng wrote:
> > On Sun, Jul 3, 2022 at 7:28 PM Heinrich Schuchardt
> > <heinrich.schuchardt at canonical.com> wrote:
> >>
> >> Consider which boot devices are enabled in the definition of the
> >> BOOT_TARGET_DEVICES() macro.
> >>
> >> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt at 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)
> >
> > For consistency, maybe CONFIG_CMD_SCSI?
>
> The situation is quite messy:
>
> ./include/config_distro_bootcmd.h uses
> #ifdef CONFIG_SCSI
>
> CONFIG_CMD_SCSI does not depend on CONFIG_SCSI.
>
> Probably the best thing to do is:
>
> Let CONFIG_CMD_SCSI depend on CONFIG_SCSI.
> Change config_distro_bootcmd.h to use CONFIG_CMD_SCSI.
> Change this patch to use CONFIG_CMD_SCSI.
>

Yes, I think that's a better approach.

Regards,
Bin


More information about the U-Boot mailing list