Message ID | 20220406094107.17878-1-quic_mpubbise@quicinc.com |
---|---|
Headers | show |
Series | add support for WCN6750 | expand |
Manikanta Pubbisetty <quic_mpubbise@quicinc.com> writes: > WCN6750 uses static window mapping to access the HW registers. > Unlike QCN9074 which uses 2nd window for CE and 3rd window > for UMAC register accesses, WCN6750 uses 1st window for UMAC > and 2nd window for CE registers. > > Code is refactored so that WCN6750 can use the existing > ath11k_pci_read/write() APIs for accessing the registers. > > Tested-on: WCN6750 hw1.0 AHB WLAN.MSL.1.0.1-00573-QCAMSLSWPLZ-1 > Tested-on: WCN6855 hw2.0 PCI WLAN.HSP.1.1-01720.1-QCAHSPSWPL_V1_V2_SILICONZ_LITE-1 > Tested-on: QCN9074 hw1.0 PCI WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1 > Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.4.0.1-00192-QCAHKSWPL_SILICONZ-1 > > Signed-off-by: Manikanta Pubbisetty <quic_mpubbise@quicinc.com> > --- > drivers/net/wireless/ath/ath11k/ahb.c | 3 ++ > drivers/net/wireless/ath/ath11k/core.h | 2 + > drivers/net/wireless/ath/ath11k/pci.c | 4 ++ > drivers/net/wireless/ath/ath11k/pcic.c | 53 +++++++++----------------- > 4 files changed, 28 insertions(+), 34 deletions(-) > > diff --git a/drivers/net/wireless/ath/ath11k/ahb.c b/drivers/net/wireless/ath/ath11k/ahb.c > index d73643e3e8dd..d27fc7276977 100644 > --- a/drivers/net/wireless/ath/ath11k/ahb.c > +++ b/drivers/net/wireless/ath/ath11k/ahb.c > @@ -42,6 +42,9 @@ const struct ath11k_bus_params ath11k_ahb_hybrid_bus_params = { > .fixed_bdf_addr = false, > .fixed_mem_region = false, > .hybrid_bus_type = true, > + .static_window_map = true, > + .dp_window_idx = 1, > + .ce_window_idx = 2, > }; Even if the values are zero, please initialise the new fields in every bus_params structure: ahb.c:31:static const struct ath11k_bus_params ath11k_ahb_bus_params = { pci.c:118:static const struct ath11k_bus_params ath11k_pci_bus_params = { > --- a/drivers/net/wireless/ath/ath11k/pci.c > +++ b/drivers/net/wireless/ath/ath11k/pci.c > @@ -771,6 +771,10 @@ static int ath11k_pci_probe(struct pci_dev *pdev, > ab->bus_params.static_window_map = true; > ab->pci.ops = &ath11k_pci_ops_qcn9074; > ab->hw_rev = ATH11K_HW_QCN9074_HW10; > + > + /* For QCN9074, CE: 2nd window, UMAC: 3rd window */ > + ab->bus_params.ce_window_idx = 2; > + ab->bus_params.dp_window_idx = 3; Bus params are supposed to be const so that you cannot change them. If there are device specific attributes they should be in hw_params. I see now that both hw_params and bus_params are not const in struct ath11k_base and that's why you were able to change them: struct ath11k_hw_params hw_params; struct ath11k_bus_params bus_params; I'll send a separate patch to fix that.
Manikanta Pubbisetty <quic_mpubbise@quicinc.com> writes: > WCN6750 is non-DBS 2x2 11AX chipset. Unlike QCA6390/WCN6855 which > are DBS (dual band simultaneous) solutions (2 LMACs), WCN6750 has a > single LMAC supporting 2G, 5G and 6G bands. It can be operated only > on one band at any given point. > > WCN6750 is a PCIe device. Unlike other supported ATH11K PCIe devices > which are directly attached to APSS (Application Processor SubSystem), > WCN6750 is not attached to APSS, it is attached to the WPSS > (Wireless Processor SubSystem) Q6 processor, the FW which runs on the > Q6 processor will enumerate the PCIe device. Since APSS is unaware of > such a device, it has to be registered as a platform device(AHB) to the > kernel for device probing. Like other AHB devices, remoteproc APIs are > used to boot up or shutdown of WCN6750. > > WCN6750 uses both AHB and PCIe ATH11K APIs for it's operation. > It uses AHB APIs for device probe and booting of the remote processor. > Once device is booted up, it uses ATH11K PCIe APIs for initialization > and register access. Hence, it is referred as hybrid bus device in > the rest of this series. > > Since the chip is enumerated by WPSS Q6, device information like > BAR and BAR size is not known to the APSS processor. A new QMI message > called device info QMI request will be sent to the target for fetching > these details. > > STA and AP modes are supported; Basic connectivity and ping are > verified in both the modes. > > An important point to note is that though WCN6750 is a PCIe device, > it cannot be attached to any other platform except on Qualcomm > Snapdragon SoCs due to the aforementioned reasons. > > Tested-on: WCN6750 hw1.0 AHB WLAN.MSL.1.0.1-00573-QCAMSLSWPLZ-1 > Tested-on: WCN6855 hw2.0 PCI WLAN.HSP.1.1-01720.1-QCAHSPSWPL_V1_V2_SILICONZ_LITE-1 > Tested-on: QCN9074 hw1.0 PCI WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1 > Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.4.0.1-00192-QCAHKSWPL_SILICONZ-1 > > Manikanta Pubbisetty (12): > dt: bindings: net: add bindings of WCN6750 for ath11k > ath11k: Add HW params for WCN6750 > ath11k: Add bus params for WCN6750 > ath11k: Add register access logic for WCN6750 > ath11k: Fetch device information via QMI for WCN6750 > ath11k: Add QMI changes for WCN6750 > ath11k: HAL changes to support WCN6750 > ath11k: Datapath changes to support WCN6750 > ath11k: Do not put HW in DBS mode for WCN6750 > ath11k: WMI changes to support WCN6750 > ath11k: Update WBM idle ring HP after FW mode on > ath11k: Add support for WCN6750 device Due to the bus_params problem I had to drop most of the patches, but I did keep few of them in the pending branch to reduce the patchset size: 495a15b1969a ath11k: Update WBM idle ring HP after FW mode on 8d121dacbe35 ath11k: WMI changes to support WCN6750 e31091e06011 ath11k: Do not put HW in DBS mode for WCN6750 Please submit v6 only after I have applied these, I'm waiting for some build testing first.
On 4/27/2022 11:15 AM, Kalle Valo wrote: > Manikanta Pubbisetty <quic_mpubbise@quicinc.com> writes: > >> WCN6750 uses static window mapping to access the HW registers. >> Unlike QCN9074 which uses 2nd window for CE and 3rd window >> for UMAC register accesses, WCN6750 uses 1st window for UMAC >> and 2nd window for CE registers. >> >> Code is refactored so that WCN6750 can use the existing >> ath11k_pci_read/write() APIs for accessing the registers. >> >> Tested-on: WCN6750 hw1.0 AHB WLAN.MSL.1.0.1-00573-QCAMSLSWPLZ-1 >> Tested-on: WCN6855 hw2.0 PCI WLAN.HSP.1.1-01720.1-QCAHSPSWPL_V1_V2_SILICONZ_LITE-1 >> Tested-on: QCN9074 hw1.0 PCI WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1 >> Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.4.0.1-00192-QCAHKSWPL_SILICONZ-1 >> >> Signed-off-by: Manikanta Pubbisetty <quic_mpubbise@quicinc.com> >> --- >> drivers/net/wireless/ath/ath11k/ahb.c | 3 ++ >> drivers/net/wireless/ath/ath11k/core.h | 2 + >> drivers/net/wireless/ath/ath11k/pci.c | 4 ++ >> drivers/net/wireless/ath/ath11k/pcic.c | 53 +++++++++----------------- >> 4 files changed, 28 insertions(+), 34 deletions(-) >> >> diff --git a/drivers/net/wireless/ath/ath11k/ahb.c b/drivers/net/wireless/ath/ath11k/ahb.c >> index d73643e3e8dd..d27fc7276977 100644 >> --- a/drivers/net/wireless/ath/ath11k/ahb.c >> +++ b/drivers/net/wireless/ath/ath11k/ahb.c >> @@ -42,6 +42,9 @@ const struct ath11k_bus_params ath11k_ahb_hybrid_bus_params = { >> .fixed_bdf_addr = false, >> .fixed_mem_region = false, >> .hybrid_bus_type = true, >> + .static_window_map = true, >> + .dp_window_idx = 1, >> + .ce_window_idx = 2, >> }; > > Even if the values are zero, please initialise the new fields in every > bus_params structure: > > ahb.c:31:static const struct ath11k_bus_params ath11k_ahb_bus_params = { > pci.c:118:static const struct ath11k_bus_params ath11k_pci_bus_params = { > Makes sense, should I send another series addressing these?
On 4/27/2022 11:23 AM, Kalle Valo wrote: > Manikanta Pubbisetty <quic_mpubbise@quicinc.com> writes: > >> WCN6750 is non-DBS 2x2 11AX chipset. Unlike QCA6390/WCN6855 which >> are DBS (dual band simultaneous) solutions (2 LMACs), WCN6750 has a >> single LMAC supporting 2G, 5G and 6G bands. It can be operated only >> on one band at any given point. >> >> WCN6750 is a PCIe device. Unlike other supported ATH11K PCIe devices >> which are directly attached to APSS (Application Processor SubSystem), >> WCN6750 is not attached to APSS, it is attached to the WPSS >> (Wireless Processor SubSystem) Q6 processor, the FW which runs on the >> Q6 processor will enumerate the PCIe device. Since APSS is unaware of >> such a device, it has to be registered as a platform device(AHB) to the >> kernel for device probing. Like other AHB devices, remoteproc APIs are >> used to boot up or shutdown of WCN6750. >> >> WCN6750 uses both AHB and PCIe ATH11K APIs for it's operation. >> It uses AHB APIs for device probe and booting of the remote processor. >> Once device is booted up, it uses ATH11K PCIe APIs for initialization >> and register access. Hence, it is referred as hybrid bus device in >> the rest of this series. >> >> Since the chip is enumerated by WPSS Q6, device information like >> BAR and BAR size is not known to the APSS processor. A new QMI message >> called device info QMI request will be sent to the target for fetching >> these details. >> >> STA and AP modes are supported; Basic connectivity and ping are >> verified in both the modes. >> >> An important point to note is that though WCN6750 is a PCIe device, >> it cannot be attached to any other platform except on Qualcomm >> Snapdragon SoCs due to the aforementioned reasons. >> >> Tested-on: WCN6750 hw1.0 AHB WLAN.MSL.1.0.1-00573-QCAMSLSWPLZ-1 >> Tested-on: WCN6855 hw2.0 PCI WLAN.HSP.1.1-01720.1-QCAHSPSWPL_V1_V2_SILICONZ_LITE-1 >> Tested-on: QCN9074 hw1.0 PCI WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1 >> Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.4.0.1-00192-QCAHKSWPL_SILICONZ-1 >> >> Manikanta Pubbisetty (12): >> dt: bindings: net: add bindings of WCN6750 for ath11k >> ath11k: Add HW params for WCN6750 >> ath11k: Add bus params for WCN6750 >> ath11k: Add register access logic for WCN6750 >> ath11k: Fetch device information via QMI for WCN6750 >> ath11k: Add QMI changes for WCN6750 >> ath11k: HAL changes to support WCN6750 >> ath11k: Datapath changes to support WCN6750 >> ath11k: Do not put HW in DBS mode for WCN6750 >> ath11k: WMI changes to support WCN6750 >> ath11k: Update WBM idle ring HP after FW mode on >> ath11k: Add support for WCN6750 device > > Due to the bus_params problem I had to drop most of the patches, but I > did keep few of them in the pending branch to reduce the patchset size: > > 495a15b1969a ath11k: Update WBM idle ring HP after FW mode on > 8d121dacbe35 ath11k: WMI changes to support WCN6750 > e31091e06011 ath11k: Do not put HW in DBS mode for WCN6750 > > Please submit v6 only after I have applied these, I'm waiting for some > build testing first. > Sure Kalle, thanks!! Manikanta