Skip to contentSkip to conversation

Radeon framebuffer weirdness in -mm2

DISCUSSION Matt Mackall 6 participants 16 messages Jan 20, 2005 – Jan 24, 2005

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

I'm seeing radeonfb on my ThinkPad T30 go weird on reboot (lots of horizontal lines) and require powercycling to fix. Worked fine with 2.6.10.

Signature · 1 line
Mathematics is the supreme nostalgia of our time.
#1 lore raw
Quoted 3 lines · Matt Mackall

I'm seeing radeonfb on my ThinkPad T30 go weird on reboot (lots of horizontal lines) and require powercycling to fix. Worked fine with 2.6.10.

Which radeon driver? CONFIG_FB_RADEON_OLD or CONFIG_FB_RADEON?

(cc Ben, who is the likely cuprit ;)

Which -mm2, btw? 2.6.10-mm2 or 2.6.11-rc1-mm2?

Did you try the corresponding -mm1?

#2 lore raw
Quoted 6 lines · Andrew Morton
Quoted 3 lines · Matt Mackall

I'm seeing radeonfb on my ThinkPad T30 go weird on reboot (lots of horizontal lines) and require powercycling to fix. Worked fine with 2.6.10.

Which radeon driver? CONFIG_FB_RADEON_OLD or CONFIG_FB_RADEON?

FB_RADEON.

Quoted 1 line

(cc Ben, who is the likely cuprit ;)

Btw, ajoshi's address from MAINTAINERS is bouncing.

Quoted 1 line

Which -mm2, btw? 2.6.10-mm2 or 2.6.11-rc1-mm2?

2.6.11-rc1-mm2

Quoted 1 line

Did you try the corresponding -mm1?

Nothing between that and .10 yet. Building -mm1 now.

Signature · 1 line
Mathematics is the supreme nostalgia of our time.
#3 lore raw
Quoted 4 lines · Matt Mackall
Quoted 2 lines

Which radeon driver? CONFIG_FB_RADEON_OLD or CONFIG_FB_RADEON?

FB_RADEON.

Ah, OK. Likely culprits are

radeonfb-massive-update-of-pm-code.patch
radeonfb-build-fix.patch

#15 lore raw
In reply to Andrew Morton
Quoted 5 lines · Andrew Morton
Quoted 3 lines · Matt Mackall

I'm seeing radeonfb on my ThinkPad T30 go weird on reboot (lots of horizontal lines) and require powercycling to fix. Worked fine with 2.6.10.

Quoted 7 lines

Which radeon driver? CONFIG_FB_RADEON_OLD or CONFIG_FB_RADEON?

(cc Ben, who is the likely cuprit ;)

Which -mm2, btw? 2.6.10-mm2 or 2.6.11-rc1-mm2?

Did you try the corresponding -mm1?

/me curses possible BIOS crap ...

radeonfb tries to restore initial mode when the module is closed, which wouldn't work for a VGA text thing in fact... I suspect something cause driver remove() routines to be called on reboot, can you confirm ? Or is it a module that gets removed ? It may well be a problem that has always been there (regardless of the radeon driver version) and just triggered by something the kernel does on reboot...

Ben.

-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl

#13 lore raw
In reply to Matt Mackall
Quoted 6 lines · Matt Mackall
Quoted 5 lines · Andrew Morton
Quoted 3 lines · Matt Mackall

I'm seeing radeonfb on my ThinkPad T30 go weird on reboot (lots of horizontal lines) and require powercycling to fix. Worked fine with 2.6.10.

Quoted 7 lines
Quoted 1 line

Which radeon driver? CONFIG_FB_RADEON_OLD or CONFIG_FB_RADEON?

FB_RADEON.

Quoted 1 line

(cc Ben, who is the likely cuprit ;)

Btw, ajoshi's address from MAINTAINERS is bouncing.

The file should be updated, I am the radeonfb maintainer now.

Quoted 7 lines
Quoted 1 line

Which -mm2, btw? 2.6.10-mm2 or 2.6.11-rc1-mm2?

2.6.11-rc1-mm2

Quoted 1 line

Did you try the corresponding -mm1?

Nothing between that and .10 yet. Building -mm1 now.

Thanks.

Ben.

-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl

#14 lore raw
Quoted 6 lines
Quoted 6 lines
Quoted 5 lines
Quoted 3 lines

I'm seeing radeonfb on my ThinkPad T30 go weird on reboot (lots of horizontal lines) and require powercycling to fix. Worked fine with 2.6.10.

Which radeon driver? CONFIG_FB_RADEON_OLD or CONFIG_FB_RADEON?

Quoted 7 lines
Quoted 5 lines

FB_RADEON.

Quoted 1 line

(cc Ben, who is the likely cuprit ;)

Btw, ajoshi's address from MAINTAINERS is bouncing.

The file should be updated, I am the radeonfb maintainer now.

Speaking of. Should we nuke the old radeonfb driver?

-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl

#4 lore raw
In reply to Andrew Morton
Quoted 10 lines · Andrew Morton
Quoted 4 lines · Matt Mackall
Quoted 2 lines

Which radeon driver? CONFIG_FB_RADEON_OLD or CONFIG_FB_RADEON?

FB_RADEON.

Ah, OK. Likely culprits are

radeonfb-massive-update-of-pm-code.patch
radeonfb-build-fix.patch

Ok, learned a few things.

Here are the symptoms:

mm2: corruption of Tux logo at boot, corruption of display at powerdown, lockup and LCD blooming on next warm boot when radeonfb starts. Ben suggested I try some radeonfb options, but none seemed to have any effect.

mm1: no observed problems

mm2 - above patches: corruption still occurs but no lockup on next warm boot.

I think I have a lead on the logo and shutdown corruption:

If I do a reboot(8) from inside X, I get switched to vt 0, but the shutdown messages come out on vt 7, where X was running. As I'm sitting on vt 0 during shutdown, I see character cells changed to something like "_" (last two scanlines filled) slowly marching down the screen corresponding to the shutdown messages.

So the logo corruption is probably getty popping up on the other vts at the end of init. The timing and the screen placement seem to agree.

Photos for the curious (be sure to see "executioner Tux" glitch):
http://selenic.com/radeon

Signature · 1 line
Mathematics is the supreme nostalgia of our time.
#5 lore raw
Quoted 8 lines · Matt Mackall

Here are the symptoms:

mm2: corruption of Tux logo at boot, corruption of display at powerdown, lockup and LCD blooming on next warm boot when radeonfb starts. Ben suggested I try some radeonfb options, but none seemed to have any effect.

Quoted 4 lines

mm1: no observed problems

mm2 - above patches: corruption still occurs but no lockup on next warm boot.

So we have multiple bugs?

Next suspects would be:

+cleanup-vc-array-access.patch
+remove-console_macrosh.patch
+merge-vt_struct-into-vc_data.patch

#6 lore raw
Quoted 8 lines · Andrew Morton

Next suspects would be:

+cleanup-vc-array-access.patch
+remove-console_macrosh.patch
+merge-vt_struct-into-vc_data.patch

Make that:

+cleanup-vc-array-access.patch +remove-console_macrosh.patch +merge-vt_struct-into-vc_data.patch +vgacon-fixes-to-help-font-restauration-in-x11.patch

and the fbdev updates, maybe:

+radeonfb-set-accelerator-id.patch +vesafb-change-return-error-id.patch +intelfb-workaround-for-830m.patch +fbcon-save-blank-state-last.patch +backlight-fix-compile-error-if-config_fb-is-unset.patch +matroxfb-fb_matrox_g-kconfig-changes.patch

-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl

#7 lore raw
Quoted 12 lines · Andrew Morton
Quoted 8 lines · Andrew Morton

Next suspects would be:

+cleanup-vc-array-access.patch
+remove-console_macrosh.patch
+merge-vt_struct-into-vc_data.patch

Make that:

Review

Quoted 4 lines
(quoted diff) +4 -0
+cleanup-vc-array-access.patch
+remove-console_macrosh.patch
+merge-vt_struct-into-vc_data.patch
+vgacon-fixes-to-help-font-restauration-in-x11.patch

It's something in this batch. Which is good, as I'd be a bit disappointed if the "vt leakage" were somehow attributable to the fb layer. More bisection after dinner.

Signature · 1 line
Mathematics is the supreme nostalgia of our time.
#8 lore raw

Hi,

Quoted 13 lines · Matt Mackall
Quoted 12 lines · Andrew Morton
Quoted 8 lines · Andrew Morton

Next suspects would be:

+cleanup-vc-array-access.patch
+remove-console_macrosh.patch
+merge-vt_struct-into-vc_data.patch

Make that:

Quoted 8 lines

Review

Quoted 4 lines
(quoted diff) +4 -0
+cleanup-vc-array-access.patch
+remove-console_macrosh.patch
+merge-vt_struct-into-vc_data.patch
+vgacon-fixes-to-help-font-restauration-in-x11.patch

It's something in this batch. Which is good, as I'd be a bit disappointed if the "vt leakage" were somehow attributable to the fb layer. More bisection after dinner.

Could you try the patch below. I cleaned up the logic a little in redraw_screen() and the code below really wants to do a update_screen(). The old switch_screen(fg_console) behaved like update_screen(fg_console).

bye, Roman

drivers/video/console/fbcon.c +1 -1
Index: linux-2.6/drivers/video/console/fbcon.c
===================================================================
@@ -609,7 +609,7 @@
 				   fg_vc->vc_rows);
 	}
 
-	switch_screen(vc_cons[fg_console].d);
+	update_screen(vc_cons[fg_console].d);
 }
 
 /**
#12 lore raw
In reply to Matt Mackall
Quoted 8 lines · Matt Mackall
Quoted 1 line · Andrew Morton

Matt Mackall <[email protected]> wrote:

If I do a reboot(8) from inside X, I get switched to vt 0, but the shutdown messages come out on vt 7, where X was running. As I'm sitting on vt 0 during shutdown, I see character cells changed to something like "_" (last two scanlines filled) slowly marching down the screen corresponding to the shutdown messages.

Confirmed that this also occurs with vesafb.

This corruption (underscores) is due to the cursor of a not visibile console being drawn on the foreground display. The console layer should decide when and where to draw the console but, for now, a simple workaround is to disallow drawing of the fbcon cursor if the console is not visible.

---

 fbcon.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)
drivers/video/console/fbcon.c +1 -1
diff -Nru a/drivers/video/console/fbcon.c b/drivers/video/console/fbcon.c
@@ -1087,7 +1087,7 @@
 	int y = real_y(p, vc->vc_y);
  	int c = scr_readw((u16 *) vc->vc_pos);
 
-	if (fbcon_is_inactive(vc, info))
+	if (fbcon_is_inactive(vc, info) || !CON_IS_VISIBLE(vc))
 		return;
 
 	ops->cursor_flash = 1;

-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl

#9 lore raw
In reply to Roman Zippel
Quoted 22 lines · Roman Zippel

Hi,

Quoted 10 lines · Matt Mackall
Quoted 9 lines · Andrew Morton
Quoted 5 lines · Andrew Morton

Next suspects would be:

+cleanup-vc-array-access.patch
+remove-console_macrosh.patch
+merge-vt_struct-into-vc_data.patch

Make that:

Quoted 8 lines

Review

Quoted 4 lines
(quoted diff) +4 -0
+cleanup-vc-array-access.patch
+remove-console_macrosh.patch
+merge-vt_struct-into-vc_data.patch
+vgacon-fixes-to-help-font-restauration-in-x11.patch

It's something in this batch. Which is good, as I'd be a bit disappointed if the "vt leakage" were somehow attributable to the fb layer. More bisection after dinner.

Quoted 4 lines

Could you try the patch below. I cleaned up the logic a little in redraw_screen() and the code below really wants to do a update_screen(). The old switch_screen(fg_console) behaved like update_screen(fg_console).

Probably does not matter as this particular code is never invoked during framebuffer initialization (unless one uses fbcon=map:n option).

Tony

-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl

#10 lore raw
In reply to Roman Zippel
Quoted 26 lines · Roman Zippel

Hi,

Quoted 13 lines · Matt Mackall
Quoted 12 lines · Andrew Morton
Quoted 8 lines · Andrew Morton

Next suspects would be:

+cleanup-vc-array-access.patch
+remove-console_macrosh.patch
+merge-vt_struct-into-vc_data.patch

Make that:

Quoted 8 lines

Review

Quoted 4 lines
(quoted diff) +4 -0
+cleanup-vc-array-access.patch
+remove-console_macrosh.patch
+merge-vt_struct-into-vc_data.patch
+vgacon-fixes-to-help-font-restauration-in-x11.patch

It's something in this batch. Which is good, as I'd be a bit disappointed if the "vt leakage" were somehow attributable to the fb layer. More bisection after dinner.

Quoted 3 lines

Could you try the patch below. I cleaned up the logic a little in redraw_screen() and the code below really wants to do a update_screen(). The old switch_screen(fg_console) behaved like update_screen(fg_console).

Same behaviour.

Signature · 1 line
Mathematics is the supreme nostalgia of our time.
#11 lore raw
In reply to Matt Mackall
Quoted 4 lines · Matt Mackall

It's something in this batch. Which is good, as I'd be a bit disappointed if the "vt leakage" were somehow attributable to the fb layer. More bisection after dinner.

Regarding the radeonfb reboot problem, can you try this patch on top of -mm2 ?

drivers/video/aty/radeon_base.c +6 -3
@@ -2435,13 +2435,16 @@
  
 	radeonfb_pm_exit(rinfo);
 
+#if 0
 	/* restore original state
 	 * 
-	 * Doesn't quite work yet, possibly because of the PPC hacking
-	 * I do on startup, disable for now. --BenH
+	 * Doesn't quite work yet, I suspect if we come from a legacy
+	 * VGA mode (or worse, text mode), we need to do some VGA black
+	 * magic here that I know nothing about. --BenH
 	 */
         radeon_write_mode (rinfo, &rinfo->init_state, 1);
- 
+ #endif
+
 	del_timer_sync(&rinfo->lvds_timer);
 
 #ifdef CONFIG_MTRR

-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl