Go to most recent revision |
Blame |
Compare with Previous |
Last modification |
View Log
| RSS feed
#include <ll/i386/hw-data.h>
#include "linuxpci.h"
/***************************************************************************/
/* This is from Linux!!! */
/***************************************************************************/
const char *pci_strclass (unsigned int class)
{
switch (class >> 8) {
case PCI_CLASS_NOT_DEFINED: return "Non-VGA device";
case PCI_CLASS_NOT_DEFINED_VGA: return "VGA compatible device";
case PCI_CLASS_STORAGE_SCSI: return "SCSI storage controller";
case PCI_CLASS_STORAGE_IDE: return "IDE interface";
case PCI_CLASS_STORAGE_FLOPPY: return "Floppy disk controller";
case PCI_CLASS_STORAGE_IPI: return "IPI bus controller";
case PCI_CLASS_STORAGE_RAID: return "RAID bus controller";
case PCI_CLASS_STORAGE_OTHER: return "Unknown mass storage controller";
case PCI_CLASS_NETWORK_ETHERNET: return "Ethernet controller";
case PCI_CLASS_NETWORK_TOKEN_RING: return "Token ring network controller";
case PCI_CLASS_NETWORK_FDDI: return "FDDI network controller";
case PCI_CLASS_NETWORK_ATM: return "ATM network controller";
case PCI_CLASS_NETWORK_OTHER: return "Network controller";
case PCI_CLASS_DISPLAY_VGA: return "VGA compatible controller";
case PCI_CLASS_DISPLAY_XGA: return "XGA compatible controller";
case PCI_CLASS_DISPLAY_OTHER: return "Display controller";
case PCI_CLASS_MULTIMEDIA_VIDEO: return "Multimedia video controller";
case PCI_CLASS_MULTIMEDIA_AUDIO: return "Multimedia audio controller";
case PCI_CLASS_MULTIMEDIA_OTHER: return "Multimedia controller";
case PCI_CLASS_MEMORY_RAM: return "RAM memory";
case PCI_CLASS_MEMORY_FLASH: return "FLASH memory";
case PCI_CLASS_MEMORY_OTHER: return "Memory";
case PCI_CLASS_BRIDGE_HOST: return "Host bridge";
case PCI_CLASS_BRIDGE_ISA: return "ISA bridge";
case PCI_CLASS_BRIDGE_EISA: return "EISA bridge";
case PCI_CLASS_BRIDGE_MC: return "MicroChannel bridge";
case PCI_CLASS_BRIDGE_PCI: return "PCI bridge";
case PCI_CLASS_BRIDGE_PCMCIA: return "PCMCIA bridge";
case PCI_CLASS_BRIDGE_NUBUS: return "NuBus bridge";
case PCI_CLASS_BRIDGE_CARDBUS: return "CardBus bridge";
case PCI_CLASS_BRIDGE_OTHER: return "Bridge";
case PCI_CLASS_COMMUNICATION_SERIAL: return "Serial controller";
case PCI_CLASS_COMMUNICATION_PARALLEL: return "Parallel controller";
case PCI_CLASS_COMMUNICATION_OTHER: return "Communication controller";
case PCI_CLASS_SYSTEM_PIC: return "PIC";
case PCI_CLASS_SYSTEM_DMA: return "DMA controller";
case PCI_CLASS_SYSTEM_TIMER: return "Timer";
case PCI_CLASS_SYSTEM_RTC: return "RTC";
case PCI_CLASS_SYSTEM_OTHER: return "System peripheral";
case PCI_CLASS_INPUT_KEYBOARD: return "Keyboard controller";
case PCI_CLASS_INPUT_PEN: return "Digitizer Pen";
case PCI_CLASS_INPUT_MOUSE: return "Mouse controller";
case PCI_CLASS_INPUT_OTHER: return "Input device controller";
case PCI_CLASS_DOCKING_GENERIC: return "Generic Docking Station";
case PCI_CLASS_DOCKING_OTHER: return "Docking Station";
case PCI_CLASS_PROCESSOR_386: return "386";
case PCI_CLASS_PROCESSOR_486: return "486";
case PCI_CLASS_PROCESSOR_PENTIUM: return "Pentium";
case PCI_CLASS_PROCESSOR_ALPHA: return "Alpha";
case PCI_CLASS_PROCESSOR_POWERPC: return "Power PC";
case PCI_CLASS_PROCESSOR_CO: return "Co-processor";
case PCI_CLASS_SERIAL_FIREWIRE: return "FireWire (IEEE 1394)";
case PCI_CLASS_SERIAL_ACCESS: return "ACCESS Bus";
case PCI_CLASS_SERIAL_SSA: return "SSA";
case PCI_CLASS_SERIAL_USB: return "USB Controller";
case PCI_CLASS_SERIAL_FIBER: return "Fiber Channel";
default: return "Unknown class";
}
}
const char *pci_strvendor(unsigned int vendor)
{
switch (vendor) {
case PCI_VENDOR_ID_COMPAQ: return "Compaq";
case PCI_VENDOR_ID_NCR: return "NCR";
case PCI_VENDOR_ID_ATI: return "ATI";
case PCI_VENDOR_ID_VLSI: return "VLSI";
case PCI_VENDOR_ID_ADL: return "Advance Logic";
case PCI_VENDOR_ID_NS: return "NS";
case PCI_VENDOR_ID_TSENG: return "Tseng'Lab";
case PCI_VENDOR_ID_WEITEK: return "Weitek";
case PCI_VENDOR_ID_DEC: return "DEC";
case PCI_VENDOR_ID_CIRRUS: return "Cirrus Logic";
case PCI_VENDOR_ID_IBM: return "IBM";
case PCI_VENDOR_ID_WD: return "Western Digital";
case PCI_VENDOR_ID_AMD: return "AMD";
case PCI_VENDOR_ID_TRIDENT: return "Trident";
case PCI_VENDOR_ID_AI: return "Acer Incorporated";
case PCI_VENDOR_ID_MATROX: return "Matrox";
case PCI_VENDOR_ID_CT: return "Chips & Technologies";
case PCI_VENDOR_ID_MIRO: return "Miro";
case PCI_VENDOR_ID_FD: return "Future Domain";
case PCI_VENDOR_ID_SI: return "Silicon Integrated Systems";
case PCI_VENDOR_ID_HP: return "Hewlett Packard";
case PCI_VENDOR_ID_PCTECH: return "PCTECH";
case PCI_VENDOR_ID_DPT: return "DPT";
case PCI_VENDOR_ID_OPTI: return "OPTI";
case PCI_VENDOR_ID_SGS: return "SGS Thomson";
case PCI_VENDOR_ID_BUSLOGIC: return "BusLogic";
case PCI_VENDOR_ID_OAK: return "OAK";
case PCI_VENDOR_ID_PROMISE: return "Promise Technology";
case PCI_VENDOR_ID_N9: return "Number Nine";
case PCI_VENDOR_ID_UMC: return "UMC";
case PCI_VENDOR_ID_X: return "X TECHNOLOGY";
case PCI_VENDOR_ID_NEXGEN: return "Nexgen";
case PCI_VENDOR_ID_QLOGIC: return "Q Logic";
case PCI_VENDOR_ID_LEADTEK: return "Leadtek Research";
case PCI_VENDOR_ID_CONTAQ: return "Contaq";
case PCI_VENDOR_ID_FOREX: return "Forex";
case PCI_VENDOR_ID_OLICOM: return "Olicom";
case PCI_VENDOR_ID_CMD: return "CMD";
case PCI_VENDOR_ID_VISION: return "Vision";
case PCI_VENDOR_ID_SIERRA: return "Sierra";
case PCI_VENDOR_ID_ACC: return "ACC MICROELECTRONICS";
case PCI_VENDOR_ID_WINBOND: return "Winbond";
case PCI_VENDOR_ID_3COM: return "3Com";
case PCI_VENDOR_ID_AL: return "Acer Labs";
case PCI_VENDOR_ID_ASP: return "Advanced System Products";
case PCI_VENDOR_ID_CERN: return "CERN";
case PCI_VENDOR_ID_IMS: return "IMS";
case PCI_VENDOR_ID_TEKRAM2: return "Tekram";
case PCI_VENDOR_ID_AMCC: return "AMCC";
case PCI_VENDOR_ID_INTERG: return "Intergraphics";
case PCI_VENDOR_ID_REALTEK: return "Realtek";
case PCI_VENDOR_ID_INIT: return "Initio Corp";
case PCI_VENDOR_ID_VIA: return "VIA Technologies";
case PCI_VENDOR_ID_VORTEX: return "VORTEX";
case PCI_VENDOR_ID_EF: return "Efficient Networks";
case PCI_VENDOR_ID_FORE: return "Fore Systems";
case PCI_VENDOR_ID_IMAGINGTECH: return "Imaging Technology";
case PCI_VENDOR_ID_PLX: return "PLX";
case PCI_VENDOR_ID_ALLIANCE: return "Alliance";
case PCI_VENDOR_ID_VMIC: return "VMIC";
case PCI_VENDOR_ID_DIGI: return "Digi Intl.";
case PCI_VENDOR_ID_MUTECH: return "Mutech";
case PCI_VENDOR_ID_TOSHIBA: return "Toshiba";
case PCI_VENDOR_ID_ZEITNET: return "ZeitNet";
case PCI_VENDOR_ID_SPECIALIX: return "Specialix";
case PCI_VENDOR_ID_RP: return "Comtrol";
case PCI_VENDOR_ID_CYCLADES: return "Cyclades";
case PCI_VENDOR_ID_SYMPHONY: return "Symphony";
case PCI_VENDOR_ID_TEKRAM: return "Tekram";
case PCI_VENDOR_ID_3DLABS: return "3Dlabs";
case PCI_VENDOR_ID_AVANCE: return "Avance";
case PCI_VENDOR_ID_S3: return "S3 Inc.";
case PCI_VENDOR_ID_INTEL: return "Intel";
case PCI_VENDOR_ID_ADAPTEC: return "Adaptec";
case PCI_VENDOR_ID_ATRONICS: return "Atronics";
case PCI_VENDOR_ID_HER: return "Hercules";
default: return "Unknown vendor";
}
}
/***************************************************************************/