mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 10:58:48 +09:00
media: rockchip: isp/ispp sync alloc buf with dma sg case
Change-Id: If4c80315efd9ce3ac80de3ec72d537ca1c27776d Signed-off-by: Cai YiWei <cyw@rock-chips.com>
This commit is contained in:
@@ -98,6 +98,7 @@ int rkisp_alloc_buffer(struct rkisp_device *dev,
|
||||
if (dev->hw_dev->is_dma_sg_ops) {
|
||||
sg_tbl = (struct sg_table *)g_ops->cookie(mem_priv);
|
||||
buf->dma_addr = sg_dma_address(sg_tbl->sgl);
|
||||
g_ops->prepare(mem_priv);
|
||||
} else {
|
||||
buf->dma_addr = *((dma_addr_t *)g_ops->cookie(mem_priv));
|
||||
}
|
||||
|
||||
@@ -90,6 +90,7 @@ int rkispp_allow_buffer(struct rkispp_device *dev,
|
||||
if (dev->hw_dev->is_dma_sg_ops) {
|
||||
sg_tbl = (struct sg_table *)g_ops->cookie(mem_priv);
|
||||
buf->dma_addr = sg_dma_address(sg_tbl->sgl);
|
||||
g_ops->prepare(mem_priv);
|
||||
} else {
|
||||
buf->dma_addr = *((dma_addr_t *)g_ops->cookie(mem_priv));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user