drm/mediatek: use correct device to import PRIME buffers
authorAlexandre Courbot <acourbot@chromium.org>
Mon, 29 Jul 2019 05:33:34 +0000 (14:33 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 10 Sep 2019 09:32:14 +0000 (10:32 +0100)
commit5655a71f8252f7681445df58701b9a93b3860269
treecbb1dece05f5e0867ab2823d0b2af1cd6134bbeb
parentc37374d643a8e33a9062f438a902dc90ad30a6c5
drm/mediatek: use correct device to import PRIME buffers

[ Upstream commit 4c6f3196e6ea111c456c6086dc3f57d4706b0b2d ]

PRIME buffers should be imported using the DMA device. To this end, use
a custom import function that mimics drm_gem_prime_import_dev(), but
passes the correct device.

Fixes: 119f5173628aa ("drm/mediatek: Add DRM Driver for Mediatek SoC MT8173.")
Signed-off-by: Alexandre Courbot <acourbot@chromium.org>
Signed-off-by: CK Hu <ck.hu@mediatek.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/mediatek/mtk_drm_drv.c