Rev 2 | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
2 | pj | 1 | #include <ll/i386/hw-data.h> |
2 | #include "linuxpci.h" |
||
3 | |||
4 | /***************************************************************************/ |
||
5 | /* This is from Linux!!! */ |
||
6 | /***************************************************************************/ |
||
7 | const char *pci_strclass (unsigned int class) |
||
8 | { |
||
9 | switch (class >> 8) { |
||
10 | case PCI_CLASS_NOT_DEFINED: return "Non-VGA device"; |
||
11 | case PCI_CLASS_NOT_DEFINED_VGA: return "VGA compatible device"; |
||
12 | |||
13 | case PCI_CLASS_STORAGE_SCSI: return "SCSI storage controller"; |
||
14 | case PCI_CLASS_STORAGE_IDE: return "IDE interface"; |
||
15 | case PCI_CLASS_STORAGE_FLOPPY: return "Floppy disk controller"; |
||
16 | case PCI_CLASS_STORAGE_IPI: return "IPI bus controller"; |
||
17 | case PCI_CLASS_STORAGE_RAID: return "RAID bus controller"; |
||
18 | case PCI_CLASS_STORAGE_OTHER: return "Unknown mass storage controller"; |
||
19 | |||
20 | case PCI_CLASS_NETWORK_ETHERNET: return "Ethernet controller"; |
||
21 | case PCI_CLASS_NETWORK_TOKEN_RING: return "Token ring network controller"; |
||
22 | case PCI_CLASS_NETWORK_FDDI: return "FDDI network controller"; |
||
23 | case PCI_CLASS_NETWORK_ATM: return "ATM network controller"; |
||
24 | case PCI_CLASS_NETWORK_OTHER: return "Network controller"; |
||
25 | |||
26 | case PCI_CLASS_DISPLAY_VGA: return "VGA compatible controller"; |
||
27 | case PCI_CLASS_DISPLAY_XGA: return "XGA compatible controller"; |
||
28 | case PCI_CLASS_DISPLAY_OTHER: return "Display controller"; |
||
29 | |||
30 | case PCI_CLASS_MULTIMEDIA_VIDEO: return "Multimedia video controller"; |
||
31 | case PCI_CLASS_MULTIMEDIA_AUDIO: return "Multimedia audio controller"; |
||
32 | case PCI_CLASS_MULTIMEDIA_OTHER: return "Multimedia controller"; |
||
33 | |||
34 | case PCI_CLASS_MEMORY_RAM: return "RAM memory"; |
||
35 | case PCI_CLASS_MEMORY_FLASH: return "FLASH memory"; |
||
36 | case PCI_CLASS_MEMORY_OTHER: return "Memory"; |
||
37 | |||
38 | case PCI_CLASS_BRIDGE_HOST: return "Host bridge"; |
||
39 | case PCI_CLASS_BRIDGE_ISA: return "ISA bridge"; |
||
40 | case PCI_CLASS_BRIDGE_EISA: return "EISA bridge"; |
||
41 | case PCI_CLASS_BRIDGE_MC: return "MicroChannel bridge"; |
||
42 | case PCI_CLASS_BRIDGE_PCI: return "PCI bridge"; |
||
43 | case PCI_CLASS_BRIDGE_PCMCIA: return "PCMCIA bridge"; |
||
44 | case PCI_CLASS_BRIDGE_NUBUS: return "NuBus bridge"; |
||
45 | case PCI_CLASS_BRIDGE_CARDBUS: return "CardBus bridge"; |
||
46 | case PCI_CLASS_BRIDGE_OTHER: return "Bridge"; |
||
47 | |||
48 | case PCI_CLASS_COMMUNICATION_SERIAL: return "Serial controller"; |
||
49 | case PCI_CLASS_COMMUNICATION_PARALLEL: return "Parallel controller"; |
||
50 | case PCI_CLASS_COMMUNICATION_OTHER: return "Communication controller"; |
||
51 | |||
52 | case PCI_CLASS_SYSTEM_PIC: return "PIC"; |
||
53 | case PCI_CLASS_SYSTEM_DMA: return "DMA controller"; |
||
54 | case PCI_CLASS_SYSTEM_TIMER: return "Timer"; |
||
55 | case PCI_CLASS_SYSTEM_RTC: return "RTC"; |
||
56 | case PCI_CLASS_SYSTEM_OTHER: return "System peripheral"; |
||
57 | |||
58 | case PCI_CLASS_INPUT_KEYBOARD: return "Keyboard controller"; |
||
59 | case PCI_CLASS_INPUT_PEN: return "Digitizer Pen"; |
||
60 | case PCI_CLASS_INPUT_MOUSE: return "Mouse controller"; |
||
61 | case PCI_CLASS_INPUT_OTHER: return "Input device controller"; |
||
62 | |||
63 | case PCI_CLASS_DOCKING_GENERIC: return "Generic Docking Station"; |
||
64 | case PCI_CLASS_DOCKING_OTHER: return "Docking Station"; |
||
65 | |||
66 | case PCI_CLASS_PROCESSOR_386: return "386"; |
||
67 | case PCI_CLASS_PROCESSOR_486: return "486"; |
||
68 | case PCI_CLASS_PROCESSOR_PENTIUM: return "Pentium"; |
||
69 | case PCI_CLASS_PROCESSOR_ALPHA: return "Alpha"; |
||
70 | case PCI_CLASS_PROCESSOR_POWERPC: return "Power PC"; |
||
71 | case PCI_CLASS_PROCESSOR_CO: return "Co-processor"; |
||
72 | |||
73 | case PCI_CLASS_SERIAL_FIREWIRE: return "FireWire (IEEE 1394)"; |
||
74 | case PCI_CLASS_SERIAL_ACCESS: return "ACCESS Bus"; |
||
75 | case PCI_CLASS_SERIAL_SSA: return "SSA"; |
||
76 | case PCI_CLASS_SERIAL_USB: return "USB Controller"; |
||
77 | case PCI_CLASS_SERIAL_FIBER: return "Fiber Channel"; |
||
78 | |||
79 | default: return "Unknown class"; |
||
80 | } |
||
81 | } |
||
82 | |||
83 | |||
84 | const char *pci_strvendor(unsigned int vendor) |
||
85 | { |
||
86 | switch (vendor) { |
||
87 | case PCI_VENDOR_ID_COMPAQ: return "Compaq"; |
||
88 | case PCI_VENDOR_ID_NCR: return "NCR"; |
||
89 | case PCI_VENDOR_ID_ATI: return "ATI"; |
||
90 | case PCI_VENDOR_ID_VLSI: return "VLSI"; |
||
91 | case PCI_VENDOR_ID_ADL: return "Advance Logic"; |
||
92 | case PCI_VENDOR_ID_NS: return "NS"; |
||
93 | case PCI_VENDOR_ID_TSENG: return "Tseng'Lab"; |
||
94 | case PCI_VENDOR_ID_WEITEK: return "Weitek"; |
||
95 | case PCI_VENDOR_ID_DEC: return "DEC"; |
||
96 | case PCI_VENDOR_ID_CIRRUS: return "Cirrus Logic"; |
||
97 | case PCI_VENDOR_ID_IBM: return "IBM"; |
||
98 | case PCI_VENDOR_ID_WD: return "Western Digital"; |
||
99 | case PCI_VENDOR_ID_AMD: return "AMD"; |
||
100 | case PCI_VENDOR_ID_TRIDENT: return "Trident"; |
||
101 | case PCI_VENDOR_ID_AI: return "Acer Incorporated"; |
||
102 | case PCI_VENDOR_ID_MATROX: return "Matrox"; |
||
103 | case PCI_VENDOR_ID_CT: return "Chips & Technologies"; |
||
104 | case PCI_VENDOR_ID_MIRO: return "Miro"; |
||
105 | case PCI_VENDOR_ID_FD: return "Future Domain"; |
||
106 | case PCI_VENDOR_ID_SI: return "Silicon Integrated Systems"; |
||
107 | case PCI_VENDOR_ID_HP: return "Hewlett Packard"; |
||
108 | case PCI_VENDOR_ID_PCTECH: return "PCTECH"; |
||
109 | case PCI_VENDOR_ID_DPT: return "DPT"; |
||
110 | case PCI_VENDOR_ID_OPTI: return "OPTI"; |
||
111 | case PCI_VENDOR_ID_SGS: return "SGS Thomson"; |
||
112 | case PCI_VENDOR_ID_BUSLOGIC: return "BusLogic"; |
||
113 | case PCI_VENDOR_ID_OAK: return "OAK"; |
||
114 | case PCI_VENDOR_ID_PROMISE: return "Promise Technology"; |
||
115 | case PCI_VENDOR_ID_N9: return "Number Nine"; |
||
116 | case PCI_VENDOR_ID_UMC: return "UMC"; |
||
117 | case PCI_VENDOR_ID_X: return "X TECHNOLOGY"; |
||
118 | case PCI_VENDOR_ID_NEXGEN: return "Nexgen"; |
||
119 | case PCI_VENDOR_ID_QLOGIC: return "Q Logic"; |
||
120 | case PCI_VENDOR_ID_LEADTEK: return "Leadtek Research"; |
||
121 | case PCI_VENDOR_ID_CONTAQ: return "Contaq"; |
||
122 | case PCI_VENDOR_ID_FOREX: return "Forex"; |
||
123 | case PCI_VENDOR_ID_OLICOM: return "Olicom"; |
||
124 | case PCI_VENDOR_ID_CMD: return "CMD"; |
||
125 | case PCI_VENDOR_ID_VISION: return "Vision"; |
||
126 | case PCI_VENDOR_ID_SIERRA: return "Sierra"; |
||
127 | case PCI_VENDOR_ID_ACC: return "ACC MICROELECTRONICS"; |
||
128 | case PCI_VENDOR_ID_WINBOND: return "Winbond"; |
||
129 | case PCI_VENDOR_ID_3COM: return "3Com"; |
||
130 | case PCI_VENDOR_ID_AL: return "Acer Labs"; |
||
131 | case PCI_VENDOR_ID_ASP: return "Advanced System Products"; |
||
132 | case PCI_VENDOR_ID_CERN: return "CERN"; |
||
133 | case PCI_VENDOR_ID_IMS: return "IMS"; |
||
134 | case PCI_VENDOR_ID_TEKRAM2: return "Tekram"; |
||
135 | case PCI_VENDOR_ID_AMCC: return "AMCC"; |
||
136 | case PCI_VENDOR_ID_INTERG: return "Intergraphics"; |
||
137 | case PCI_VENDOR_ID_REALTEK: return "Realtek"; |
||
138 | case PCI_VENDOR_ID_INIT: return "Initio Corp"; |
||
139 | case PCI_VENDOR_ID_VIA: return "VIA Technologies"; |
||
140 | case PCI_VENDOR_ID_VORTEX: return "VORTEX"; |
||
141 | case PCI_VENDOR_ID_EF: return "Efficient Networks"; |
||
142 | case PCI_VENDOR_ID_FORE: return "Fore Systems"; |
||
143 | case PCI_VENDOR_ID_IMAGINGTECH: return "Imaging Technology"; |
||
144 | case PCI_VENDOR_ID_PLX: return "PLX"; |
||
145 | case PCI_VENDOR_ID_ALLIANCE: return "Alliance"; |
||
146 | case PCI_VENDOR_ID_VMIC: return "VMIC"; |
||
147 | case PCI_VENDOR_ID_DIGI: return "Digi Intl."; |
||
148 | case PCI_VENDOR_ID_MUTECH: return "Mutech"; |
||
149 | case PCI_VENDOR_ID_TOSHIBA: return "Toshiba"; |
||
150 | case PCI_VENDOR_ID_ZEITNET: return "ZeitNet"; |
||
151 | case PCI_VENDOR_ID_SPECIALIX: return "Specialix"; |
||
152 | case PCI_VENDOR_ID_RP: return "Comtrol"; |
||
153 | case PCI_VENDOR_ID_CYCLADES: return "Cyclades"; |
||
154 | case PCI_VENDOR_ID_SYMPHONY: return "Symphony"; |
||
155 | case PCI_VENDOR_ID_TEKRAM: return "Tekram"; |
||
156 | case PCI_VENDOR_ID_3DLABS: return "3Dlabs"; |
||
157 | case PCI_VENDOR_ID_AVANCE: return "Avance"; |
||
158 | case PCI_VENDOR_ID_S3: return "S3 Inc."; |
||
159 | case PCI_VENDOR_ID_INTEL: return "Intel"; |
||
160 | case PCI_VENDOR_ID_ADAPTEC: return "Adaptec"; |
||
161 | case PCI_VENDOR_ID_ATRONICS: return "Atronics"; |
||
162 | case PCI_VENDOR_ID_HER: return "Hercules"; |
||
163 | default: return "Unknown vendor"; |
||
164 | } |
||
165 | } |
||
166 | |||
167 | /***************************************************************************/ |
||
168 | |||
169 |