From: "Antonino A. Daplas" <adaplas@hotpop.com>
To: David Eger <eger@havoc.gtf.org>, adaplas@pol.net
Cc: Linux Fbdev development list <linux-fbdev-devel@lists.sourceforge.net>
Subject: Re: Sane behavior of fbset
Date: Sat, 19 Jun 2004 02:40:46 +0800 [thread overview]
Message-ID: <200406190240.26228.adaplas@hotpop.com> (raw)
In-Reply-To: <20040618173840.GA3989@havoc.gtf.org>
On Saturday 19 June 2004 01:38, David Eger wrote:
> On Fri, Jun 18, 2004 at 09:45:12AM +0800, Antonino A. Daplas wrote:
> > Hi,
> >
> > Currently, using fbset either corrupts the display, or at worst, hangs
> > the GPU. I consider this a critical bug. I don't want to discuss the
> > pros/cons of using fbset vs stty to change the console size, but we need
> > to make sure that using fbset (or any utility that utilizes the
> > fb_set_var ioctl) does not produce undefined behavior. There are at
> > least 3 possibilities:
> >
> > 1. Revert to 2.4 behavior. This is easy to add since fbdev already has
> > a notifier support. (I already have working code for this). Of course,
> > stty will still work.
>
> Just for my enlightenment, could you give a synopsis of 2.4 behavior
> versus 2.6 behavior?
>
In 2.4
1. you can use fbset to change the console window size.
2. stty will not change the window size (produce a small viewport or the
contents will be clipped)
3. Switching from one console to another will preserve the video mode.
Example:
tty1 - 800x600-16@85
tty2 - 1024x768-8@60
When switching from tty2 to tty1 or vice versa, your mode setting will be
retained. This is because each console has its own copy of
fb_var_screeninfo.
4. The need to create/validate a modeline is optional as this is expected to
be done in userland.
In 2.6
1. If you use fbset, you will get screen corruption or hang the GPU
2. stty will do the function of fbset. However, stty will only pass rows and
cols (xres and yres respectively). There is no information for bit depth,
timings, virtual resolution, etc.
3. Switching from one console to another may or may not preserve your mode
settings. In the example above, If I switch from tty2 to tty1, I might get a
display with a refresh of 60Hz at 8 bpp. The mode you get will depend on the
drivers capability to pick/create a modeline. This is because you only have
1 valid fb_var_screeninfo at one time, and this is info->var.
4. Creation/validation of modelines by drivers is practically a necessity.
Of course, 2.6 does have some good points. It's easier to write a driver for
it, the resulting driver code is probably smaller, it's faster, and fbcon and
fbdev are separated, ie you can load fbdev without taking over your console.
The last one is probably useful for embedded devices.
Tony
-------------------------------------------------------
This SF.Net email is sponsored by The 2004 JavaOne(SM) Conference
Learn from the experts at JavaOne(SM), Sun's Worldwide Java Developer
Conference, June 28 - July 1 at the Moscone Center in San Francisco, CA
REGISTER AND SAVE! http://java.sun.com/javaone/sf Priority Code NWMGYKND
next prev parent reply other threads:[~2004-06-18 18:40 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-06-18 1:45 Sane behavior of fbset Antonino A. Daplas
2004-06-18 8:24 ` Geert Uytterhoeven
2004-06-23 18:52 ` jsimmons
2004-06-23 18:59 ` Geert Uytterhoeven
2004-06-23 19:07 ` jsimmons
2004-06-23 19:17 ` Geert Uytterhoeven
2004-06-23 19:21 ` jsimmons
2004-06-18 13:31 ` John Zielinski
2004-06-18 17:38 ` David Eger
2004-06-18 18:40 ` Antonino A. Daplas [this message]
2004-06-19 3:16 ` David Eger
2004-06-19 6:13 ` Antonino A. Daplas
2004-06-19 15:59 ` John Zielinski
2004-06-23 18:57 ` jsimmons
2004-06-23 15:55 ` Benjamin Herrenschmidt
2004-06-23 16:08 ` Geert Uytterhoeven
2004-06-23 17:29 ` John Zielinski
2004-06-23 20:39 ` jsimmons
2004-06-23 21:44 ` John Zielinski
2004-06-23 19:00 ` jsimmons
2004-06-23 19:38 ` Benjamin Herrenschmidt
2004-06-23 20:03 ` jsimmons
2004-06-23 20:12 ` Benjamin Herrenschmidt
2004-06-23 23:50 ` Antonino A. Daplas
2004-06-24 2:17 ` Antonino A. Daplas
2004-06-19 15:50 ` John Zielinski
2004-06-23 18:55 ` jsimmons
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=200406190240.26228.adaplas@hotpop.com \
--to=adaplas@hotpop.com \
--cc=adaplas@pol.net \
--cc=eger@havoc.gtf.org \
--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).