Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
screen goes un-readably distorted after leaving X11
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

Goto page 1, 2, 3  Next  
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
gnychis
Veteran
Veteran


Joined: 23 Mar 2005
Posts: 1004
Location: Pittsburgh, PA

PostPosted: Wed Jun 15, 2005 5:53 pm    Post subject: screen goes un-readably distorted after leaving X11 Reply with quote

Hi,

I use a Dell 2005FPW which is a wide screen LCD. It took me some time to get it to work with X11, but ever since I have, when I leave X11, it makes my console completely distorted and unreadable. Everything is blurry and the text is just all over the place.

Another thing, is when I boot up, the screen seems wrongly offset or something, for instance, when gentoo loads, it has the [OK] boxes on the right hand side... well the right bracket gets cut off and ends up at the beginning of the line, so it looks like:

Code:
]  Bringing up eth0                                       [OK


I can't figure out either of the problems. Any help would be greatly appreciated, thanks!

So let me give you some of my settings:

In my kernel, I have the following enabled:
Code:

Device Drivers -> Graphics Support -> Support for framebuffer devices
Device Drivers -> Graphics Support -> Vesa VGA Graphics Support -> Vesa Driver Type -> vesafb
Device Drivers -> Graphics Support -> support for the framebuffer splash


/boot/grub/grub.conf
Code:

default 0
timeout 5
splashimage=(hd0,0)/boot/grub/splash.xpm.gz

title=Gentoo Linux RAID
root (hd0,0)
kernel (hd0,0)/kernel-2.6.11-gentoo-r11 root=/dev/md0 video=vesafb:ywrap,mtrr,1680x1050-32@60

title=Windows XP G@m1nG
map (hd0) (hd2)
map (hd2) (hd0)
rootnoverify (hd2,0)
chainloader +1


xorg.conf
Code:

Section "Module"
    Load        "dbe"   # Double buffer extension
    SubSection  "extmod"
      Option    "omit xfree86-dga"   # don't initialise the DGA extension
    EndSubSection
    Load        "type1"
    Load        "freetype"
    Load       "glx"
EndSection

Section "Files"
    RgbPath     "/usr/X11R6/lib/X11/rgb"
    FontPath   "/usr/share/fonts/misc/"
    FontPath   "/usr/share/fonts/TTF/"
    FontPath   "/usr/share/fonts/Type1/"
    FontPath   "/usr/share/fonts/75dpi/"
    FontPath   "/usr/share/fonts/100dpi/"
    FontPath   "/usr/share/fonts/local/"
EndSection

Section "ServerFlags"
EndSection

Section "InputDevice"

    Identifier  "Keyboard1"
    Driver      "kbd"
    Option "AutoRepeat" "500 30"
    Option "XkbRules"   "xorg"
    Option "XkbModel"   "pc104"
    Option "XkbLayout"  "us"
EndSection

Section "InputDevice"
    Identifier  "Mouse1"
    Driver      "mouse"
    Option "Protocol"   "ExplorerPS/2"
    Option "Device"     "/dev/input/mice"
    Option "Buttons"    "10"
    Option "ZAxisMapping"       "9 10"
    Option "Resolution" "800"
EndSection

Section "Modes"
Identifier "16:10"
ModeLine "1680x1050" 146.2 1680 1960 2136 2240 1050 1080 1086 1089
-hsync +vsync
EndSection

Section "Monitor"
    Identifier  "Monitor0"
    UseModes "16:10"
    HorizSync   30-83
    VertRefresh 56-75
    Option "dpms"
EndSection

Section "Device"
    Identifier  "Standard VGA"
    VendorName  "Unknown"
    BoardName   "Unknown"
    Driver     "vga"
EndSection

Section "Device"
    Identifier  "Leadtek Winfast gf6800"
    Driver      "nvidia"
EndSection

Section "Screen"
    Identifier  "Screen 1"
    Device      "Leadtek Winfast gf6800"
    Monitor     "Monitor0"
    DefaultDepth 24

    Subsection "Display"
        Depth       8
        Modes       "1680x1050"
        ViewPort    0 0
    EndSubsection
    Subsection "Display"
        Depth       16
        Modes       "1680x1050"
        ViewPort    0 0
    EndSubsection
    Subsection "Display"
        Depth       24
        Modes       "1680x1050"
        ViewPort    0 0
    EndSubsection
    Subsection "Display"
        Depth       32
        Modes       "1680x1050"
        ViewPort    0 0
    EndSubsection

EndSection

Section "ServerLayout"
    Identifier  "Simple Layout"
    Screen "Screen 1"
    InputDevice "Mouse1" "CorePointer"
    InputDevice "Keyboard1" "CoreKeyboard"
EndSection
Back to top
View user's profile Send private message
drefo
n00b
n00b


Joined: 28 May 2005
Posts: 46

PostPosted: Wed Jun 15, 2005 10:29 pm    Post subject: Reply with quote

hedpe wrote:

Code:

]  Bringing up eth0                                       [OK


Code:

Section "Modes"
Identifier "16:10"
ModeLine "1680x1050" 146.2 1680 1960 2136 2240 1050 1080 1086 1089
-hsync +vsync
EndSection



Have you tried tweaking your ModeLine using the HSkew option? Since your last few pixels are
wrapping around to the left, it seems like you may need a lower setting than whatever the default
is.
Back to top
View user's profile Send private message
Deathwing00
Bodhisattva
Bodhisattva


Joined: 13 Jun 2003
Posts: 4087
Location: Dresden, Germany

PostPosted: Wed Jun 15, 2005 11:00 pm    Post subject: Reply with quote

Moved from Multimedia to Desktop Environments.
Back to top
View user's profile Send private message
darkphader
Veteran
Veteran


Joined: 09 May 2002
Posts: 1217
Location: Motown

PostPosted: Wed Jun 15, 2005 11:14 pm    Post subject: Reply with quote

I have the same problem with an IBM T20 notebook.
The console will appear correct after closing X about 20% of the time, the other 80% will leave it in various states of offset.
_________________
WYSIWYG - What You See Is What You Grep
Back to top
View user's profile Send private message
gnychis
Veteran
Veteran


Joined: 23 Mar 2005
Posts: 1004
Location: Pittsburgh, PA

PostPosted: Thu Jun 16, 2005 5:20 am    Post subject: Reply with quote

the only reason i don't think it is modeline, is that in X11 there is no pixel wrap around, it is only with the framebuffer when the computers boots up
Back to top
View user's profile Send private message
drefo
n00b
n00b


Joined: 28 May 2005
Posts: 46

PostPosted: Thu Jun 16, 2005 6:43 am    Post subject: Reply with quote

Good point ... I misunderstood. But I think you can also set similar options for the framebuffer at
boot time in your `video=' kernel argument. In fact, if there's an inconsistency between the framebuffer
timings and the X server modeline, it might explain your problem which occurs when switching
from X back to the system console, with the console on the framebuffer.

Code:

video=vesafb:mtrr, ywrap, xres:<>, yres:<>, depth:<>, left:<>, right:<>, hslen:<>, upper:<>, lower:<>, vslen:<>


Something like this, with the appropriate values might help.

Check out the framebuffer HOWTO for the way to choose the values.
Back to top
View user's profile Send private message
gnychis
Veteran
Veteran


Joined: 23 Mar 2005
Posts: 1004
Location: Pittsburgh, PA

PostPosted: Thu Jun 16, 2005 4:52 pm    Post subject: Reply with quote

thanks for that info, i followed your advice and changed my kernel line to:

Code:

kernel (hd0,0)/kernel-2.6.11-gentoo-r11 root=/dev/md0 video=vesafb:xres:1680,yres:1050,depth:32,left:104,right:280,hslen:176,upper:3,lower:30,vslen:6


but it still happens :(

I followed http://www.faqs.org/docs/Linux-HOWTO/Framebuffer-HOWTO.html to convert my X11 ModeLine to the settings above

any other ideas?
Back to top
View user's profile Send private message
drefo
n00b
n00b


Joined: 28 May 2005
Posts: 46

PostPosted: Thu Jun 16, 2005 6:24 pm    Post subject: Reply with quote

There's no hskew parameter for the framebuffer.

So I would try playing around a little bit with the parameters to see if you can produce a leftward
shift in the picture. Maybe try first reducing `left' by a bit, say by 4 or 5 and increasing `right'
by the same amount. If that doesn't work, you could possibly also try changing hsync length,
or even explicitly specify a different value for pixelclocks. The framebuffer timings may not be
quite the same as the X timings.

Make small changes that might affect the horizontal spacing and see if anything happens ... that's
my only real suggestion.

Also see fb.txt in the kernel documentation for a graphic representation of the meaning of the
parameters.
Back to top
View user's profile Send private message
gnychis
Veteran
Veteran


Joined: 23 Mar 2005
Posts: 1004
Location: Pittsburgh, PA

PostPosted: Fri Jun 17, 2005 8:48 am    Post subject: Reply with quote

you know what,

no matter how drastically i change left and right, it does not effect the screen what so ever... its like it's not even reading the settings

any more ideas? :\
Back to top
View user's profile Send private message
drefo
n00b
n00b


Joined: 28 May 2005
Posts: 46

PostPosted: Fri Jun 17, 2005 8:24 pm    Post subject: Reply with quote

Sounds like the vesafb driver is not accepting the options I suggested ... strange.
Does anything enlightening appear in dmesg about vesafb?

Maybe try compiling framebuffer support as modules ... at least it would
make it easier for you to play with the options: you wouldn't need to reboot.

You could try using the rivafb instead of the vesafb. I think it supported
some of the nvidia geforce cards, though I don't know whether it would work
on your gf6800 ...
Back to top
View user's profile Send private message
darkphader
Veteran
Veteran


Joined: 09 May 2002
Posts: 1217
Location: Motown

PostPosted: Fri Jun 17, 2005 9:25 pm    Post subject: Reply with quote

Fixed my problem by using the vesafb-tng for console support instead the savagefb.
With the vesafb-tng you can build a default resolution right in the kernel. I use it with my desktop system as well, which has an nVidia card, it may work for you as well.
_________________
WYSIWYG - What You See Is What You Grep
Back to top
View user's profile Send private message
darkphader
Veteran
Veteran


Joined: 09 May 2002
Posts: 1217
Location: Motown

PostPosted: Fri Jun 17, 2005 10:51 pm    Post subject: Reply with quote

drefo wrote:
Maybe try compiling framebuffer support as modules

I think there's a problem there in that the module doesn't get loaded soon enough.
_________________
WYSIWYG - What You See Is What You Grep
Back to top
View user's profile Send private message
drefo
n00b
n00b


Joined: 28 May 2005
Posts: 46

PostPosted: Sat Jun 18, 2005 1:32 am    Post subject: Reply with quote

darkphader wrote:
I think there's a problem there in that the module doesn't get loaded soon enough.


Probably you're right. I was just thinking for testing purposes it might be OK. I looked through the 2.6.12 vanilla sources
in drivers/video/vesafb.c, and it seems that the left, right, etcetera options were removed from the newer vesafb drivers.
So that explains why they don't work anymore :(

There does seem to be a possibility of specifiying the parameters by hand. I haven't read the sources carefully yet but it looks
as if you can specify some of the values in fbmon.c using certain define statements. Is the vesa-tng included in the vanilla
sources, or is there a patch you need to apply?
Back to top
View user's profile Send private message
darkphader
Veteran
Veteran


Joined: 09 May 2002
Posts: 1217
Location: Motown

PostPosted: Sat Jun 18, 2005 4:33 am    Post subject: Reply with quote

drefo wrote:
Is the vesa-tng included in the vanilla
sources, or is there a patch you need to apply?

Don't know for sure as I use darkphader-sources (fiigures), which is gentoo-sources plus the video for linux updates (needed for my DVB device). Ebuild at: http://realcomputerguy.com/gentoo/
I know that v4l2 doesn't provide vesafb-tng so either it's in vanilla or the Gentoo patchset provides it.
_________________
WYSIWYG - What You See Is What You Grep
Back to top
View user's profile Send private message
gnychis
Veteran
Veteran


Joined: 23 Mar 2005
Posts: 1004
Location: Pittsburgh, PA

PostPosted: Sat Jun 18, 2005 5:38 pm    Post subject: Reply with quote

it seems as if it doesn't support 1680 as a mode, I downloaded fbset, to try and set the framebuffer, and whenever i try to do "fbset -xres 1680", it gives me an error

Also, when i have it read the current framebuffer settings, it tells me I am in "1400x1050@60" mode. It seems as if it just has no clue what 1680 is.

How can I add this mode?
Back to top
View user's profile Send private message
gnychis
Veteran
Veteran


Joined: 23 Mar 2005
Posts: 1004
Location: Pittsburgh, PA

PostPosted: Sat Jun 18, 2005 5:51 pm    Post subject: Reply with quote

I found errors using dmesg :(

Code:

hedpe@monster ~ $ dmesg | grep vesafb
42:Kernel command line: root=/dev/md0 video=vesafb:xres:1680,yres:1050,depth:32,left:104,right:280,hslen:176,upper:3,lower:30,vslen:6
154:vesafb: unrecognized option xres:1680
155:vesafb: unrecognized option yres:1050
156:vesafb: unrecognized option depth:32
157:vesafb: unrecognized option left:104
158:vesafb: unrecognized option right:280
159:vesafb: unrecognized option hslen:176
160:vesafb: unrecognized option upper:3
161:vesafb: unrecognized option lower:30
162:vesafb: unrecognized option vslen:6
Back to top
View user's profile Send private message
darkphader
Veteran
Veteran


Joined: 09 May 2002
Posts: 1217
Location: Motown

PostPosted: Sat Jun 18, 2005 6:04 pm    Post subject: Reply with quote

You may want to try vesafb-tng which, as I pointed out previously, works for me. Compile it into the kernel and set the resolution during the kernel make. No need to provide and boot time parameters then (unless you want different ones).
_________________
WYSIWYG - What You See Is What You Grep
Back to top
View user's profile Send private message
gnychis
Veteran
Veteran


Joined: 23 Mar 2005
Posts: 1004
Location: Pittsburgh, PA

PostPosted: Sat Jun 18, 2005 8:40 pm    Post subject: Reply with quote

i thought with vesafb-tng you still have to set boot time parameters...

i will try that now
Back to top
View user's profile Send private message
darkphader
Veteran
Veteran


Joined: 09 May 2002
Posts: 1217
Location: Motown

PostPosted: Sat Jun 18, 2005 11:25 pm    Post subject: Reply with quote

hedpe wrote:
i thought with vesafb-tng you still have to set boot time parameters...

Only if you don't want the default the you compile into the kernel.
If you want to set boot time params the argument is different:
Code:
video=vesafb:ypan,1024x768-32@85
as an example.
_________________
WYSIWYG - What You See Is What You Grep
Back to top
View user's profile Send private message
gnychis
Veteran
Veteran


Joined: 23 Mar 2005
Posts: 1004
Location: Pittsburgh, PA

PostPosted: Sun Jun 19, 2005 5:03 am    Post subject: Reply with quote

i tried not supplying the kernel with vesafb parameters, and it still only gives me 1400x1050@60 :(

any other ideas?
George :)
Back to top
View user's profile Send private message
drefo
n00b
n00b


Joined: 28 May 2005
Posts: 46

PostPosted: Tue Jun 21, 2005 10:03 pm    Post subject: Reply with quote

I think your problem is that the 1680x1050 resolution is not a standard
mode for the framebuffer, so it's not detected by the vesafb code when you request
that resolution in the kernel "video=vesafb:" bootup option. It would be interesting
to know how the driver selects 1400x1050. That seems to suggest that the vesafb driver
does probe your monitor ... do you see anything in dmesg about how the
1400x1050 was chosen?

Default modes for the framebuffer seem to be defined in drivers/video/modedb.c,
in the array:

Code:

static const struct fb_videomode modedb[] = {
    { ....



There is some documentation about how it works in Documentation/fb/modedb.txt.

So it may be that you could write a new videomode entry defining your 1680x1050 screen into
modedb [], and get the vesafb to recognize it, with some hacking of vesafb-tng.c

Probably you'ld have to set noedid at boot. There also seems to be an option called gtf
for vesafb-tng, which may let you customize the modes a bit. But it looks like you'll
either need to do a little hacking, or post your problem to a list where framebuffer
developers can read it.

If I can manage to figure it out myself, I'll post a patch.

You can possibly also use the fbset utility to set the resolution you want ... although
that wouldn't solve the boot-time problem with the text wrapping around.

(I think you just have to write the mode description you want into /etc/fb.modes, and then
load it using fbset -db /etc/fb.modes, but of course check man fb.modes and man fbset
to be sure.)


Last edited by drefo on Tue Jun 21, 2005 10:25 pm; edited 1 time in total
Back to top
View user's profile Send private message
darkphader
Veteran
Veteran


Joined: 09 May 2002
Posts: 1217
Location: Motown

PostPosted: Tue Jun 21, 2005 10:19 pm    Post subject: Reply with quote

drefo wrote:
I think your problem is that the 1680x1050 resolution is not a standard
mode for the framebuffer


As a note, I have set undefined resolutions successfully when using the savagefb driver (never tried it with vesafb-tng).
_________________
WYSIWYG - What You See Is What You Grep
Back to top
View user's profile Send private message
drefo
n00b
n00b


Joined: 28 May 2005
Posts: 46

PostPosted: Tue Jun 21, 2005 10:29 pm    Post subject: Reply with quote

darkphader wrote:


As a note, I have set undefined resolutions successfully when using the savagefb driver (never tried it with vesafb-tng).


If you grep for fb_find_mode in savage/savagefb.c you'll find that this function is
called in the savage driver, but there is no such call in vesafb.c, or vesafb-tng.c.
So I think the behaviour is probably different.
Back to top
View user's profile Send private message
darkphader
Veteran
Veteran


Joined: 09 May 2002
Posts: 1217
Location: Motown

PostPosted: Tue Jun 21, 2005 11:00 pm    Post subject: Reply with quote

drefo wrote:
So I think the behaviour is probably different.

Just tested it and it appears one cannot set undefined resolutions with vesafb-tng.
_________________
WYSIWYG - What You See Is What You Grep
Back to top
View user's profile Send private message
gnychis
Veteran
Veteran


Joined: 23 Mar 2005
Posts: 1004
Location: Pittsburgh, PA

PostPosted: Wed Jun 22, 2005 12:10 am    Post subject: Reply with quote

i guess I will try to hack at modedb.c

I cannot use fbset because it doesn't recognize the mode... i tried adding the settings to /etc/fb.modes also, but i can't get it

Code:

monster linux # fbset -xres 1680
ioctl FBIOPUT_VSCREENINFO: Invalid argument


I guess my only solution is modedb.c?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Goto page 1, 2, 3  Next
Page 1 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum