* [PATCH] fbdev: bail out immediately, if driver's fb_open fails
@ 2010-09-03 7:52 Guennadi Liakhovetski
0 siblings, 0 replies; only message in thread
From: Guennadi Liakhovetski @ 2010-09-03 7:52 UTC (permalink / raw)
To: linux-fbdev
If driver specific fb_open fails no need to continue the function and call
fb_deferred_io_open(), bail out immediately.
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
---
drivers/video/fbmem.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/drivers/video/fbmem.c b/drivers/video/fbmem.c
index b066475..adcf655 100644
--- a/drivers/video/fbmem.c
+++ b/drivers/video/fbmem.c
@@ -1395,8 +1395,10 @@ __releases(&info->lock)
file->private_data = info;
if (info->fbops->fb_open) {
res = info->fbops->fb_open(info,1);
- if (res)
+ if (res) {
module_put(info->fbops->owner);
+ goto out;
+ }
}
#ifdef CONFIG_FB_DEFERRED_IO
if (info->fbdefio)
--
1.7.1
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2010-09-03 7:52 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-09-03 7:52 [PATCH] fbdev: bail out immediately, if driver's fb_open fails Guennadi Liakhovetski
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).