summaryrefslogtreecommitdiffstats
path: root/certs
diff options
context:
space:
mode:
authorJisheng Zhang <jszhang@marvell.com>2017-04-26 10:59:34 +0200
committerPeter Chen <peter.chen@nxp.com>2017-05-18 02:55:22 +0200
commitc4a0bbbdb7f6e3c37fa6deb3ef28c5ed99da6175 (patch)
tree1830586f3287e1a393115c05211103ee986185f5 /certs
parentLinux 4.12-rc1 (diff)
downloadlinux-c4a0bbbdb7f6e3c37fa6deb3ef28c5ed99da6175.tar.xz
linux-c4a0bbbdb7f6e3c37fa6deb3ef28c5ed99da6175.zip
usb: chipidea: properly handle host or gadget initialization failure
If ci_hdrc_host_init() or ci_hdrc_gadget_init() returns error and the error != -ENXIO, as Peter pointed out, "it stands for initialization for host or gadget has failed", so we'd better return failure rather continue. And before destroying the otg, i.e ci_hdrc_otg_destroy(ci), we should also check ci->roles[CI_ROLE_GADGET]. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Peter Chen <peter.chen@nxp.com>
Diffstat (limited to 'certs')
0 files changed, 0 insertions, 0 deletions