Received: by 2002:a05:7412:bbc7:b0:fc:a2b0:25d7 with SMTP id kh7csp3132067rdb; Tue, 6 Feb 2024 08:03:14 -0800 (PST) X-Google-Smtp-Source: AGHT+IH+TJq9voP3MZYgJSwwQCWSsBV99AkmonfaPHqjzrRvuK0JLVPPu7RaLVj/nQY2EE3AHyH5 X-Received: by 2002:aa7:864d:0:b0:6e0:5249:69e6 with SMTP id a13-20020aa7864d000000b006e0524969e6mr3057908pfo.17.1707235394687; Tue, 06 Feb 2024 08:03:14 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707235394; cv=pass; d=google.com; s=arc-20160816; b=SXiU4IwqeKYif9pWp+SAlpHXXzo4x11haqOqxqKRoa0MCjvE8eWEjrkcD5GaTULiRx Vd1wNchb0i15HHHXhwM6OqrVu8YKrwuxRG/+Tf7uxsYT4IkSEWr4Bts8iHNq/qiZuoK9 B9is+OdSmstINnwtXbpieGrn7Mnj/QyB4+LyqzGkBqMYu87sQjufonme+DBilDNajdiJ CduC+/e5m89NNcuU/6gUfeTAz5YYVo+AM7DR/Eo0tU02dH1+jXuYGEUWAmgSka0jU+fV jjYPbTDm8RAHfmOE9XjYpcCg8wD3fBa2F+qWcGjBH0D1DOq2H/1voYaxRB/nwenFsk8/ M/dw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:organization:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=mRSt2XvwcDE1xc9TS3sGpBphYKNY0mZzAPhoOuEHUdw=; fh=knxyPNsav/dYkz5HXn2D+3u8A/9O6WvTMrcyE9SOwCw=; b=AIgVj/c0NmGh5nrS/KWSXtntHVa9bwtAvCSO38yHg6wIlDR0fKJvYBdqzvUkDvcfgU Kt1f5cykv9sBKj+UOuk2Z3voOEqVgurrQOH1TX2aQZcA553yn6Nhla+rkaPCwrKyu3f8 OTOmtUIGf0GFNPKFAuS91cUTNd2SRloempHxXzyn+KQdoVLsGixef6478uvY85xD6tGa pfCcNr8cNzWeQ2eYKCY3hEQXfpAc/Bo68v81SQXY49U4vNPl4ga+16QHZCc5ykYc70Jj /ohLKgIkNvNknfD8ZEfdo16Dvhsq45mxHdoLH2sRrOJRoSwXD/OdJ5pcDMrv93DiSA8v cJsg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=biS8pUCr; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: domain of linux-wireless+bounces-3240-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-3240-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com X-Forwarded-Encrypted: i=1; AJvYcCUKs0W/AeqgU1BxkEe3qDqjrLvnSkry+6HR0zGPsvAMPkh3vMH5Rwj2dipusHOFU9tY7xXoctxQGDA1FgbOuBRljqHTsTw7sUUh80wdIw== Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id bq25-20020a056a000e1900b006e047cefa0fsi1832292pfb.82.2024.02.06.08.03.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Feb 2024 08:03:14 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless+bounces-3240-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=biS8pUCr; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: domain of linux-wireless+bounces-3240-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-3240-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 568A12907ED for ; Tue, 6 Feb 2024 16:03:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7FEF0134CC2; Tue, 6 Feb 2024 16:02:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="biS8pUCr" X-Original-To: linux-wireless@vger.kernel.org Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.9]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E36B1134CE2 for ; Tue, 6 Feb 2024 16:02:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.175.65.9 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707235365; cv=none; b=iOmxoi9NMmjxV1Y3uXw/KzZfoxGt1dlDdjuRk0o6SBMz6Jv3ti1ZkaWMiCYziUt08zVVsWpEMfWb1qyI3qSVQrj1Tneb3Kl9vbCgBNhdmNEL6G6Bgo/fG6QzROgs8z69CzSsiZJzfnPdWaAn7wK9a87p4qJs3crzycqU0eEw/C8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707235365; c=relaxed/simple; bh=fkU0LPKftaA7BihYZTIDQ6Vcd3L6sWgNc+unk7ZCQ0I=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=Qmrge4dsZLcN/FXgade16TWewZio8rzEHXYb2sW3NdorhiMPxjZpTpn17VU+RDuLdBIWR5dIO/hRRyPGQ/BHyO0e0xlE62ylELqpeuC8f40hEngx7yU0zUWG+mJjcZcmgNW3mLokqYv53gc2RxEld/svtBoeQFdWM+cYGP25adc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com; spf=pass smtp.mailfrom=intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=biS8pUCr; arc=none smtp.client-ip=198.175.65.9 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=intel.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1707235364; x=1738771364; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=fkU0LPKftaA7BihYZTIDQ6Vcd3L6sWgNc+unk7ZCQ0I=; b=biS8pUCr6yXRT72fEyguH1BWh5OzBfZF7aHUpsy55hTnxwxuDfRvpOqI y1UF11vQs2oCqQ5AdyloFdQkVeDqs1JMeWnTVOQwRwZmBOuSRc/nh3fyS bEHcap2wcqusy8VBKmm9PgfpuJ35Mtd3bMgEpKvbEjLsiGGUigMO9Jqcf 7NYl0gmEY5wFwKR9OK3T/UHM9uYAnBZtU+/tpbg/URr+2GvtsJ8aoB1/O cT9BNcYCUp3g+n9ucnlD/n+LRitRiSZrReNcPlel4dY4Rfz1to/JpMbPZ lROvaInjSCZIuzSR9zgBCou2eBtSAUVWtul/L2O5cWJn6qulG3ZwN1WTa w==; X-IronPort-AV: E=McAfee;i="6600,9927,10976"; a="23252445" X-IronPort-AV: E=Sophos;i="6.05,247,1701158400"; d="scan'208";a="23252445" Received: from fmviesa006.fm.intel.com ([10.60.135.146]) by orvoesa101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Feb 2024 08:02:44 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.05,247,1701158400"; d="scan'208";a="1349850" Received: from unknown (HELO WEIS0040.iil.intel.com) ([10.12.217.108]) by fmviesa006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Feb 2024 08:02:42 -0800 From: Miri Korenblit To: johannes@sipsolutions.net Cc: linux-wireless@vger.kernel.org, Shaul Triebitz Subject: [PATCH 09/11] wifi: iwlwifi: iwlmvm: handle unprotected deauth/disassoc in d3 Date: Tue, 6 Feb 2024 18:02:12 +0200 Message-Id: <20240206175739.fde438a22e3f.I3c8497520aaa95a22febff727b0ad08146965d47@changeid> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240206160214.3260547-1-miriam.rachel.korenblit@intel.com> References: <20240206160214.3260547-1-miriam.rachel.korenblit@intel.com> Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Organization: Intel Israel (74) Limited Content-Transfer-Encoding: 8bit From: Shaul Triebitz In MFP, do not disconnect if an unprotected deauth or disassoc was received during D3. For that, need to configure wowlan with MFP (IS_11W_ASSOC). Now, in case of an unprotected deauth/disassoc, the wakeup reason returned by the firmware will be: IWL_WAKEUP_BY_11W_UNPROTECTED_DEAUTH_OR_DISASSOC (and not IWL_WOWLAN_WAKEUP_BY_DISCONNECTION_ON_DEAUTH which will cause a disconnection). Also, report this reason to cfg80211. In another patch, the driver will send an SA query. Signed-off-by: Shaul Triebitz Signed-off-by: Miri Korenblit --- drivers/net/wireless/intel/iwlwifi/mvm/d3.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/d3.c b/drivers/net/wireless/intel/iwlwifi/mvm/d3.c index e1c77276557d..26c01d740d0d 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/d3.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/d3.c @@ -925,6 +925,9 @@ iwl_mvm_get_wowlan_config(struct iwl_mvm *mvm, wowlan_config_cmd->flags = ENABLE_L3_FILTERING | ENABLE_NBNS_FILTERING | ENABLE_DHCP_FILTERING; + if (ap_sta->mfp) + wowlan_config_cmd->flags |= IS_11W_ASSOC; + if (iwl_fw_lookup_cmd_ver(mvm->fw, WOWLAN_CONFIGURATION, 0) < 6) { /* Query the last used seqno and set it */ int ret = iwl_mvm_get_last_nonqos_seq(mvm, vif); @@ -1511,6 +1514,9 @@ static void iwl_mvm_report_wakeup_reasons(struct iwl_mvm *mvm, if (reasons & IWL_WOWLAN_WAKEUP_BY_REM_WAKE_WAKEUP_PACKET) wakeup.tcp_match = true; + if (reasons & IWL_WAKEUP_BY_11W_UNPROTECTED_DEAUTH_OR_DISASSOC) + wakeup.unprot_deauth_disassoc = true; + if (status->wake_packet) { int pktsize = status->wake_packet_bufsize; int pktlen = status->wake_packet_length; -- 2.34.1