Add qemu 2.4.0
[kvmfornfv.git] / qemu / roms / SLOF / lib / libusb / usb-key.h
1 #ifndef _USB_KEYB_H
2 #define _USB_KEYB_H
3
4 /*****************************************************************************
5  * Copyright (c) 2013 IBM Corporation
6  * All rights reserved.
7  * This program and the accompanying materials
8  * are made available under the terms of the BSD License
9  * which accompanies this distribution, and is available at
10  * http://www.opensource.org/licenses/bsd-license.php
11  *
12  * Contributors:
13  *     IBM Corporation - initial implementation
14  *****************************************************************************/
15
16 #define BIT_0           1
17 #define BIT_1           (BIT_0 << 1)
18 #define BIT_2           (BIT_0 << 2)
19 #define BIT_3           (BIT_0 << 3)
20 #define BIT_4           (BIT_0 << 4)
21 #define BIT_5           (BIT_0 << 5)
22 #define BIT_6           (BIT_0 << 6)
23 #define BIT_7           (BIT_0 << 7)
24
25 /* bits from modifier input */
26 #define MODIFIER_CTRL   (BIT_0 | BIT_4)
27 #define MODIFIER_SHIFT  (BIT_1 | BIT_5)
28 #define MODIFIER_ALT    (BIT_2 | BIT_6)
29 #define MODIFIER_GUI    (BIT_3 | BIT_7)
30 #define MODIFIER_ALT_GR BIT_6
31
32 /* bits representing Keyboard-LEDs */
33 #define LED_NUM_LOCK    BIT_0
34 #define LED_CAPS_LOCK   BIT_1
35 #define LED_SCROLL_LOCK BIT_2
36
37 extern const uint8_t keycodes_std_US[];
38 extern const uint8_t keycodes_shift_US[];
39 extern const uint8_t keycodes_alt_GR[];
40 extern const uint8_t keycodes_ctrl[];
41
42 #endif