qcacmn: override irq disable/enable for msi mode
irq_enable/disable may be different for legacy srng and msi vs single line interrupts. Provide a place to insert the interrupt mitigation scheeme. Change-Id: I66559a404b0c2105da143215203c04f2311a763a CRs-Fixed: 1093364
此提交包含在:
@@ -3551,7 +3551,27 @@ irqreturn_t hif_ce_interrupt_handler(int irq, void *context)
|
|||||||
}
|
}
|
||||||
extern const char *ce_name[];
|
extern const char *ce_name[];
|
||||||
|
|
||||||
static int hif_ce_srng_msi_request_irq(struct hif_softc *scn)
|
/* hif_srng_msi_irq_disable() - disable the irq for msi
|
||||||
|
* @hif_sc: hif context
|
||||||
|
* @ce_id: which ce to disable copy complete interrupts for
|
||||||
|
*
|
||||||
|
* since MSI interrupts are not level based, the system can function
|
||||||
|
* without disabling these interrupts. Interrupt mitigation can be
|
||||||
|
* added here for better system performance.
|
||||||
|
*/
|
||||||
|
static void hif_ce_srng_msi_irq_disable(struct hif_softc *hif_sc, int ce_id)
|
||||||
|
{}
|
||||||
|
|
||||||
|
static void hif_ce_srng_msi_irq_enable(struct hif_softc *hif_sc, int ce_id)
|
||||||
|
{}
|
||||||
|
|
||||||
|
static void hif_ce_legacy_msi_irq_disable(struct hif_softc *hif_sc, int ce_id)
|
||||||
|
{}
|
||||||
|
|
||||||
|
static void hif_ce_legacy_msi_irq_enable(struct hif_softc *hif_sc, int ce_id)
|
||||||
|
{}
|
||||||
|
|
||||||
|
static int hif_ce_msi_configure_irq(struct hif_softc *scn)
|
||||||
{
|
{
|
||||||
int ret;
|
int ret;
|
||||||
int ce_id, irq;
|
int ce_id, irq;
|
||||||
@@ -3586,6 +3606,20 @@ static int hif_ce_srng_msi_request_irq(struct hif_softc *scn)
|
|||||||
goto free_irq;
|
goto free_irq;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (ce_srng_based(scn)) {
|
||||||
|
scn->bus_ops.hif_irq_disable =
|
||||||
|
&hif_ce_srng_msi_irq_disable;
|
||||||
|
scn->bus_ops.hif_irq_enable =
|
||||||
|
&hif_ce_srng_msi_irq_enable;
|
||||||
|
} else {
|
||||||
|
scn->bus_ops.hif_irq_disable =
|
||||||
|
&hif_ce_legacy_msi_irq_disable;
|
||||||
|
scn->bus_ops.hif_irq_enable =
|
||||||
|
&hif_ce_legacy_msi_irq_enable;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
free_irq:
|
free_irq:
|
||||||
@@ -3601,6 +3635,7 @@ free_irq:
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* hif_configure_irq() - configure interrupt
|
* hif_configure_irq() - configure interrupt
|
||||||
*
|
*
|
||||||
@@ -3620,7 +3655,7 @@ int hif_configure_irq(struct hif_softc *scn)
|
|||||||
|
|
||||||
hif_init_reschedule_tasklet_work(sc);
|
hif_init_reschedule_tasklet_work(sc);
|
||||||
|
|
||||||
ret = hif_ce_srng_msi_request_irq(scn);
|
ret = hif_ce_msi_configure_irq(scn);
|
||||||
if (ret == 0) {
|
if (ret == 0) {
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
新增問題並參考
封鎖使用者