some console colors cannot be modified

Bug #395374 reported by Norm Pierce
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
usplash (Ubuntu)
Invalid
Low
Unassigned

Bug Description

Binary package hint: usplash

Ubuntu 8.10
Linux 2.6.27-14-generic #1 SMP Wed Apr 15 18:59:16 UTC 2009
linux-image-2.6.27-14-generic, Version: 2.6.27-14.33
usplash, Version 0.5.25

Bug also appears with 8.10 live CD (with 2.6.27-7 kernel).

After booting with usplash ("splash") and no frame buffer ("nofb"), some console text colors cannot be modified, nor do they blank when the screen blanks. If you've noticed that when the console blanks after the blank timeout (the default is usually ten minutes) some text remains visible, you have this bug.

To reproduce:

 1. Download the three attached text files.
 2. If necessary, reboot using the nofb and splash options.
 3. Wait for system to fully boot up, then switch to a text console and log-in.
 4. Load a 256-character font so that all sixteen colors can be used:
    setfont Lat15-Fixed16
 5. cat display_text_colors.txt
 6. The text colors should now be seen (15 digits on a black background).
 7. cat set_red_text_colors.txt
 8. All text should now be pure red. If some aren't, you have this bug.
 9. cat restore_text_colors.txt
10. Text should now be back to its default colors.

While all colors remain on the screen, you may also set the blank timeout:

     setterm -blank 1

Then wait a minute to see if all colors go blank. (If APM is available, this may or may not be a useful test. If your backlight also goes out you won't see anything anyway.)

This bug is caused by the fact that usplash does not restore the VGA Palette Registers. In fact, usplash doesn't restore any VGA registers, which also caused bug 392795. See LP:392795 for details. Years ago it did restore the registers, but that code was removed.

As I did for the other bug, I am including a couple of patches for consideration. Either one should fix the problem. One patch, "restore_all_regs.patch", simply restores the code that restores all of the VGA registers. The other patch, "restore_attr_ctrl_reg.patch", restores only the Attribute Controller Registers -- the registers that relate to this bug and to bug 392795. I think the first patch is probably the better patch, and could make usplash a little more robust by possibly preventing other bugs from cropping up in the future due to registers that were not restored. (We've already found a couple; there could be more.) On the other hand, there is something to be said for making the smallest change necessary to fix a bug, and thus reduce the chances of creating others, which is why I've included the second patch.

Note that either of these patches should also fix bug 392795. So if either of these is used, there is no need to install another patch to fix that bug.

Does anyone see any potential for usplash and the kernel trying to access the VGA registers at the same time? Do we need to add any handshaking to prevent conflicts? I've not seen any problems of that sort, but it would be good if someone who knows this code better than I looked it over for that sort of thing.

When testing the patch, don't forget to update the appropriate initrd.img... file (as I have forgotten more times than I'd like to admit!).

Revision history for this message
Norm Pierce (npierce-at2a) wrote :
Revision history for this message
Norm Pierce (npierce-at2a) wrote :
Revision history for this message
Norm Pierce (npierce-at2a) wrote :
Revision history for this message
Norm Pierce (npierce-at2a) wrote :
Revision history for this message
Norm Pierce (npierce-at2a) wrote :
Revision history for this message
Steve Beattie (sbeattie) wrote :

Are you sure this is solely a usplash issue? I can reproduce it even when booting with nofb and without the splash option by simply doing:

  (1) boot into a kernel with "nofb" (splash, quiet disabled)
  (2) switch to the console (alt-f1) and login
  (3) setfont /usr/share/consolefonts/Arabic-Fixed15.psf.gz
  (4) showconsolefont
  (5) setterm -blank 1

and then wait 1 minute, as not all of the screen blanks. I have reproduced this behavior on hardy, intrepid, and karmic's 2.6.30 and 2.6.31 kernels.

Changed in usplash (Ubuntu):
importance: Undecided → Low
status: New → Confirmed
Revision history for this message
Norm Pierce (npierce-at2a) wrote :

Steve, I'm using an Intel Mobile 945 graphics controller. I'm wondering if you are using an ATI controller.

On my system I do not see this problem if I don't boot with usplash; I do see it when I do boot with usplash (version 0.5.25); I do not see it if I apply either of the above patches and boot with usplash.

I have seen console color problems with an ATI Radeon X1600/X1650 series controller that were unrelated to usplash (although not this particular problem). And I have seen other console-related bugs reported in Launchpad which apply to systems with ATI controllers, but not all controllers.

If you are using an ATI controller, you may have found another bug related, perhaps, to the ATI controller not getting initialized properly.

Revision history for this message
Steve Beattie (sbeattie) wrote :

Norm, I reproduced it within a virtualbox environment. I'll try to reproduce it with live hardware later (I don't have any ATI controllers, mostly intel and an ancient nvidia).

Revision history for this message
Norm Pierce (npierce-at2a) wrote :

I believe that the above patches will also fix the symptoms described in LP:139453.

Revision history for this message
Phillip Susi (psusi) wrote :

The usplash package has been superseded by plymouth and has been removed from the Ubuntu archive. Closing all related bugs.

Changed in usplash (Ubuntu):
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.