diff mbox

Please apply

Message ID 4ABD10D0.9030308@canonical.com
State Accepted
Headers show

Commit Message

Chuck Short Sept. 25, 2009, 6:49 p.m. UTC
Hi,

I wish to have the following patch applied to the ec2 topic branch. 
Basically it changes the default console from xvc0 to tty1.

If you have any questions please let me know.

Regards
chuck

Comments

Tim Gardner Sept. 25, 2009, 9:52 p.m. UTC | #1
Chuck Short wrote:
> Hi,
> 
> I wish to have the following patch applied to the ec2 topic branch. 
> Basically it changes the default console from xvc0 to tty1.
> 
> If you have any questions please let me know.
> 
> Regards
> chuck
> 

I've applied after fixing the compile issues, but before I push to the 
core repo and upload I'd like you to test what I've built in:

http://kernel.ubuntu.com/~rtg/2.6.31-300.3

rtg
Chuck Short Sept. 25, 2009, 11:23 p.m. UTC | #2
Tim Gardner wrote:
> Chuck Short wrote:
>> Hi,
>>
>> I wish to have the following patch applied to the ec2 topic branch. 
>> Basically it changes the default console from xvc0 to tty1.
>>
>> If you have any questions please let me know.
>>
>> Regards
>> chuck
>>
>
> I've applied after fixing the compile issues, but before I push to the 
> core repo and upload I'd like you to test what I've built in:
>
> http://kernel.ubuntu.com/~rtg/2.6.31-300.3
>
> rtg
Hi Tim,

The patch works as expected:

http://people.canonical.com/~chucks/dmesg.txt

Regards
chuck
Tim Gardner Sept. 26, 2009, 3:57 a.m. UTC | #3
Chuck Short wrote:
> Tim Gardner wrote:
>> Chuck Short wrote:
>>> Hi,
>>>
>>> I wish to have the following patch applied to the ec2 topic branch. 
>>> Basically it changes the default console from xvc0 to tty1.
>>>
>>> If you have any questions please let me know.
>>>
>>> Regards
>>> chuck
>>>
>>
>> I've applied after fixing the compile issues, but before I push to the 
>> core repo and upload I'd like you to test what I've built in:
>>
>> http://kernel.ubuntu.com/~rtg/2.6.31-300.3
>>
>> rtg
> Hi Tim,
> 
> The patch works as expected:
> 
> http://people.canonical.com/~chucks/dmesg.txt
> 
> Regards
> chuck

applied, uploaded linux-ec2_2.6.31-300.3
diff mbox

Patch

From dadc31f8852896533c4ec61f4d49922bf20d3e39 Mon Sep 17 00:00:00 2001
From: Chuck Short <zulcss@ubuntu.com>
Date: Fri, 25 Sep 2009 14:24:56 -0400
Subject: [PATCH] UBUNTU: SAUCE: ec2: Default domU console to tty.

I believe that there is a change between the xencons daemon for 3.0.2
and pretty much any version above 3.0.2 that prevents the console from
being displayed. Which prevents the user from looking at the console
without wondering what is happening to their domU.

This patch changes the default behaviour for domU from xvc0 to tty1.

OriginalAuthor: Chuck Short <zulcss@ubuntu.com>
BugLink: http://bugs.launchpad.net/bugs/431103

Signed-off-by: Chuck Short <zulcss@ubuntu.com>
---
 arch/x86/kernel/setup-xen.c   |    1 +
 drivers/xen/console/console.c |   12 +++++++++++-
 include/xen/xencons.h         |    2 ++
 3 files changed, 14 insertions(+), 1 deletions(-)

diff --git a/arch/x86/kernel/setup-xen.c b/arch/x86/kernel/setup-xen.c
index 11004cb..6e48fc5 100644
--- a/arch/x86/kernel/setup-xen.c
+++ b/arch/x86/kernel/setup-xen.c
@@ -1337,6 +1337,7 @@  void __init setup_arch(char **cmdline_p)
 		conswitchp = &vga_con;
 #endif
 #endif
+    xencons_early_setup();
 #endif /* CONFIG_XEN */
 }
 
diff --git a/drivers/xen/console/console.c b/drivers/xen/console/console.c
index 19cdeee..79a249b 100644
--- a/drivers/xen/console/console.c
+++ b/drivers/xen/console/console.c
@@ -73,7 +73,7 @@ 
  */
 static enum {
 	XC_OFF, XC_TTY, XC_SERIAL, XC_XVC, XC_HVC
-} xc_mode = XC_XVC;
+} xc_mode;
 static int xc_num = -1;
 
 /* /dev/xvc0 device number allocated by lanana.org. */
@@ -84,6 +84,16 @@  static int xc_num = -1;
 #define XEN_HVC_MAJOR 229
 #define XEN_HVC_MINOR 0
 
+static xencons_early_setup(void)
+{
+    if (is_initial_xendomain()) {
+        xc_mode = XC_SERIAL;
+    } else {
+        xc_mode = XC_TTY;
+        console_use_vt = 0;
+    }
+}
+
 static int __init xencons_setup(char *str)
 {
 	char *q;
diff --git a/include/xen/xencons.h b/include/xen/xencons.h
index c5a55d6..6b09cd1 100644
--- a/include/xen/xencons.h
+++ b/include/xen/xencons.h
@@ -14,4 +14,6 @@  void xencons_tx(void);
 int xencons_ring_init(void);
 int xencons_ring_send(const char *data, unsigned len);
 
+void xencons_early_setup(void);
+
 #endif /* __ASM_XENCONS_H__ */
-- 
1.6.3.3