1 #ifndef LINUX_PNP_RESOURCE
2 #define LINUX_PNP_RESOURCE
4 /* ISA Plug and Play Resource Definitions */
6 #define PNP_RES_LARGE_ITEM 0x80
8 /* Small resource items */
9 #define PNP_RES_SMTAG_VERSION 0x01
10 #define PNP_RES_SMTAG_LDID 0x02
11 #define PNP_RES_SMTAG_CDID 0x03
12 #define PNP_RES_SMTAG_IRQ 0x04
13 #define PNP_RES_SMTAG_DMA 0x05
14 #define PNP_RES_SMTAG_DEP_START 0x06
15 #define PNP_RES_SMTAG_DEP_END 0x07
16 #define PNP_RES_SMTAG_IO 0x08
17 #define PNP_RES_SMTAG_IO_FIXED 0x09
18 #define PNP_RES_SMTAG_VENDOR 0x0e
19 #define PNP_RES_SMTAG_END 0x0f
21 /* Large resource items */
22 #define PNP_RES_LGTAG_MEM 0x01
23 #define PNP_RES_LGTAG_ID_ANSI 0x02
24 #define PNP_RES_LGTAG_ID_UNICODE 0x03
25 #define PNP_RES_LGTAG_VENDOR 0x04
26 #define PNP_RES_LGTAG_MEM32 0x05
27 #define PNP_RES_LGTAG_MEM32_FIXED 0x06
29 /* Logical device ID flags */
30 #define PNP_RES_LDID_BOOT 0x01
33 #define PNP_RES_IRQ_HIGH_EDGE 0x01
34 #define PNP_RES_IRQ_LOW_EDGE 0x02
35 #define PNP_RES_IRQ_HIGH_LEVEL 0x04
36 #define PNP_RES_IRQ_LOW_LEVEL 0x08
39 #define PNP_RES_DMA_WIDTH_MASK 0x03
40 #define PNP_RES_DMA_WIDTH_8 0x00
41 #define PNP_RES_DMA_WIDTH_8_16 0x01
42 #define PNP_RES_DMA_WIDTH_16 0x02
43 #define PNP_RES_DMA_BUSMASTER 0x04
44 #define PNP_RES_DMA_COUNT_BYTE 0x08
45 #define PNP_RES_DMA_COUNT_WORD 0x10
46 #define PNP_RES_DMA_SPEED_MASK 0x60
47 #define PNP_RES_DMA_SPEED_COMPAT 0x00
48 #define PNP_RES_DMA_SPEED_TYPEA 0x20
49 #define PNP_RES_DMA_SPEED_TYPEB 0x40
50 #define PNP_RES_DMA_SPEED_TYPEF 0x60
52 /* Resource group priority */
53 #define PNP_RES_CONFIG_GOOD 0x00
54 #define PNP_RES_CONFIG_ACCEPTABLE 0x01
55 #define PNP_RES_CONFIG_SUBOPTIMAL 0x02
58 #define PNP_RES_IO_DECODE_16 0x01
60 /* Memory information */
61 #define PNP_RES_MEM_WRITEABLE 0x01
62 #define PNP_RES_MEM_CACHEABLE 0x02
63 #define PNP_RES_MEM_HIGH_ADDRESS 0x04
64 #define PNP_RES_MEM_WIDTH_MASK 0x18
65 #define PNP_RES_MEM_WIDTH_8 0x00
66 #define PNP_RES_MEM_WIDTH_16 0x08
67 #define PNP_RES_MEM_WIDTH_8_16 0x10
68 #define PNP_RES_MEM_WIDTH_32 0x18
69 #define PNP_RES_MEM_SHADOWABLE 0x20
70 #define PNP_RES_MEM_EXPANSION_ROM 0x40
73 note: multi-byte data types in these structures are little endian,
74 and have to be byte swapped before use on big endian platforms.
78 union pnp_small_resource {
113 union pnp_large_resource {
116 __u16 min, max, align, len;
127 __u32 min, max, align, len;
138 union pnp_small_resource d;
143 union pnp_large_resource d;
148 #endif /* LINUX_PNP_RESOURCE */