diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-06-22 14:57:09 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-06-22 14:57:09 -0400 |
commit | 5165aece0efac6574fc3e32b6f1c2a964820d1c6 (patch) | |
tree | 73131c06a021578a47526a95bad391dbd9d3b932 /drivers/net/wireless/ath | |
parent | e38be994b9cad09b0d8d78a1875d7e8a2e115d29 (diff) | |
parent | f6b24caaf933a466397915a08e30e885a32f905a (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (43 commits)
via-velocity: Fix velocity driver unmapping incorrect size.
mlx4_en: Remove redundant refill code on RX
mlx4_en: Removed redundant check on lso header size
mlx4_en: Cancel port_up check in transmit function
mlx4_en: using stop/start_all_queues
mlx4_en: Removed redundant skb->len check
mlx4_en: Counting all the dropped packets on the TX side
usbnet cdc_subset: fix issues talking to PXA gadgets
Net: qla3xxx, remove sleeping in atomic
ipv4: fix NULL pointer + success return in route lookup path
isdn: clean up documentation index
cfg80211: validate station settings
cfg80211: allow setting station parameters in mesh
cfg80211: allow adding/deleting stations on mesh
ath5k: fix beacon_int handling
MAINTAINERS: Fix Atheros pattern paths
ath9k: restore PS mode, before we put the chip into FULL SLEEP state.
ath9k: wait for beacon frame along with CAB
acer-wmi: fix rfkill conversion
ath5k: avoid PCI FATAL interrupts by restoring RETRY_TIMEOUT disabling
...
Diffstat (limited to 'drivers/net/wireless/ath')
-rw-r--r-- | drivers/net/wireless/ath/ath5k/base.c | 11 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/main.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/pci.c | 18 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/recv.c | 7 |
4 files changed, 32 insertions, 6 deletions
diff --git a/drivers/net/wireless/ath/ath5k/base.c b/drivers/net/wireless/ath/ath5k/base.c index 55f7de09d13..ea045151f95 100644 --- a/drivers/net/wireless/ath/ath5k/base.c +++ b/drivers/net/wireless/ath/ath5k/base.c | |||
@@ -538,6 +538,7 @@ ath5k_pci_probe(struct pci_dev *pdev, | |||
538 | sc->iobase = mem; /* So we can unmap it on detach */ | 538 | sc->iobase = mem; /* So we can unmap it on detach */ |
539 | sc->cachelsz = csz * sizeof(u32); /* convert to bytes */ | 539 | sc->cachelsz = csz * sizeof(u32); /* convert to bytes */ |
540 | sc->opmode = NL80211_IFTYPE_STATION; | 540 | sc->opmode = NL80211_IFTYPE_STATION; |
541 | sc->bintval = 1000; | ||
541 | mutex_init(&sc->lock); | 542 | mutex_init(&sc->lock); |
542 | spin_lock_init(&sc->rxbuflock); | 543 | spin_lock_init(&sc->rxbuflock); |
543 | spin_lock_init(&sc->txbuflock); | 544 | spin_lock_init(&sc->txbuflock); |
@@ -686,6 +687,13 @@ ath5k_pci_resume(struct pci_dev *pdev) | |||
686 | if (err) | 687 | if (err) |
687 | return err; | 688 | return err; |
688 | 689 | ||
690 | /* | ||
691 | * Suspend/Resume resets the PCI configuration space, so we have to | ||
692 | * re-disable the RETRY_TIMEOUT register (0x41) to keep | ||
693 | * PCI Tx retries from interfering with C3 CPU state | ||
694 | */ | ||
695 | pci_write_config_byte(pdev, 0x41, 0); | ||
696 | |||
689 | err = request_irq(pdev->irq, ath5k_intr, IRQF_SHARED, "ath", sc); | 697 | err = request_irq(pdev->irq, ath5k_intr, IRQF_SHARED, "ath", sc); |
690 | if (err) { | 698 | if (err) { |
691 | ATH5K_ERR(sc, "request_irq failed\n"); | 699 | ATH5K_ERR(sc, "request_irq failed\n"); |
@@ -2748,9 +2756,6 @@ static int ath5k_add_interface(struct ieee80211_hw *hw, | |||
2748 | goto end; | 2756 | goto end; |
2749 | } | 2757 | } |
2750 | 2758 | ||
2751 | /* Set to a reasonable value. Note that this will | ||
2752 | * be set to mac80211's value at ath5k_config(). */ | ||
2753 | sc->bintval = 1000; | ||
2754 | ath5k_hw_set_lladdr(sc->ah, conf->mac_addr); | 2759 | ath5k_hw_set_lladdr(sc->ah, conf->mac_addr); |
2755 | 2760 | ||
2756 | ret = 0; | 2761 | ret = 0; |
diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c index 9f49a3251d4..66a6c1f5022 100644 --- a/drivers/net/wireless/ath/ath9k/main.c +++ b/drivers/net/wireless/ath/ath9k/main.c | |||
@@ -1196,8 +1196,8 @@ void ath_radio_disable(struct ath_softc *sc) | |||
1196 | 1196 | ||
1197 | ath9k_hw_phy_disable(ah); | 1197 | ath9k_hw_phy_disable(ah); |
1198 | ath9k_hw_configpcipowersave(ah, 1); | 1198 | ath9k_hw_configpcipowersave(ah, 1); |
1199 | ath9k_hw_setpower(ah, ATH9K_PM_FULL_SLEEP); | ||
1200 | ath9k_ps_restore(sc); | 1199 | ath9k_ps_restore(sc); |
1200 | ath9k_hw_setpower(ah, ATH9K_PM_FULL_SLEEP); | ||
1201 | } | 1201 | } |
1202 | 1202 | ||
1203 | /*******************/ | 1203 | /*******************/ |
diff --git a/drivers/net/wireless/ath/ath9k/pci.c b/drivers/net/wireless/ath/ath9k/pci.c index ccdf20a2e9b..170c5b32e49 100644 --- a/drivers/net/wireless/ath/ath9k/pci.c +++ b/drivers/net/wireless/ath/ath9k/pci.c | |||
@@ -87,6 +87,7 @@ static int ath_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id) | |||
87 | struct ath_softc *sc; | 87 | struct ath_softc *sc; |
88 | struct ieee80211_hw *hw; | 88 | struct ieee80211_hw *hw; |
89 | u8 csz; | 89 | u8 csz; |
90 | u32 val; | ||
90 | int ret = 0; | 91 | int ret = 0; |
91 | struct ath_hw *ah; | 92 | struct ath_hw *ah; |
92 | 93 | ||
@@ -133,6 +134,14 @@ static int ath_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id) | |||
133 | 134 | ||
134 | pci_set_master(pdev); | 135 | pci_set_master(pdev); |
135 | 136 | ||
137 | /* | ||
138 | * Disable the RETRY_TIMEOUT register (0x41) to keep | ||
139 | * PCI Tx retries from interfering with C3 CPU state. | ||
140 | */ | ||
141 | pci_read_config_dword(pdev, 0x40, &val); | ||
142 | if ((val & 0x0000ff00) != 0) | ||
143 | pci_write_config_dword(pdev, 0x40, val & 0xffff00ff); | ||
144 | |||
136 | ret = pci_request_region(pdev, 0, "ath9k"); | 145 | ret = pci_request_region(pdev, 0, "ath9k"); |
137 | if (ret) { | 146 | if (ret) { |
138 | dev_err(&pdev->dev, "PCI memory region reserve error\n"); | 147 | dev_err(&pdev->dev, "PCI memory region reserve error\n"); |
@@ -239,12 +248,21 @@ static int ath_pci_resume(struct pci_dev *pdev) | |||
239 | struct ieee80211_hw *hw = pci_get_drvdata(pdev); | 248 | struct ieee80211_hw *hw = pci_get_drvdata(pdev); |
240 | struct ath_wiphy *aphy = hw->priv; | 249 | struct ath_wiphy *aphy = hw->priv; |
241 | struct ath_softc *sc = aphy->sc; | 250 | struct ath_softc *sc = aphy->sc; |
251 | u32 val; | ||
242 | int err; | 252 | int err; |
243 | 253 | ||
244 | err = pci_enable_device(pdev); | 254 | err = pci_enable_device(pdev); |
245 | if (err) | 255 | if (err) |
246 | return err; | 256 | return err; |
247 | pci_restore_state(pdev); | 257 | pci_restore_state(pdev); |
258 | /* | ||
259 | * Suspend/Resume resets the PCI configuration space, so we have to | ||
260 | * re-disable the RETRY_TIMEOUT register (0x41) to keep | ||
261 | * PCI Tx retries from interfering with C3 CPU state | ||
262 | */ | ||
263 | pci_read_config_dword(pdev, 0x40, &val); | ||
264 | if ((val & 0x0000ff00) != 0) | ||
265 | pci_write_config_dword(pdev, 0x40, val & 0xffff00ff); | ||
248 | 266 | ||
249 | /* Enable LED */ | 267 | /* Enable LED */ |
250 | ath9k_hw_cfg_output(sc->sc_ah, ATH_LED_PIN, | 268 | ath9k_hw_cfg_output(sc->sc_ah, ATH_LED_PIN, |
diff --git a/drivers/net/wireless/ath/ath9k/recv.c b/drivers/net/wireless/ath/ath9k/recv.c index f99f3a76df3..cece1c4c6bd 100644 --- a/drivers/net/wireless/ath/ath9k/recv.c +++ b/drivers/net/wireless/ath/ath9k/recv.c | |||
@@ -539,11 +539,14 @@ static void ath_rx_ps_beacon(struct ath_softc *sc, struct sk_buff *skb) | |||
539 | if (ath_beacon_dtim_pending_cab(skb)) { | 539 | if (ath_beacon_dtim_pending_cab(skb)) { |
540 | /* | 540 | /* |
541 | * Remain awake waiting for buffered broadcast/multicast | 541 | * Remain awake waiting for buffered broadcast/multicast |
542 | * frames. | 542 | * frames. If the last broadcast/multicast frame is not |
543 | * received properly, the next beacon frame will work as | ||
544 | * a backup trigger for returning into NETWORK SLEEP state, | ||
545 | * so we are waiting for it as well. | ||
543 | */ | 546 | */ |
544 | DPRINTF(sc, ATH_DBG_PS, "Received DTIM beacon indicating " | 547 | DPRINTF(sc, ATH_DBG_PS, "Received DTIM beacon indicating " |
545 | "buffered broadcast/multicast frame(s)\n"); | 548 | "buffered broadcast/multicast frame(s)\n"); |
546 | sc->sc_flags |= SC_OP_WAIT_FOR_CAB; | 549 | sc->sc_flags |= SC_OP_WAIT_FOR_CAB | SC_OP_WAIT_FOR_BEACON; |
547 | return; | 550 | return; |
548 | } | 551 | } |
549 | 552 | ||