From patchwork Mon Jul 10 12:40:46 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amitkumar Karwar X-Patchwork-Id: 9832917 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 0F0B760318 for ; Mon, 10 Jul 2017 12:45:52 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 02587269E2 for ; Mon, 10 Jul 2017 12:45:52 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E959A27FB7; Mon, 10 Jul 2017 12:45:51 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.5 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9AD8A269E2 for ; Mon, 10 Jul 2017 12:45:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754013AbdGJMpp (ORCPT ); Mon, 10 Jul 2017 08:45:45 -0400 Received: from mail-pf0-f196.google.com ([209.85.192.196]:34962 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753955AbdGJMpo (ORCPT ); Mon, 10 Jul 2017 08:45:44 -0400 Received: by mail-pf0-f196.google.com with SMTP id q85so14376774pfq.2 for ; Mon, 10 Jul 2017 05:45:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=7lnKwvcDtiBcoX+gARaiGRGR0BpmVomLAU9R4Esy4q0=; b=beDnNh82R3OV7MQtNw4oRg3tL6AAPZ5fCxmvJNbOvOpJyLyZPeEJGRPuZhsS5aUOvW i0J4Xb7YueL7bOwalzo4haiLlyTzfeYWUzg34Lhoo58bTf/ajUgnAneEjoEbO/kYBV1W p5K0WVhRMv3N+O4YmOD5jK5HoZF5Vho+J+pqln36E/PsTXezdt6xBK69sqkMKq/rw3Yk 9YdTpHCY9Aspwd75JPlu2pLVRA6zPJR+vq74s4GeauGXO/69Vf+6xNva5EZirMH+wwjC Z2P9O57JPQT0EVxzTByc+Qal9+P2NZctw2RYjVCJUu8DBmt5AVFUkRdJYNooJG3nIFFP VNOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=7lnKwvcDtiBcoX+gARaiGRGR0BpmVomLAU9R4Esy4q0=; b=NZeQyLAtfPzBV39LRgOxNfRqW6kOGBGIckQd/ZuOeGIgpvZN6ohXnuenuuIHvnae42 1HpTvDZqR8lV3Jp9+shMXEdgnFY05gSsY24R1oefwt38ukeezm7y+TVlV6AbCwy7r8Yg yUSUfOgAbvb9hR0XttmqrlGYanWWNpawQICXZc8IRGCQoOQUK5Hbvcq0pQJfrOcXrG7D K5J/lhDaD9ZYg13HNEXQBzvWU71/XozydJtadN97ziMzhZs/qmpMeomVuuRbfgBy404J jTI45iWfgXDg+TlZTifsu8z7V9j0M1sGzJp4c6f0STLcvg4YBXUOtwdR33SuoxlBq6FI hJ9Q== X-Gm-Message-State: AIVw110C6fd62hwJ152YjcfbTnjEju822xCq1e/qkZZs9W+qfDHEYczh CglnPc8ff3t2stYf X-Received: by 10.84.195.3 with SMTP id i3mr17525230pld.65.1499690738613; Mon, 10 Jul 2017 05:45:38 -0700 (PDT) Received: from cpu185.redpinesignals.com ([203.196.161.90]) by smtp.gmail.com with ESMTPSA id s9sm27503963pfe.67.2017.07.10.05.45.36 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 10 Jul 2017 05:45:38 -0700 (PDT) From: Amitkumar Karwar To: Kalle Valo Cc: linux-wireless@vger.kernel.org, Amitkumar Karwar , Prameela Rani Garnepudi Subject: [v2 15/17] rsi: Remove internal header from Tx status skb Date: Mon, 10 Jul 2017 18:10:46 +0530 Message-Id: <1499690448-9956-16-git-send-email-amitkarwar@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1499690448-9956-1-git-send-email-amitkarwar@gmail.com> References: <1499690448-9956-1-git-send-email-amitkarwar@gmail.com> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Prameela Rani Garnepudi Device specific descriptor for each TX packet is prepared on top of skb data address. This descriptor should be pulled out before indicating the TX status to mac80211. Signed-off-by: Prameela Rani Garnepudi Signed-off-by: Amitkumar Karwar --- drivers/net/wireless/rsi/rsi_91x_mac80211.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/rsi/rsi_91x_mac80211.c b/drivers/net/wireless/rsi/rsi_91x_mac80211.c index 021e5ac..36303ae 100644 --- a/drivers/net/wireless/rsi/rsi_91x_mac80211.c +++ b/drivers/net/wireless/rsi/rsi_91x_mac80211.c @@ -229,12 +229,20 @@ void rsi_indicate_tx_status(struct rsi_hw *adapter, int status) { struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb); + struct skb_info *tx_params; - memset(info->driver_data, 0, IEEE80211_TX_INFO_DRIVER_DATA_SIZE); + if (!adapter->hw) { + rsi_dbg(ERR_ZONE, "##### No MAC #####\n"); + return; + } if (!status) info->flags |= IEEE80211_TX_STAT_ACK; + tx_params = (struct skb_info *)info->driver_data; + skb_pull(skb, tx_params->internal_hdr_size); + memset(info->driver_data, 0, IEEE80211_TX_INFO_DRIVER_DATA_SIZE); + ieee80211_tx_status_irqsafe(adapter->hw, skb); }