From: roel kluin <roel.kluin@gmail.com>
To: adaplas@gmail.com, linux-fbdev-devel@lists.sourceforge.net
Subject: [PATCH] gbefb: unsigned var->pixclock cannot be less than 0
Date: Wed, 29 Oct 2008 17:29:51 -0400 [thread overview]
Message-ID: <4908D5CF.5080103@gmail.com> (raw)
unsigned var->pixclock cannot be less than 0
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
---
diff --git a/drivers/video/gbefb.c b/drivers/video/gbefb.c
index f89c3cc..a386443 100644
--- a/drivers/video/gbefb.c
+++ b/drivers/video/gbefb.c
@@ -912,6 +912,7 @@ static int gbefb_check_var(struct fb_var_screeninfo *var, struct fb_info *info)
{
unsigned int line_length;
struct gbe_timing_info timing;
+ int ret;
/* Limit bpp to 8, 16, and 32 */
if (var->bits_per_pixel <= 8)
@@ -930,8 +931,10 @@ static int gbefb_check_var(struct fb_var_screeninfo *var, struct fb_info *info)
var->grayscale = 0; /* No grayscale for now */
- if ((var->pixclock = compute_gbe_timing(var, &timing)) < 0)
+ ret = compute_gbe_timing(var, &timing);
+ if (ret < 0)
return(-EINVAL);
+ var->pixclock = ret;
/* Adjust virtual resolution, if necessary */
if (var->xres > var->xres_virtual || (!ywrap && !ypan))
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
next reply other threads:[~2008-10-29 21:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-29 21:29 roel kluin [this message]
-- strict thread matches above, loose matches on Subject: below --
2008-11-26 22:18 [PATCH] gbefb: unsigned var->pixclock cannot be less than 0 roel kluin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4908D5CF.5080103@gmail.com \
--to=roel.kluin@gmail.com \
--cc=adaplas@gmail.com \
--cc=linux-fbdev-devel@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).