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-changelog

[Xen-changelog] Add a manual 'sync_console' boot parameter that forces s

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Add a manual 'sync_console' boot parameter that forces synchronous
From: BitKeeper Bot <riel@xxxxxxxxxxx>
Date: Sat, 04 Jun 2005 17:45:49 +0000
Delivery-date: Sat, 04 Jun 2005 18:01:51 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: Xen Development List <xen-devel@xxxxxxxxxxxxxxxxxxx>
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
ChangeSet 1.1671, 2005/06/04 18:45:49+01:00, kaf24@xxxxxxxxxxxxxxxxxxxx

        Add a manual 'sync_console' boot parameter that forces synchronous
        console output. May be useful for systems that crash unexpectedly
        and lose the last chunk of console output.
        Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>



 docs/src/user.tex          |    7 +++++++
 xen/drivers/char/console.c |   14 ++++++++++++--
 2 files changed, 19 insertions(+), 2 deletions(-)


diff -Nru a/docs/src/user.tex b/docs/src/user.tex
--- a/docs/src/user.tex 2005-06-04 14:02:45 -04:00
+++ b/docs/src/user.tex 2005-06-04 14:02:45 -04:00
@@ -1729,6 +1729,13 @@
  transmitted/received character.
  [NB. Default for this option is `com1,vga'] 
 
+\item [sync\_console ]
+ Force synchronous console output. This is useful if you system fails
+ unexpectedly before it has sent all available output to the
+ console. In most cases Xen will automatically enter synchronous mode
+ when an exceptional event occurs, but this option provides a manual
+ fallback.
+
 \item [conswitch=$<$switch-char$><$auto-switch-char$>$ ] 
  Specify how to switch serial-console input between
  Xen and DOM0. The required sequence is CTRL-$<$switch-char$>$
diff -Nru a/xen/drivers/char/console.c b/xen/drivers/char/console.c
--- a/xen/drivers/char/console.c        2005-06-04 14:02:45 -04:00
+++ b/xen/drivers/char/console.c        2005-06-04 14:02:45 -04:00
@@ -24,17 +24,21 @@
 #include <asm/debugger.h>
 #include <asm/io.h>
 
-/* opt_console: comma-separated list of console outputs. */
+/* console: comma-separated list of console outputs. */
 static char opt_console[30] = OPT_CONSOLE_STR;
 string_param("console", opt_console);
 
-/* opt_conswitch: a character pair controlling console switching. */
+/* conswitch: a character pair controlling console switching. */
 /* Char 1: CTRL+<char1> is used to switch console input between Xen and DOM0 */
 /* Char 2: If this character is 'x', then do not auto-switch to DOM0 when it */
 /*         boots. Any other value, or omitting the char, enables auto-switch */
 static unsigned char opt_conswitch[5] = "a";
 string_param("conswitch", opt_conswitch);
 
+/* sync_console: force synchronous console output (useful for debugging). */
+static int opt_sync_console;
+boolean_param("sync_console", opt_sync_console);
+
 static int xpos, ypos;
 static unsigned char *video;
 
@@ -437,6 +441,12 @@
            XEN_COMPILER, XEN_COMPILE_DATE);
     printk(" Latest ChangeSet: %s\n\n", XEN_CHANGESET);
     set_printk_prefix("(XEN) ");
+
+    if ( opt_sync_console )
+    {
+        serial_start_sync(sercon_handle);
+        printk("Console output is synchronous.\n");
+    }
 }
 
 void console_endboot(int disable_vga)

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Add a manual 'sync_console' boot parameter that forces synchronous, BitKeeper Bot <=