From 777a1765e14209aa5fb67f5d45f10080bcbd43dd Mon Sep 17 00:00:00 2001 From: Kuogee Hsieh Date: Thu, 25 Oct 2012 09:07:58 -0700 Subject: [PATCH] msm_fb: display: fix iommu leak during base layer swap Retain RGB1 iommu information during base layer swap so that iommu used by RGB1 can be freed back to pool later. Change-Id: Ibed85179284743dc8a9d1434f0c81626b0567e16 Signed-off-by: Kuogee Hsieh (cherry picked from commit be46f9f596c5172438a74759d48ca7db600cd737) --- drivers/video/msm/mdp4_overlay.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/video/msm/mdp4_overlay.c b/drivers/video/msm/mdp4_overlay.c index b705085a2f2f..3c1ea79488bb 100644 --- a/drivers/video/msm/mdp4_overlay.c +++ b/drivers/video/msm/mdp4_overlay.c @@ -1731,6 +1731,7 @@ void mdp4_overlay_borderfill_stage_down(struct mdp4_overlay_pipe *pipe) struct mdp4_overlay_pipe *bspipe; int ptype, pnum, pndx, mixer; int format, alpha_enable, alpha; + struct mdp4_iommu_pipe_info iom; if (pipe->pipe_type != OVERLAY_TYPE_BF) return; @@ -1745,6 +1746,7 @@ void mdp4_overlay_borderfill_stage_down(struct mdp4_overlay_pipe *pipe) return; } + iom = bspipe->iommu; ptype = bspipe->pipe_type; pnum = bspipe->pipe_num; pndx = bspipe->pipe_ndx; @@ -1758,6 +1760,7 @@ void mdp4_overlay_borderfill_stage_down(struct mdp4_overlay_pipe *pipe) bspipe->src_format = format; bspipe->alpha_enable = alpha_enable; bspipe->alpha = alpha; + bspipe->iommu = iom; bspipe->pipe_used++; /* mark base layer pipe used */