aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@ti.com>2014-10-16 05:17:44 -0400
committerTomi Valkeinen <tomi.valkeinen@ti.com>2014-10-22 04:07:08 -0400
commit63cec5a22c13a80d80cb38acdb5b555eafb74ddc (patch)
tree2bd1590b918ee76e10223a9ac1a9bf365e000a4b
parent22500c19e6dc1a7c897323eff040364289bce0b7 (diff)
OMAPFB: fix overlay disable when freeing resources.
When omapfb is shutting down, it will disable all the overlays. However, instead of actually disabling all the overlays, it disables only all the overlays that are currently attached to framebuffers. On OMAP4+, this leaves the fourth overlay left enabled. Fix the loop so that we actually go through all the overlays. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
-rw-r--r--drivers/video/fbdev/omap2/omapfb/omapfb-main.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/video/fbdev/omap2/omapfb/omapfb-main.c b/drivers/video/fbdev/omap2/omapfb/omapfb-main.c
index 10207daf41fe..a04096a63cb1 100644
--- a/drivers/video/fbdev/omap2/omapfb/omapfb-main.c
+++ b/drivers/video/fbdev/omap2/omapfb/omapfb-main.c
@@ -1833,14 +1833,10 @@ static void omapfb_free_resources(struct omapfb2_device *fbdev)
1833 if (fbdev == NULL) 1833 if (fbdev == NULL)
1834 return; 1834 return;
1835 1835
1836 for (i = 0; i < fbdev->num_fbs; i++) { 1836 for (i = 0; i < fbdev->num_overlays; i++) {
1837 struct omapfb_info *ofbi = FB2OFB(fbdev->fbs[i]); 1837 struct omap_overlay *ovl = fbdev->overlays[i];
1838 int j;
1839 1838
1840 for (j = 0; j < ofbi->num_overlays; j++) { 1839 ovl->disable(ovl);
1841 struct omap_overlay *ovl = ofbi->overlays[j];
1842 ovl->disable(ovl);
1843 }
1844 } 1840 }
1845 1841
1846 for (i = 0; i < fbdev->num_fbs; i++) 1842 for (i = 0; i < fbdev->num_fbs; i++)