Vendor IDs can be found under the /proc/pci. Most modules do actually give the option of loading with a certain vendor id if they support more than one chipset. A more reliable thing you can do is check to see which card was loaded by comparing /proc/pci with /proc/asound/cards, both of which list unique characteristics that can be used to determine if a card was loaded (or if more than one was loaded, etc). Just to be clear, /proc/pci lists everything on your PCI bus. /proc/asound/cards lists all cards for which you have loaded modules. This technique could easily generalize to also checking other buses, such as USB, firewire, or CardBus. I wonder if any of the hardware detection systems use this approach (looking through proc to see what turned up)? On Sun, 2005-01-16 at 01:24 +0100, Christoph Eckert wrote: > Hi, > > > just for fun and for learning the system, I wanted to write a > small script which automatically configures any soundcards > (similar to alsaconf). > > Based on PCI, I wanted to get all vendor and card IDs and > modprobe each ALSA module to each card found and check the > result. > > Unfortunately, this doesn't seem to be that easy. Could anyone > confirm, that I cannot load a module to a certain PCI card? > > Furthermore, modprobe does not give any error when probing a > module for a card I do not have. > > And I found no way to get backwards the card ID for a loaded > module :( . > > Does anyone know a way how I can find out which cards are in > the system and which module fits to it? > > > Any wee small hint is very welcome. > > > > Best regards > > > ce > --