4 #include <linux/types.h>
7 #define VC_CATEGORY(c) (((c) >> 24) & 0x3F)
8 #define VC_COMMAND(c) (((c) >> 16) & 0xFF)
9 #define VC_VERSION(c) ((c) & 0xFFF)
11 #define VC_CMD(c, i, v) ((((VC_CAT_ ## c) & 0x3F) << 24) \
12 | (((i) & 0xFF) << 16) | ((v) & 0xFFF))
18 |VERSION|CREATE |MODIFY |MIGRATE|CONTROL|EXPERIM| |SPECIAL|SPECIAL|
19 |STATS |DESTROY|ALTER |CHANGE |LIMIT |TEST | | | |
20 |INFO |SETUP | |MOVE | | | | | |
21 -------+-------+-------+-------+-------+-------+-------+ +-------+-------+
22 SYSTEM |VERSION|VSETUP |VHOST | | | | |DEVICE | |
23 HOST | 00| 01| 02| 03| 04| 05| | 06| 07|
24 -------+-------+-------+-------+-------+-------+-------+ +-------+-------+
25 CPU | |VPROC |PROCALT|PROCMIG|PROCTRL| | |SCHED. | |
26 PROCESS| 08| 09| 10| 11| 12| 13| | 14| 15|
27 -------+-------+-------+-------+-------+-------+-------+ +-------+-------+
28 MEMORY | | | | | | | |SWAP | |
29 | 16| 17| 18| 19| 20| 21| | 22| 23|
30 -------+-------+-------+-------+-------+-------+-------+ +-------+-------+
31 NETWORK| |VNET |NETALT |NETMIG |NETCTL | | |SERIAL | |
32 | 24| 25| 26| 27| 28| 29| | 30| 31|
33 -------+-------+-------+-------+-------+-------+-------+ +-------+-------+
34 DISK | | | |TAGMIG |DLIMIT | | |INODE | |
35 VFS | 32| 33| 34| 35| 36| 37| | 38| 39|
36 -------+-------+-------+-------+-------+-------+-------+ +-------+-------+
37 OTHER |VSTAT | | | | | | |VINFO | |
38 | 40| 41| 42| 43| 44| 45| | 46| 47|
39 =======+=======+=======+=======+=======+=======+=======+ +=======+=======+
40 SPECIAL|EVENT | | | |FLAGS | | | | |
41 | 48| 49| 50| 51| 52| 53| | 54| 55|
42 -------+-------+-------+-------+-------+-------+-------+ +-------+-------+
43 SPECIAL|DEBUG | | | |RLIMIT |SYSCALL| | |COMPAT |
44 | 56| 57| 58| 59| 60|TEST 61| | 62| 63|
45 -------+-------+-------+-------+-------+-------+-------+ +-------+-------+
49 #define VC_CAT_VERSION 0
51 #define VC_CAT_VSETUP 1
52 #define VC_CAT_VHOST 2
54 #define VC_CAT_DEVICE 6
56 #define VC_CAT_VPROC 9
57 #define VC_CAT_PROCALT 10
58 #define VC_CAT_PROCMIG 11
59 #define VC_CAT_PROCTRL 12
61 #define VC_CAT_SCHED 14
63 #define VC_CAT_MEMCTRL 20
65 #define VC_CAT_VNET 25
66 #define VC_CAT_NETALT 26
67 #define VC_CAT_NETMIG 27
68 #define VC_CAT_NETCTRL 28
70 #define VC_CAT_TAGMIG 35
71 #define VC_CAT_DLIMIT 36
72 #define VC_CAT_INODE 38
74 #define VC_CAT_VSTAT 40
75 #define VC_CAT_VINFO 46
76 #define VC_CAT_EVENT 48
78 #define VC_CAT_FLAGS 52
79 #define VC_CAT_DEBUG 56
80 #define VC_CAT_RLIMIT 60
82 #define VC_CAT_SYSTEST 61
83 #define VC_CAT_COMPAT 63
87 #define VCMD_get_version VC_CMD(VERSION, 0, 0)
88 #define VCMD_get_vci VC_CMD(VERSION, 1, 0)
93 #endif /* _VX_SWITCH_H */