OSDN Git Service
(root)
/
android-x86
/
kernel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f7410ce
)
USB: musb: don't dereference NULL tusb_dma in dma_controller_destroy()
author
Roel Kluin
<roel.kluin@gmail.com>
Sat, 9 Jan 2010 20:57:44 +0000
(21:57 +0100)
committer
Greg Kroah-Hartman
<gregkh@suse.de>
Tue, 2 Mar 2010 22:54:14 +0000
(14:54 -0800)
Test whether tusb_dma is not NULL before dereferencing
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Cc: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/musb/tusb6010_omap.c
patch
|
blob
|
history
diff --git
a/drivers/usb/musb/tusb6010_omap.c
b/drivers/usb/musb/tusb6010_omap.c
index
e13c770
..
1c86809
100644
(file)
--- a/
drivers/usb/musb/tusb6010_omap.c
+++ b/
drivers/usb/musb/tusb6010_omap.c
@@
-648,7
+648,7
@@
void dma_controller_destroy(struct dma_controller *c)
}
}
- if (
!tusb_dma->multichannel && tusb_dma
&& tusb_dma->ch >= 0)
+ if (
tusb_dma && !tusb_dma->multichannel
&& tusb_dma->ch >= 0)
omap_free_dma(tusb_dma->ch);
kfree(tusb_dma);