diff options
author | Rob Clark <rob@ti.com> | 2011-12-17 14:28:52 -0500 |
---|---|---|
committer | Tomi Valkeinen <tomi.valkeinen@ti.com> | 2012-01-02 01:51:28 -0500 |
commit | 1f3f53ae5179ba7f24b4a429bc41773f1f4857ca (patch) | |
tree | ade70e034a61a37b9f9db68f31d3783be3883221 /drivers/video/omap2/dss/apply.c | |
parent | 6ea9b31792745ee620509930dc9eead6e1c4be25 (diff) |
OMAPDSS: APPLY: fix NULL pointer deref when mgr is not set
extra_info_update_ongoing() goes through all overlays, but doesn't check
if the overlay is connected to a manager. This leads to a crash whenever
an overlay has been detached.
Add a check to skip the non-connected overlays.
Reported-by: Rob Clark <rob@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/video/omap2/dss/apply.c')
-rw-r--r-- | drivers/video/omap2/dss/apply.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/video/omap2/dss/apply.c b/drivers/video/omap2/dss/apply.c index 0a6fb8de19c0..052dc874cd3d 100644 --- a/drivers/video/omap2/dss/apply.c +++ b/drivers/video/omap2/dss/apply.c | |||
@@ -327,6 +327,9 @@ static bool extra_info_update_ongoing(void) | |||
327 | ovl = omap_dss_get_overlay(i); | 327 | ovl = omap_dss_get_overlay(i); |
328 | op = get_ovl_priv(ovl); | 328 | op = get_ovl_priv(ovl); |
329 | 329 | ||
330 | if (!ovl->manager) | ||
331 | continue; | ||
332 | |||
330 | mp = get_mgr_priv(ovl->manager); | 333 | mp = get_mgr_priv(ovl->manager); |
331 | 334 | ||
332 | if (!mp->enabled) | 335 | if (!mp->enabled) |