Ensure proper endianness support for big-endian platforms by correcting data types in the QMI phy capability response message. Add missing byte swaps wherever this structure is accessed or modified. Fixes: 53a65445c144 ("wifi: ath12k: add QMI PHY capability learn support") Signed-off-by: Alexander Wilhelm <alexander.wilhelm@xxxxxxxxxxxx> --- drivers/net/wireless/ath/ath12k/qmi.c | 2 +- drivers/net/wireless/ath/ath12k/qmi.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/wireless/ath/ath12k/qmi.c b/drivers/net/wireless/ath/ath12k/qmi.c index 2287ed87dae8..2973edd2735b 100644 --- a/drivers/net/wireless/ath/ath12k/qmi.c +++ b/drivers/net/wireless/ath/ath12k/qmi.c @@ -2283,7 +2283,7 @@ static void ath12k_qmi_phy_cap_send(struct ath12k_base *ab) "phy capability resp valid %d single_chip_mlo_support %d valid %d num_phy %d valid %d board_id %d\n", resp.single_chip_mlo_support_valid, resp.single_chip_mlo_support, resp.num_phy_valid, resp.num_phy, - resp.board_id_valid, resp.board_id); + resp.board_id_valid, le32_to_cpu(resp.board_id)); return; diff --git a/drivers/net/wireless/ath/ath12k/qmi.h b/drivers/net/wireless/ath/ath12k/qmi.h index ed7808fe2b71..abe2fba25d13 100644 --- a/drivers/net/wireless/ath/ath12k/qmi.h +++ b/drivers/net/wireless/ath/ath12k/qmi.h @@ -273,7 +273,7 @@ struct qmi_wlanfw_phy_cap_resp_msg_v01 { u8 num_phy_valid; u8 num_phy; u8 board_id_valid; - u32 board_id; + __le32 board_id; u8 single_chip_mlo_support_valid; u8 single_chip_mlo_support; }; -- 2.34.1