|
@@ -2925,10 +2925,13 @@ static int bcm43xx_wireless_core_init(struct bcm43xx_private *bcm,
|
|
bcm43xx_write16(bcm, 0x043C, 0x000C);
|
|
bcm43xx_write16(bcm, 0x043C, 0x000C);
|
|
|
|
|
|
if (active_wlcore) {
|
|
if (active_wlcore) {
|
|
- if (bcm43xx_using_pio(bcm))
|
|
|
|
|
|
+ if (bcm43xx_using_pio(bcm)) {
|
|
err = bcm43xx_pio_init(bcm);
|
|
err = bcm43xx_pio_init(bcm);
|
|
- else
|
|
|
|
|
|
+ } else {
|
|
err = bcm43xx_dma_init(bcm);
|
|
err = bcm43xx_dma_init(bcm);
|
|
|
|
+ if (err == -ENOSYS)
|
|
|
|
+ err = bcm43xx_pio_init(bcm);
|
|
|
|
+ }
|
|
if (err)
|
|
if (err)
|
|
goto err_chip_cleanup;
|
|
goto err_chip_cleanup;
|
|
}
|
|
}
|
|
@@ -3992,8 +3995,6 @@ static int bcm43xx_init_private(struct bcm43xx_private *bcm,
|
|
struct net_device *net_dev,
|
|
struct net_device *net_dev,
|
|
struct pci_dev *pci_dev)
|
|
struct pci_dev *pci_dev)
|
|
{
|
|
{
|
|
- int err;
|
|
|
|
-
|
|
|
|
bcm43xx_set_status(bcm, BCM43xx_STAT_UNINIT);
|
|
bcm43xx_set_status(bcm, BCM43xx_STAT_UNINIT);
|
|
bcm->ieee = netdev_priv(net_dev);
|
|
bcm->ieee = netdev_priv(net_dev);
|
|
bcm->softmac = ieee80211_priv(net_dev);
|
|
bcm->softmac = ieee80211_priv(net_dev);
|
|
@@ -4011,22 +4012,8 @@ static int bcm43xx_init_private(struct bcm43xx_private *bcm,
|
|
(void (*)(unsigned long))bcm43xx_interrupt_tasklet,
|
|
(void (*)(unsigned long))bcm43xx_interrupt_tasklet,
|
|
(unsigned long)bcm);
|
|
(unsigned long)bcm);
|
|
tasklet_disable_nosync(&bcm->isr_tasklet);
|
|
tasklet_disable_nosync(&bcm->isr_tasklet);
|
|
- if (modparam_pio) {
|
|
|
|
|
|
+ if (modparam_pio)
|
|
bcm->__using_pio = 1;
|
|
bcm->__using_pio = 1;
|
|
- } else {
|
|
|
|
- err = pci_set_dma_mask(pci_dev, DMA_30BIT_MASK);
|
|
|
|
- err |= pci_set_consistent_dma_mask(pci_dev, DMA_30BIT_MASK);
|
|
|
|
- if (err) {
|
|
|
|
-#ifdef CONFIG_BCM43XX_PIO
|
|
|
|
- printk(KERN_WARNING PFX "DMA not supported. Falling back to PIO.\n");
|
|
|
|
- bcm->__using_pio = 1;
|
|
|
|
-#else
|
|
|
|
- printk(KERN_ERR PFX "FATAL: DMA not supported and PIO not configured. "
|
|
|
|
- "Recompile the driver with PIO support, please.\n");
|
|
|
|
- return -ENODEV;
|
|
|
|
-#endif /* CONFIG_BCM43XX_PIO */
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
bcm->rts_threshold = BCM43xx_DEFAULT_RTS_THRESHOLD;
|
|
bcm->rts_threshold = BCM43xx_DEFAULT_RTS_THRESHOLD;
|
|
|
|
|
|
/* default to sw encryption for now */
|
|
/* default to sw encryption for now */
|