linux/drivers/net/wireless/ath/ath12k/pci.c

// SPDX-License-Identifier: BSD-3-Clause-Clear
/*
 * Copyright (c) 2019-2021 The Linux Foundation. All rights reserved.
 * Copyright (c) 2021-2024 Qualcomm Innovation Center, Inc. All rights reserved.
 */

#include <linux/module.h>
#include <linux/msi.h>
#include <linux/pci.h>

#include "pci.h"
#include "core.h"
#include "hif.h"
#include "mhi.h"
#include "debug.h"

#define ATH12K_PCI_BAR_NUM
#define ATH12K_PCI_DMA_MASK

#define ATH12K_PCI_IRQ_CE0_OFFSET

#define WINDOW_ENABLE_BIT
#define WINDOW_REG_ADDRESS
#define WINDOW_VALUE_MASK
#define WINDOW_START
#define WINDOW_RANGE_MASK
#define WINDOW_STATIC_MASK

#define TCSR_SOC_HW_VERSION
#define TCSR_SOC_HW_VERSION_MAJOR_MASK
#define TCSR_SOC_HW_VERSION_MINOR_MASK

/* BAR0 + 4k is always accessible, and no
 * need to force wakeup.
 * 4K - 32 = 0xFE0
 */
#define ACCESS_ALWAYS_OFF

#define QCN9274_DEVICE_ID
#define WCN7850_DEVICE_ID

#define PCIE_LOCAL_REG_QRTR_NODE_ID
#define DOMAIN_NUMBER_MASK
#define BUS_NUMBER_MASK

static const struct pci_device_id ath12k_pci_id_table[] =;

MODULE_DEVICE_TABLE(pci, ath12k_pci_id_table);

/* TODO: revisit IRQ mapping for new SRNG's */
static const struct ath12k_msi_config ath12k_msi_config[] =;

static const struct ath12k_msi_config msi_config_one_msi =;

static const char *irq_name[ATH12K_IRQ_NUM_MAX] =;

static int ath12k_pci_bus_wake_up(struct ath12k_base *ab)
{}

static void ath12k_pci_bus_release(struct ath12k_base *ab)
{}

static const struct ath12k_pci_ops ath12k_pci_ops_qcn9274 =;

static const struct ath12k_pci_ops ath12k_pci_ops_wcn7850 =;

static void ath12k_pci_select_window(struct ath12k_pci *ab_pci, u32 offset)
{}

static void ath12k_pci_select_static_window(struct ath12k_pci *ab_pci)
{}

static u32 ath12k_pci_get_window_start(struct ath12k_base *ab,
				       u32 offset)
{}

static inline bool ath12k_pci_is_offset_within_mhi_region(u32 offset)
{}

static void ath12k_pci_soc_global_reset(struct ath12k_base *ab)
{}

static void ath12k_pci_clear_dbg_registers(struct ath12k_base *ab)
{}

static void ath12k_pci_enable_ltssm(struct ath12k_base *ab)
{}

static void ath12k_pci_clear_all_intrs(struct ath12k_base *ab)
{}

static void ath12k_pci_set_wlaon_pwr_ctrl(struct ath12k_base *ab)
{}

static void ath12k_pci_force_wake(struct ath12k_base *ab)
{}

static void ath12k_pci_sw_reset(struct ath12k_base *ab, bool power_on)
{}

static void ath12k_pci_free_ext_irq(struct ath12k_base *ab)
{}

static void ath12k_pci_free_irq(struct ath12k_base *ab)
{}

static void ath12k_pci_ce_irq_enable(struct ath12k_base *ab, u16 ce_id)
{}

static void ath12k_pci_ce_irq_disable(struct ath12k_base *ab, u16 ce_id)
{}

static void ath12k_pci_ce_irqs_disable(struct ath12k_base *ab)
{}

static void ath12k_pci_sync_ce_irqs(struct ath12k_base *ab)
{}

static void ath12k_pci_ce_tasklet(struct tasklet_struct *t)
{}

static irqreturn_t ath12k_pci_ce_interrupt_handler(int irq, void *arg)
{}

static void ath12k_pci_ext_grp_disable(struct ath12k_ext_irq_grp *irq_grp)
{}

static void __ath12k_pci_ext_irq_disable(struct ath12k_base *ab)
{}

static void ath12k_pci_ext_grp_enable(struct ath12k_ext_irq_grp *irq_grp)
{}

static void ath12k_pci_sync_ext_irqs(struct ath12k_base *ab)
{}

static int ath12k_pci_ext_grp_napi_poll(struct napi_struct *napi, int budget)
{}

static irqreturn_t ath12k_pci_ext_interrupt_handler(int irq, void *arg)
{}

static int ath12k_pci_ext_irq_config(struct ath12k_base *ab)
{}

static int ath12k_pci_set_irq_affinity_hint(struct ath12k_pci *ab_pci,
					    const struct cpumask *m)
{}

static int ath12k_pci_config_irq(struct ath12k_base *ab)
{}

static void ath12k_pci_init_qmi_ce_config(struct ath12k_base *ab)
{}

static void ath12k_pci_ce_irqs_enable(struct ath12k_base *ab)
{}

static void ath12k_pci_msi_config(struct ath12k_pci *ab_pci, bool enable)
{}

static void ath12k_pci_msi_enable(struct ath12k_pci *ab_pci)
{}

static void ath12k_pci_msi_disable(struct ath12k_pci *ab_pci)
{}

static int ath12k_pci_msi_alloc(struct ath12k_pci *ab_pci)
{}

static void ath12k_pci_msi_free(struct ath12k_pci *ab_pci)
{}

static int ath12k_pci_config_msi_data(struct ath12k_pci *ab_pci)
{}

static int ath12k_pci_claim(struct ath12k_pci *ab_pci, struct pci_dev *pdev)
{}

static void ath12k_pci_free_region(struct ath12k_pci *ab_pci)
{}

static void ath12k_pci_aspm_disable(struct ath12k_pci *ab_pci)
{}

static void ath12k_pci_update_qrtr_node_id(struct ath12k_base *ab)
{}

static void ath12k_pci_aspm_restore(struct ath12k_pci *ab_pci)
{}

static void ath12k_pci_kill_tasklets(struct ath12k_base *ab)
{}

static void ath12k_pci_ce_irq_disable_sync(struct ath12k_base *ab)
{}

int ath12k_pci_map_service_to_pipe(struct ath12k_base *ab, u16 service_id,
				   u8 *ul_pipe, u8 *dl_pipe)
{}

int ath12k_pci_get_msi_irq(struct device *dev, unsigned int vector)
{}

int ath12k_pci_get_user_msi_assignment(struct ath12k_base *ab, char *user_name,
				       int *num_vectors, u32 *user_base_data,
				       u32 *base_vector)
{}

void ath12k_pci_get_msi_address(struct ath12k_base *ab, u32 *msi_addr_lo,
				u32 *msi_addr_hi)
{}

void ath12k_pci_get_ce_msi_idx(struct ath12k_base *ab, u32 ce_id,
			       u32 *msi_idx)
{}

void ath12k_pci_hif_ce_irq_enable(struct ath12k_base *ab)
{}

void ath12k_pci_hif_ce_irq_disable(struct ath12k_base *ab)
{}

void ath12k_pci_ext_irq_enable(struct ath12k_base *ab)
{}

void ath12k_pci_ext_irq_disable(struct ath12k_base *ab)
{}

int ath12k_pci_hif_suspend(struct ath12k_base *ab)
{}

int ath12k_pci_hif_resume(struct ath12k_base *ab)
{}

void ath12k_pci_stop(struct ath12k_base *ab)
{}

int ath12k_pci_start(struct ath12k_base *ab)
{}

u32 ath12k_pci_read32(struct ath12k_base *ab, u32 offset)
{}

void ath12k_pci_write32(struct ath12k_base *ab, u32 offset, u32 value)
{}

int ath12k_pci_power_up(struct ath12k_base *ab)
{}

void ath12k_pci_power_down(struct ath12k_base *ab, bool is_suspend)
{}

static int ath12k_pci_panic_handler(struct ath12k_base *ab)
{}

static const struct ath12k_hif_ops ath12k_pci_hif_ops =;

static
void ath12k_pci_read_hw_version(struct ath12k_base *ab, u32 *major, u32 *minor)
{}

static int ath12k_pci_probe(struct pci_dev *pdev,
			    const struct pci_device_id *pci_dev)
{}

static void ath12k_pci_remove(struct pci_dev *pdev)
{}

static void ath12k_pci_shutdown(struct pci_dev *pdev)
{}

static __maybe_unused int ath12k_pci_pm_suspend(struct device *dev)
{}

static __maybe_unused int ath12k_pci_pm_resume(struct device *dev)
{}

static __maybe_unused int ath12k_pci_pm_suspend_late(struct device *dev)
{}

static __maybe_unused int ath12k_pci_pm_resume_early(struct device *dev)
{}

static const struct dev_pm_ops __maybe_unused ath12k_pci_pm_ops =;

static struct pci_driver ath12k_pci_driver =;

static int ath12k_pci_init(void)
{}
module_init();

static void ath12k_pci_exit(void)
{}

module_exit(ath12k_pci_exit);

MODULE_DESCRIPTION();
MODULE_LICENSE();