mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 10:40:03 +01:00
libxl: return any serial tty path in libxl_console_get_tty
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@oracle.com> Acked-by: Wei Liu <wei.liu2@citrix.com> (cherry picked from commit35dbf099ac) (cherry picked from commit822464961a)
This commit is contained in:
1 parent
0e94436476
commit
e06d2bae53
1 file changed
+1
-1
+1
-1
@@ -1813,7 +1813,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);
|
||||
break;
|
||||
case LIBXL_CONSOLE_TYPE_PV:
|
||||
if (cons_num == 0)
|
||||
|
||||