Re: [PATCH ath-next] wifi: ath11k: fix reg_info_store leak in ath11k_service_ready_ext_event()

Baochen Qiang <[email protected]>
Newsgroups org.infradead.lists.ath11k,org.kernel.vger.linux-kernel,org.kernel.vger.linux-wireless
Message-ID <[email protected]>

On 8/18/2026 7:46 AM, Jeff Johnson wrote:
> Currently, while processing the WMI Service Ready Ext event, the iterator
> in ath11k_service_ready_ext_event() can dispatch the HAL Regulatory
> Capabilities handler ath11k_wmi_tlv_ext_soc_hal_reg_caps_parse() which can
> allocate ab->reg_info_store.
> 
> If a subsequent failure occurs during iteration, the ab->reg_info_store
> allocation is leaked.
> 
> Directly free and clear the pointer on the error path.
> 
> Note that the normal cleanup function ath11k_reg_free() cannot be used
> since other regulatory-related fields are not yet populated at this point.
> 
> Compile tested only.
> 
> Fixes: 7004bdceef60 ("wifi: ath11k: store cur_regulatory_info for each radio")
> Assisted-by: Claude:claude-sonnet-4-6
> Signed-off-by: Jeff Johnson <[email protected]>

Reviewed-by: Baochen Qiang <[email protected]>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.