projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
87c0f56
)
USB: fix DWC_OTG HCD disconnect bug to avoid NULL pointer.
author
wlf
<wulf@rock-chips.com>
Mon, 30 Jun 2014 09:01:12 +0000
(17:01 +0800)
committer
wlf
<wulf@rock-chips.com>
Mon, 30 Jun 2014 09:01:12 +0000
(17:01 +0800)
drivers/usb/dwc_otg_310/dwc_otg_hcd.c
patch
|
blob
|
history
diff --git
a/drivers/usb/dwc_otg_310/dwc_otg_hcd.c
b/drivers/usb/dwc_otg_310/dwc_otg_hcd.c
index 825c14d283732840544cb7c6195a5feb0c20adbc..13f76b4664c9daea188c4407de381e332e3be908 100755
(executable)
--- a/
drivers/usb/dwc_otg_310/dwc_otg_hcd.c
+++ b/
drivers/usb/dwc_otg_310/dwc_otg_hcd.c
@@
-286,8
+286,8
@@
static int32_t dwc_otg_hcd_disconnect_cb(void *p)
/* In some case, we don't disconnect a usb device, but
* disconnect intr was triggered, so check hprt0 here. */
if ((!hprt0.b.prtenchng)
- && (
hprt0.d32 != 0x1000
)
- &&
(hprt0.d32 != 0x1100)
) {
+ && (
!hprt0.b.prtconndet
)
+ &&
hprt0.b.prtconnsts
) {
DWC_PRINTF("%s: hprt0 = 0x%08x\n", __func__, hprt0.d32);
return 1;
}