projects
/
linux-2.6-microblaze.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3aa3c66
)
xhci-ext-caps.c: Add missing platform_device_put() on error in xhci_create_intel_xhci...
author
Wei Yongjun
<weiyongjun1@huawei.com>
Thu, 5 Sep 2019 10:00:01 +0000
(10:00 +0000)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Fri, 4 Oct 2019 12:37:53 +0000
(14:37 +0200)
Add the missing platform_device_put() before return from
xhci_create_intel_xhci_sw_pdev() in the error handling case.
Fixes:
6ed151f26484
("xhci-ext-caps.c: Add property to disable Intel SW switch")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Link:
https://lore.kernel.org/r/20190905100001.128349-1-weiyongjun1@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/host/xhci-ext-caps.c
patch
|
blob
|
history
diff --git
a/drivers/usb/host/xhci-ext-caps.c
b/drivers/usb/host/xhci-ext-caps.c
index
f498160
..
3351d07
100644
(file)
--- a/
drivers/usb/host/xhci-ext-caps.c
+++ b/
drivers/usb/host/xhci-ext-caps.c
@@
-57,6
+57,7
@@
static int xhci_create_intel_xhci_sw_pdev(struct xhci_hcd *xhci, u32 cap_offset)
ret = platform_device_add_properties(pdev, role_switch_props);
if (ret) {
dev_err(dev, "failed to register device properties\n");
+ platform_device_put(pdev);
return ret;
}
}