[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] tools/xenpaging: fix return value from xc_mem_paging_flush_ioemu_cache
# HG changeset patch # User Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx> # Date 1294764489 0 # Node ID ae3567ccf5240f31f77fed80ba6e174085f49bff # Parent 6852e3e7ef58bd1db90af1edeb42c6cf24318fc8 tools/xenpaging: fix return value from xc_mem_paging_flush_ioemu_cache While using xenpaging, "Error flushing ioemu cache" message will be shown even if the "flush-cache" command is sent to xenstore correctly. That is because xenpaging assumes xc_mem_paging_flush_ioemu_cache() returns non-zero value when the operation fails. But xc_mem_paging_flush_ioemu_cache() returns the return value from xs_write() which is zero on error. So, we should invert the return value from xs_write() and return -1 on error, or 0 on success, like other xc_ functions. Signed-off-by: Han-Lin Li <Han-Lin.Li@xxxxxxxxxxx> Author: Olaf Hering <olaf@xxxxxxxxx> Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx> Committed-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx> --- tools/xenpaging/xc.c | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-) diff -r 6852e3e7ef58 -r ae3567ccf524 tools/xenpaging/xc.c --- a/tools/xenpaging/xc.c Tue Jan 11 16:42:41 2011 +0000 +++ b/tools/xenpaging/xc.c Tue Jan 11 16:48:09 2011 +0000 @@ -62,7 +62,7 @@ int xc_mem_paging_flush_ioemu_cache(domi xs_daemon_close(xsh); - return rc; + return rc ? 0 : -1; } int xc_wait_for_event_or_timeout(xc_interface *xch, xc_evtchn *xce, unsigned long ms) _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |