Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
The vexed question: skge or sky2? An answer
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
wynn
Advocate
Advocate


Joined: 01 Apr 2005
Posts: 2416
Location: UK

PostPosted: Mon Aug 21, 2006 5:15 pm    Post subject: The vexed question: skge or sky2? An answer Reply with quote

The lspci text for the ethernet controllers which skge will drive is:
Code:
3Com Corporation 3c940 10/100/1000Base-T [Marvell]
3Com Corporation 3c940B 10/100/1000Base-T
SysKonnect SK-9872 Gigabit Ethernet Server Adapter (SK-NET GE-ZX dual link)
SysKonnect SK-9871 V2.0 Gigabit Ethernet 1000Base-ZX Adapter, PCI64, Fiber ZX/SC
D-Link System Inc Gigabit Ethernet Adapter
D-Link System Inc DGE-530T Gigabit Ethernet Adapter (rev 11)
Marvell Technology Group Ltd. 88E8001 Gigabit Ethernet Controller
Marvell Technology Group Ltd. Belkin F5D5005 Gigabit Desktop Network PCI Card
CNet Technology Inc GigaCard Network Adapter
Linksys Gigabit Network Adapter
Linksys Gigabit Network Adapter

The lspci text for the ethernet controllers which sky2 will drive is:
Code:
SysKonnect SK-9S21 10/100/1000Base-T Server Adapter, PCI-X, Copper RJ-45
SysKonnect SK-9E21D 10/100/1000Base-T Adapter, Copper RJ-45
D-Link System Inc Unknown device 4b00
Marvell Technology Group Ltd. 88E8021 PCI-X IPMI Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8022 PCI-X IPMI Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8061 PCI-E IPMI Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8062 PCI-E IPMI Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8021 PCI-X IPMI Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8022 PCI-X IPMI Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8061 PCI-E IPMI Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8062 PCI-E IPMI Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8035 PCI-E Fast Ethernet Controller
Marvell Technology Group Ltd. 88E8036 PCI-E Fast Ethernet Controller
Marvell Technology Group Ltd. 88E8038 PCI-E Fast Ethernet Controller
Marvell Technology Group Ltd. 88E8052 PCI-E ASF Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8050 PCI-E ASF Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8053 PCI-E Gigabit Ethernet Controller
Marvell Technology Group Ltd. 88E8055 PCI-E Gigabit Ethernet Controller
Marvell Technology Group Ltd. Unknown device 4364

This information has been extracted from the 'struct pci_device_id' in drivers/net/skge.c and drivers/net/sky2.c in the kernel source for 2.6.17-gentoo-r5.

HOWTO:

  • Create a directory for the work.
  • Copy the table from the module source to a new file in the working directory, this is the pci table file: example
    Code:
    static const struct pci_device_id skge_id_table[] = {
            { PCI_DEVICE(PCI_VENDOR_ID_3COM, PCI_DEVICE_ID_3COM_3C940) },
            { PCI_DEVICE(PCI_VENDOR_ID_3COM, PCI_DEVICE_ID_3COM_3C940B) },
            { PCI_DEVICE(PCI_VENDOR_ID_SYSKONNECT, PCI_DEVICE_ID_SYSKONNECT_GE) },
            { PCI_DEVICE(PCI_VENDOR_ID_SYSKONNECT, PCI_DEVICE_ID_SYSKONNECT_YU) },
            { PCI_DEVICE(PCI_VENDOR_ID_DLINK, PCI_DEVICE_ID_DLINK_DGE510T), },
            { PCI_DEVICE(PCI_VENDOR_ID_DLINK, 0x4b01) },    /* DGE-530T */
            { PCI_DEVICE(PCI_VENDOR_ID_MARVELL, 0x4320) },
            { PCI_DEVICE(PCI_VENDOR_ID_MARVELL, 0x5005) }, /* Belkin */
            { PCI_DEVICE(PCI_VENDOR_ID_CNET, PCI_DEVICE_ID_CNET_GIGACARD) },
            { PCI_DEVICE(PCI_VENDOR_ID_LINKSYS, PCI_DEVICE_ID_LINKSYS_EG1064) },
            { PCI_VENDOR_ID_LINKSYS, 0x1032, PCI_ANY_ID, 0x0015, },
            { 0 }
    };

  • Copy include/linux/pci_ids.h from the kernel source to the working directory.
  • Put the line
    Code:
    #include "pci_ids.h"
    at the top of the pci table file.
  • Run the file through the C preprocessor
    Code:
    cpp <pci table file>

    and save the output.
  • Run the program pci-lookup with the output file as the only argument.

Note: you might like to update /usr/share/misc/pci.ids using /usr/sbin/update-pciids from pciutils before running pci-lookup.

The program, which uses libpci from pciutils and code from lspci, is 231 lines and seems too large for this margin, it has been put in http://pastebin.ca/142706

I hope it works for you too :)
_________________
The avatar is jorma, a "duck" from "Elephants Dream": the film and all the production materials have been made available under a Creative Commons Attribution 2.5 License, see orange.blender.org for details.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum