Received: by 10.213.65.68 with SMTP id h4csp503122imn; Fri, 16 Mar 2018 09:43:38 -0700 (PDT) X-Google-Smtp-Source: AG47ELvOQ264LpfbS7sI8SIjesJLBQNh7TY4D30yhy0I6vSM/SzdRTUG0PjjoPT5tTldRLgIfZez X-Received: by 2002:a17:902:7804:: with SMTP id p4-v6mr2877116pll.17.1521218618580; Fri, 16 Mar 2018 09:43:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521218618; cv=none; d=google.com; s=arc-20160816; b=pxpumnFPWNPyNCWCAIdVHrTqbg1Yj/14y5tU3nV3ItsYCLt5uLoZEd2SctAA7cJnY1 GVQR92WZwAfitCNacG4pcPnV6AF+xN8f5rCJVJHR8LoRmZIqI3L5PyyJJWHsT/BINSDh mef1BgWirpRFKyaQW+mqaXCAGniJQe9oRo2NNwvTCfTmQaHyCFSvJ4ICqKGAxmOiBYmA Sp4mj0yH/Koarxb4bG3LY4tOanZ83odyOgFi+KVyjWh4fLoFfTxg18etO3c/J2CKyO5B UN7MCLBvUNPE4V+ZsB2ypavbXvQ1uMCaXnWeXBhMHBMlWkEYA1cz6HX9O0mS2u6d9mx+ MfBA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=LtJbozyRLNtkmV+igu8ZsF/10Hm+X3XWxD5xImibHZo=; b=JjSO/2Mj4ze/9zTEV8VXRUfmjASirJQ0Pi/0PBtNv23ujePlDAxjr4pxvZphMTVvkW O7dO0PtyRZIOgTbzV543zk6j+nxj6jpQG0BqBBXpFZ0gEc0005SJuvQ+R3OM4urR6WEA 8pj6VS+ER8n+5wf24asLxr6RIwJphWVgEaWu2B5CCgdJKmva/uhr6ulHXVXghnvAPKKX Dk26kgSyjYbCsWTn6RtvrPdkzAyvW5qVT/OWrHl/79lJVzf/Q7uHcIaM/W56SIpu3utK Uz8vAC5pIR0p1lR7fufZPMfw9wVqbNwG3+mniUIc2DCL62Oz3y4utkY/J3gTSLHQNBg2 n3+g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b13si5664529pfi.53.2018.03.16.09.43.24; Fri, 16 Mar 2018 09:43:38 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753026AbeCPQmO (ORCPT + 99 others); Fri, 16 Mar 2018 12:42:14 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:40392 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933763AbeCPPgk (ORCPT ); Fri, 16 Mar 2018 11:36:40 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 98B831065; Fri, 16 Mar 2018 15:36:39 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Manikanta Pubbisetty , Kalle Valo , Sasha Levin Subject: [PATCH 4.14 062/109] ath10k: update tdls teardown state to target Date: Fri, 16 Mar 2018 16:23:31 +0100 Message-Id: <20180316152333.334538628@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180316152329.844663293@linuxfoundation.org> References: <20180316152329.844663293@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.14-stable review patch. If anyone has any objections, please let me know. ------------------ From: Manikanta Pubbisetty [ Upstream commit 424ea0d174e82365f85c6770225dba098b8f1d5f ] It is required to update the teardown state of the peer when a tdls link with that peer is terminated. This information is useful for the target to perform some cleanups wrt the tdls peer. Without proper cleanup, target assumes that the peer is connected and blocks future connection requests, updating the teardown state of the peer addresses the problem. Tested this change on QCA9888 with 10.4-3.5.1-00018 fw version. Signed-off-by: Manikanta Pubbisetty Signed-off-by: Kalle Valo Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- drivers/net/wireless/ath/ath10k/mac.c | 10 ++++++++++ 1 file changed, 10 insertions(+) --- a/drivers/net/wireless/ath/ath10k/mac.c +++ b/drivers/net/wireless/ath/ath10k/mac.c @@ -6183,6 +6183,16 @@ static int ath10k_sta_state(struct ieee8 "mac vdev %d peer delete %pM sta %pK (sta gone)\n", arvif->vdev_id, sta->addr, sta); + if (sta->tdls) { + ret = ath10k_mac_tdls_peer_update(ar, arvif->vdev_id, + sta, + WMI_TDLS_PEER_STATE_TEARDOWN); + if (ret) + ath10k_warn(ar, "failed to update tdls peer state for %pM state %d: %i\n", + sta->addr, + WMI_TDLS_PEER_STATE_TEARDOWN, ret); + } + ret = ath10k_peer_delete(ar, arvif->vdev_id, sta->addr); if (ret) ath10k_warn(ar, "failed to delete peer %pM for vdev %d: %i\n",