Commit 3c3052ea authored by John W. Linville's avatar John W. Linville

Merge branch 'master' of...

Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless into for-davem
parents 5a8887d3 ed90542b
...@@ -373,7 +373,7 @@ static void ar9003_hw_spur_ofdm_work(struct ath_hw *ah, ...@@ -373,7 +373,7 @@ static void ar9003_hw_spur_ofdm_work(struct ath_hw *ah,
else else
spur_subchannel_sd = 0; spur_subchannel_sd = 0;
spur_freq_sd = (freq_offset << 9) / 11; spur_freq_sd = ((freq_offset + 10) << 9) / 11;
} else { } else {
if (REG_READ_FIELD(ah, AR_PHY_GEN_CTRL, if (REG_READ_FIELD(ah, AR_PHY_GEN_CTRL,
...@@ -382,7 +382,7 @@ static void ar9003_hw_spur_ofdm_work(struct ath_hw *ah, ...@@ -382,7 +382,7 @@ static void ar9003_hw_spur_ofdm_work(struct ath_hw *ah,
else else
spur_subchannel_sd = 1; spur_subchannel_sd = 1;
spur_freq_sd = (freq_offset << 9) / 11; spur_freq_sd = ((freq_offset - 10) << 9) / 11;
} }
......
...@@ -2637,6 +2637,7 @@ static int brcmf_sdbrcm_dpc_thread(void *data) ...@@ -2637,6 +2637,7 @@ static int brcmf_sdbrcm_dpc_thread(void *data)
/* after stopping the bus, exit thread */ /* after stopping the bus, exit thread */
brcmf_sdbrcm_bus_stop(bus->sdiodev->dev); brcmf_sdbrcm_bus_stop(bus->sdiodev->dev);
bus->dpc_tsk = NULL; bus->dpc_tsk = NULL;
spin_lock_irqsave(&bus->dpc_tl_lock, flags);
break; break;
} }
......
...@@ -773,8 +773,7 @@ static void iwlagn_pass_packet_to_mac80211(struct iwl_priv *priv, ...@@ -773,8 +773,7 @@ static void iwlagn_pass_packet_to_mac80211(struct iwl_priv *priv,
struct sk_buff *skb; struct sk_buff *skb;
__le16 fc = hdr->frame_control; __le16 fc = hdr->frame_control;
struct iwl_rxon_context *ctx; struct iwl_rxon_context *ctx;
struct page *p; unsigned int hdrlen, fraglen;
int offset;
/* We only process data packets if the interface is open */ /* We only process data packets if the interface is open */
if (unlikely(!priv->is_open)) { if (unlikely(!priv->is_open)) {
...@@ -788,16 +787,24 @@ static void iwlagn_pass_packet_to_mac80211(struct iwl_priv *priv, ...@@ -788,16 +787,24 @@ static void iwlagn_pass_packet_to_mac80211(struct iwl_priv *priv,
iwlagn_set_decrypted_flag(priv, hdr, ampdu_status, stats)) iwlagn_set_decrypted_flag(priv, hdr, ampdu_status, stats))
return; return;
skb = dev_alloc_skb(128); /* Dont use dev_alloc_skb(), we'll have enough headroom once
* ieee80211_hdr pulled.
*/
skb = alloc_skb(128, GFP_ATOMIC);
if (!skb) { if (!skb) {
IWL_ERR(priv, "dev_alloc_skb failed\n"); IWL_ERR(priv, "alloc_skb failed\n");
return; return;
} }
hdrlen = min_t(unsigned int, len, skb_tailroom(skb));
memcpy(skb_put(skb, hdrlen), hdr, hdrlen);
fraglen = len - hdrlen;
offset = (void *)hdr - rxb_addr(rxb); if (fraglen) {
p = rxb_steal_page(rxb); int offset = (void *)hdr + hdrlen - rxb_addr(rxb);
skb_add_rx_frag(skb, 0, p, offset, len, len);
skb_add_rx_frag(skb, 0, rxb_steal_page(rxb), offset,
fraglen, rxb->truesize);
}
iwl_update_stats(priv, false, fc, len); iwl_update_stats(priv, false, fc, len);
/* /*
......
...@@ -374,8 +374,9 @@ static void iwl_rx_handle_rxbuf(struct iwl_trans *trans, ...@@ -374,8 +374,9 @@ static void iwl_rx_handle_rxbuf(struct iwl_trans *trans,
if (WARN_ON(!rxb)) if (WARN_ON(!rxb))
return; return;
rxcb.truesize = PAGE_SIZE << hw_params(trans).rx_page_order;
dma_unmap_page(trans->dev, rxb->page_dma, dma_unmap_page(trans->dev, rxb->page_dma,
PAGE_SIZE << hw_params(trans).rx_page_order, rxcb.truesize,
DMA_FROM_DEVICE); DMA_FROM_DEVICE);
rxcb._page = rxb->page; rxcb._page = rxb->page;
......
...@@ -260,6 +260,7 @@ static inline void iwl_free_resp(struct iwl_host_cmd *cmd) ...@@ -260,6 +260,7 @@ static inline void iwl_free_resp(struct iwl_host_cmd *cmd)
struct iwl_rx_cmd_buffer { struct iwl_rx_cmd_buffer {
struct page *_page; struct page *_page;
unsigned int truesize;
}; };
static inline void *rxb_addr(struct iwl_rx_cmd_buffer *r) static inline void *rxb_addr(struct iwl_rx_cmd_buffer *r)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment