From: Michal Januszewski <spock@gentoo.org>
To: linux-fbdev-devel@lists.sourceforge.net
Cc: "Antonino A. Daplas" <adaplas@gmail.com>
Subject: Re: [PATCH] fbdev: fix the fb_find_nearest_mode() function
Date: Fri, 14 Oct 2005 17:04:08 +0200 [thread overview]
Message-ID: <20051014150408.GA9296@spock.one.pl> (raw)
In-Reply-To: <434EF940.9020608@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1281 bytes --]
On Fri, Oct 14, 2005 at 08:18:08AM +0800, Antonino A. Daplas wrote:
> > In case you're wondering why would anyone ever need to have
> > var->pixclock set to 0 -- I was using it to denote modes with a default
> > refresh rate set by the hardware (well, the Video BIOS to be more
> > specific). Please let me know is this is very wrong, but I just didn't
> > see any other way of doing it.
>
> No, it's not wrong. But it is preferrable to have a nonzero value in
> var->pixclock (whether calculated or via a VBE function call).
>
> Still, I agree with you to initialize mode->refresh to zero (or perhaps
> -1 to to denote a divide by zero) for these cases.
OK, nice. I'd say that 0 might be a little cleaner (we're avoiding
<nn>x<nn>-4294967295 entries in the sysfs nodes without having to
write any additional code). Also, no one should be dividing anything by
mode->refresh without checking its contents first, so having a zero
there doesn't seem like something dangerous. But, ultimately it's
up to you to decide, of course.
--
Michal Januszewski Gentoo Linux Developer
cell: +48504917690 http://dev.gentoo.org/~spock/
JID: spock@im.gentoo.org freenode: #gentoo-dev, #gentoo-pl
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
prev parent reply other threads:[~2005-10-14 15:04 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-09 9:29 [PATCH] fbdev: fix the fb_find_nearest_mode() function Michal Januszewski
2005-10-10 8:21 ` Antonino A. Daplas
2005-10-13 19:36 ` Michal Januszewski
2005-10-14 0:18 ` Antonino A. Daplas
2005-10-14 15:04 ` Michal Januszewski [this message]
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=20051014150408.GA9296@spock.one.pl \
--to=spock@gentoo.org \
--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