diff --git a/fw/wlan_defs.h b/fw/wlan_defs.h index beeb87b17a75..9c878dc41fe3 100755 --- a/fw/wlan_defs.h +++ b/fw/wlan_defs.h @@ -172,11 +172,23 @@ typedef enum { #endif } WLAN_PHY_MODE; -#ifndef CONFIG_160MHZ_SUPPORT +#if (!defined(CONFIG_160MHZ_SUPPORT)) && (!defined(SUPPORT_11AX)) A_COMPILE_TIME_ASSERT( mode_unknown_value_consistency_Check, MODE_UNKNOWN == MODE_UNKNOWN_NO_160MHZ_SUPPORT); #else +/* + * If SUPPORT_11AX is defined but CONFIG_160MHZ_SUPPORT is not defined, + * there will be a gap in the mode values, with 14 and 15 being unused. + * But MODE_UNKNOWN_NO_160MHZ_SUPPORT will have an invalid value, since + * mode values 16 through 23 will be used for 11AX modes. + * Thus, MODE_UNKNOWN would still be MODE_UNKNOWN_160MHZ_SUPPORT, for + * cases where 160 MHz is not supported by 11AX is supported. + * (Ideally, MODE_UNKNOWN_160MHZ_SUPPORT and NO_160MHZ_SUPPORT should be + * renamed to cover the 4 permutations of support or no support for + * 11AX and 160 MHZ, but that is impractical, due to backwards + * compatibility concerns.) + */ A_COMPILE_TIME_ASSERT( mode_unknown_value_consistency_Check, MODE_UNKNOWN == MODE_UNKNOWN_160MHZ_SUPPORT);