[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 2 of 4] xenconsole: add support for a console type parameter



On Fri, 13 Aug 2010, Ian Jackson wrote:
> Stefano Stabellini writes ("[Xen-devel] [PATCH 2 of 4] xenconsole: add 
> support for a console type parameter"):
> > xenconsole: implement support for an explicit console type parameter
> > 
> > This patch adds support to xenconsole for an explicity console "type"
> > parameter. The parameter can be "pv", to specify that the user wants to
> > connect to a pv console, or "serial", to specify that the user wants to
> > connect to an emulated serial.
> > If the type parameter hasn't been specified be the user, xenconsole
> > tries to guess which type of console it has to connect to, defaulting to
> > pv console for pv guests and emulated serial for hvm guests.
> > 
> > This patch also changes the xenstore paths corresponding to pv consoles
> > to the console prefix, leaving the serial prefix to emulated serials.
> > 
> > Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
> > 
> > diff -r 6b28b2dac7dd tools/console/client/main.c
> > --- a/tools/console/client/main.c   Thu Aug 05 11:36:24 2010 +0100
> > +++ b/tools/console/client/main.c   Mon Aug 09 14:26:22 2010 +0100
> ...
> > -   path = malloc(strlen(dom_path) + strlen("/serial/0/tty") + 5);
> >   [ 27 lines to determine whether guest is HVM or PV ]
> 
> Is this really the best way to do this ?  Is there no other function
> somewhere which will do this more sensibly ?
> 
> Perhaps xenconsole needs to become a libxl caller rather than a helper
> program run by xl console.
> 
> Aside from that, I'm happy with this patch.
 
Please note that the 'guessing' code is not really required, I only
added it to retain compatibility with xend that I didn't want to modify.


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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.