drm/rockchip: vop: fix iommu crash with async atomic
authorMark Yao <mark.yao@rock-chips.com>
Fri, 29 Apr 2016 03:37:20 +0000 (11:37 +0800)
committerHuang, Tao <huangtao@rock-chips.com>
Wed, 4 May 2016 10:27:54 +0000 (18:27 +0800)
commit9bde4e671f2b1efa84c92608a5749dc97012c691
tree3ec0c167db0e435ac2b20618194b402c9983d773
parented547bb16f27448033d0005c6ee3e282375a8f27
drm/rockchip: vop: fix iommu crash with async atomic

On Async atomic_commit callback, drm_atomic_clean_old_fb will
clean all old fb, but because async, the old fb may be also on
the vop hardware, dma will access the old fb buffer, clean old
fb will cause iommu page fault.

Reference the fb and unreference it when the fb actuall swap out
from vop hardware.

Change-Id: I585786884295060efdaef0a00c3cbd75244399d7
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
drivers/gpu/drm/rockchip/rockchip_drm_vop.c