diff options
| author | Ujwal Patel <ujwalp@codeaurora.org> | 2015-02-13 13:48:18 -0800 |
|---|---|---|
| committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-23 20:38:05 -0700 |
| commit | f4621d3955ab0cb30838fa6f23c1aeb11f4ce656 (patch) | |
| tree | a9a8c5871203d0e4d5496bc297714a28f894d0b2 | |
| parent | bcba569a2983134fa762ac1463b3420f7a70a71f (diff) | |
msm: mdss: prevent excessive logging after shutdown requested
Current frame-buffer driver gets shutdown call back and it turns the
display off. Once shutdown call-back is received, any subsequent
frame-buffer opens are rejected and an error log is generated. Now
user-land display clients are not aware of shutdown and they keep
opening the frame-buffer devices repeatedly ignoring the failures and
notifications sent by the driver. Due to this, excessive logging is
observed which in turn leads to watch-dog bite and a crash. Prevent
this by generating error log only once and keep sending sysfs
notification for every rejected frame-buffer open.
Change-Id: I9df6cb708a2d6c986a31324540a3d040dffbcdfc
Signed-off-by: Ujwal Patel <ujwalp@codeaurora.org>
| -rw-r--r-- | drivers/video/fbdev/msm/mdss_fb.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/video/fbdev/msm/mdss_fb.c b/drivers/video/fbdev/msm/mdss_fb.c index 701537721fc8..a9e0152cb206 100644 --- a/drivers/video/fbdev/msm/mdss_fb.c +++ b/drivers/video/fbdev/msm/mdss_fb.c @@ -2162,8 +2162,9 @@ static int mdss_fb_open(struct fb_info *info, int user) struct task_struct *task = current->group_leader; if (mfd->shutdown_pending) { - pr_err("Shutdown pending. Aborting operation. Request from pid:%d name=%s\n", - pid, task->comm); + pr_err_once("Shutdown pending. Aborting operation. Request from pid:%d name=%s\n", + pid, task->comm); + sysfs_notify(&mfd->fbi->dev->kobj, NULL, "show_blank_event"); return -EPERM; } @@ -2241,8 +2242,8 @@ static int mdss_fb_release_all(struct fb_info *info, bool release_all) struct task_struct *task = current->group_leader; if (!mfd->ref_cnt) { - pr_info("try to close unopened fb %d! from %s\n", mfd->index, - task->comm); + pr_info("try to close unopened fb %d! from pid:%d name:%s\n", + mfd->index, pid, task->comm); return -EINVAL; } |
