[PATCH] fixup! fastboot/dfu: use system partitions as fall back

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



For configuration where DFU is disabled, opts->dfu_opts.files would
contain the system partitions and multi-gadget auto start would
fail. Ignore dfu == true when support is not compiled in.

Signed-off-by: Ahmad Fatoum <a.fatoum@xxxxxxxxxxxxxx>
---
 common/usbgadget.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/common/usbgadget.c b/common/usbgadget.c
index bdbb4d794889..489b3b801630 100644
--- a/common/usbgadget.c
+++ b/common/usbgadget.c
@@ -53,7 +53,7 @@ int usbgadget_register(bool dfu, const char *dfu_opts,
 	opts = xzalloc(sizeof(*opts));
 	opts->release = usb_multi_opts_release;
 
-	if (dfu)
+	if (IS_ENABLED(CONFIG_USB_GADGET_DFU) && dfu)
 		opts->dfu_opts.files = dfu_opts ? parse(dfu_opts)
 			: get_dfu_function();
 
-- 
2.29.2


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux