* [PATCH] usb: gadget: dfu: detect devices when necessary
@ 2025-01-20 13:28 Sascha Hauer
2025-01-21 8:32 ` Sascha Hauer
0 siblings, 1 reply; 2+ messages in thread
From: Sascha Hauer @ 2025-01-20 13:28 UTC (permalink / raw)
To: Barebox List
the DFU file list might refer to devices which are not yet detected.
Call detect on the devices on the list to make sure they are present
when DFU is started.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
drivers/usb/gadget/function/dfu.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/usb/gadget/function/dfu.c b/drivers/usb/gadget/function/dfu.c
index 44a6ec1aa6..893dcc7f70 100644
--- a/drivers/usb/gadget/function/dfu.c
+++ b/drivers/usb/gadget/function/dfu.c
@@ -372,6 +372,8 @@ dfu_bind(struct usb_configuration *c, struct usb_function *f)
dfu_files = opts->files;
}
+ file_list_detect_all(dfu_files);
+
n_entries = list_count_nodes(&dfu_files->list);
dfu_string_defs = xzalloc(sizeof(struct usb_string) * (n_entries + 2));
--
2.39.5
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-01-21 8:33 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-01-20 13:28 [PATCH] usb: gadget: dfu: detect devices when necessary Sascha Hauer
2025-01-21 8:32 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox