diff options
author | David S. Miller <davem@davemloft.net> | 2010-02-15 01:30:54 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-15 01:30:54 -0500 |
commit | 5ecccb74dc91e22496a142b103ba958f93c29275 (patch) | |
tree | b560b8974ec0e0478492d60753d45d8aea9db9b0 | |
parent | f6f223039c0d0683bdea1eabd35b309e10311a60 (diff) | |
parent | 3d0beb921fa34ebf8b13e206e5473329b14deb83 (diff) |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:
net/mac80211/rate.c
-rw-r--r-- | drivers/net/sfc/efx.c | 1 | ||||
-rw-r--r-- | drivers/net/sfc/qt202x_phy.c | 2 | ||||
-rw-r--r-- | drivers/net/via-velocity.c | 41 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/xmit.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-rx.c | 5 | ||||
-rw-r--r-- | drivers/net/wireless/iwmc3200wifi/rx.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/rtl818x/rtl8187_dev.c | 1 | ||||
-rw-r--r-- | net/ipv4/igmp.c | 2 | ||||
-rw-r--r-- | net/ipv4/tcp_input.c | 6 | ||||
-rw-r--r-- | net/mac80211/rate.c | 3 |
10 files changed, 36 insertions, 31 deletions
diff --git a/drivers/net/sfc/efx.c b/drivers/net/sfc/efx.c index fafaf30ecd9a..dc58d9fd0f32 100644 --- a/drivers/net/sfc/efx.c +++ b/drivers/net/sfc/efx.c | |||
@@ -2284,6 +2284,7 @@ static int __devinit efx_pci_probe(struct pci_dev *pci_dev, | |||
2284 | fail2: | 2284 | fail2: |
2285 | efx_fini_struct(efx); | 2285 | efx_fini_struct(efx); |
2286 | fail1: | 2286 | fail1: |
2287 | WARN_ON(rc > 0); | ||
2287 | EFX_LOG(efx, "initialisation failed. rc=%d\n", rc); | 2288 | EFX_LOG(efx, "initialisation failed. rc=%d\n", rc); |
2288 | free_netdev(net_dev); | 2289 | free_netdev(net_dev); |
2289 | return rc; | 2290 | return rc; |
diff --git a/drivers/net/sfc/qt202x_phy.c b/drivers/net/sfc/qt202x_phy.c index 14793d8bd661..1bee62c83001 100644 --- a/drivers/net/sfc/qt202x_phy.c +++ b/drivers/net/sfc/qt202x_phy.c | |||
@@ -320,7 +320,7 @@ static int qt202x_reset_phy(struct efx_nic *efx) | |||
320 | 320 | ||
321 | falcon_board(efx)->type->init_phy(efx); | 321 | falcon_board(efx)->type->init_phy(efx); |
322 | 322 | ||
323 | return rc; | 323 | return 0; |
324 | 324 | ||
325 | fail: | 325 | fail: |
326 | EFX_ERR(efx, "PHY reset timed out\n"); | 326 | EFX_ERR(efx, "PHY reset timed out\n"); |
diff --git a/drivers/net/via-velocity.c b/drivers/net/via-velocity.c index bdb19c3d6568..cd4e866321f8 100644 --- a/drivers/net/via-velocity.c +++ b/drivers/net/via-velocity.c | |||
@@ -1879,13 +1879,12 @@ static void velocity_error(struct velocity_info *vptr, int status) | |||
1879 | /** | 1879 | /** |
1880 | * tx_srv - transmit interrupt service | 1880 | * tx_srv - transmit interrupt service |
1881 | * @vptr; Velocity | 1881 | * @vptr; Velocity |
1882 | * @status: | ||
1883 | * | 1882 | * |
1884 | * Scan the queues looking for transmitted packets that | 1883 | * Scan the queues looking for transmitted packets that |
1885 | * we can complete and clean up. Update any statistics as | 1884 | * we can complete and clean up. Update any statistics as |
1886 | * necessary/ | 1885 | * necessary/ |
1887 | */ | 1886 | */ |
1888 | static int velocity_tx_srv(struct velocity_info *vptr, u32 status) | 1887 | static int velocity_tx_srv(struct velocity_info *vptr) |
1889 | { | 1888 | { |
1890 | struct tx_desc *td; | 1889 | struct tx_desc *td; |
1891 | int qnum; | 1890 | int qnum; |
@@ -2092,14 +2091,12 @@ static int velocity_receive_frame(struct velocity_info *vptr, int idx) | |||
2092 | /** | 2091 | /** |
2093 | * velocity_rx_srv - service RX interrupt | 2092 | * velocity_rx_srv - service RX interrupt |
2094 | * @vptr: velocity | 2093 | * @vptr: velocity |
2095 | * @status: adapter status (unused) | ||
2096 | * | 2094 | * |
2097 | * Walk the receive ring of the velocity adapter and remove | 2095 | * Walk the receive ring of the velocity adapter and remove |
2098 | * any received packets from the receive queue. Hand the ring | 2096 | * any received packets from the receive queue. Hand the ring |
2099 | * slots back to the adapter for reuse. | 2097 | * slots back to the adapter for reuse. |
2100 | */ | 2098 | */ |
2101 | static int velocity_rx_srv(struct velocity_info *vptr, int status, | 2099 | static int velocity_rx_srv(struct velocity_info *vptr, int budget_left) |
2102 | int budget_left) | ||
2103 | { | 2100 | { |
2104 | struct net_device_stats *stats = &vptr->dev->stats; | 2101 | struct net_device_stats *stats = &vptr->dev->stats; |
2105 | int rd_curr = vptr->rx.curr; | 2102 | int rd_curr = vptr->rx.curr; |
@@ -2153,32 +2150,24 @@ static int velocity_poll(struct napi_struct *napi, int budget) | |||
2153 | struct velocity_info *vptr = container_of(napi, | 2150 | struct velocity_info *vptr = container_of(napi, |
2154 | struct velocity_info, napi); | 2151 | struct velocity_info, napi); |
2155 | unsigned int rx_done; | 2152 | unsigned int rx_done; |
2156 | u32 isr_status; | 2153 | unsigned long flags; |
2157 | |||
2158 | spin_lock(&vptr->lock); | ||
2159 | isr_status = mac_read_isr(vptr->mac_regs); | ||
2160 | |||
2161 | /* Ack the interrupt */ | ||
2162 | mac_write_isr(vptr->mac_regs, isr_status); | ||
2163 | if (isr_status & (~(ISR_PRXI | ISR_PPRXI | ISR_PTXI | ISR_PPTXI))) | ||
2164 | velocity_error(vptr, isr_status); | ||
2165 | 2154 | ||
2155 | spin_lock_irqsave(&vptr->lock, flags); | ||
2166 | /* | 2156 | /* |
2167 | * Do rx and tx twice for performance (taken from the VIA | 2157 | * Do rx and tx twice for performance (taken from the VIA |
2168 | * out-of-tree driver). | 2158 | * out-of-tree driver). |
2169 | */ | 2159 | */ |
2170 | rx_done = velocity_rx_srv(vptr, isr_status, budget / 2); | 2160 | rx_done = velocity_rx_srv(vptr, budget / 2); |
2171 | velocity_tx_srv(vptr, isr_status); | 2161 | velocity_tx_srv(vptr); |
2172 | rx_done += velocity_rx_srv(vptr, isr_status, budget - rx_done); | 2162 | rx_done += velocity_rx_srv(vptr, budget - rx_done); |
2173 | velocity_tx_srv(vptr, isr_status); | 2163 | velocity_tx_srv(vptr); |
2174 | |||
2175 | spin_unlock(&vptr->lock); | ||
2176 | 2164 | ||
2177 | /* If budget not fully consumed, exit the polling mode */ | 2165 | /* If budget not fully consumed, exit the polling mode */ |
2178 | if (rx_done < budget) { | 2166 | if (rx_done < budget) { |
2179 | napi_complete(napi); | 2167 | napi_complete(napi); |
2180 | mac_enable_int(vptr->mac_regs); | 2168 | mac_enable_int(vptr->mac_regs); |
2181 | } | 2169 | } |
2170 | spin_unlock_irqrestore(&vptr->lock, flags); | ||
2182 | 2171 | ||
2183 | return rx_done; | 2172 | return rx_done; |
2184 | } | 2173 | } |
@@ -2208,10 +2197,17 @@ static irqreturn_t velocity_intr(int irq, void *dev_instance) | |||
2208 | return IRQ_NONE; | 2197 | return IRQ_NONE; |
2209 | } | 2198 | } |
2210 | 2199 | ||
2200 | /* Ack the interrupt */ | ||
2201 | mac_write_isr(vptr->mac_regs, isr_status); | ||
2202 | |||
2211 | if (likely(napi_schedule_prep(&vptr->napi))) { | 2203 | if (likely(napi_schedule_prep(&vptr->napi))) { |
2212 | mac_disable_int(vptr->mac_regs); | 2204 | mac_disable_int(vptr->mac_regs); |
2213 | __napi_schedule(&vptr->napi); | 2205 | __napi_schedule(&vptr->napi); |
2214 | } | 2206 | } |
2207 | |||
2208 | if (isr_status & (~(ISR_PRXI | ISR_PPRXI | ISR_PTXI | ISR_PPTXI))) | ||
2209 | velocity_error(vptr, isr_status); | ||
2210 | |||
2215 | spin_unlock(&vptr->lock); | 2211 | spin_unlock(&vptr->lock); |
2216 | 2212 | ||
2217 | return IRQ_HANDLED; | 2213 | return IRQ_HANDLED; |
@@ -3100,7 +3096,7 @@ static int velocity_resume(struct pci_dev *pdev) | |||
3100 | velocity_init_registers(vptr, VELOCITY_INIT_WOL); | 3096 | velocity_init_registers(vptr, VELOCITY_INIT_WOL); |
3101 | mac_disable_int(vptr->mac_regs); | 3097 | mac_disable_int(vptr->mac_regs); |
3102 | 3098 | ||
3103 | velocity_tx_srv(vptr, 0); | 3099 | velocity_tx_srv(vptr); |
3104 | 3100 | ||
3105 | for (i = 0; i < vptr->tx.numq; i++) { | 3101 | for (i = 0; i < vptr->tx.numq; i++) { |
3106 | if (vptr->tx.used[i]) | 3102 | if (vptr->tx.used[i]) |
@@ -3344,6 +3340,7 @@ static int velocity_set_coalesce(struct net_device *dev, | |||
3344 | { | 3340 | { |
3345 | struct velocity_info *vptr = netdev_priv(dev); | 3341 | struct velocity_info *vptr = netdev_priv(dev); |
3346 | int max_us = 0x3f * 64; | 3342 | int max_us = 0x3f * 64; |
3343 | unsigned long flags; | ||
3347 | 3344 | ||
3348 | /* 6 bits of */ | 3345 | /* 6 bits of */ |
3349 | if (ecmd->tx_coalesce_usecs > max_us) | 3346 | if (ecmd->tx_coalesce_usecs > max_us) |
@@ -3365,6 +3362,7 @@ static int velocity_set_coalesce(struct net_device *dev, | |||
3365 | ecmd->tx_coalesce_usecs); | 3362 | ecmd->tx_coalesce_usecs); |
3366 | 3363 | ||
3367 | /* Setup the interrupt suppression and queue timers */ | 3364 | /* Setup the interrupt suppression and queue timers */ |
3365 | spin_lock_irqsave(&vptr->lock, flags); | ||
3368 | mac_disable_int(vptr->mac_regs); | 3366 | mac_disable_int(vptr->mac_regs); |
3369 | setup_adaptive_interrupts(vptr); | 3367 | setup_adaptive_interrupts(vptr); |
3370 | setup_queue_timers(vptr); | 3368 | setup_queue_timers(vptr); |
@@ -3372,6 +3370,7 @@ static int velocity_set_coalesce(struct net_device *dev, | |||
3372 | mac_write_int_mask(vptr->int_mask, vptr->mac_regs); | 3370 | mac_write_int_mask(vptr->int_mask, vptr->mac_regs); |
3373 | mac_clear_isr(vptr->mac_regs); | 3371 | mac_clear_isr(vptr->mac_regs); |
3374 | mac_enable_int(vptr->mac_regs); | 3372 | mac_enable_int(vptr->mac_regs); |
3373 | spin_unlock_irqrestore(&vptr->lock, flags); | ||
3375 | 3374 | ||
3376 | return 0; | 3375 | return 0; |
3377 | } | 3376 | } |
diff --git a/drivers/net/wireless/ath/ath9k/xmit.c b/drivers/net/wireless/ath/ath9k/xmit.c index f5cbbcb9a4aa..47294f90bbe5 100644 --- a/drivers/net/wireless/ath/ath9k/xmit.c +++ b/drivers/net/wireless/ath/ath9k/xmit.c | |||
@@ -1610,7 +1610,7 @@ static int ath_tx_setup_buffer(struct ieee80211_hw *hw, struct ath_buf *bf, | |||
1610 | bf->bf_frmlen -= padsize; | 1610 | bf->bf_frmlen -= padsize; |
1611 | } | 1611 | } |
1612 | 1612 | ||
1613 | if (conf_is_ht(&hw->conf) && !is_pae(skb)) | 1613 | if (conf_is_ht(&hw->conf)) |
1614 | bf->bf_state.bf_type |= BUF_HT; | 1614 | bf->bf_state.bf_type |= BUF_HT; |
1615 | 1615 | ||
1616 | bf->bf_flags = setup_tx_flags(sc, skb, txctl->txq); | 1616 | bf->bf_flags = setup_tx_flags(sc, skb, txctl->txq); |
@@ -1696,7 +1696,7 @@ static void ath_tx_start_dma(struct ath_softc *sc, struct ath_buf *bf, | |||
1696 | goto tx_done; | 1696 | goto tx_done; |
1697 | } | 1697 | } |
1698 | 1698 | ||
1699 | if (tx_info->flags & IEEE80211_TX_CTL_AMPDU) { | 1699 | if ((tx_info->flags & IEEE80211_TX_CTL_AMPDU) && !is_pae(skb)) { |
1700 | /* | 1700 | /* |
1701 | * Try aggregation if it's a unicast data frame | 1701 | * Try aggregation if it's a unicast data frame |
1702 | * and the destination is HT capable. | 1702 | * and the destination is HT capable. |
diff --git a/drivers/net/wireless/iwlwifi/iwl-rx.c b/drivers/net/wireless/iwlwifi/iwl-rx.c index 5df66382d922..0f718f6df5fd 100644 --- a/drivers/net/wireless/iwlwifi/iwl-rx.c +++ b/drivers/net/wireless/iwlwifi/iwl-rx.c | |||
@@ -1012,7 +1012,10 @@ static void iwl_pass_packet_to_mac80211(struct iwl_priv *priv, | |||
1012 | if (ieee80211_is_mgmt(fc) || | 1012 | if (ieee80211_is_mgmt(fc) || |
1013 | ieee80211_has_protected(fc) || | 1013 | ieee80211_has_protected(fc) || |
1014 | ieee80211_has_morefrags(fc) || | 1014 | ieee80211_has_morefrags(fc) || |
1015 | le16_to_cpu(hdr->seq_ctrl) & IEEE80211_SCTL_FRAG) | 1015 | le16_to_cpu(hdr->seq_ctrl) & IEEE80211_SCTL_FRAG || |
1016 | (ieee80211_is_data_qos(fc) && | ||
1017 | *ieee80211_get_qos_ctl(hdr) & | ||
1018 | IEEE80211_QOS_CONTROL_A_MSDU_PRESENT)) | ||
1016 | ret = skb_linearize(skb); | 1019 | ret = skb_linearize(skb); |
1017 | else | 1020 | else |
1018 | ret = __pskb_pull_tail(skb, min_t(u16, IWL_LINK_HDR_MAX, len)) ? | 1021 | ret = __pskb_pull_tail(skb, min_t(u16, IWL_LINK_HDR_MAX, len)) ? |
diff --git a/drivers/net/wireless/iwmc3200wifi/rx.c b/drivers/net/wireless/iwmc3200wifi/rx.c index d32adeab68a3..ad8f7eabb5aa 100644 --- a/drivers/net/wireless/iwmc3200wifi/rx.c +++ b/drivers/net/wireless/iwmc3200wifi/rx.c | |||
@@ -794,7 +794,7 @@ static int iwm_mlme_update_bss_table(struct iwm_priv *iwm, u8 *buf, | |||
794 | } | 794 | } |
795 | 795 | ||
796 | bss->bss = kzalloc(bss_len, GFP_KERNEL); | 796 | bss->bss = kzalloc(bss_len, GFP_KERNEL); |
797 | if (!bss) { | 797 | if (!bss->bss) { |
798 | kfree(bss); | 798 | kfree(bss); |
799 | IWM_ERR(iwm, "Couldn't allocate bss\n"); | 799 | IWM_ERR(iwm, "Couldn't allocate bss\n"); |
800 | return -ENOMEM; | 800 | return -ENOMEM; |
diff --git a/drivers/net/wireless/rtl818x/rtl8187_dev.c b/drivers/net/wireless/rtl818x/rtl8187_dev.c index a05382557789..0fb850e0c656 100644 --- a/drivers/net/wireless/rtl818x/rtl8187_dev.c +++ b/drivers/net/wireless/rtl818x/rtl8187_dev.c | |||
@@ -65,6 +65,7 @@ static struct usb_device_id rtl8187_table[] __devinitdata = { | |||
65 | /* Sitecom */ | 65 | /* Sitecom */ |
66 | {USB_DEVICE(0x0df6, 0x000d), .driver_info = DEVICE_RTL8187}, | 66 | {USB_DEVICE(0x0df6, 0x000d), .driver_info = DEVICE_RTL8187}, |
67 | {USB_DEVICE(0x0df6, 0x0028), .driver_info = DEVICE_RTL8187B}, | 67 | {USB_DEVICE(0x0df6, 0x0028), .driver_info = DEVICE_RTL8187B}, |
68 | {USB_DEVICE(0x0df6, 0x0029), .driver_info = DEVICE_RTL8187B}, | ||
68 | /* Sphairon Access Systems GmbH */ | 69 | /* Sphairon Access Systems GmbH */ |
69 | {USB_DEVICE(0x114B, 0x0150), .driver_info = DEVICE_RTL8187}, | 70 | {USB_DEVICE(0x114B, 0x0150), .driver_info = DEVICE_RTL8187}, |
70 | /* Dick Smith Electronics */ | 71 | /* Dick Smith Electronics */ |
diff --git a/net/ipv4/igmp.c b/net/ipv4/igmp.c index d28363998743..63bf298ca109 100644 --- a/net/ipv4/igmp.c +++ b/net/ipv4/igmp.c | |||
@@ -946,7 +946,6 @@ int igmp_rcv(struct sk_buff *skb) | |||
946 | break; | 946 | break; |
947 | case IGMP_HOST_MEMBERSHIP_REPORT: | 947 | case IGMP_HOST_MEMBERSHIP_REPORT: |
948 | case IGMPV2_HOST_MEMBERSHIP_REPORT: | 948 | case IGMPV2_HOST_MEMBERSHIP_REPORT: |
949 | case IGMPV3_HOST_MEMBERSHIP_REPORT: | ||
950 | /* Is it our report looped back? */ | 949 | /* Is it our report looped back? */ |
951 | if (skb_rtable(skb)->fl.iif == 0) | 950 | if (skb_rtable(skb)->fl.iif == 0) |
952 | break; | 951 | break; |
@@ -960,6 +959,7 @@ int igmp_rcv(struct sk_buff *skb) | |||
960 | in_dev_put(in_dev); | 959 | in_dev_put(in_dev); |
961 | return pim_rcv_v1(skb); | 960 | return pim_rcv_v1(skb); |
962 | #endif | 961 | #endif |
962 | case IGMPV3_HOST_MEMBERSHIP_REPORT: | ||
963 | case IGMP_DVMRP: | 963 | case IGMP_DVMRP: |
964 | case IGMP_TRACE: | 964 | case IGMP_TRACE: |
965 | case IGMP_HOST_LEAVE_MESSAGE: | 965 | case IGMP_HOST_LEAVE_MESSAGE: |
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index 28e029632493..3fddc69ccccc 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c | |||
@@ -5783,11 +5783,9 @@ int tcp_rcv_state_process(struct sock *sk, struct sk_buff *skb, | |||
5783 | 5783 | ||
5784 | /* tcp_ack considers this ACK as duplicate | 5784 | /* tcp_ack considers this ACK as duplicate |
5785 | * and does not calculate rtt. | 5785 | * and does not calculate rtt. |
5786 | * Fix it at least with timestamps. | 5786 | * Force it here. |
5787 | */ | 5787 | */ |
5788 | if (tp->rx_opt.saw_tstamp && | 5788 | tcp_ack_update_rtt(sk, 0, 0); |
5789 | tp->rx_opt.rcv_tsecr && !tp->srtt) | ||
5790 | tcp_ack_saw_tstamp(sk, 0); | ||
5791 | 5789 | ||
5792 | if (tp->rx_opt.tstamp_ok) | 5790 | if (tp->rx_opt.tstamp_ok) |
5793 | tp->advmss -= TCPOLEN_TSTAMP_ALIGNED; | 5791 | tp->advmss -= TCPOLEN_TSTAMP_ALIGNED; |
diff --git a/net/mac80211/rate.c b/net/mac80211/rate.c index 99ab24cc9783..0b299d236fa1 100644 --- a/net/mac80211/rate.c +++ b/net/mac80211/rate.c | |||
@@ -303,6 +303,9 @@ void rate_control_get_rate(struct ieee80211_sub_if_data *sdata, | |||
303 | info->control.rates[i].count = 1; | 303 | info->control.rates[i].count = 1; |
304 | } | 304 | } |
305 | 305 | ||
306 | if (sdata->local->hw.flags & IEEE80211_HW_HAS_RATE_CONTROL) | ||
307 | return; | ||
308 | |||
306 | ref->ops->get_rate(ref->priv, ista, priv_sta, txrc); | 309 | ref->ops->get_rate(ref->priv, ista, priv_sta, txrc); |
307 | 310 | ||
308 | /* | 311 | /* |