From patchwork Mon Nov 2 15:04:42 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krishna Chaitanya X-Patchwork-Id: 539011 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2001:1868:205::9]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 05548140DA5 for ; Tue, 3 Nov 2015 02:05:35 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b=eEboojMw; dkim-atps=neutral Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZtGfp-0000lz-9E; Mon, 02 Nov 2015 15:05:29 +0000 Received: from mail-wi0-x235.google.com ([2a00:1450:400c:c05::235]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZtGfm-0000GJ-H9 for hostap@lists.infradead.org; Mon, 02 Nov 2015 15:05:27 +0000 Received: by wicll6 with SMTP id ll6so51854722wic.1 for ; Mon, 02 Nov 2015 07:05:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=te+yjG6wFbkS/6vDXQerwsl0axwhphd8M9uzx7MlYfg=; b=eEboojMwCqfFryVDHirN66XsRTtr0jahqfZBMZDC9TzrS0FWpkcFb61ZVpZOtHU55J eHuu+hbtrWzUFr3Kyn/27nndSzIzvjjJSjx42hO0tNytu77vvcMisJnt5WYEjyLPlT4x y4qyclTlRjO9gcql3Vm2MDTqHIiZybael7GPCDGYMQekf8KTHHISUW0Z5gHWsL4Nk/gj +mB4PcdhItrO7GDHV/kvfnz6E5ZOjCGb+cNUQzXtByI/pEeJdbIJxwS47ADA1iXu2k4p i3dw2GKbJUgzclbWCVM8VhTWuAlp4PY8hTBhKe4KQVkBcNbeLZPbdbsalXcmJVrZzjOt H6fA== X-Received: by 10.194.187.41 with SMTP id fp9mr27315185wjc.14.1446476704604; Mon, 02 Nov 2015 07:05:04 -0800 (PST) Received: from rocky.hb.imgtec.org ([115.112.122.66]) by smtp.gmail.com with ESMTPSA id 20sm18598034wmh.8.2015.11.02.07.05.01 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 02 Nov 2015 07:05:04 -0800 (PST) From: Chaitanya T K To: hostap@lists.infradead.org, linux-wireless@vger.kernel.org, j@w1.fi Subject: [PATCH] offchannel: Cancel the pending_action TX wait, before starting new one. Date: Mon, 2 Nov 2015 20:34:42 +0530 Message-Id: <1446476682-23007-1-git-send-email-chaitanya.mgit@gmail.com> X-Mailer: git-send-email 1.7.9.5 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20151102_070526_723382_EF134206 X-CRM114-Status: UNSURE ( 9.05 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.7 (--) X-Spam-Report: SpamAssassin version 3.4.0 on bombadil.infradead.org summary: Content analysis details: (-2.7 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [2a00:1450:400c:c05:0:0:0:235 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (chaitanya.mgit[at]gmail.com) -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature X-BeenThere: hostap@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: tkc MIME-Version: 1.0 Sender: "Hostap" Errors-To: hostap-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org From: tkc From: Chaitanya T K Before the tx_status is received for the action frame, if we get another request, we respond to that by freeing the memory for pending_action_tx, but we don't cancel the TX wait, so in the kernel the ROC will not be cancelled. Due to above issue, wpa_supplicant assumes that all pending RoC's are cancelled and proceeds with interface creation and connection, where as state in mac80211/driver will be roc_in_progress. This is leading to issues at driver level. Signed-off-by: Chaitanya T K --- wpa_supplicant/offchannel.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/wpa_supplicant/offchannel.c b/wpa_supplicant/offchannel.c index 6b3f83c..bd2f905 100644 --- a/wpa_supplicant/offchannel.c +++ b/wpa_supplicant/offchannel.c @@ -254,13 +254,7 @@ int offchannel_send_action(struct wpa_supplicant *wpa_s, unsigned int freq, wpa_s->pending_action_tx_status_cb = tx_cb; if (wpa_s->pending_action_tx) { - wpa_printf(MSG_DEBUG, "Off-channel: Dropped pending Action " - "frame TX to " MACSTR " (pending_action_tx=%p)", - MAC2STR(wpa_s->pending_action_dst), - wpa_s->pending_action_tx); - wpa_hexdump_buf(MSG_MSGDUMP, "Pending TX frame", - wpa_s->pending_action_tx); - wpabuf_free(wpa_s->pending_action_tx); + offchannel_send_action_done(wpa_s); } wpa_s->pending_action_tx_done = 0; wpa_s->pending_action_tx = wpabuf_alloc(len);