wifi: ath11k/ath12k: bound READY MAC address array reads
Get series with b4
b4 am [email protected] change-id 20261015-rdy-mac-array-bounds-de70c7750217Versions newest first
- v2 Latest2 patches 0 repliesNew
- v1 RFC2 patches 0 repliesSuperseded
Changes in v2 from the cover letter
- Drop RFC.
- ath11k: note the hardware run and add a Tested-on tag; no code change.
- v1 was accidentally sent twice; apologies for the duplicate.
- Link to v1: https://patch.msgid.link/[email protected]
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | wifi: ath11k: bound READY MAC address array readsdrivers/ | +6 | 0 replies | |
| 2/2 | wifi: ath12k: bound READY MAC address array readsdrivers/ | +6 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [PATCH ath-next v2 0/2] wifi: ath11k/ath12k: bound READY MAC address array reads
ath11k_wmi_tlv_rdy_parse() and ath12k_wmi_rdy_parse() copy one MAC address per radio from the READY event's fixed-struct array after checking only the count advertised in the fixed record, not the array TLV length. A firmware READY event with a short array makes the copy read past the end of the TLV value.
These patches check the array length first and fall back to the driver's default per-radio addresses when it is too short.
Found while bringing up an IPQ8074 v1 device with older firmware; the issue is not specific to that hardware. Verified with a userspace harness around the unmodified parsers under AddressSanitizer. Compile tested on ath-next (W=1). The ath11k change has also run on an IPQ8074 hw1.0 board on every boot since 16 Oct; its firmware sends a well-formed array, so that covers the normal path only. The ath12k change is compile tested only. Neither has been tested on hardware with a malformed event.
Jeff, following your pointers on my earlier ath12k RX-ring RFC, these carry a full-name sign-off, an Assisted-by tag, and state the testing explicitly. This work was developed with AI assistance.
---
Changes in v2:
- Drop RFC.
- ath11k: note the hardware run and add a Tested-on tag; no code change.
- v1 was accidentally sent twice; apologies for the duplicate.
- Link to v1: https://patch.msgid.link/[email protected]
---
John Macias (2):
wifi: ath11k: bound READY MAC address array reads
wifi: ath12k: bound READY MAC address array reads
drivers/net/wireless/ath/ath11k/wmi.c | 6 ++++++ drivers/net/wireless/ath/ath12k/wmi.c | 6 ++++++ 2 files changed, 12 insertions(+)
---
base-commit: cd026e68fdbf88b9cc522b76c7a9d92c9a41f709
change-id: 20261015-rdy-mac-array-bounds-de70c7750217
Best regards,
Signature · 1 line
John Macias <[email protected]>