* [PATCH] omapfb: Return error code when applying overlay settings fails
@ 2015-01-30 7:59 Peter Meerwald
2015-02-04 10:42 ` Tomi Valkeinen
0 siblings, 1 reply; 2+ messages in thread
From: Peter Meerwald @ 2015-01-30 7:59 UTC (permalink / raw)
To: linux-omap; +Cc: tomi.valkeinen, linux-fbdev, Peter Meerwald
the check of the return code is missing, user space does not get notified
about the error condition:
omapdss OVERLAY error: overlay 2 horizontally not inside the display area (403 + 800 >= 800)
omapdss APPLY error: failed to apply settings: illegal configuration.
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
---
drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c b/drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c
index 146b6f5..9ddfdd6 100644
--- a/drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c
+++ b/drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c
@@ -137,8 +137,11 @@ static int omapfb_setup_plane(struct fb_info *fbi, struct omapfb_plane_info *pi)
goto undo;
}
- if (ovl->manager)
- ovl->manager->apply(ovl->manager);
+ if (ovl->manager) {
+ r = ovl->manager->apply(ovl->manager);
+ if (r)
+ goto undo;
+ }
if (pi->enabled) {
r = ovl->enable(ovl);
--
1.7.10.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] omapfb: Return error code when applying overlay settings fails
2015-01-30 7:59 [PATCH] omapfb: Return error code when applying overlay settings fails Peter Meerwald
@ 2015-02-04 10:42 ` Tomi Valkeinen
0 siblings, 0 replies; 2+ messages in thread
From: Tomi Valkeinen @ 2015-02-04 10:42 UTC (permalink / raw)
To: Peter Meerwald, linux-omap; +Cc: linux-fbdev
[-- Attachment #1: Type: text/plain, Size: 1179 bytes --]
On 30/01/15 09:59, Peter Meerwald wrote:
> the check of the return code is missing, user space does not get notified
> about the error condition:
>
> omapdss OVERLAY error: overlay 2 horizontally not inside the display area (403 + 800 >= 800)
> omapdss APPLY error: failed to apply settings: illegal configuration.
>
> Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
> ---
> drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c | 7 +++++--
> 1 file changed, 5 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c b/drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c
> index 146b6f5..9ddfdd6 100644
> --- a/drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c
> +++ b/drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c
> @@ -137,8 +137,11 @@ static int omapfb_setup_plane(struct fb_info *fbi, struct omapfb_plane_info *pi)
> goto undo;
> }
>
> - if (ovl->manager)
> - ovl->manager->apply(ovl->manager);
> + if (ovl->manager) {
> + r = ovl->manager->apply(ovl->manager);
> + if (r)
> + goto undo;
> + }
>
> if (pi->enabled) {
> r = ovl->enable(ovl);
>
Thanks, queued for 3.20.
Tomi
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-02-04 10:42 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-30 7:59 [PATCH] omapfb: Return error code when applying overlay settings fails Peter Meerwald
2015-02-04 10:42 ` Tomi Valkeinen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).