summaryrefslogtreecommitdiff
path: root/drivers/usb/gadget/udc/aspeed-vhub/core.c
diff options
context:
space:
mode:
authorTao Ren <rentao.bupt@gmail.com>2020-03-15 12:16:27 -0700
committerFelipe Balbi <balbi@kernel.org>2020-05-05 10:58:51 +0300
commit5cc0710f23689455d40d590ebbcbcd21b0d84c77 (patch)
tree2da1d6da8a1e97da94045feefb83ed89642187b8 /drivers/usb/gadget/udc/aspeed-vhub/core.c
parenta23be4ed8f481000080df5221d9119b8bbc7e7c8 (diff)
downloadlinux-5cc0710f23689455d40d590ebbcbcd21b0d84c77.tar.gz
linux-5cc0710f23689455d40d590ebbcbcd21b0d84c77.tar.bz2
linux-5cc0710f23689455d40d590ebbcbcd21b0d84c77.zip
usb: gadget: aspeed: support multiple language strings
This patch introduces a link list to store string descriptors with different languages, and "ast_vhub_rep_string" function is also improved to support multiple language usb strings. Signed-off-by: Tao Ren <rentao.bupt@gmail.com> Signed-off-by: Felipe Balbi <balbi@kernel.org>
Diffstat (limited to 'drivers/usb/gadget/udc/aspeed-vhub/core.c')
-rw-r--r--drivers/usb/gadget/udc/aspeed-vhub/core.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/usb/gadget/udc/aspeed-vhub/core.c b/drivers/usb/gadget/udc/aspeed-vhub/core.c
index 555e8645fb1e..cdf96911e4b1 100644
--- a/drivers/usb/gadget/udc/aspeed-vhub/core.c
+++ b/drivers/usb/gadget/udc/aspeed-vhub/core.c
@@ -408,7 +408,9 @@ static int ast_vhub_probe(struct platform_device *pdev)
goto err;
/* Init hub emulation */
- ast_vhub_init_hub(vhub);
+ rc = ast_vhub_init_hub(vhub);
+ if (rc)
+ goto err;
/* Initialize HW */
ast_vhub_init_hw(vhub);