diff options
author | David S. Miller <davem@davemloft.net> | 2009-12-30 16:51:29 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-12-30 16:51:29 -0500 |
commit | 3a999e6eb5d277cd6a321dcda3fc43c3d9e4e4b8 (patch) | |
tree | b0ad8d03710ee556e97515ba1c949233859391ce /drivers/net/wireless/b43/main.c | |
parent | 6cd9b49d7328c4656bfc17fcb47fb814955d40d2 (diff) | |
parent | 891dc5e73783eeabd2a704a9425e2a199b39c9f9 (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6
Diffstat (limited to 'drivers/net/wireless/b43/main.c')
-rw-r--r-- | drivers/net/wireless/b43/main.c | 35 |
1 files changed, 19 insertions, 16 deletions
diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c index 4c41cfe44f26..60290c06e950 100644 --- a/drivers/net/wireless/b43/main.c +++ b/drivers/net/wireless/b43/main.c | |||
@@ -102,6 +102,9 @@ int b43_modparam_verbose = B43_VERBOSITY_DEFAULT; | |||
102 | module_param_named(verbose, b43_modparam_verbose, int, 0644); | 102 | module_param_named(verbose, b43_modparam_verbose, int, 0644); |
103 | MODULE_PARM_DESC(verbose, "Log message verbosity: 0=error, 1=warn, 2=info(default), 3=debug"); | 103 | MODULE_PARM_DESC(verbose, "Log message verbosity: 0=error, 1=warn, 2=info(default), 3=debug"); |
104 | 104 | ||
105 | static int modparam_pio; | ||
106 | module_param_named(pio, modparam_pio, int, 0444); | ||
107 | MODULE_PARM_DESC(pio, "enable(1) / disable(0) PIO mode"); | ||
105 | 108 | ||
106 | static const struct ssb_device_id b43_ssb_tbl[] = { | 109 | static const struct ssb_device_id b43_ssb_tbl[] = { |
107 | SSB_DEVICE(SSB_VENDOR_BROADCOM, SSB_DEV_80211, 5), | 110 | SSB_DEVICE(SSB_VENDOR_BROADCOM, SSB_DEV_80211, 5), |
@@ -1786,8 +1789,8 @@ static void b43_do_interrupt_thread(struct b43_wldev *dev) | |||
1786 | dma_reason[4], dma_reason[5]); | 1789 | dma_reason[4], dma_reason[5]); |
1787 | b43err(dev->wl, "This device does not support DMA " | 1790 | b43err(dev->wl, "This device does not support DMA " |
1788 | "on your system. Please use PIO instead.\n"); | 1791 | "on your system. Please use PIO instead.\n"); |
1789 | b43err(dev->wl, "CONFIG_B43_FORCE_PIO must be set in " | 1792 | b43err(dev->wl, "Unload the b43 module and reload " |
1790 | "your kernel configuration.\n"); | 1793 | "with 'pio=1'\n"); |
1791 | return; | 1794 | return; |
1792 | } | 1795 | } |
1793 | if (merged_dma_reason & B43_DMAIRQ_NONFATALMASK) { | 1796 | if (merged_dma_reason & B43_DMAIRQ_NONFATALMASK) { |
@@ -4353,7 +4356,7 @@ static int b43_wireless_core_init(struct b43_wldev *dev) | |||
4353 | 4356 | ||
4354 | if ((dev->dev->bus->bustype == SSB_BUSTYPE_PCMCIA) || | 4357 | if ((dev->dev->bus->bustype == SSB_BUSTYPE_PCMCIA) || |
4355 | (dev->dev->bus->bustype == SSB_BUSTYPE_SDIO) || | 4358 | (dev->dev->bus->bustype == SSB_BUSTYPE_SDIO) || |
4356 | B43_FORCE_PIO) { | 4359 | modparam_pio) { |
4357 | dev->__using_pio_transfers = 1; | 4360 | dev->__using_pio_transfers = 1; |
4358 | err = b43_pio_init(dev); | 4361 | err = b43_pio_init(dev); |
4359 | } else { | 4362 | } else { |
@@ -4388,7 +4391,7 @@ err_busdown: | |||
4388 | } | 4391 | } |
4389 | 4392 | ||
4390 | static int b43_op_add_interface(struct ieee80211_hw *hw, | 4393 | static int b43_op_add_interface(struct ieee80211_hw *hw, |
4391 | struct ieee80211_if_init_conf *conf) | 4394 | struct ieee80211_vif *vif) |
4392 | { | 4395 | { |
4393 | struct b43_wl *wl = hw_to_b43_wl(hw); | 4396 | struct b43_wl *wl = hw_to_b43_wl(hw); |
4394 | struct b43_wldev *dev; | 4397 | struct b43_wldev *dev; |
@@ -4396,24 +4399,24 @@ static int b43_op_add_interface(struct ieee80211_hw *hw, | |||
4396 | 4399 | ||
4397 | /* TODO: allow WDS/AP devices to coexist */ | 4400 | /* TODO: allow WDS/AP devices to coexist */ |
4398 | 4401 | ||
4399 | if (conf->type != NL80211_IFTYPE_AP && | 4402 | if (vif->type != NL80211_IFTYPE_AP && |
4400 | conf->type != NL80211_IFTYPE_MESH_POINT && | 4403 | vif->type != NL80211_IFTYPE_MESH_POINT && |
4401 | conf->type != NL80211_IFTYPE_STATION && | 4404 | vif->type != NL80211_IFTYPE_STATION && |
4402 | conf->type != NL80211_IFTYPE_WDS && | 4405 | vif->type != NL80211_IFTYPE_WDS && |
4403 | conf->type != NL80211_IFTYPE_ADHOC) | 4406 | vif->type != NL80211_IFTYPE_ADHOC) |
4404 | return -EOPNOTSUPP; | 4407 | return -EOPNOTSUPP; |
4405 | 4408 | ||
4406 | mutex_lock(&wl->mutex); | 4409 | mutex_lock(&wl->mutex); |
4407 | if (wl->operating) | 4410 | if (wl->operating) |
4408 | goto out_mutex_unlock; | 4411 | goto out_mutex_unlock; |
4409 | 4412 | ||
4410 | b43dbg(wl, "Adding Interface type %d\n", conf->type); | 4413 | b43dbg(wl, "Adding Interface type %d\n", vif->type); |
4411 | 4414 | ||
4412 | dev = wl->current_dev; | 4415 | dev = wl->current_dev; |
4413 | wl->operating = 1; | 4416 | wl->operating = 1; |
4414 | wl->vif = conf->vif; | 4417 | wl->vif = vif; |
4415 | wl->if_type = conf->type; | 4418 | wl->if_type = vif->type; |
4416 | memcpy(wl->mac_addr, conf->mac_addr, ETH_ALEN); | 4419 | memcpy(wl->mac_addr, vif->addr, ETH_ALEN); |
4417 | 4420 | ||
4418 | b43_adjust_opmode(dev); | 4421 | b43_adjust_opmode(dev); |
4419 | b43_set_pretbtt(dev); | 4422 | b43_set_pretbtt(dev); |
@@ -4428,17 +4431,17 @@ static int b43_op_add_interface(struct ieee80211_hw *hw, | |||
4428 | } | 4431 | } |
4429 | 4432 | ||
4430 | static void b43_op_remove_interface(struct ieee80211_hw *hw, | 4433 | static void b43_op_remove_interface(struct ieee80211_hw *hw, |
4431 | struct ieee80211_if_init_conf *conf) | 4434 | struct ieee80211_vif *vif) |
4432 | { | 4435 | { |
4433 | struct b43_wl *wl = hw_to_b43_wl(hw); | 4436 | struct b43_wl *wl = hw_to_b43_wl(hw); |
4434 | struct b43_wldev *dev = wl->current_dev; | 4437 | struct b43_wldev *dev = wl->current_dev; |
4435 | 4438 | ||
4436 | b43dbg(wl, "Removing Interface type %d\n", conf->type); | 4439 | b43dbg(wl, "Removing Interface type %d\n", vif->type); |
4437 | 4440 | ||
4438 | mutex_lock(&wl->mutex); | 4441 | mutex_lock(&wl->mutex); |
4439 | 4442 | ||
4440 | B43_WARN_ON(!wl->operating); | 4443 | B43_WARN_ON(!wl->operating); |
4441 | B43_WARN_ON(wl->vif != conf->vif); | 4444 | B43_WARN_ON(wl->vif != vif); |
4442 | wl->vif = NULL; | 4445 | wl->vif = NULL; |
4443 | 4446 | ||
4444 | wl->operating = 0; | 4447 | wl->operating = 0; |