Эх сурвалжийг харах

qcacmn: Set the num of subchans for 240MHZ as 12

In 5 GHz band, a 320 MHz band channel cannot be formed without
puncturing. Hence the contiguous available BW is 240MHZ which has
twelve 20MHZ channels from 5500 - 5720. Send CAC start/CAC
complete/radar detect information only for the channels which are
not punctured.

CRs-Fixed: 3200931
Change-Id: I5c2bc3314df6d1d61500e7fb24eef4a096ba4bb5
Priyadarshnee Srinivasan 3 жил өмнө
parent
commit
a485ae2901

+ 3 - 1
umac/dfs/core/src/dfs_process_radar_found_ind.h

@@ -1,6 +1,6 @@
 /*
  * Copyright (c) 2017-2021 The Linux Foundation. All rights reserved.
- * Copyright (c) 2021 Qualcomm Innovation Center, Inc. All rights reserved.
+ * Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved.
  *
  * Permission to use, copy, modify, and/or distribute this software for
  * any purpose with or without fee is hereby granted, provided that the
@@ -115,6 +115,8 @@ dfs_flush_additional_pulses(struct wlan_dfs *dfs)
 #define NUM_CHANNELS_160MHZ  8
 /* Number of 20MHz sub-channels in 320 MHz segment */
 #define NUM_CHANNELS_320MHZ 16
+/* Number of 20MHz sub-channels in 240 MHz (320-80) segment */
+#define NUM_CHANNELS_240MHZ 12
 
 #ifdef WLAN_FEATURE_11BE
 #define MAX_20MHZ_SUBCHANS NUM_CHANNELS_320MHZ

+ 6 - 1
umac/dfs/core/src/misc/dfs_process_radar_found_ind.c

@@ -585,7 +585,12 @@ void dfs_get_320mhz_bonding_channels(uint16_t center_freq, uint16_t *freq_list,
 {
 	uint16_t chwidth = 320;
 
-	*nchannels = 16;
+	/*
+	 * In 5Ghz band, the 320Mhz channel is always 80Mhz punctured
+	 * to the right. Therefore, it is actually a 240Mhz channel and
+	 * has twelve 20Mhz subchannels.
+	 */
+	*nchannels = NUM_CHANNELS_240MHZ;
 	dfs_calc_bonding_freqs(center_freq, chwidth, freq_list);
 }
 #else