Search Linux Wireless

Re: [PATCH v2 0/2] wifi: ath11k: fix layout of scan_flags in struct scan_req_params

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2/9/2024 3:35 AM, Nicolas Escande wrote:
> As previously discussed in [1] we have a mismatch in struct scan_req_params
> between the bitfield scan_f_xxx & the scan_flags when used with WMI_SCAN_XXX
> values.
> 
> To fix the issue & prevent it from happenning again lets stop using & remove
> scan_flags altogether in the driver and only use the bitfield instead. That way
> even if the bitfield doesn't match the WMI_SCAN_XXX flags, the right value will
> still be sent through the wmi command to the firmware (see
> ath11k_wmi_copy_scan_event_cntrl_flags).
> 
> Questions:
>   - In the same rationale shouldn't we remove scan_events from the same struct ?

yes, scan_events is unused so it and the union+struct can be removed,
leaving just the u32 bitfield. feel free to submit that as a separate patch

>   - The same goes for ath12k, should I send a seperate patch or respin a v3 with
>     similar patches for ath12k ?

please send a separate series for ath12k since it has a separate mailing
list

> 
> [1] https://lore.kernel.org/all/20231127180559.1696041-1-nico.escande@xxxxxxxxx/
> 
> v2:
>   - remove explicit uses of scan_flags with WMI_SCAN_XXX flags
>   - remove the underlying union of scan_flags to only leave the bitfield
> 
> Nicolas Escande (2):
>   wifi: ath11k: Do not directly use scan_flags in struct scan_req_params
>   wifi: ath11k: remove scan_flags union from struct scan_req_params
> 
>  drivers/net/wireless/ath/ath11k/mac.c |  6 +--
>  drivers/net/wireless/ath/ath11k/wmi.c |  2 +-
>  drivers/net/wireless/ath/ath11k/wmi.h | 55 ++++++++++++---------------
>  3 files changed, 29 insertions(+), 34 deletions(-)
> 

Thank you for this cleanup!

/jeff




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux