mwifiex: fix hang issue for USB chipsets
Bug 60815 - Interface hangs in mwifiex_usb https://bugzilla.kernel.org/show_bug.cgi?id=60815 We have 4 bytes of interface header for packets delivered to SDIO and PCIe, but not for USB interface. In Tx AMSDU case, currently 4 bytes of garbage data is unnecessarily appended for USB packets. This sometimes leads to a firmware hang, because it may not interpret the data packet correctly. Problem is fixed by removing this redundant headroom for USB. Cc: <stable@vger.kernel.org> # 3.5+ Tested-by: Dmitry Khromov <icechrome@gmail.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
1e43692cdb
commit
bd1c6142ed
3 changed files with 4 additions and 4 deletions
|
@ -150,7 +150,7 @@ mwifiex_11n_form_amsdu_txpd(struct mwifiex_private *priv,
|
|||
*/
|
||||
int
|
||||
mwifiex_11n_aggregate_pkt(struct mwifiex_private *priv,
|
||||
struct mwifiex_ra_list_tbl *pra_list, int headroom,
|
||||
struct mwifiex_ra_list_tbl *pra_list,
|
||||
int ptrindex, unsigned long ra_list_flags)
|
||||
__releases(&priv->wmm.ra_list_spinlock)
|
||||
{
|
||||
|
@ -160,6 +160,7 @@ mwifiex_11n_aggregate_pkt(struct mwifiex_private *priv,
|
|||
int pad = 0, ret;
|
||||
struct mwifiex_tx_param tx_param;
|
||||
struct txpd *ptx_pd = NULL;
|
||||
int headroom = adapter->iface_type == MWIFIEX_USB ? 0 : INTF_HEADER_LEN;
|
||||
|
||||
skb_src = skb_peek(&pra_list->skb_head);
|
||||
if (!skb_src) {
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
int mwifiex_11n_deaggregate_pkt(struct mwifiex_private *priv,
|
||||
struct sk_buff *skb);
|
||||
int mwifiex_11n_aggregate_pkt(struct mwifiex_private *priv,
|
||||
struct mwifiex_ra_list_tbl *ptr, int headroom,
|
||||
struct mwifiex_ra_list_tbl *ptr,
|
||||
int ptr_index, unsigned long flags)
|
||||
__releases(&priv->wmm.ra_list_spinlock);
|
||||
|
||||
|
|
|
@ -1239,8 +1239,7 @@ mwifiex_dequeue_tx_packet(struct mwifiex_adapter *adapter)
|
|||
if (enable_tx_amsdu && mwifiex_is_amsdu_allowed(priv, tid) &&
|
||||
mwifiex_is_11n_aggragation_possible(priv, ptr,
|
||||
adapter->tx_buf_size))
|
||||
mwifiex_11n_aggregate_pkt(priv, ptr, INTF_HEADER_LEN,
|
||||
ptr_index, flags);
|
||||
mwifiex_11n_aggregate_pkt(priv, ptr, ptr_index, flags);
|
||||
/* ra_list_spinlock has been freed in
|
||||
mwifiex_11n_aggregate_pkt() */
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue