summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorManoj Rao <manojraj@codeaurora.org>2013-08-19 16:35:12 -0700
committerDavid Keitel <dkeitel@codeaurora.org>2016-03-23 20:22:46 -0700
commitea53b661521df4bcae207df9b5b19d855002e1b9 (patch)
tree71ee3216d4f3758d5993dd3c37708a6e55f0cc5d
parenta637447cc1a8a72a799809fd3e8e041691b978be (diff)
msm: mdss: fb: null check mfd data
Add appropriate null check for mfd data structure before accessing it's members. This prevents null pointer accesses in the driver. Change-Id: Id301d4a90c9a52049944c7e3b31aa1a34ad292d7 CRs-Fixed: 526286 Signed-off-by: Manoj Rao <manojraj@codeaurora.org>
-rw-r--r--drivers/video/fbdev/msm/mdss_fb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/video/fbdev/msm/mdss_fb.c b/drivers/video/fbdev/msm/mdss_fb.c
index eab529d5292d..20b838780b62 100644
--- a/drivers/video/fbdev/msm/mdss_fb.c
+++ b/drivers/video/fbdev/msm/mdss_fb.c
@@ -1439,7 +1439,7 @@ static int mdss_fb_pan_display_ex(struct fb_info *info,
u32 wait_for_finish = disp_commit->wait_for_finish;
int ret = 0;
- if ((!mfd->op_enable) || (!mfd->panel_power_on))
+ if (!mfd || (!mfd->op_enable) || (!mfd->panel_power_on))
return -EPERM;
if (var->xoffset > (info->var.xres_virtual - info->var.xres))