[PATCH ath-next 15/16] wifi: ath11k: define userPDs for QCN6122

From: George Moussalem via B4 Relay

Date: Wed Sep 23 2026 - 08:16:28 EST


From: George Moussalem <george.moussalem@xxxxxxxxxxx>

The IPQ5018 platform can come with one or two optional QCN6122 wifi
cards. To differentiate the two, the user PD instance number (1 or 2) is
added to the QMI service instance ID so the QCN6122 firmware knows which
radio instance to use and on what PCIe rail it is on.

On IPQ5018/QCN6122 boards, the default mapping is as follows:

+-> User PD 1 ----> IPQ5018 Internal 2.4G Radio
/
/
Root PD +---> User PD 2 ----> QCN6122 5G/6G Radio on PCIe rail 1
\
\
+-> User PD 3 ----> QCN6122 5G/6G Radio on PCIe rail 0

Signed-off-by: George Moussalem <george.moussalem@xxxxxxxxxxx>
---
drivers/net/wireless/ath/ath11k/ahb.c | 8 ++++++++
drivers/net/wireless/ath/ath11k/ahb.h | 2 ++
2 files changed, 10 insertions(+)

diff --git a/drivers/net/wireless/ath/ath11k/ahb.c b/drivers/net/wireless/ath/ath11k/ahb.c
index 03936f574c8d..26110c927577 100644
--- a/drivers/net/wireless/ath/ath11k/ahb.c
+++ b/drivers/net/wireless/ath/ath11k/ahb.c
@@ -969,6 +969,14 @@ static int ath11k_ahb_init_userpd(struct ath11k_base *ab, int userpd_id)

ab_ahb->userpd_id = userpd_id;
break;
+ case ATH11K_HW_QCN6122_HW10:
+ if (userpd_id != ATH11K_AHB_USERPD_ID_2 &&
+ userpd_id != ATH11K_AHB_USERPD_ID_3)
+ return -EINVAL;
+
+ ab_ahb->userpd_id = userpd_id;
+ ab->qmi.service_ins_id += (ab_ahb->userpd_id - 1);
+ break;
default:
return -EINVAL;
}
diff --git a/drivers/net/wireless/ath/ath11k/ahb.h b/drivers/net/wireless/ath/ath11k/ahb.h
index 0647bdb9ea62..ec89e0e89ca0 100644
--- a/drivers/net/wireless/ath/ath11k/ahb.h
+++ b/drivers/net/wireless/ath/ath11k/ahb.h
@@ -28,6 +28,8 @@

enum ath11k_ahb_userpd_id {
ATH11K_AHB_USERPD_ID_1 = 1,
+ ATH11K_AHB_USERPD_ID_2,
+ ATH11K_AHB_USERPD_ID_3,
ATH11K_AHB_USERPD_ID_MAX,
};


--
2.53.0