119 |
// Get MMIO area |
// Get MMIO area |
120 |
// |
// |
121 |
if ((err = pci_request_regions(pci, CARD_NAME_SHORT)) != 0) |
if ((err = pci_request_regions(pci, CARD_NAME_SHORT)) != 0) |
122 |
goto regions_out; |
goto regions_out; |
123 |
|
|
124 |
//chip->mmio = ioremap_nocache(pci_resource_start(pci,0), pci_resource_len(pci,0)); |
//chip->mmio = ioremap_nocache(pci_resource_start(pci,0), pci_resource_len(pci,0)); |
125 |
chip->mmio = ioremap(pci_resource_start(pci,0), pci_resource_len(pci,0)); |
chip->mmio = ioremap(pci_resource_start(pci,0), pci_resource_len(pci,0)); |
126 |
if (!chip->mmio) { |
if (!chip->mmio) { |
127 |
printk(KERN_ERR "MMIO area remap failed.\n"); |
printk(KERN_ERR "MMIO area remap failed.\n"); |
128 |
err = -ENOMEM; |
err = -ENOMEM; |
129 |
goto ioremap_out; |
goto ioremap_out; |
130 |
} |
} |
131 |
|
|
132 |
/* Init audio core. |
/* Init audio core. |
140 |
if ((err = request_irq(pci->irq, vortex_interrupt, SA_INTERRUPT | SA_SHIRQ, |
if ((err = request_irq(pci->irq, vortex_interrupt, SA_INTERRUPT | SA_SHIRQ, |
141 |
CARD_NAME_SHORT, (void *) chip)) != 0) { |
CARD_NAME_SHORT, (void *) chip)) != 0) { |
142 |
printk(KERN_ERR "cannot grab irq\n"); |
printk(KERN_ERR "cannot grab irq\n"); |
143 |
goto irq_out; |
goto irq_out; |
144 |
} |
} |
145 |
chip->irq = pci->irq; |
chip->irq = pci->irq; |
146 |
|
|
172 |
//FIXME: this not the right place to unregister the gameport |
//FIXME: this not the right place to unregister the gameport |
173 |
vortex_gameport_unregister(chip); |
vortex_gameport_unregister(chip); |
174 |
return err; |
return err; |
|
|
|
175 |
} |
} |
176 |
|
|
177 |
// constructor -- see "Constructor" sub-section |
// constructor -- see "Constructor" sub-section |