projects
/
GitHub
/
mt8127
/
android_kernel_alcatel_ttab.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
30bac7a
)
[PATCH] pcmcia: fix pcmcia_device_remove oops
author
Hugh Dickins
<hugh@veritas.com>
Fri, 10 Mar 2006 21:15:19 +0000
(21:15 +0000)
committer
Dominik Brodowski
<linux@dominikbrodowski.net>
Fri, 31 Mar 2006 15:30:51 +0000
(17:30 +0200)
Fix pcmcia_device_remove NULL pointer dereference at shutdown.
Signed-off-by: Hugh Dickins <hugh@veritas.com>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
drivers/pcmcia/ds.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/pcmcia/ds.c
b/drivers/pcmcia/ds.c
index 8966dd09139d9eee4e159c1a36a9cebb33b71574..ae10d1eed65e2417bf3077dffe7eb7963a0cb2f7 100644
(file)
--- a/
drivers/pcmcia/ds.c
+++ b/
drivers/pcmcia/ds.c
@@
-464,7
+464,7
@@
static int pcmcia_device_remove(struct device * dev)
* all devices
*/
did = (struct pcmcia_device_id *) p_dev->dev.driver_data;
- if ((did->match_flags & PCMCIA_DEV_ID_MATCH_DEVICE_NO) &&
+ if (
did &&
(did->match_flags & PCMCIA_DEV_ID_MATCH_DEVICE_NO) &&
(p_dev->socket->device_count != 0) &&
(p_dev->device_no == 0))
pcmcia_card_remove(p_dev->socket, p_dev);