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

Re: [Xen-devel] [PATCH] tools:libxl: return tty path for all serials



I would suggest changing the title to 

  libxl: return any serial tty path in libxl_console_get_tty

On Wed, Aug 03, 2016 at 09:27:19AM +0800, Bob Liu wrote:
> When specifying a serial list in domain config, users of
> libxl_console_get_tty cannot get the tty path of a second specified pty 
> serial,
> since right now it always returns the tty path of serial 0.
> 
> Signed-off-by: Bob Liu <bob.liu@xxxxxxxxxx>
> ---
>  tools/libxl/libxl.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tools/libxl/libxl.c b/tools/libxl/libxl.c
> index 2cf7451..00af286 100644
> --- a/tools/libxl/libxl.c
> +++ b/tools/libxl/libxl.c
> @@ -1795,7 +1795,7 @@ int libxl_console_get_tty(libxl_ctx *ctx, uint32_t 
> domid, int cons_num,
>  
>      switch (type) {
>      case LIBXL_CONSOLE_TYPE_SERIAL:
> -        tty_path = GCSPRINTF("%s/serial/0/tty", dom_path);
> +        tty_path = GCSPRINTF("%s/serial/%d/tty", dom_path, cons_num);

Code-wise, this patch looks good to me. It's a valid bug fix that should
be backported.

Please CC Ian and me in your future submissions.

Wei.
>          break;
>      case LIBXL_CONSOLE_TYPE_PV:
>          if (cons_num == 0)
> -- 
> 1.7.10.4
> 
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@xxxxxxxxxxxxx
> https://lists.xen.org/xen-devel

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

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