Sat 17 Apr 2004 03:30:29 AM UTC, comment #1:
if ((err = pci_read_config_word(pci, PCI_DEVICE_ID,
&(chip->device))) < 0) {
snd_card_free(card);
return err;
}
if ((err = pci_read_config_word(pci, PCI_VENDOR_ID,
&(chip->vendor))) < 0) {
snd_card_free(card);
return err;
}
chip->vendor and chip->device have been initalised in
if ((err = snd_vortex_create(card, pci, &chip)) < 0) {
.
.
.
chip->card = card;
// initialize the stuff
chip->pci_dev = pci;
chip->io = pci_resource_start(pci, 0);
chip->vendor = pci->vendor;
chip->device = pci->device;
chip->card = card;
chip->irq = -1;
To provide more information about the card
if ((err = pci_read_config_word(pci, PCI_SUBSYSTEM_ID,
&(chip->subsystem_device))) < 0) {
snd_card_free(card);
return err;
}
if ((err = pci_read_config_word(pci, PCI_SUBSYSTEM_VENDOR_ID,
&(chip->subsystem_vendor))) < 0) {
snd_card_free(card);
return err;
}
printk(KERN_INFO "Aureal Vortex %s Rev.(%.2x) Subsystem %.4x:%.4x - %s\n",
card->shortname,
chip->rev,
chip->subsystem_vendor,
chip->subsystem_device,
card->mixername);
|