Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=a1a4849c419337f649c6633219b555eb4d4d955a
Commit:     a1a4849c419337f649c6633219b555eb4d4d955a
Parent:     79974a0e4c6be6e9a3717b4c5a5d5c44c36b1653
Author:     Gerd Hoffmann <[EMAIL PROTECTED]>
AuthorDate: Wed May 16 22:11:09 2007 -0700
Committer:  Linus Torvalds <[EMAIL PROTECTED]>
CommitDate: Thu May 17 05:23:04 2007 -0700

    Refine SCREEN_INFO sanity check for vgacon initialization
    
    Refine SCREEN_INFO sanity check for vgacon initialization.
    
    Checking video mode field only to see whenever SCREEN_INFO is
    initialized is not enougth, in some cases it is zero although
    a vga card is present.  Lets additionally check cols and lines.
    
    Signed-off-by: Gerd Hoffmann <[EMAIL PROTECTED]>
    Cc: Rusty Russell <[EMAIL PROTECTED]>
    Cc: Andi Kleen <[EMAIL PROTECTED]>
    Cc: Alan <[EMAIL PROTECTED]>
    Cc: Ingo Molnar <[EMAIL PROTECTED]>
    Acked-by: Eric W. Biederman <[EMAIL PROTECTED]>
    Cc: "H. Peter Anvin" <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
---
 drivers/video/console/vgacon.c |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/drivers/video/console/vgacon.c b/drivers/video/console/vgacon.c
index 2460b82..f46fe95 100644
--- a/drivers/video/console/vgacon.c
+++ b/drivers/video/console/vgacon.c
@@ -368,9 +368,14 @@ static const char *vgacon_startup(void)
 #endif
        }
 
+       /* SCREEN_INFO initialized? */
+       if ((ORIG_VIDEO_MODE  == 0) &&
+           (ORIG_VIDEO_LINES == 0) &&
+           (ORIG_VIDEO_COLS  == 0))
+               goto no_vga;
+
        /* VGA16 modes are not handled by VGACON */
-       if ((ORIG_VIDEO_MODE == 0x00) ||        /* SCREEN_INFO not initialized 
*/
-           (ORIG_VIDEO_MODE == 0x0D) ||        /* 320x200/4 */
+       if ((ORIG_VIDEO_MODE == 0x0D) ||        /* 320x200/4 */
            (ORIG_VIDEO_MODE == 0x0E) ||        /* 640x200/4 */
            (ORIG_VIDEO_MODE == 0x10) ||        /* 640x350/4 */
            (ORIG_VIDEO_MODE == 0x12) ||        /* 640x480/4 */
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to