リビジョン | 48b6d2e70e68d730b246b7aa25f1bf6558fbdf99 (tree) |
---|---|
日時 | 2011-12-30 14:41:04 |
作者 | Chih-Wei Huang <cwhuang@linu...> |
コミッター | Chih-Wei Huang |
input.h: update to EV_VERSION 0x010001
This is required by newer kernel(>=2.6.37).
@@ -7,66 +7,79 @@ | ||
7 | 7 | *** structures, and macros generated from the original header, and thus, |
8 | 8 | *** contains no copyrightable information. |
9 | 9 | *** |
10 | + *** To edit the content of this header, modify the corresponding | |
11 | + *** source file (e.g. under external/kernel-headers/original/) then | |
12 | + *** run bionic/libc/kernel/tools/update_all.py | |
13 | + *** | |
14 | + *** Any manual change here will be lost the next time this script will | |
15 | + *** be run. You've been warned! | |
16 | + *** | |
10 | 17 | **************************************************************************** |
11 | 18 | ****************************************************************************/ |
12 | 19 | #ifndef _INPUT_H |
13 | 20 | #define _INPUT_H |
14 | - | |
15 | 21 | #include <sys/time.h> |
16 | 22 | #include <sys/ioctl.h> |
17 | 23 | #include <sys/types.h> |
18 | -#include <asm/types.h> | |
19 | - | |
24 | +#include <linux/types.h> | |
20 | 25 | struct input_event { |
21 | 26 | struct timeval time; |
22 | 27 | __u16 type; |
23 | 28 | __u16 code; |
24 | 29 | __s32 value; |
25 | 30 | }; |
26 | - | |
27 | -#define EV_VERSION 0x010000 | |
28 | - | |
31 | +#define EV_VERSION 0x010001 | |
29 | 32 | struct input_id { |
30 | 33 | __u16 bustype; |
31 | 34 | __u16 vendor; |
32 | 35 | __u16 product; |
33 | 36 | __u16 version; |
34 | 37 | }; |
35 | - | |
36 | 38 | struct input_absinfo { |
37 | 39 | __s32 value; |
38 | 40 | __s32 minimum; |
39 | 41 | __s32 maximum; |
40 | 42 | __s32 fuzz; |
41 | 43 | __s32 flat; |
44 | + __s32 resolution; | |
42 | 45 | }; |
43 | - | |
44 | -#define EVIOCGVERSION _IOR('E', 0x01, int) | |
45 | -#define EVIOCGID _IOR('E', 0x02, struct input_id) | |
46 | -#define EVIOCGREP _IOR('E', 0x03, int[2]) | |
47 | -#define EVIOCSREP _IOW('E', 0x03, int[2]) | |
48 | -#define EVIOCGKEYCODE _IOR('E', 0x04, int[2]) | |
49 | -#define EVIOCSKEYCODE _IOW('E', 0x04, int[2]) | |
50 | - | |
51 | -#define EVIOCGNAME(len) _IOC(_IOC_READ, 'E', 0x06, len) | |
52 | -#define EVIOCGPHYS(len) _IOC(_IOC_READ, 'E', 0x07, len) | |
53 | -#define EVIOCGUNIQ(len) _IOC(_IOC_READ, 'E', 0x08, len) | |
54 | - | |
55 | -#define EVIOCGKEY(len) _IOC(_IOC_READ, 'E', 0x18, len) | |
56 | -#define EVIOCGLED(len) _IOC(_IOC_READ, 'E', 0x19, len) | |
57 | -#define EVIOCGSND(len) _IOC(_IOC_READ, 'E', 0x1a, len) | |
58 | -#define EVIOCGSW(len) _IOC(_IOC_READ, 'E', 0x1b, len) | |
59 | - | |
60 | -#define EVIOCGBIT(ev,len) _IOC(_IOC_READ, 'E', 0x20 + ev, len) | |
61 | -#define EVIOCGABS(abs) _IOR('E', 0x40 + abs, struct input_absinfo) | |
62 | -#define EVIOCSABS(abs) _IOW('E', 0xc0 + abs, struct input_absinfo) | |
63 | - | |
64 | -#define EVIOCSFF _IOC(_IOC_WRITE, 'E', 0x80, sizeof(struct ff_effect)) | |
65 | -#define EVIOCRMFF _IOW('E', 0x81, int) | |
66 | -#define EVIOCGEFFECTS _IOR('E', 0x84, int) | |
67 | - | |
68 | -#define EVIOCGRAB _IOW('E', 0x90, int) | |
69 | - | |
46 | +struct input_keymap_entry { | |
47 | +#define INPUT_KEYMAP_BY_INDEX (1 << 0) | |
48 | + __u8 flags; | |
49 | + __u8 len; | |
50 | + __u16 index; | |
51 | + __u32 keycode; | |
52 | + __u8 scancode[32]; | |
53 | +}; | |
54 | +#define EVIOCGVERSION _IOR('E', 0x01, int) | |
55 | +#define EVIOCGID _IOR('E', 0x02, struct input_id) | |
56 | +#define EVIOCGREP _IOR('E', 0x03, unsigned int[2]) | |
57 | +#define EVIOCSREP _IOW('E', 0x03, unsigned int[2]) | |
58 | +#define EVIOCGKEYCODE _IOR('E', 0x04, unsigned int[2]) | |
59 | +#define EVIOCGKEYCODE_V2 _IOR('E', 0x04, struct input_keymap_entry) | |
60 | +#define EVIOCSKEYCODE _IOW('E', 0x04, unsigned int[2]) | |
61 | +#define EVIOCSKEYCODE_V2 _IOW('E', 0x04, struct input_keymap_entry) | |
62 | +#define EVIOCGNAME(len) _IOC(_IOC_READ, 'E', 0x06, len) | |
63 | +#define EVIOCGPHYS(len) _IOC(_IOC_READ, 'E', 0x07, len) | |
64 | +#define EVIOCGUNIQ(len) _IOC(_IOC_READ, 'E', 0x08, len) | |
65 | +#define EVIOCGPROP(len) _IOC(_IOC_READ, 'E', 0x09, len) | |
66 | +#define EVIOCGKEY(len) _IOC(_IOC_READ, 'E', 0x18, len) | |
67 | +#define EVIOCGLED(len) _IOC(_IOC_READ, 'E', 0x19, len) | |
68 | +#define EVIOCGSND(len) _IOC(_IOC_READ, 'E', 0x1a, len) | |
69 | +#define EVIOCGSW(len) _IOC(_IOC_READ, 'E', 0x1b, len) | |
70 | +#define EVIOCGBIT(ev,len) _IOC(_IOC_READ, 'E', 0x20 + ev, len) | |
71 | +#define EVIOCGABS(abs) _IOR('E', 0x40 + abs, struct input_absinfo) | |
72 | +#define EVIOCSABS(abs) _IOW('E', 0xc0 + abs, struct input_absinfo) | |
73 | +#define EVIOCSFF _IOC(_IOC_WRITE, 'E', 0x80, sizeof(struct ff_effect)) | |
74 | +#define EVIOCRMFF _IOW('E', 0x81, int) | |
75 | +#define EVIOCGEFFECTS _IOR('E', 0x84, int) | |
76 | +#define EVIOCGRAB _IOW('E', 0x90, int) | |
77 | +#define INPUT_PROP_POINTER 0x00 | |
78 | +#define INPUT_PROP_DIRECT 0x01 | |
79 | +#define INPUT_PROP_BUTTONPAD 0x02 | |
80 | +#define INPUT_PROP_SEMI_MT 0x03 | |
81 | +#define INPUT_PROP_MAX 0x1f | |
82 | +#define INPUT_PROP_CNT (INPUT_PROP_MAX + 1) | |
70 | 83 | #define EV_SYN 0x00 |
71 | 84 | #define EV_KEY 0x01 |
72 | 85 | #define EV_REL 0x02 |
@@ -80,10 +93,11 @@ struct input_absinfo { | ||
80 | 93 | #define EV_PWR 0x16 |
81 | 94 | #define EV_FF_STATUS 0x17 |
82 | 95 | #define EV_MAX 0x1f |
83 | - | |
96 | +#define EV_CNT (EV_MAX+1) | |
84 | 97 | #define SYN_REPORT 0 |
85 | 98 | #define SYN_CONFIG 1 |
86 | - | |
99 | +#define SYN_MT_REPORT 2 | |
100 | +#define SYN_DROPPED 3 | |
87 | 101 | #define KEY_RESERVED 0 |
88 | 102 | #define KEY_ESC 1 |
89 | 103 | #define KEY_1 2 |
@@ -168,7 +182,6 @@ struct input_absinfo { | ||
168 | 182 | #define KEY_KP3 81 |
169 | 183 | #define KEY_KP0 82 |
170 | 184 | #define KEY_KPDOT 83 |
171 | - | |
172 | 185 | #define KEY_ZENKAKUHANKAKU 85 |
173 | 186 | #define KEY_102ND 86 |
174 | 187 | #define KEY_F11 87 |
@@ -204,7 +217,7 @@ struct input_absinfo { | ||
204 | 217 | #define KEY_KPEQUAL 117 |
205 | 218 | #define KEY_KPPLUSMINUS 118 |
206 | 219 | #define KEY_PAUSE 119 |
207 | - | |
220 | +#define KEY_SCALE 120 | |
208 | 221 | #define KEY_KPCOMMA 121 |
209 | 222 | #define KEY_HANGEUL 122 |
210 | 223 | #define KEY_HANGUEL KEY_HANGEUL |
@@ -213,7 +226,6 @@ struct input_absinfo { | ||
213 | 226 | #define KEY_LEFTMETA 125 |
214 | 227 | #define KEY_RIGHTMETA 126 |
215 | 228 | #define KEY_COMPOSE 127 |
216 | - | |
217 | 229 | #define KEY_STOP 128 |
218 | 230 | #define KEY_AGAIN 129 |
219 | 231 | #define KEY_PROPS 130 |
@@ -239,6 +251,7 @@ struct input_absinfo { | ||
239 | 251 | #define KEY_WWW 150 |
240 | 252 | #define KEY_MSDOS 151 |
241 | 253 | #define KEY_COFFEE 152 |
254 | +#define KEY_SCREENLOCK KEY_COFFEE | |
242 | 255 | #define KEY_DIRECTION 153 |
243 | 256 | #define KEY_CYCLEWINDOWS 154 |
244 | 257 | #define KEY_MAIL 155 |
@@ -269,7 +282,6 @@ struct input_absinfo { | ||
269 | 282 | #define KEY_KPRIGHTPAREN 180 |
270 | 283 | #define KEY_NEW 181 |
271 | 284 | #define KEY_REDO 182 |
272 | - | |
273 | 285 | #define KEY_F13 183 |
274 | 286 | #define KEY_F14 184 |
275 | 287 | #define KEY_F15 185 |
@@ -282,11 +294,11 @@ struct input_absinfo { | ||
282 | 294 | #define KEY_F22 192 |
283 | 295 | #define KEY_F23 193 |
284 | 296 | #define KEY_F24 194 |
285 | - | |
286 | 297 | #define KEY_PLAYCD 200 |
287 | 298 | #define KEY_PAUSECD 201 |
288 | 299 | #define KEY_PROG3 202 |
289 | 300 | #define KEY_PROG4 203 |
301 | +#define KEY_DASHBOARD 204 | |
290 | 302 | #define KEY_SUSPEND 205 |
291 | 303 | #define KEY_CLOSE 206 |
292 | 304 | #define KEY_PLAY 207 |
@@ -309,32 +321,27 @@ struct input_absinfo { | ||
309 | 321 | #define KEY_BRIGHTNESSDOWN 224 |
310 | 322 | #define KEY_BRIGHTNESSUP 225 |
311 | 323 | #define KEY_MEDIA 226 |
312 | - | |
313 | -#define KEY_STAR 227 | |
314 | -#define KEY_SHARP 228 | |
315 | -#define KEY_SOFT1 229 | |
316 | -#define KEY_SOFT2 230 | |
317 | -#define KEY_SEND 231 | |
318 | -#define KEY_CENTER 232 | |
319 | -#define KEY_HEADSETHOOK 233 | |
320 | -#define KEY_0_5 234 | |
321 | -#define KEY_2_5 235 | |
322 | - | |
323 | -#define KEY_SWITCHVIDEOMODE 236 | |
324 | -#define KEY_KBDILLUMTOGGLE 237 | |
325 | -#define KEY_KBDILLUMDOWN 238 | |
326 | -#define KEY_KBDILLUMUP 239 | |
327 | - | |
324 | +#define KEY_SWITCHVIDEOMODE 227 | |
325 | +#define KEY_KBDILLUMTOGGLE 228 | |
326 | +#define KEY_KBDILLUMDOWN 229 | |
327 | +#define KEY_KBDILLUMUP 230 | |
328 | 328 | #define KEY_SEND 231 |
329 | 329 | #define KEY_REPLY 232 |
330 | 330 | #define KEY_FORWARDMAIL 233 |
331 | 331 | #define KEY_SAVE 234 |
332 | 332 | #define KEY_DOCUMENTS 235 |
333 | - | |
334 | 333 | #define KEY_BATTERY 236 |
335 | - | |
334 | +#define KEY_BLUETOOTH 237 | |
335 | +#define KEY_WLAN 238 | |
336 | +#define KEY_UWB 239 | |
336 | 337 | #define KEY_UNKNOWN 240 |
337 | - | |
338 | +#define KEY_VIDEO_NEXT 241 | |
339 | +#define KEY_VIDEO_PREV 242 | |
340 | +#define KEY_BRIGHTNESS_CYCLE 243 | |
341 | +#define KEY_BRIGHTNESS_ZERO 244 | |
342 | +#define KEY_DISPLAY_OFF 245 | |
343 | +#define KEY_WIMAX 246 | |
344 | +#define KEY_RFKILL 247 | |
338 | 345 | #define BTN_MISC 0x100 |
339 | 346 | #define BTN_0 0x100 |
340 | 347 | #define BTN_1 0x101 |
@@ -346,7 +353,6 @@ struct input_absinfo { | ||
346 | 353 | #define BTN_7 0x107 |
347 | 354 | #define BTN_8 0x108 |
348 | 355 | #define BTN_9 0x109 |
349 | - | |
350 | 356 | #define BTN_MOUSE 0x110 |
351 | 357 | #define BTN_LEFT 0x110 |
352 | 358 | #define BTN_RIGHT 0x111 |
@@ -356,7 +362,6 @@ struct input_absinfo { | ||
356 | 362 | #define BTN_FORWARD 0x115 |
357 | 363 | #define BTN_BACK 0x116 |
358 | 364 | #define BTN_TASK 0x117 |
359 | - | |
360 | 365 | #define BTN_JOYSTICK 0x120 |
361 | 366 | #define BTN_TRIGGER 0x120 |
362 | 367 | #define BTN_THUMB 0x121 |
@@ -371,7 +376,6 @@ struct input_absinfo { | ||
371 | 376 | #define BTN_BASE5 0x12a |
372 | 377 | #define BTN_BASE6 0x12b |
373 | 378 | #define BTN_DEAD 0x12f |
374 | - | |
375 | 379 | #define BTN_GAMEPAD 0x130 |
376 | 380 | #define BTN_A 0x130 |
377 | 381 | #define BTN_B 0x131 |
@@ -388,7 +392,6 @@ struct input_absinfo { | ||
388 | 392 | #define BTN_MODE 0x13c |
389 | 393 | #define BTN_THUMBL 0x13d |
390 | 394 | #define BTN_THUMBR 0x13e |
391 | - | |
392 | 395 | #define BTN_DIGI 0x140 |
393 | 396 | #define BTN_TOOL_PEN 0x140 |
394 | 397 | #define BTN_TOOL_RUBBER 0x141 |
@@ -403,11 +406,10 @@ struct input_absinfo { | ||
403 | 406 | #define BTN_STYLUS2 0x14c |
404 | 407 | #define BTN_TOOL_DOUBLETAP 0x14d |
405 | 408 | #define BTN_TOOL_TRIPLETAP 0x14e |
406 | - | |
409 | +#define BTN_TOOL_QUADTAP 0x14f | |
407 | 410 | #define BTN_WHEEL 0x150 |
408 | 411 | #define BTN_GEAR_DOWN 0x150 |
409 | 412 | #define BTN_GEAR_UP 0x151 |
410 | - | |
411 | 413 | #define KEY_OK 0x160 |
412 | 414 | #define KEY_SELECT 0x161 |
413 | 415 | #define KEY_GOTO 0x162 |
@@ -472,12 +474,37 @@ struct input_absinfo { | ||
472 | 474 | #define KEY_DIGITS 0x19d |
473 | 475 | #define KEY_TEEN 0x19e |
474 | 476 | #define KEY_TWEN 0x19f |
475 | - | |
477 | +#define KEY_VIDEOPHONE 0x1a0 | |
478 | +#define KEY_GAMES 0x1a1 | |
479 | +#define KEY_ZOOMIN 0x1a2 | |
480 | +#define KEY_ZOOMOUT 0x1a3 | |
481 | +#define KEY_ZOOMRESET 0x1a4 | |
482 | +#define KEY_WORDPROCESSOR 0x1a5 | |
483 | +#define KEY_EDITOR 0x1a6 | |
484 | +#define KEY_SPREADSHEET 0x1a7 | |
485 | +#define KEY_GRAPHICSEDITOR 0x1a8 | |
486 | +#define KEY_PRESENTATION 0x1a9 | |
487 | +#define KEY_DATABASE 0x1aa | |
488 | +#define KEY_NEWS 0x1ab | |
489 | +#define KEY_VOICEMAIL 0x1ac | |
490 | +#define KEY_ADDRESSBOOK 0x1ad | |
491 | +#define KEY_MESSENGER 0x1ae | |
492 | +#define KEY_DISPLAYTOGGLE 0x1af | |
493 | +#define KEY_SPELLCHECK 0x1b0 | |
494 | +#define KEY_LOGOFF 0x1b1 | |
495 | +#define KEY_DOLLAR 0x1b2 | |
496 | +#define KEY_EURO 0x1b3 | |
497 | +#define KEY_FRAMEBACK 0x1b4 | |
498 | +#define KEY_FRAMEFORWARD 0x1b5 | |
499 | +#define KEY_CONTEXT_MENU 0x1b6 | |
500 | +#define KEY_MEDIA_REPEAT 0x1b7 | |
501 | +#define KEY_10CHANNELSUP 0x1b8 | |
502 | +#define KEY_10CHANNELSDOWN 0x1b9 | |
503 | +#define KEY_IMAGES 0x1ba | |
476 | 504 | #define KEY_DEL_EOL 0x1c0 |
477 | 505 | #define KEY_DEL_EOS 0x1c1 |
478 | 506 | #define KEY_INS_LINE 0x1c2 |
479 | 507 | #define KEY_DEL_LINE 0x1c3 |
480 | - | |
481 | 508 | #define KEY_FN 0x1d0 |
482 | 509 | #define KEY_FN_ESC 0x1d1 |
483 | 510 | #define KEY_FN_F1 0x1d2 |
@@ -499,7 +526,6 @@ struct input_absinfo { | ||
499 | 526 | #define KEY_FN_F 0x1e2 |
500 | 527 | #define KEY_FN_S 0x1e3 |
501 | 528 | #define KEY_FN_B 0x1e4 |
502 | - | |
503 | 529 | #define KEY_BRL_DOT1 0x1f1 |
504 | 530 | #define KEY_BRL_DOT2 0x1f2 |
505 | 531 | #define KEY_BRL_DOT3 0x1f3 |
@@ -508,10 +534,75 @@ struct input_absinfo { | ||
508 | 534 | #define KEY_BRL_DOT6 0x1f6 |
509 | 535 | #define KEY_BRL_DOT7 0x1f7 |
510 | 536 | #define KEY_BRL_DOT8 0x1f8 |
511 | - | |
537 | +#define KEY_BRL_DOT9 0x1f9 | |
538 | +#define KEY_BRL_DOT10 0x1fa | |
539 | +#define KEY_NUMERIC_0 0x200 | |
540 | +#define KEY_NUMERIC_1 0x201 | |
541 | +#define KEY_NUMERIC_2 0x202 | |
542 | +#define KEY_NUMERIC_3 0x203 | |
543 | +#define KEY_NUMERIC_4 0x204 | |
544 | +#define KEY_NUMERIC_5 0x205 | |
545 | +#define KEY_NUMERIC_6 0x206 | |
546 | +#define KEY_NUMERIC_7 0x207 | |
547 | +#define KEY_NUMERIC_8 0x208 | |
548 | +#define KEY_NUMERIC_9 0x209 | |
549 | +#define KEY_NUMERIC_STAR 0x20a | |
550 | +#define KEY_NUMERIC_POUND 0x20b | |
551 | +#define KEY_CAMERA_FOCUS 0x210 | |
552 | +#define KEY_WPS_BUTTON 0x211 | |
553 | +#define KEY_TOUCHPAD_TOGGLE 0x212 | |
554 | +#define KEY_TOUCHPAD_ON 0x213 | |
555 | +#define KEY_TOUCHPAD_OFF 0x214 | |
556 | +#define KEY_CAMERA_ZOOMIN 0x215 | |
557 | +#define KEY_CAMERA_ZOOMOUT 0x216 | |
558 | +#define KEY_CAMERA_UP 0x217 | |
559 | +#define KEY_CAMERA_DOWN 0x218 | |
560 | +#define KEY_CAMERA_LEFT 0x219 | |
561 | +#define KEY_CAMERA_RIGHT 0x21a | |
562 | +#define BTN_TRIGGER_HAPPY 0x2c0 | |
563 | +#define BTN_TRIGGER_HAPPY1 0x2c0 | |
564 | +#define BTN_TRIGGER_HAPPY2 0x2c1 | |
565 | +#define BTN_TRIGGER_HAPPY3 0x2c2 | |
566 | +#define BTN_TRIGGER_HAPPY4 0x2c3 | |
567 | +#define BTN_TRIGGER_HAPPY5 0x2c4 | |
568 | +#define BTN_TRIGGER_HAPPY6 0x2c5 | |
569 | +#define BTN_TRIGGER_HAPPY7 0x2c6 | |
570 | +#define BTN_TRIGGER_HAPPY8 0x2c7 | |
571 | +#define BTN_TRIGGER_HAPPY9 0x2c8 | |
572 | +#define BTN_TRIGGER_HAPPY10 0x2c9 | |
573 | +#define BTN_TRIGGER_HAPPY11 0x2ca | |
574 | +#define BTN_TRIGGER_HAPPY12 0x2cb | |
575 | +#define BTN_TRIGGER_HAPPY13 0x2cc | |
576 | +#define BTN_TRIGGER_HAPPY14 0x2cd | |
577 | +#define BTN_TRIGGER_HAPPY15 0x2ce | |
578 | +#define BTN_TRIGGER_HAPPY16 0x2cf | |
579 | +#define BTN_TRIGGER_HAPPY17 0x2d0 | |
580 | +#define BTN_TRIGGER_HAPPY18 0x2d1 | |
581 | +#define BTN_TRIGGER_HAPPY19 0x2d2 | |
582 | +#define BTN_TRIGGER_HAPPY20 0x2d3 | |
583 | +#define BTN_TRIGGER_HAPPY21 0x2d4 | |
584 | +#define BTN_TRIGGER_HAPPY22 0x2d5 | |
585 | +#define BTN_TRIGGER_HAPPY23 0x2d6 | |
586 | +#define BTN_TRIGGER_HAPPY24 0x2d7 | |
587 | +#define BTN_TRIGGER_HAPPY25 0x2d8 | |
588 | +#define BTN_TRIGGER_HAPPY26 0x2d9 | |
589 | +#define BTN_TRIGGER_HAPPY27 0x2da | |
590 | +#define BTN_TRIGGER_HAPPY28 0x2db | |
591 | +#define BTN_TRIGGER_HAPPY29 0x2dc | |
592 | +#define BTN_TRIGGER_HAPPY30 0x2dd | |
593 | +#define BTN_TRIGGER_HAPPY31 0x2de | |
594 | +#define BTN_TRIGGER_HAPPY32 0x2df | |
595 | +#define BTN_TRIGGER_HAPPY33 0x2e0 | |
596 | +#define BTN_TRIGGER_HAPPY34 0x2e1 | |
597 | +#define BTN_TRIGGER_HAPPY35 0x2e2 | |
598 | +#define BTN_TRIGGER_HAPPY36 0x2e3 | |
599 | +#define BTN_TRIGGER_HAPPY37 0x2e4 | |
600 | +#define BTN_TRIGGER_HAPPY38 0x2e5 | |
601 | +#define BTN_TRIGGER_HAPPY39 0x2e6 | |
602 | +#define BTN_TRIGGER_HAPPY40 0x2e7 | |
512 | 603 | #define KEY_MIN_INTERESTING KEY_MUTE |
513 | -#define KEY_MAX 0x1ff | |
514 | - | |
604 | +#define KEY_MAX 0x2ff | |
605 | +#define KEY_CNT (KEY_MAX+1) | |
515 | 606 | #define REL_X 0x00 |
516 | 607 | #define REL_Y 0x01 |
517 | 608 | #define REL_Z 0x02 |
@@ -523,7 +614,7 @@ struct input_absinfo { | ||
523 | 614 | #define REL_WHEEL 0x08 |
524 | 615 | #define REL_MISC 0x09 |
525 | 616 | #define REL_MAX 0x0f |
526 | - | |
617 | +#define REL_CNT (REL_MAX+1) | |
527 | 618 | #define ABS_X 0x00 |
528 | 619 | #define ABS_Y 0x01 |
529 | 620 | #define ABS_Z 0x02 |
@@ -550,20 +641,44 @@ struct input_absinfo { | ||
550 | 641 | #define ABS_TOOL_WIDTH 0x1c |
551 | 642 | #define ABS_VOLUME 0x20 |
552 | 643 | #define ABS_MISC 0x28 |
644 | +#define ABS_MT_SLOT 0x2f | |
645 | +#define ABS_MT_TOUCH_MAJOR 0x30 | |
646 | +#define ABS_MT_TOUCH_MINOR 0x31 | |
647 | +#define ABS_MT_WIDTH_MAJOR 0x32 | |
648 | +#define ABS_MT_WIDTH_MINOR 0x33 | |
649 | +#define ABS_MT_ORIENTATION 0x34 | |
650 | +#define ABS_MT_POSITION_X 0x35 | |
651 | +#define ABS_MT_POSITION_Y 0x36 | |
652 | +#define ABS_MT_TOOL_TYPE 0x37 | |
653 | +#define ABS_MT_BLOB_ID 0x38 | |
654 | +#define ABS_MT_TRACKING_ID 0x39 | |
655 | +#define ABS_MT_PRESSURE 0x3a | |
656 | +#define ABS_MT_DISTANCE 0x3b | |
553 | 657 | #define ABS_MAX 0x3f |
554 | - | |
555 | -#define SW_LID 0x00 | |
556 | -#define SW_TABLET_MODE 0x01 | |
557 | -#define SW_HEADPHONE_INSERT 0x02 | |
658 | +#define ABS_CNT (ABS_MAX+1) | |
659 | +#define SW_LID 0x00 | |
660 | +#define SW_TABLET_MODE 0x01 | |
661 | +#define SW_HEADPHONE_INSERT 0x02 | |
662 | +#define SW_RFKILL_ALL 0x03 | |
663 | +#define SW_RADIO SW_RFKILL_ALL | |
664 | +#define SW_MICROPHONE_INSERT 0x04 | |
665 | +#define SW_DOCK 0x05 | |
666 | +#define SW_LINEOUT_INSERT 0x06 | |
667 | +#define SW_JACK_PHYSICAL_INSERT 0x07 | |
668 | +#define SW_VIDEOOUT_INSERT 0x08 | |
669 | +#define SW_CAMERA_LENS_COVER 0x09 | |
670 | +#define SW_KEYPAD_SLIDE 0x0a | |
671 | +#define SW_FRONT_PROXIMITY 0x0b | |
672 | +#define SW_ROTATE_LOCK 0x0c | |
558 | 673 | #define SW_MAX 0x0f |
559 | - | |
674 | +#define SW_CNT (SW_MAX+1) | |
560 | 675 | #define MSC_SERIAL 0x00 |
561 | 676 | #define MSC_PULSELED 0x01 |
562 | 677 | #define MSC_GESTURE 0x02 |
563 | 678 | #define MSC_RAW 0x03 |
564 | 679 | #define MSC_SCAN 0x04 |
565 | 680 | #define MSC_MAX 0x07 |
566 | - | |
681 | +#define MSC_CNT (MSC_MAX+1) | |
567 | 682 | #define LED_NUML 0x00 |
568 | 683 | #define LED_CAPSL 0x01 |
569 | 684 | #define LED_SCROLLL 0x02 |
@@ -576,27 +691,26 @@ struct input_absinfo { | ||
576 | 691 | #define LED_MAIL 0x09 |
577 | 692 | #define LED_CHARGING 0x0a |
578 | 693 | #define LED_MAX 0x0f |
579 | - | |
694 | +#define LED_CNT (LED_MAX+1) | |
580 | 695 | #define REP_DELAY 0x00 |
581 | 696 | #define REP_PERIOD 0x01 |
582 | 697 | #define REP_MAX 0x01 |
583 | - | |
698 | +#define REP_CNT (REP_MAX+1) | |
584 | 699 | #define SND_CLICK 0x00 |
585 | 700 | #define SND_BELL 0x01 |
586 | 701 | #define SND_TONE 0x02 |
587 | 702 | #define SND_MAX 0x07 |
588 | - | |
703 | +#define SND_CNT (SND_MAX+1) | |
589 | 704 | #define ID_BUS 0 |
590 | 705 | #define ID_VENDOR 1 |
591 | 706 | #define ID_PRODUCT 2 |
592 | 707 | #define ID_VERSION 3 |
593 | - | |
594 | 708 | #define BUS_PCI 0x01 |
595 | 709 | #define BUS_ISAPNP 0x02 |
596 | 710 | #define BUS_USB 0x03 |
597 | 711 | #define BUS_HIL 0x04 |
598 | 712 | #define BUS_BLUETOOTH 0x05 |
599 | - | |
713 | +#define BUS_VIRTUAL 0x06 | |
600 | 714 | #define BUS_ISA 0x10 |
601 | 715 | #define BUS_I8042 0x11 |
602 | 716 | #define BUS_XTKBD 0x12 |
@@ -608,80 +722,65 @@ struct input_absinfo { | ||
608 | 722 | #define BUS_I2C 0x18 |
609 | 723 | #define BUS_HOST 0x19 |
610 | 724 | #define BUS_GSC 0x1A |
611 | - | |
725 | +#define BUS_ATARI 0x1B | |
726 | +#define BUS_SPI 0x1C | |
727 | +#define MT_TOOL_FINGER 0 | |
728 | +#define MT_TOOL_PEN 1 | |
729 | +#define MT_TOOL_MAX 1 | |
612 | 730 | #define FF_STATUS_STOPPED 0x00 |
613 | 731 | #define FF_STATUS_PLAYING 0x01 |
614 | 732 | #define FF_STATUS_MAX 0x01 |
615 | - | |
616 | 733 | struct ff_replay { |
617 | 734 | __u16 length; |
618 | 735 | __u16 delay; |
619 | 736 | }; |
620 | - | |
621 | 737 | struct ff_trigger { |
622 | 738 | __u16 button; |
623 | 739 | __u16 interval; |
624 | 740 | }; |
625 | - | |
626 | 741 | struct ff_envelope { |
627 | 742 | __u16 attack_length; |
628 | 743 | __u16 attack_level; |
629 | 744 | __u16 fade_length; |
630 | 745 | __u16 fade_level; |
631 | 746 | }; |
632 | - | |
633 | 747 | struct ff_constant_effect { |
634 | 748 | __s16 level; |
635 | 749 | struct ff_envelope envelope; |
636 | 750 | }; |
637 | - | |
638 | 751 | struct ff_ramp_effect { |
639 | 752 | __s16 start_level; |
640 | 753 | __s16 end_level; |
641 | 754 | struct ff_envelope envelope; |
642 | 755 | }; |
643 | - | |
644 | 756 | struct ff_condition_effect { |
645 | 757 | __u16 right_saturation; |
646 | 758 | __u16 left_saturation; |
647 | - | |
648 | 759 | __s16 right_coeff; |
649 | 760 | __s16 left_coeff; |
650 | - | |
651 | 761 | __u16 deadband; |
652 | 762 | __s16 center; |
653 | - | |
654 | 763 | }; |
655 | - | |
656 | 764 | struct ff_periodic_effect { |
657 | 765 | __u16 waveform; |
658 | 766 | __u16 period; |
659 | 767 | __s16 magnitude; |
660 | 768 | __s16 offset; |
661 | 769 | __u16 phase; |
662 | - | |
663 | 770 | struct ff_envelope envelope; |
664 | - | |
665 | 771 | __u32 custom_len; |
666 | 772 | __s16 *custom_data; |
667 | - | |
668 | 773 | }; |
669 | - | |
670 | 774 | struct ff_rumble_effect { |
671 | 775 | __u16 strong_magnitude; |
672 | 776 | __u16 weak_magnitude; |
673 | 777 | }; |
674 | - | |
675 | 778 | struct ff_effect { |
676 | 779 | __u16 type; |
677 | - | |
678 | 780 | __s16 id; |
679 | - | |
680 | 781 | __u16 direction; |
681 | - | |
682 | 782 | struct ff_trigger trigger; |
683 | 783 | struct ff_replay replay; |
684 | - | |
685 | 784 | union { |
686 | 785 | struct ff_constant_effect constant; |
687 | 786 | struct ff_ramp_effect ramp; |
@@ -690,7 +789,6 @@ struct ff_effect { | ||
690 | 789 | struct ff_rumble_effect rumble; |
691 | 790 | } u; |
692 | 791 | }; |
693 | - | |
694 | 792 | #define FF_RUMBLE 0x50 |
695 | 793 | #define FF_PERIODIC 0x51 |
696 | 794 | #define FF_CONSTANT 0x52 |
@@ -699,17 +797,19 @@ struct ff_effect { | ||
699 | 797 | #define FF_DAMPER 0x55 |
700 | 798 | #define FF_INERTIA 0x56 |
701 | 799 | #define FF_RAMP 0x57 |
702 | - | |
800 | +#define FF_EFFECT_MIN FF_RUMBLE | |
801 | +#define FF_EFFECT_MAX FF_RAMP | |
703 | 802 | #define FF_SQUARE 0x58 |
704 | 803 | #define FF_TRIANGLE 0x59 |
705 | 804 | #define FF_SINE 0x5a |
706 | 805 | #define FF_SAW_UP 0x5b |
707 | 806 | #define FF_SAW_DOWN 0x5c |
708 | 807 | #define FF_CUSTOM 0x5d |
709 | - | |
808 | +#define FF_WAVEFORM_MIN FF_SQUARE | |
809 | +#define FF_WAVEFORM_MAX FF_CUSTOM | |
710 | 810 | #define FF_GAIN 0x60 |
711 | 811 | #define FF_AUTOCENTER 0x61 |
712 | - | |
713 | 812 | #define FF_MAX 0x7f |
714 | - | |
813 | +#define FF_CNT (FF_MAX+1) | |
715 | 814 | #endif |
815 | + |