Loading drivers/net/wireless/ath/ath10k/ahb.c +2 −1 Original line number Diff line number Diff line Loading @@ -787,8 +787,9 @@ static int ath10k_ahb_probe(struct platform_device *pdev) ar_pci->mem = ar_ahb->mem; ar_pci->mem_len = ar_ahb->mem_len; ar_pci->ar = ar; ar_pci->bus_ops = &ath10k_ahb_bus_ops; ar_pci->ce.bus_ops = &ath10k_ahb_bus_ops; ar_pci->targ_cpu_to_ce_addr = ath10k_ahb_qca4019_targ_cpu_to_ce_addr; ar->ce_priv = &ar_pci->ce; ret = ath10k_pci_setup_resource(ar); if (ret) { Loading drivers/net/wireless/ath/ath10k/ce.c +164 −135 File changed.Preview size limit exceeded, changes collapsed. Show changes drivers/net/wireless/ath/ath10k/ce.h +26 −4 Original line number Diff line number Diff line Loading @@ -122,6 +122,24 @@ struct ath10k_ce_pipe { /* Copy Engine settable attributes */ struct ce_attr; struct ath10k_bus_ops { u32 (*read32)(struct ath10k *ar, u32 offset); void (*write32)(struct ath10k *ar, u32 offset, u32 value); int (*get_num_banks)(struct ath10k *ar); }; static inline struct ath10k_ce *ath10k_ce_priv(struct ath10k *ar) { return (struct ath10k_ce *)ar->ce_priv; } struct ath10k_ce { /* protects CE info */ spinlock_t ce_lock; const struct ath10k_bus_ops *bus_ops; struct ath10k_ce_pipe ce_states[CE_COUNT_MAX]; }; /*==================Send====================*/ /* ath10k_ce_send flags */ Loading Loading @@ -291,9 +309,13 @@ static inline u32 ath10k_ce_base_address(struct ath10k *ar, unsigned int ce_id) CE_WRAPPER_INTERRUPT_SUMMARY_HOST_MSI_LSB) #define CE_WRAPPER_INTERRUPT_SUMMARY_ADDRESS 0x0000 #define CE_INTERRUPT_SUMMARY(ar) \ CE_WRAPPER_INTERRUPT_SUMMARY_HOST_MSI_GET( \ ath10k_pci_read32((ar), CE_WRAPPER_BASE_ADDRESS + \ CE_WRAPPER_INTERRUPT_SUMMARY_ADDRESS)) static inline u32 ath10k_ce_interrupt_summary(struct ath10k *ar) { struct ath10k_ce *ce = ath10k_ce_priv(ar); return CE_WRAPPER_INTERRUPT_SUMMARY_HOST_MSI_GET( ce->bus_ops->read32((ar), CE_WRAPPER_BASE_ADDRESS + CE_WRAPPER_INTERRUPT_SUMMARY_ADDRESS)); } #endif /* _CE_H_ */ drivers/net/wireless/ath/ath10k/core.c +5 −0 Original line number Diff line number Diff line Loading @@ -2516,6 +2516,11 @@ struct ath10k *ath10k_core_create(size_t priv_size, struct device *dev, ar->hw_ce_regs = &qcax_ce_regs; ar->hw_values = &qca4019_values; break; case ATH10K_HW_WCN3990: ar->regs = &wcn3990_regs; ar->hw_ce_regs = &wcn3990_ce_regs; ar->hw_values = &wcn3990_values; break; default: ath10k_err(ar, "unsupported core hardware revision %d\n", hw_rev); Loading drivers/net/wireless/ath/ath10k/core.h +2 −0 Original line number Diff line number Diff line Loading @@ -993,6 +993,8 @@ struct ath10k { u32 reg_ack_cts_timeout_orig; } fw_coverage; void *ce_priv; /* must be last */ u8 drv_priv[0] __aligned(sizeof(void *)); }; Loading Loading
drivers/net/wireless/ath/ath10k/ahb.c +2 −1 Original line number Diff line number Diff line Loading @@ -787,8 +787,9 @@ static int ath10k_ahb_probe(struct platform_device *pdev) ar_pci->mem = ar_ahb->mem; ar_pci->mem_len = ar_ahb->mem_len; ar_pci->ar = ar; ar_pci->bus_ops = &ath10k_ahb_bus_ops; ar_pci->ce.bus_ops = &ath10k_ahb_bus_ops; ar_pci->targ_cpu_to_ce_addr = ath10k_ahb_qca4019_targ_cpu_to_ce_addr; ar->ce_priv = &ar_pci->ce; ret = ath10k_pci_setup_resource(ar); if (ret) { Loading
drivers/net/wireless/ath/ath10k/ce.c +164 −135 File changed.Preview size limit exceeded, changes collapsed. Show changes
drivers/net/wireless/ath/ath10k/ce.h +26 −4 Original line number Diff line number Diff line Loading @@ -122,6 +122,24 @@ struct ath10k_ce_pipe { /* Copy Engine settable attributes */ struct ce_attr; struct ath10k_bus_ops { u32 (*read32)(struct ath10k *ar, u32 offset); void (*write32)(struct ath10k *ar, u32 offset, u32 value); int (*get_num_banks)(struct ath10k *ar); }; static inline struct ath10k_ce *ath10k_ce_priv(struct ath10k *ar) { return (struct ath10k_ce *)ar->ce_priv; } struct ath10k_ce { /* protects CE info */ spinlock_t ce_lock; const struct ath10k_bus_ops *bus_ops; struct ath10k_ce_pipe ce_states[CE_COUNT_MAX]; }; /*==================Send====================*/ /* ath10k_ce_send flags */ Loading Loading @@ -291,9 +309,13 @@ static inline u32 ath10k_ce_base_address(struct ath10k *ar, unsigned int ce_id) CE_WRAPPER_INTERRUPT_SUMMARY_HOST_MSI_LSB) #define CE_WRAPPER_INTERRUPT_SUMMARY_ADDRESS 0x0000 #define CE_INTERRUPT_SUMMARY(ar) \ CE_WRAPPER_INTERRUPT_SUMMARY_HOST_MSI_GET( \ ath10k_pci_read32((ar), CE_WRAPPER_BASE_ADDRESS + \ CE_WRAPPER_INTERRUPT_SUMMARY_ADDRESS)) static inline u32 ath10k_ce_interrupt_summary(struct ath10k *ar) { struct ath10k_ce *ce = ath10k_ce_priv(ar); return CE_WRAPPER_INTERRUPT_SUMMARY_HOST_MSI_GET( ce->bus_ops->read32((ar), CE_WRAPPER_BASE_ADDRESS + CE_WRAPPER_INTERRUPT_SUMMARY_ADDRESS)); } #endif /* _CE_H_ */
drivers/net/wireless/ath/ath10k/core.c +5 −0 Original line number Diff line number Diff line Loading @@ -2516,6 +2516,11 @@ struct ath10k *ath10k_core_create(size_t priv_size, struct device *dev, ar->hw_ce_regs = &qcax_ce_regs; ar->hw_values = &qca4019_values; break; case ATH10K_HW_WCN3990: ar->regs = &wcn3990_regs; ar->hw_ce_regs = &wcn3990_ce_regs; ar->hw_values = &wcn3990_values; break; default: ath10k_err(ar, "unsupported core hardware revision %d\n", hw_rev); Loading
drivers/net/wireless/ath/ath10k/core.h +2 −0 Original line number Diff line number Diff line Loading @@ -993,6 +993,8 @@ struct ath10k { u32 reg_ack_cts_timeout_orig; } fw_coverage; void *ce_priv; /* must be last */ u8 drv_priv[0] __aligned(sizeof(void *)); }; Loading