aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Solnit <jsolnit@google.com>2017-04-05 21:11:55 -0700
committerAndrew Chant <achant@google.com>2017-04-10 23:12:05 +0000
commit80b1ca674b081a28713d89cb4146a88e8e054dbb (patch)
tree92ada76e2821fb5062491894cfcfba6031f14eeb
parent7d8bf14e48a12079ddda5b9d579b62afc80f9e9f (diff)
BACKPORT: msm: mdss: Fix invalid dma attachment during fb shutdownandroid-7.1.1_r0.61
If DMA attachment fail during fb_mmap, all ION memory will get free. It is necessary to reset the fbmem and fb_attachemnt pointer to NULL, otherwise during shutdown will perform another free and causing issue. CRs-Fixed: 1090244 Bug: 36251984 Change-Id: I36eb3ca12ae90789b2b63ddd6d9ed69517b2eb59 Signed-off-by: Benjamin Chan <bkchan@codeaurora.org> Signed-off-by: Jonathan Solnit <jsolnit@google.com>
-rw-r--r--drivers/video/msm/mdss/mdss_fb.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/video/msm/mdss/mdss_fb.c b/drivers/video/msm/mdss/mdss_fb.c
index d5f306ecc8e2..656742d35968 100644
--- a/drivers/video/msm/mdss/mdss_fb.c
+++ b/drivers/video/msm/mdss/mdss_fb.c
@@ -1314,6 +1314,7 @@ static int mdss_fb_alloc_fb_ion_memory(struct msm_fb_data_type *mfd,
fb_mmap_failed:
ion_free(mfd->fb_ion_client, mfd->fb_ion_handle);
+ mfd->fb_ion_handle = NULL;
return rc;
}