Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/qat/qat_common/adf_isr.c
Show All 32 Lines | adf_enable_msix(struct adf_accel_dev *accel_dev) | ||||
struct adf_accel_pci *info_pci_dev = &accel_dev->accel_pci_dev; | struct adf_accel_pci *info_pci_dev = &accel_dev->accel_pci_dev; | ||||
struct adf_hw_device_data *hw_data = accel_dev->hw_device; | struct adf_hw_device_data *hw_data = accel_dev->hw_device; | ||||
int msix_num_entries = 1; | int msix_num_entries = 1; | ||||
int count = 0; | int count = 0; | ||||
int error = 0; | int error = 0; | ||||
int num_vectors = 0; | int num_vectors = 0; | ||||
u_int *vectors; | u_int *vectors; | ||||
if (hw_data->set_msix_rttable) | |||||
hw_data->set_msix_rttable(accel_dev); | |||||
/* If SR-IOV is disabled, add entries for each bank */ | /* If SR-IOV is disabled, add entries for each bank */ | ||||
if (!accel_dev->u1.pf.vf_info) { | if (!accel_dev->u1.pf.vf_info) { | ||||
msix_num_entries += hw_data->num_banks; | msix_num_entries += hw_data->num_banks; | ||||
num_vectors = 0; | num_vectors = 0; | ||||
vectors = NULL; | vectors = NULL; | ||||
} else { | } else { | ||||
num_vectors = hw_data->num_banks + 1; | num_vectors = hw_data->num_banks + 1; | ||||
vectors = malloc(num_vectors * sizeof(u_int), | vectors = malloc(num_vectors * sizeof(u_int), | ||||
Show All 36 Lines | adf_disable_msix(struct adf_accel_pci *info_pci_dev) | ||||
pci_release_msi(info_pci_dev->pci_dev); | pci_release_msi(info_pci_dev->pci_dev); | ||||
} | } | ||||
static void | static void | ||||
adf_msix_isr_bundle(void *bank_ptr) | adf_msix_isr_bundle(void *bank_ptr) | ||||
{ | { | ||||
struct adf_etr_bank_data *bank = bank_ptr; | struct adf_etr_bank_data *bank = bank_ptr; | ||||
struct adf_etr_data *priv_data = bank->accel_dev->transport; | struct adf_etr_data *priv_data = bank->accel_dev->transport; | ||||
struct adf_hw_csr_ops *csr_ops = GET_CSR_OPS(bank->accel_dev); | |||||
WRITE_CSR_INT_FLAG_AND_COL(bank->csr_addr, bank->bank_number, 0); | csr_ops->write_csr_int_flag_and_col(bank->csr_addr, | ||||
bank->bank_number, | |||||
0); | |||||
adf_response_handler((uintptr_t)&priv_data->banks[bank->bank_number]); | adf_response_handler((uintptr_t)&priv_data->banks[bank->bank_number]); | ||||
return; | return; | ||||
} | } | ||||
static void | static void | ||||
adf_msix_isr_ae(void *dev_ptr) | adf_msix_isr_ae(void *dev_ptr) | ||||
{ | { | ||||
struct adf_accel_dev *accel_dev = dev_ptr; | struct adf_accel_dev *accel_dev = dev_ptr; | ||||
▲ Show 20 Lines • Show All 243 Lines • Show Last 20 Lines |