2.6.0: atyfb broken
Hello,
I have got an HP omnibook 4150B. When booting with atyfb, the kernel messages look great:
atyfb: 3D RAGE Mobility (PCI) [0x4c4d rev 0x64] 8M SDRAM, 29.498928 MHz XTAL, 230 MHz PLL, 50 Mhz MCLK
fb0: ATY Mach64 frame buffer device on PCI
But either the screen is black and I see only the cursor and Background colors (CONFIG_FRAMEBUFFER_CONSOLE disabled), but X11 starts fine.
With CONFIG_FRAMEBUFFER_CONSOLE enabled it does not work at all:
I get a completely broken picture that is not syncing and blinking and so on. Its completely useless. X11 will not work either :(
I enabled in the kernel config:CONFIG_FB_ATY, CONFIG_FB_ATY_CT and CONFIG_FB_ATY_XL_INIT
lspci -v:
01:00.0 VGA compatible controller:
ATI Technologies Inc Rage Mobility P/M AGP 2x (rev 64) (prog-if 00 [VGA])
Subsystem: Hewlett-Packard Company: Unknown device 000a
Flags: bus master, stepping, medium devsel, latency 66, IRQ 10 Memory at fd000000 (32-bit, non-prefetchable) [size=16M]
I/O ports at e800 [size=256]
Memory at fedfe000 (32-bit, non-prefetchable) [size=4K] Expansion ROM at <unassigned> [disabled] [size=128K]
Capabilities: [50] AGP version 1.0
Capabilities: [5c] Power Management version 1
According to dmesg and to the omnibook's manual the card shall have 8 MB memory and not 16 MB as lspci is saying.
Regards, claas
Quoted 9 lines · Claas Langbehn
Hello,
I have got an HP omnibook 4150B. When booting with atyfb, the kernel messages look great:
atyfb: 3D RAGE Mobility (PCI) [
0x4c4drev0x64] 8M SDRAM, 29.498928 MHz XTAL, 230 MHz PLL, 50 Mhz MCLK
fb0: ATY Mach64 frame buffer device on PCI
Quoted 8 lines
But either the screen is black and I see only the cursor and Background colors (
CONFIG_FRAMEBUFFER_CONSOLEdisabled), but X11 starts fine.With
CONFIG_FRAMEBUFFER_CONSOLEenabled it does not work at all:
I get a completely broken picture that is not syncing and blinking and so on. Its completely useless. X11 will not work either :(
The framebuffer drivers in 2.6.0 aren't very up to date, and don't work very well. There are many fixes sitting out in an external tree and we'll try to start merging that work up next month.
Ben, if you could shoot me over a copy of the current linux-fbdev tree that might help things along a bit.
Quoted 3 lines
Ben, if you could shoot me over a copy of the current linux-fbdev tree that might help things along a bit.
linux-fbdev is at bk://fbdev.bkbits.net/fbdev-2.5
Some things in there are too crappy though, like the whole gfx-client stuff, I suggest you don't merge as-is. I will start sending you patches tomorrow hopefully.
Ben.
Quoted 9 lines
Quoted 3 lines
Ben, if you could shoot me over a copy of the current linux-fbdev tree that might help things along a bit.
linux-fbdev is at bk://fbdev.bkbits.net/fbdev-2.5
Some things in there are too crappy though, like the whole gfx-client stuff, I suggest you don't merge as-is. I will start sending you patches tomorrow hopefully.
Is the gfx-client stuff the only issue for you?
Quoted 10 lines · James Simmons
Quoted 8 lines
Quoted 2 lines
Ben, if you could shoot me over a copy of the current linux-fbdev tree that might help things along a bit.
linux-fbdev is at bk://fbdev.bkbits.net/fbdev-2.5
Some things in there are too crappy though, like the whole gfx-client stuff, I suggest you don't merge as-is. I will start sending you patches tomorrow hopefully.
Is the gfx-client stuff the only issue for
The main one. I have some problems with the pixmap code (see my other message about this, the locking is definitely broken) and I'm not sure we want to merge the allocation changes upstream yet (well, maybe they are stable enough by now ?)
Ben.
Quoted 10 lines · James Simmons
Quoted 8 lines
Quoted 2 lines
Ben, if you could shoot me over a copy of the current linux-fbdev tree that might help things along a bit.
linux-fbdev is at bk://fbdev.bkbits.net/fbdev-2.5
Some things in there are too crappy though, like the whole gfx-client stuff, I suggest you don't merge as-is. I will start sending you patches tomorrow hopefully.
Is the gfx-client stuff the only issue for
The main one. I have some problems with the pixmap code (see my other message about this, the locking is definitely broken) and I'm not sure we want to merge the allocation changes upstream yet (well, maybe they are stable enough by now ?)
Ben.
Quoted 9 lines
Quoted 3 lines
Ben, if you could shoot me over a copy of the current linux-fbdev tree that might help things along a bit.
linux-fbdev is at bk://fbdev.bkbits.net/fbdev-2.5
Some things in there are too crappy though, like the whole gfx-client stuff, I suggest you don't merge as-is. I will start sending you patches tomorrow hopefully.
Is the gfx-client stuff the only issue for you?
Quoted 8 lines · Claas Langbehn
I have got an HP omnibook 4150B. When booting with atyfb, the kernel messages look great:
atyfb: 3D RAGE Mobility (PCI) [
0x4c4drev0x64] 8M SDRAM, 29.498928 MHz XTAL, 230 MHz PLL, 50 Mhz MCLK
fb0: ATY Mach64 frame buffer device on PCIBut either the screen is black and I see only the cursor and Background colors (
CONFIG_FRAMEBUFFER_CONSOLEdisabled), but X11 starts fine.
Does your notebook work with the atyfb in 2.4.23? With the one in 2.4.22 and earlier?
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]
In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
Hello Geert,
Quoted 11 lines
Quoted 8 lines
I have got an HP omnibook 4150B. When booting with atyfb, the kernel messages look great:
atyfb: 3D RAGE Mobility (PCI) [
0x4c4drev0x64] 8M SDRAM, 29.498928 MHz XTAL, 230 MHz PLL, 50 Mhz MCLK
fb0: ATY Mach64 frame buffer device on PCIBut either the screen is black and I see only the cursor and Background colors (
CONFIG_FRAMEBUFFER_CONSOLEdisabled), but X11 starts fine.Does your notebook work with the atyfb in 2.4.23? With the one in 2.4.22 and earlier?
with 2.4.23 it does not work either.
dmesg says:
atyfb: using auxiliary register aperture
atyfb: Mach64 BIOS is located at c0000, mapped at c00c0000.
atyfb: BIOS contains driver information table.
atyfb: colour active matrix monitor detected: CPT CLAA141XB01
id=10, 1024x768 pixels, 262144 colours (LT mode)
supports 60 Hz refresh rates, default 60 Hz
LCD CRTC parameters: 15384 167 127 130 0 17 805 767 769 6
atyfb: 3D RAGE Mobility (PCI) [0x4c4d rev 0x64] 8M SDRAM, 29.498928 MHz XTAL,
230 MHz PLL, 83 Mhz MCLK, 125 Mhz XCLKConsole: switching to colour frame buffer device 80x25
fb0: ATY Mach64 frame buffer device on PCI
When booting the screen gets slowly flooded with white. X11 works anyway.
dmesg's output shows different MCLK and XCLK with kernel 2.4.23 (see above).
Regards,claas
Quoted 29 lines · Claas Langbehn
Quoted 11 lines
Quoted 8 lines
I have got an HP omnibook 4150B. When booting with atyfb, the kernel messages look great:
atyfb: 3D RAGE Mobility (PCI) [
0x4c4drev0x64] 8M SDRAM, 29.498928 MHz XTAL, 230 MHz PLL, 50 Mhz MCLK
fb0: ATY Mach64 frame buffer device on PCIBut either the screen is black and I see only the cursor and Background colors (
CONFIG_FRAMEBUFFER_CONSOLEdisabled), but X11 starts fine.Does your notebook work with the atyfb in 2.4.23? With the one in 2.4.22 and earlier?
with 2.4.23 it does not work either.
dmesg says:
atyfb: using auxiliary register aperture
atyfb: Mach64 BIOS is located at c0000, mapped atc00c0000.
atyfb: BIOS contains driver information table.
atyfb: colour active matrix monitor detected: CPT CLAA141XB01id=10, 1024x768 pixels, 262144 colours (LT mode) supports 60 Hz refresh rates, default 60 Hz LCD CRTC parameters: 15384 167 127 130 0 17 805 767 769 6 atyfb: 3D RAGE Mobility (PCI) [0x4c4d rev 0x64] 8M SDRAM, 29.498928 MHz XTAL, 230 MHz PLL, 83 Mhz MCLK, 125 Mhz XCLKConsole: switching to colour frame buffer device 80x25
fb0: ATY Mach64 frame buffer device on PCI
Quoted 5 lines
When booting the screen gets slowly flooded with white. X11 works anyway.
dmesg's output shows different MCLK and XCLK with kernel 2.4.23 (see above).
Does it work with 2.4.22 and earlier? Mobility support was changed a lot in 2.4.23.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]
In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
Quoted 17 lines · Geert Uytterhoeven
Quoted 17 lines
with 2.4.23 it does not work either.
dmesg says:
atyfb: using auxiliary register aperture
atyfb: Mach64 BIOS is located at c0000, mapped atc00c0000.
atyfb: BIOS contains driver information table.
atyfb: colour active matrix monitor detected: CPT CLAA141XB01id=10, 1024x768 pixels, 262144 colours (LT mode) supports 60 Hz refresh rates, default 60 Hz LCD CRTC parameters: 15384 167 127 130 0 17 805 767 769 6 atyfb: 3D RAGE Mobility (PCI) [0x4c4d rev 0x64] 8M SDRAM, 29.498928 MHz XTAL, 230 MHz PLL, 83 Mhz MCLK, 125 Mhz XCLKConsole: switching to colour frame buffer device 80x25
fb0: ATY Mach64 frame buffer device on PCI
Quoted 8 lines
Quoted 5 lines
When booting the screen gets slowly flooded with white. X11 works anyway.
dmesg's output shows different MCLK and XCLK with kernel 2.4.23 (see above).
Does it work with 2.4.22 and earlier? Mobility support was changed a lot in 2.4.23.
Did this laptop work before? My first guess is no. Both 2.4.22 and 2.6.0 do not support LCD displays.
2.4.23 does, and is the only kernel that does have a chance of working.
In case 2.4.22 did work (possible since 720x400 VGA text mode is converted in hardware to 640x400, and therefore very similar to 640x480 in timings), it will work very badly, the image is most likely not correct and any attempt to switch video mode will fail.
The mclk/xclk settings in 2.4.23 are the correct default clock frequencies (checked with ATi). Other kernel versions use timings for an Apple Powerbook, which, because the open firmware initializes a correct startup video mode and PowerPC specific code that prevents switching to 640x480 will work with the original driver. This Apple laptop is detected in 2.4.23 and still gets the original frequencies.
Anyway, the frequencies are correct for your laptop, if the display is fading white it means the graphics chip is operating correctly but provide wrong video mode timings to your LCD display.
Daniël
Hello!
Quoted 2 lines
Quoted 2 lines
Does it work with 2.4.22 and earlier? Mobility support was changed a lot in 2.4.23.
No, 2.4.22 does not work either. It has also screen-flickering.
2.6.0 seems to be closest to a working solution.
( CONFIG_FB_ATY, CONFIG_FB_ATY_CT and CONFIG_FB_ATY_XL_INIT switched on, CONFIG_FRAMEBUFFER_CONSOLE disabled)
bye, claas
Quoted 7 lines · Claas Langbehn
Hello!
Quoted 2 lines
Quoted 2 lines
Does it work with 2.4.22 and earlier? Mobility support was changed a lot in 2.4.23.
No, 2.4.22 does not work either. It has also screen-flickering.
Ok, that was expected; this most likely is because of the initialisation code in 2.4.22; it is completely unsuitable for the Mobility M1 and programs very bad values into the chip.
Quoted 1 line
2.6.0 seems to be closest to a working solution.
Not at all. Your laptop has an LCD display. Unlike CRTs, LCD displays have a fixed resolution; you LCD display has 1024x768 pixels. Because the display is completely digital, the display needs its pixel data send at a fixed rate, enforcing also the refresh rate, 60 Hz in your case.
(LCD monitors with VGA-connectors have special chips that adapt the resolution and refresh rate of a VGA signal to the video mode desired by the panel. Image quality suffers badly)
Because of this, a traditional video driver will fail on such a display. I.e. Atyfb switches to 640x480 60 Hz, which is completely different from what your display accepts, and it won't work.
Because of some VGA compatibility stuff normal 720x400 VGA text mode is downscaled to 640x400 by your laptop. Therefore, it is not too different from 640x480 and on some computers it displays something. I experienced this on my Rage LT pro, the image was completely wrong, the bottom part of the screen was a mirror of the upper part.
Therefore, it might happen that 2.6.0 does display something (initialization is different from 2.4.x), but 2.6.0 will not display a correct image in any case.
Years ago I started making the Atyfb support LCD displays. It was a very difficult project; I got my own laptop working more than 2 years ago, after that slowly all the other machines I knew of started working. However, it was only until recently before Geert's laptop did work; that was a really stupborn one. The LCD registers on the chips are very tricky to set right; the clock code (which was completely wrong) was even more tricky to get right.
My work was included in 2.4.23. Therefore that kernel
is the only one which has any chance of working. Apparently there still is an LCD specific issue with your laptop, which needs to be debugged.
What to do?
The best thing you can try is to connect a CRT. Its a handy tool (it eats any video mode, including wrong ones) to check if the driver does something wrong. Use it to inspect geometry and the horizontal & vertical refresh rates. The CRT should dislay 1024x768 60 Hz in all resolutions (unless you switch off the LCD display).
Compile Atyfb as module. Use fbset to switch video modes blindly. Check the following modes: 640x400, 640x480, 1024x768.
If everything is ok, we'll start to do some register debugging.
Daniël
Hello Daniël!
Quoted 10 lines
What to do?
The best thing you can try is to connect a CRT. Its a handy tool (it eats any video mode, including wrong ones) to check if the driver does something wrong. Use it to inspect geometry and the horizontal & vertical refresh rates. The CRT should dislay 1024x768 60 Hz in all resolutions (unless you switch off the LCD display).
Compile Atyfb as module. Use fbset to switch video modes blindly. Check the following modes: 640x400, 640x480, 1024x768.
Okay, the external monitor was a good idea.
I can boot with the external monitor and atyfb.
when I do fbset 1024x768-60, then the screen gets distorted, then I hit Fn + F5 (Monitor selection) several times, and finally I get a working picture.
So tell me how we can do register debuggig.
Regards, claas
Quoted 11 lines · Claas Langbehn
Quoted 8 lines
The best thing you can try is to connect a CRT. Its a handy tool (it eats any video mode, including wrong ones) to check if the driver does something wrong. Use it to inspect geometry and the horizontal & vertical refresh rates. The CRT should dislay 1024x768 60 Hz in all resolutions (unless you switch off the LCD display).
Compile Atyfb as module. Use fbset to switch video modes blindly. Check the following modes: 640x400, 640x480, 1024x768.
Okay, the external monitor was a good idea.
I can boot with the external monitor and atyfb.
2.4.23?
Quoted 3 lines
when I do fbset 1024x768-60, then the screen gets distorted, then I hit Fn + F5 (Monitor selection) several times, and finally I get a working picture.
Ah you have a working fn-f5? good! fn-f5 will fix your display in most cases, however, my experience is also that it can mess things up. If you can get in 1024x768 without fn-f5 please try so, to make sure the chip is in a clean state.
Remember to do all tests with both displays enabled. When you are in 1024x768 60 Hz, the hardware stretcher is disabled. Test if horizontal stretching works:
fbset -xres 640
You can do this because the video timings are locked to 1024x768-60, and your refresh rate does not get a boost like with a normal vga monitor. Because we only use 1 Crt controller, your external monitor is locked too.
You should now have a 640x768 mode. Watch the image on the Crt display. It should be rock stable during the mode switch the Crt should not be detecting any mode change and the picture should not change position.
Switch back to 1024x768:
fbset -xres 1024
Now try the vertical streching:
fbset -yres 480
Check again very close what happens on your crt. It is my expectation that one of these tests fails and the other will wok correctly.
Quoted 1 line
So tell me how we can do register debuggig.
I'll send you my register dump programs so you can compare the setting of the Crt controller with fo example X video modes.
Daniël
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
Hello Daniël,
(the follwing is made with 2.4.23:)
at first I want to thank you again for helping me to debug this bug. After you left irc, i continued to debug, with the following results:
First, I need to enable CONFIG_FB_ATY_GENERIC_LCD. But I dont need to patch it. around the hack for Geerts notebook.
Second, I need to enable "Video Expansion" in system bios. (At lower resolutions, video is expanded to cover the entire LCD)
If I dont enable Video Expansion, the 640x480-60 and 800x600-60 resolutions are broken. Repairing by pressing Fn-F5 is possible, though. In that case booting with video=atyfb:1024x768-8@60 helped to get at least that resolution working.
Have a look at my debugging logs 10.log - 16.log at
http://www.rootdir.de/files/atyfb/.
regards, claas
Quoted 8 lines
Hello,
I have got an HP omnibook 4150B. When booting with atyfb, the kernel messages look great:
atyfb: 3D RAGE Mobility (PCI) [
0x4c4drev0x64] 8M SDRAM, 29.498928 MHz XTAL, 230 MHz PLL, 50 Mhz MCLK
fb0: ATY Mach64 frame buffer device on PCI
Can you try my latest patch.
* James Simmons <[email protected]>:
Quoted 3 lines
Can you try my latest patch.
This patch did wonders for my laptop with neofb, for the FIRST TIME since 2.5.x I get a usable FB when swithcing back from X11.
Great job!
atyfb at work, however got a nice blinking cursor, and when booting the logo is fucked up and I've got some random chars on the screen.
Screenshot at request.
Signature · 4 lines
Ralf Hildebrandt (Im Auftrag des Referat V a) [email protected] Charite - Universitätsmedizin Berlin Tel. +49 (0)30-450 570-155 Gemeinsame Einrichtung von FU- und HU-Berlin Fax. +49 (0)30-450 570-916 Referat V a - Kommunikationsnetze - AIM. ralfpostfix
Quoted 7 lines
Quoted 2 lines
This patch did wonders for my laptop with neofb, for the FIRST TIME since 2.5.x I get a usable FB when swithcing back from X11.
Great job!
Yeah!!!
Quoted 4 lines
atyfb at work, however got a nice blinking cursor, and when booting the logo is fucked up and I've got some random chars on the screen.
Screenshot at request.
please do. Also please send me info on the Mach64 card you have.