It does. I wrote a similar patch earlier today which just forced
vgacon to always return 1, but this was a brute force hack. Your
patch is clearly more correct.
Linus has entered a different patch which works in char/vt.c and
puts explicit set_palette calls before each unblank_screen. I've
not yet tried his patch. Other people have said it does work.
I think yours makes more sense though because you say con_switch
doesn't return success/failure, but instead whether an update is
needed. So set_palette should never have been in the if-block.
I prefer your patch. Please resend to Linus so he can choose the
patch he prefers.
> --- linux/drivers/char/console.c Wed Jul 19 00:57:28 2000
> +++ linux/drivers/char/console.c Wed Aug 9 10:44:35 2000
> @@ -586,12 +586,14 @@
> }
>
> if (redraw) {
> + int updateregion;
> +
> set_origin(currcons);
> - if (sw->con_switch(vc_cons[currcons].d) && vcmode != KD_GRAPHICS) {
> - /* Update the screen contents */
> - set_palette(currcons);
> + updateregion = sw->con_switch(vc_cons[currcons].d);
> + set_palette(currcons);
> + /* Update the screen contents */
> + if (updateregion && (vcmode != KD_GRAPHICS))
> do_update_region(currcons, origin, screenbuf_size/2);
> - }
> }
> set_cursor(currcons);
> if (is_switch) {
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/