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

[Xen-changelog] [xen master] xen/arm: vpl011: Add a new console_open_log function in xenconsole



commit b6cd2afdecf802030606b163c51d265d7febf4de
Author:     Bhupinder Thakur <bhupinder.thakur@xxxxxxxxxx>
AuthorDate: Wed Sep 27 11:43:28 2017 +0530
Commit:     Stefano Stabellini <sstabellini@xxxxxxxxxx>
CommitDate: Tue Oct 3 15:23:37 2017 -0700

    xen/arm: vpl011: Add a new console_open_log function in xenconsole
    
    This patch introduces a console_open_log console_cleanup function. This 
function
    opens the console log file.
    
    Signed-off-by: Bhupinder Thakur <bhupinder.thakur@xxxxxxxxxx>
    Reviewed-by: Stefano Stabellini <sstabellini@xxxxxxxxxx>
    Acked-by: Wei Liu <wei.liu2@xxxxxxxxxx>
---
 tools/console/daemon/io.c | 13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)

diff --git a/tools/console/daemon/io.c b/tools/console/daemon/io.c
index ff69e52..cfd7273 100644
--- a/tools/console/daemon/io.c
+++ b/tools/console/daemon/io.c
@@ -1038,6 +1038,15 @@ static void handle_hv_logs(xenevtchn_handle *xce_handle, 
bool force)
                (void)xenevtchn_unmask(xce_handle, port);
 }
 
+static void console_open_log(struct console *con)
+{
+       if (console_enabled(con)) {
+               if (con->log_fd != -1)
+                       close(con->log_fd);
+               con->log_fd = create_console_log(con);
+       }
+}
+
 static void handle_log_reload(void)
 {
        if (log_guest) {
@@ -1045,9 +1054,7 @@ static void handle_log_reload(void)
                for (d = dom_head; d; d = d->next) {
                        struct console *con = &d->console;
 
-                       if (con->log_fd != -1)
-                               close(con->log_fd);
-                       con->log_fd = create_console_log(con);
+                       console_open_log(con);
                }
        }
 
--
generated by git-patchbot for /home/xen/git/xen.git#master

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

 


Rackspace

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