X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=include%2Flinux%2Finput.h;h=8d2b874d9e723d2356c62a3bd44cb85a3f361b1e;hb=f60d2b111cd55c335c2b70e50d66a612d2b10856;hp=50e338d2ffda9cb5a835d67849e38ae0ceba1647;hpb=877fbae3d51ba792639535bfc0f428154b8da605;p=powerpc.git diff --git a/include/linux/input.h b/include/linux/input.h index 50e338d2ff..8d2b874d9e 100644 --- a/include/linux/input.h +++ b/include/linux/input.h @@ -15,6 +15,7 @@ #else #include #include +#include #include #endif @@ -345,6 +346,8 @@ struct input_absinfo { #define KEY_SAVE 234 #define KEY_DOCUMENTS 235 +#define KEY_BATTERY 236 + #define KEY_UNKNOWN 240 #define BTN_MISC 0x100 @@ -577,14 +580,9 @@ struct input_absinfo { * Switch events */ -#define SW_0 0x00 -#define SW_1 0x01 -#define SW_2 0x02 -#define SW_3 0x03 -#define SW_4 0x04 -#define SW_5 0x05 -#define SW_6 0x06 -#define SW_7 0x07 +#define SW_LID 0x00 /* set = lid shut */ +#define SW_TABLET_MODE 0x01 /* set = tablet mode */ +#define SW_HEADPHONE_INSERT 0x02 /* set = inserted */ #define SW_MAX 0x0f /* @@ -1007,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) { @@ -1018,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 *);