qcacmn: Make DMA coherent mask macro independent of IPA offload
Macro DMA_COHERENT_MASK_IPA_VER_3_AND_ABOVE is used in non IPA offload case also so bring this macro definition out of IPA offload feature and change it to DMA_COHERENT_MASK_DEFAULT. Change-Id: Ib03aa8ae2938e1de1a957660923a711d452a9337 CRs-Fixed: 2649909
This commit is contained in:

committed by
nshrivas

parent
1929eefb7f
commit
765d5e27ed
@@ -68,8 +68,9 @@ typedef void *hif_handle_t;
|
||||
#define HIF_TYPE_QCA6750 23
|
||||
#define HIF_TYPE_QCA5018 24
|
||||
|
||||
#define DMA_COHERENT_MASK_DEFAULT 37
|
||||
|
||||
#ifdef IPA_OFFLOAD
|
||||
#define DMA_COHERENT_MASK_IPA_VER_3_AND_ABOVE 37
|
||||
#define DMA_COHERENT_MASK_BELOW_IPA_VER_3 32
|
||||
#endif
|
||||
|
||||
|
@@ -627,7 +627,7 @@ QDF_STATUS hif_ipci_enable_bus(struct hif_softc *ol_sc,
|
||||
}
|
||||
|
||||
ret = qdf_set_dma_coherent_mask(dev,
|
||||
DMA_COHERENT_MASK_IPA_VER_3_AND_ABOVE);
|
||||
DMA_COHERENT_MASK_DEFAULT);
|
||||
if (ret) {
|
||||
HIF_ERROR("%s: failed to set dma mask error = %d",
|
||||
__func__, ret);
|
||||
|
@@ -232,19 +232,20 @@ static int hif_set_dma_coherent_mask(qdf_device_t osdev)
|
||||
|
||||
if (false == hif_get_ipa_present())
|
||||
return qdf_set_dma_coherent_mask(osdev->dev,
|
||||
DMA_COHERENT_MASK_IPA_VER_3_AND_ABOVE);
|
||||
DMA_COHERENT_MASK_DEFAULT);
|
||||
|
||||
if (hif_get_ipa_hw_type() < IPA_HW_v3_0)
|
||||
addr_bits = DMA_COHERENT_MASK_BELOW_IPA_VER_3;
|
||||
else
|
||||
addr_bits = DMA_COHERENT_MASK_IPA_VER_3_AND_ABOVE;
|
||||
addr_bits = DMA_COHERENT_MASK_DEFAULT;
|
||||
|
||||
return qdf_set_dma_coherent_mask(osdev->dev, addr_bits);
|
||||
}
|
||||
#else
|
||||
static int hif_set_dma_coherent_mask(qdf_device_t osdev)
|
||||
{
|
||||
return qdf_set_dma_coherent_mask(osdev->dev, 37);
|
||||
return qdf_set_dma_coherent_mask(osdev->dev,
|
||||
DMA_COHERENT_MASK_DEFAULT);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user