]> www.infradead.org Git - users/dwmw2/linux.git/commit
media: marvell-ccic: fix DMA s/g desc number calculation
authorLubomir Rintel <lkundrak@v3.sk>
Sun, 5 May 2019 14:00:23 +0000 (10:00 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 31 Jul 2019 05:28:20 +0000 (07:28 +0200)
commit9f5860dca1292f84791c8c30280c14ec39ba07dd
tree7a3d56ff3a2c41cf0ef79dd35bc608672a705de4
parentb503e9887655d2fea9fa2491a5e8b16a75be8af5
media: marvell-ccic: fix DMA s/g desc number calculation

[ Upstream commit 0c7aa32966dab0b8a7424e1b34c7f206817953ec ]

The commit d790b7eda953 ("[media] vb2-dma-sg: move dma_(un)map_sg here")
left dma_desc_nent unset. It previously contained the number of DMA
descriptors as returned from dma_map_sg().

We can now (since the commit referred to above) obtain the same value from
the sg_table and drop dma_desc_nent altogether.

Tested on OLPC XO-1.75 machine. Doesn't affect the OLPC XO-1's Cafe
driver, since that one doesn't do DMA.

[mchehab+samsung@kernel.org: fix a checkpatch warning]

Fixes: d790b7eda953 ("[media] vb2-dma-sg: move dma_(un)map_sg here")
Signed-off-by: Lubomir Rintel <lkundrak@v3.sk>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/media/platform/marvell-ccic/mcam-core.c