浏览代码

mwifiex: fix cmd_skb headroom decreasing issue

Before calling host_to_card() to send the cmd to firmware,
we use skb_push() to add 4 bytes SDIO interface header at
the start of the data buffer. Since cmd_skb data structure
will be re-used at a later time, we need to restore its
headroom by removing the 4 bytes header.

Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: Marc Yang <yangyang@marvell.com>
Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Bing Zhao 14 年之前
父节点
当前提交
18bf965702
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      drivers/net/wireless/mwifiex/cmdevt.c

+ 2 - 0
drivers/net/wireless/mwifiex/cmdevt.c

@@ -206,6 +206,8 @@ static int mwifiex_dnld_cmd_to_fw(struct mwifiex_private *priv,
 					     cmd_node->cmd_skb->data,
 					     cmd_node->cmd_skb->data,
 					     cmd_node->cmd_skb->len, NULL);
 					     cmd_node->cmd_skb->len, NULL);
 
 
+	skb_pull(cmd_node->cmd_skb, INTF_HEADER_LEN);
+
 	if (ret == -1) {
 	if (ret == -1) {
 		dev_err(adapter->dev, "DNLD_CMD: host to card failed\n");
 		dev_err(adapter->dev, "DNLD_CMD: host to card failed\n");
 		if (wait_queue)
 		if (wait_queue)