Commit ffb66624 authored by Sudip Mukherjee's avatar Sudip Mukherjee Committed by Bartlomiej Zolnierkiewicz

sm501fb: suspend and resume fb if it exists

There are cases when panel and crt both are not defined and only one of
them is defined and initialized. In such cases, suspend or resume it
only if it is defined.
Signed-off-by: default avatarSudip Mukherjee <sudipm.mukherjee@gmail.com>
Signed-off-by: default avatarBartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
parent 35bfbf70
......@@ -2101,6 +2101,9 @@ static int sm501fb_suspend_fb(struct sm501fb_info *info,
struct fb_info *fbi = info->fb[head];
struct sm501fb_par *par = fbi->par;
if (!fbi)
return 0;
if (par->screen.size == 0)
return 0;
......@@ -2148,6 +2151,9 @@ static void sm501fb_resume_fb(struct sm501fb_info *info,
struct fb_info *fbi = info->fb[head];
struct sm501fb_par *par = fbi->par;
if (!fbi)
return;
if (par->screen.size == 0)
return;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment