projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d9b830f
)
Input: tegra-kbc - correct call to input_free_device
author
Axel Lin
<
[email protected]
>
Thu, 11 Aug 2011 16:22:45 +0000
(09:22 -0700)
committer
Dmitry Torokhov
<
[email protected]
>
Thu, 11 Aug 2011 16:23:06 +0000
(09:23 -0700)
If kzalloc for kbc fails, then we have NULL pointer dereference while
calling input_free_device(kbc->idev) in the error handling.
So it is safer to always use the original name, input_dev.
Signed-off-by: Axel Lin <
[email protected]
>
Signed-off-by: Dmitry Torokhov <
[email protected]
>
drivers/input/keyboard/tegra-kbc.c
patch
|
blob
|
history
diff --git
a/drivers/input/keyboard/tegra-kbc.c
b/drivers/input/keyboard/tegra-kbc.c
index f270447ba9519cb9497eea8a02d9869eef58ba4b..a5a77915c65003fb30eb058765945353f11d6298 100644
(file)
--- a/
drivers/input/keyboard/tegra-kbc.c
+++ b/
drivers/input/keyboard/tegra-kbc.c
@@
-702,7
+702,7
@@
err_iounmap:
err_free_mem_region:
release_mem_region(res->start, resource_size(res));
err_free_mem:
- input_free_device(
kbc->i
dev);
+ input_free_device(
input_
dev);
kfree(kbc);
return err;