On Thursday, 01.10.2015 at 15:15, Antti Kantee wrote:
> On 01/10/15 14:51, Martin Lucina wrote:
> >On Wednesday, 30.09.2015 at 21:00, Andrew Stuart wrote:
> >>>>Any ideas?
> >>
> >>I’m out of my depth technically here but on Linux you can send console 
> >>output to both VGA and serial.  I don’t know if that is practical or 
> >>relevant here.
> >>https://www.kernel.org/doc/Documentation/serial-console.txt
> >
> >We definitely don't want to do that by default because a) It's slow b) The
> >platform might have something else on COM1.
> 
> Isn't your assumption that if there's no VGA, there can never be anything
> else on COM1 except a 115200/8N1 serial console?

Correct. Except that Xen HVM provides a VGA even when you don't want to
use it, and no one seems to do so in practice. 

I want to detect the Xen case and just do the right thing -- the internet
is full enough as it is of people asking "How do I get serial console
output on Xen HVM to work".

> 
> >Anyway, I've figured out the obvious answer, which is to detect Xen (or in
> >fact other hypervisors) using CPUID and prefer the serial console if on
> >Xen. Just trying to get it into a committable state...
> 
> Console config (port,params) is needed in any case, so why not start from
> that, and then see how to make things as convenient as possible (but no more
> convenient than that!).  "first make it right, then make it $improved".

Console config would require -

  a) defining the relevant parameter and its possible syntax
  b) parsing it, which is currently done at a higher layer up the stack,
  and we need to know which console to use much earlier, at which point we
  can't use even e.g. libc str* interfaces

That is quite a bit more work and a more invasive change than the current
approach. Also, I've not yet had a user ask for console configuration, so
I'm not convinced it's needed.


Reply via email to