From patchwork Mon Oct 16 06:01:37 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: yintang@qti.qualcomm.com X-Patchwork-Id: 10007711 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 691ED60235 for ; Mon, 16 Oct 2017 06:00:02 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 58B3427D4A for ; Mon, 16 Oct 2017 06:00:02 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4B80127DA4; Mon, 16 Oct 2017 06:00:02 +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=-4.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id E126627D4A for ; Mon, 16 Oct 2017 06:00:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=MxUTpIGna6zbVfKjQcIML1lJ6bKG5QRl5fesOMfoE/Y=; b=QstlvtwJ4Sa6y6 oqUK3PeW5XaZV3R65I7B8Al1hBo5veBY+TEkQvYG9igx+n7rV6OPUs8lCMcosgu12wNVkHpK6w7XV EWlxB4NV4N+2KCsrZkns8Yc1ZNuCp3cC9u3GA/XFI6csIaW4fRR5ZJeezxhjJpLKOT5NOlgTxWPca D5BzCDEbMPOMmyWbQdvkhS660DxGWIVK3vujYj+Ggx6uRg5RbuHs16/HcwC9lT27FqU0DZIOZNCEx DJD3TxSeD8zvuUW+2tlPLpq5qokbBB3fcVovrF8xtDenud3r28EqMKDLkunoSf1UDM1wMtUWR4eDY dr2Ma9DfqQ90bYDCmCkA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1e3yRR-0007HV-Ur; Mon, 16 Oct 2017 05:59:57 +0000 Received: from alexa-out.qualcomm.com ([129.46.98.28]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1e3yRO-0007CL-5D for ath10k@lists.infradead.org; Mon, 16 Oct 2017 05:59:55 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=qti.qualcomm.com; i=@qti.qualcomm.com; q=dns/txt; s=qcdkim; t=1508133594; x=1539669594; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version; bh=Bqi56Q+fHcUs6lzdv1oPx2dGuVOjW4RSO35QmugZpK0=; b=hZGLASpkcIJ9B3pyisYXpHBI2nV3bAFYWcCRdx7k597Q58F/pq11GrcA CR1nS37CAZ7ycasfExSaFzTQoBBrB0XRRF7IdujCMRmzyYz4iEZOZTSVQ 7v8JFIlj+8key1I59EKhp7pzzuuNllfv+FMQ00DlDku9Jwda318Gf1ApK U=; X-IronPort-AV: E=Sophos;i="5.43,385,1503385200"; d="scan'208";a="6372600" Received: from ironmsg04-l-new.qualcomm.com (HELO Ironmsg04-L.qualcomm.com) ([10.53.140.111]) by alexa-out.qualcomm.com with ESMTP; 15 Oct 2017 22:59:34 -0700 X-IronPort-AV: E=McAfee;i="5900,7806,8685"; a="1444069765" X-MGA-submission: =?us-ascii?q?MDE17VfgTdJ86APbtnM7DgiE8hPBXVCVo1/u/T?= =?us-ascii?q?E/PxI1gdtlRSJiuTxZQbDCl3bnj6NnEp84oIWARVsE7E2Mqay5ZoD9kh?= =?us-ascii?q?GqjpBPJMz69rgAcT0KrZyi+vVmweUF2t1GSTcTGEfMQEBk56yerbyqTJ?= =?us-ascii?q?vv?= Received: from nasanexm01h.na.qualcomm.com ([10.85.0.34]) by Ironmsg04-L.qualcomm.com with ESMTP/TLS/AES256-SHA; 15 Oct 2017 22:59:33 -0700 Received: from aptaiexm02b.ap.qualcomm.com (10.249.150.12) by NASANEXM01H.na.qualcomm.com (10.85.0.34) with Microsoft SMTP Server (TLS) id 15.0.1293.2; Sun, 15 Oct 2017 22:59:32 -0700 Received: from yintang-HP-EliteBook-1.qca.qualcomm.com (10.80.80.8) by aptaiexm02b.ap.qualcomm.com (10.249.150.12) with Microsoft SMTP Server (TLS) id 15.0.1293.2; Mon, 16 Oct 2017 13:59:28 +0800 From: To: Subject: [PATCH V6 5/5] ath10k: Fix TDLS peer TX data failure issue on encryped AP Date: Mon, 16 Oct 2017 14:01:37 +0800 Message-ID: <1508133697-23255-1-git-send-email-yintang@qti.qualcomm.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: MIME-Version: 1.0 X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: NASANEXM01C.na.qualcomm.com (10.85.0.83) To aptaiexm02b.ap.qualcomm.com (10.249.150.12) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171015_225954_255122_5BBE0126 X-CRM114-Status: UNSURE ( 5.44 ) X-CRM114-Notice: Please train this message. X-BeenThere: ath10k@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-wireless@vger.kernel.org Sender: "ath10k" Errors-To: ath10k-bounces+patchwork-ath10k=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Yingying Tang For WPA encryption, QCA6174 firmware(version: WLAN.RM.4.4) will unblock data when M4 was sent successfully. For other encryption which didn't need 4-way handshake firmware will unblock the data when peer authorized. Since TDLS is 3-way handshake host need send authorize cmd to firmware to unblock data. Signed-off-by: Yingying Tang --- drivers/net/wireless/ath/ath10k/mac.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/net/wireless/ath/ath10k/mac.c b/drivers/net/wireless/ath/ath10k/mac.c index a984a72..fe14d3c 100644 --- a/drivers/net/wireless/ath/ath10k/mac.c +++ b/drivers/net/wireless/ath/ath10k/mac.c @@ -5841,6 +5841,10 @@ static int ath10k_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd, ath10k_warn(ar, "Peer %pM disappeared!\n", peer_addr); spin_unlock_bh(&ar->data_lock); + if (sta && sta->tdls) + ath10k_wmi_peer_set_param(ar, arvif->vdev_id, sta->addr, + WMI_PEER_AUTHORIZE, 1); + exit: mutex_unlock(&ar->conf_mutex); return ret;