From 213fa47dacf07d11f094ff58a5695cd0c425e164 Mon Sep 17 00:00:00 2001 From: Ye Li Date: Mon, 29 Jun 2020 10:12:26 +0800 Subject: usb: gadget: Fix controller index in UMS The usb mass storage (f_mass_storage.c) uses fixed usb index 0, this causes problem while CDNS3 USB controller index is 1. Modify the API of fsg to pass the controller index. Reviewed-by: Jun Li Signed-off-by: Ye Li Signed-off-by: Peng Fan --- cmd/usb_mass_storage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cmd') diff --git a/cmd/usb_mass_storage.c b/cmd/usb_mass_storage.c index d565635c6c..cf2f55994e 100644 --- a/cmd/usb_mass_storage.c +++ b/cmd/usb_mass_storage.c @@ -170,7 +170,7 @@ static int do_usb_mass_storage(struct cmd_tbl *cmdtp, int flag, goto cleanup_ums_init; } - rc = fsg_init(ums, ums_count); + rc = fsg_init(ums, ums_count, controller_index); if (rc) { pr_err("fsg_init failed\n"); rc = CMD_RET_FAILURE; -- cgit