WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-ia64-devel

[Xen-ia64-devel] [PATCH] VGA Fixes (3/3)

To: xen-ia64-devel <xen-ia64-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-ia64-devel] [PATCH] VGA Fixes (3/3)
From: Alex Williamson <alex.williamson@xxxxxx>
Date: Tue, 24 Jul 2007 17:28:30 -0600
Delivery-date: Tue, 24 Jul 2007 16:26:18 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
Organization: HP OSLO R&D
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
   This patch re-orders setup_arch in xenlinux slightly.  This allows us
to check if conswitchp was setup early by the HCDP code to point to a
VGA console (the previous patch leaves efi.hcdp in place for dom0 if the
primary console is VGA).  Also fix a bug w/ zero'ing the preferred
console name string.

Signed-off-by: Alex Williamson <alex.williamson@xxxxxx>
---

diff -r b64323b3a963 arch/ia64/kernel/setup.c
--- a/arch/ia64/kernel/setup.c  Thu Jul 19 16:02:02 2007 -0600
+++ b/arch/ia64/kernel/setup.c  Tue Jul 24 15:02:25 2007 -0600
@@ -526,22 +526,6 @@ setup_arch (char **cmdline_p)
        acpi_boot_init();
 #endif
 
-#ifdef CONFIG_VT
-       if (!conswitchp) {
-# if defined(CONFIG_DUMMY_CONSOLE)
-               conswitchp = &dummy_con;
-# endif
-# if defined(CONFIG_VGA_CONSOLE)
-               /*
-                * Non-legacy systems may route legacy VGA MMIO range to system
-                * memory.  vga_con probes the MMIO hole, so memory looks like
-                * a VGA device to it.  The EFI memory map can tell us if it's
-                * memory so we can avoid this problem.
-                */
-               if (efi_mem_type(0xA0000) != EFI_CONVENTIONAL_MEMORY)
-                       conswitchp = &vga_con;
-# endif
-       }
 #ifdef CONFIG_XEN
        if (is_running_on_xen()) {
                shared_info_t *s = HYPERVISOR_shared_info;
@@ -553,9 +537,6 @@ setup_arch (char **cmdline_p)
                       xen_start_info->nr_pages, xen_start_info->flags);
 
                if (!is_initial_xendomain()) {
-#if !defined(CONFIG_VT) || !defined(CONFIG_DUMMY_CONSOLE)
-                       conswitchp = NULL;
-#endif
                }
                
                /*
@@ -567,7 +548,8 @@ setup_arch (char **cmdline_p)
                        char *p, *q, name[5];
                        int offset = 0;
 
-                       if (is_initial_xendomain())
+                       memset(name, 0, sizeof(name));
+                       if (is_initial_xendomain() && conswitchp != &vga_con)
                                strncpy(name, "ttyS", 4);
                        else
                                strncpy(name, "tty", 3);
@@ -599,13 +581,33 @@ setup_arch (char **cmdline_p)
        }
        xencons_early_setup();
 #endif
-#endif
-
+
+#ifdef CONFIG_VT
+       if (!conswitchp) {
+# if defined(CONFIG_DUMMY_CONSOLE)
+               conswitchp = &dummy_con;
+# endif
+# if defined(CONFIG_VGA_CONSOLE)
+               /*
+                * Non-legacy systems may route legacy VGA MMIO range to system
+                * memory.  vga_con probes the MMIO hole, so memory looks like
+                * a VGA device to it.  The EFI memory map can tell us if it's
+                * memory so we can avoid this problem.
+                */
+               if (efi_mem_type(0xA0000) != EFI_CONVENTIONAL_MEMORY)
+                       conswitchp = &vga_con;
+# endif
+       }
+#endif
 
        /* enable IA-64 Machine Check Abort Handling unless disabled */
 #ifdef CONFIG_XEN
-       if (is_running_on_xen() && !is_initial_xendomain())
+       if (is_running_on_xen() && !is_initial_xendomain()) {
                nomca = 1;
+#if !defined(CONFIG_VT) || !defined(CONFIG_DUMMY_CONSOLE)
+               conswitchp = NULL;
+#endif
+       }
 #endif
        if (!nomca)
                ia64_mca_init();



_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel

<Prev in Thread] Current Thread [Next in Thread>