aboutsummaryrefslogtreecommitdiffstats
path: root/tools/libxc/xtl_logger_stdio.c
Commit message (Collapse)AuthorAgeFilesLines
* tools/xentoollog: update tty detection in stdiostream_progressOlaf Hering2013-02-281-1/+3
| | | | | | | | | As suggested by IanJ: Check isatty only once to preserve the errno of ->progress users, and to reduce the noice in strace output. Signed-off-by: Olaf Hering <olaf@aepfle.de> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
* tools/xc: handle tty output differently in stdiostream_progressOlaf Hering2013-02-151-2/+20
| | | | | | | | | | | | | | If the output goes to a tty, rewind the cursor and print everything in a single line as it was done up to now. If the output goes to a file or pipe print a newline after each progress output. This will fix logging of progress messages from xc_save to xend.log. To support XTL_STDIOSTREAM_SHOW_PID or XTL_STDIOSTREAM_SHOW_DATE print the output via vmessage if the output is not a tty. Signed-off-by: Olaf Hering <olaf@aepfle.de> Acked-by: Ian Campbell <ian.campbell@citrix.com> Committed-by: Ian Campbell <ian.campbell@citrix.com>
* tools/xc: fix logic error in stdiostream_progressOlaf Hering2013-02-151-1/+1
| | | | | | | | Setting XTL_STDIOSTREAM_HIDE_PROGRESS should disable progress reporting. Signed-off-by: Olaf Hering <olaf@aepfle.de> Acked-by: Ian Campbell <ian.campbell@citrix.com> Committed-by: Ian Campbell <ian.campbell@citrix.com>
* libxc: logger: add newline when progress is completeIan Campbell2010-09-031-2/+5
| | | | | | | | | | | | | | | | | | | | | In xc_domain_save ensure that we signal completion at the end of each batch. This ensures that the next logged line starts on a new line. e.g. instead of: Savefile contains xl domain config xc: Saving memory: iter 3 (last sent 0 skipped 0): 0/32768 0%migration target: Transfer complete, requesting permission to start domain. migration sender: Target has acknowledged transfer. what is desired is: Savefile contains xl domain config xc: Saving memory: iter 0 (last sent 0 skipped 0): 32768/32768 100% xc: Saving memory: iter 1 (last sent 32576 skipped 192): 32768/32768 100% xc: Saving memory: iter 2 (last sent 217 skipped 0): 32768/32768 100% xc: Saving memory: iter 3 (last sent 0 skipped 0): 32768/32768 100% migration target: Transfer complete, requesting permission to start domain. migration sender: Target has acknowledged transfer. Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
* # HG changeset patchIan Campbell2010-08-241-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | # User Ian Campbell <ian.campbell@citrix.com> # Date 1282671421 -3600 # Node ID d1dd29a470ef1b9d2c77478a123326036dfe90bb # Parent d7a4adad9c328decbd384d87b23001aea8951b86 tools/libxc, tools/libelf: Relicense under LGPL v2.1 Relicense these two libraries under LGPL v2.1 only except where individual files already included the "or later" provision. Copyright holders have been contacted by Stephen Spector and have all agreed this change. Removed tools/libxc/ia64/aclinux.h since it appeared to be unused. There is a separate, more up to date, copy in xen/include/acpi/platform/aclinux.h which does appear to be used. Clarify the license of MiniOS privcmd.h under the same terms as other tools/include/xen-sys headers. Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Acked-by: Stephen Spector <stephen.spector@citrix.com> Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
* tools: Build fixes.Keir Fraser2010-05-281-1/+1
| | | | Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
* xl/libxtl: Remove glitch in xl migrate log outputKeir Fraser2010-05-281-0/+15
| | | | | | | | | * Provide a new XTL_STDIOSTREAM_HIDE_PROGRESS flag in the stdio logger * Provide a way to adjust the flags after logger setup * Use these to disable progress output from the migration receiver, as the sender is also sending progress information. Signed-off-by: Ian Jackson <Ian.Jackson@eu.citrix.com>
* xl: Allow control of logging level.Keir Fraser2010-05-281-1/+4
| | | | | | | The -v option, which must come before the xl command, increases the logging level each time it is supplied. Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
* xtl: New xentoollog mini-library.Keir Fraser2010-05-281-0/+122
We provide a new header file "xentoollog.h" which defines an interface that libraries and applications can use for logging. This avoids having to wrap each library's log callbacks up, massage arguments to log callbacks, and so on. The library's .o files are within libxc to avoid having to create a separate lib*.a, but callers do not need to #include xenctrl.h and it should be regarded as a separate API. Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>