From f60d2b111cd55c335c2b70e50d66a612d2b10856 Mon Sep 17 00:00:00 2001 From: Dmitry Torokhov Date: Mon, 26 Jun 2006 01:48:36 -0400 Subject: Input: reset name, phys and uniq when unregistering Name, phys and uniq are quite often constant strings in moules implementing particular input device. If a module unregisters input device and then gets unloaded, the device could still be present in memory (pinned via sysfs), but aforementioned members would point to some random memory. Set them all to NULL when unregistering so sysfs handlers won't try dereferencing them. Signed-off-by: Dmitry Torokhov --- include/linux/input.h | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'include/linux') diff --git a/include/linux/input.h b/include/linux/input.h index b32c2b6..8d2b874 100644 --- a/include/linux/input.h +++ b/include/linux/input.h @@ -1005,6 +1005,7 @@ static inline void init_input_dev(struct input_dev *dev) } struct input_dev *input_allocate_device(void); +void input_free_device(struct input_dev *dev); static inline struct input_dev *input_get_device(struct input_dev *dev) { @@ -1016,12 +1017,6 @@ static inline void input_put_device(struct input_dev *dev) class_device_put(&dev->cdev); } -static inline void input_free_device(struct input_dev *dev) -{ - if (dev) - input_put_device(dev); -} - int input_register_device(struct input_dev *); void input_unregister_device(struct input_dev *); -- cgit v1.1 From b9ab58dd8e771d30df110c56e785db1ae5e073df Mon Sep 17 00:00:00 2001 From: Jerome Pinot Date: Mon, 26 Jun 2006 01:51:23 -0400 Subject: Input: fix misspelling of Hangeul key Fix a mispelling of the korean alphabet name in the input subsystem. See http://en.wikipedia.org/wiki/Hangeul#Names for more details. KEY_HANGUEL left to not break people Signed-off-by: Jerome Pinot Signed-off-by: Dmitry Torokhov --- include/linux/input.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include/linux') diff --git a/include/linux/input.h b/include/linux/input.h index 8d2b874..56f1e0e 100644 --- a/include/linux/input.h +++ b/include/linux/input.h @@ -232,7 +232,8 @@ struct input_absinfo { #define KEY_PAUSE 119 #define KEY_KPCOMMA 121 -#define KEY_HANGUEL 122 +#define KEY_HANGEUL 122 +#define KEY_HANGUEL KEY_HANGEUL #define KEY_HANJA 123 #define KEY_YEN 124 #define KEY_LEFTMETA 125 -- cgit v1.1