From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 E4FDA1DF24A; Wed, 6 Nov 2024 12:07:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730894843; cv=none; b=KCqAQe0+BM8rw33eyRHwOqs/+790opclkPrFqf52Jtr0wt0WcPQLuXDWx6eg6BFgTH/8lxktP9K9H1bTSreLHXgmsHR7C9JCA4fe9oPhu3p7cwQU1Yg4bCFQ8QOoheM8nFKz6nGIWkTnhHfH2iGCyiEJHa/qMv9cVJwsPrwfWdc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730894843; c=relaxed/simple; bh=eqxeQ2BBYUAQsnhxN7Hcql3pn13anGruJyWAr7p10qY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=I6edi0jkcFyw+55lqSO4z726eQgGjKM/nTo+LahYuFbU4/5ArSWM0ZTllOlxB8KtyO1EVp2EIrqPgAO1jZTp1hswVtJ2mKXsHJrprVOsRVTdCqwqlHML3GTzD/2h3tUfyZMpu5qczoFrfb71WH7EP+lh4lsADBgafMrJ9t0nniY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=UfNC/ton; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="UfNC/ton" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 68F9FC4CECD; Wed, 6 Nov 2024 12:07:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1730894842; bh=eqxeQ2BBYUAQsnhxN7Hcql3pn13anGruJyWAr7p10qY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=UfNC/tonbQzPQA67x0hcbm7SOPywp+pq+mhYDoNi0x2rhEC0Stwj4Lw85p8JkBgzU g57SDxplhTmrqVpmAB8yYI5cac729BaA2nZJohnXWLJL4Hbi7kfXA5CREIg4py1Hxx ziIL7m8Jnqlw6QkBilYJjI5T+d0J5zlCZIWWU3g4= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Daniel Gabay , Ilan Peer , Miri Korenblit , Johannes Berg , Sasha Levin Subject: [PATCH 4.19 019/350] wifi: iwlwifi: mvm: fix iwl_mvm_max_scan_ie_fw_cmd_room() Date: Wed, 6 Nov 2024 12:59:07 +0100 Message-ID: <20241106120321.347531321@linuxfoundation.org> X-Mailer: git-send-email 2.47.0 In-Reply-To: <20241106120320.865793091@linuxfoundation.org> References: <20241106120320.865793091@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 4.19-stable review patch. If anyone has any objections, please let me know. ------------------ From: Daniel Gabay [ Upstream commit 916a5d9c5354c426220a0a6533a5e8ea1287d6ea ] Driver creates also the WFA TPC element, consider that in the calculation. Signed-off-by: Daniel Gabay Reviewed-by: Ilan Peer Signed-off-by: Miri Korenblit Link: https://patch.msgid.link/20240825191257.e710ce446b7f.I2715c6742e9c3d160e2ba41bc4b35de370d2ce34@changeid Signed-off-by: Johannes Berg Signed-off-by: Sasha Levin --- drivers/net/wireless/intel/iwlwifi/mvm/scan.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/scan.c b/drivers/net/wireless/intel/iwlwifi/mvm/scan.c index eb2d235e9dc59..7f9eeef17f231 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/scan.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/scan.c @@ -91,6 +91,8 @@ /* adaptive dwell default APs number in social channels (1, 6, 11) */ #define IWL_SCAN_ADWELL_DEFAULT_N_APS_SOCIAL 10 +#define WFA_TPC_IE_LEN 9 + struct iwl_mvm_scan_timing_params { u32 suspend_time; u32 max_out_time; @@ -328,8 +330,8 @@ static int iwl_mvm_max_scan_ie_fw_cmd_room(struct iwl_mvm *mvm) max_probe_len = SCAN_OFFLOAD_PROBE_REQ_SIZE; - /* we create the 802.11 header and SSID element */ - max_probe_len -= 24 + 2; + /* we create the 802.11 header SSID element and WFA TPC element */ + max_probe_len -= 24 + 2 + WFA_TPC_IE_LEN; /* DS parameter set element is added on 2.4GHZ band if required */ if (iwl_mvm_rrm_scan_needed(mvm)) @@ -727,8 +729,6 @@ static u8 *iwl_mvm_copy_and_insert_ds_elem(struct iwl_mvm *mvm, const u8 *ies, return newpos; } -#define WFA_TPC_IE_LEN 9 - static void iwl_mvm_add_tpc_report_ie(u8 *pos) { pos[0] = WLAN_EID_VENDOR_SPECIFIC; -- 2.43.0