Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4803cecf authored by Veera Sundaram Sankaran's avatar Veera Sundaram Sankaran
Browse files

msm: mdss: fix dsi buf_aloc when using physical memory



Set the dmap to correct translated physical address during
dsi_alloc_buf and also include GPF_DMA flag during kzalloc
to ensure the address allocated is 32-bit.

Change-Id: I5b0445eda6c4a93ca321ca9469626ecce4a167e9
Signed-off-by: default avatarVeera Sundaram Sankaran <veeras@codeaurora.org>
parent 5a3ed9ec
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -380,7 +380,13 @@ static void mdss_smmu_unmap_v2(int domain, unsigned long iova, int gfp_order)
static char *mdss_smmu_dsi_alloc_buf_v2(struct device *dev, int size,
		dma_addr_t *dmap, gfp_t gfp)
{
	return kzalloc(size, GFP_KERNEL);
	char *data;

	data = kzalloc(size, GFP_KERNEL | GFP_DMA);
	if (data)
		*dmap = (dma_addr_t) virt_to_phys(data);

	return data;
}

/*