|
|
|
|
|
|
|
|
|
|
xen-devel
[Xen-devel] [PATCH 11 of 15] xenpaging: improve mainloop exit handling
# HG changeset patch
# User Olaf Hering <olaf@xxxxxxxxx>
# Date 1319189039 -7200
# Node ID 1f9a27425952493878a54c82e0518b47560161af
# Parent 0b7d7a2bd6673f358faf0183b79b29e6a2f036a5
xenpaging: improve mainloop exit handling
Remove the if/else logic to exit from the in case a signal arrives.
Update comments.
Signed-off-by: Olaf Hering <olaf@xxxxxxxxx>
diff -r 0b7d7a2bd667 -r 1f9a27425952 tools/xenpaging/xenpaging.c
--- a/tools/xenpaging/xenpaging.c
+++ b/tools/xenpaging/xenpaging.c
@@ -806,7 +806,7 @@ int main(int argc, char *argv[])
}
}
- /* Write all pages back into the guest */
+ /* If interrupted, write all pages back into the guest */
if ( interrupted == SIGTERM || interrupted == SIGINT )
{
/* If no more pages to process, exit loop. */
@@ -815,13 +815,15 @@ int main(int argc, char *argv[])
/* One more round if there are still pages to process. */
resume_pages(paging, paging->num_paged_out);
+
+ /* Resume main loop */
+ continue;
}
- else
- {
- /* Exit on any other signal */
- if ( interrupted )
- break;
- }
+
+ /* Exit main loop on any other signal */
+ if ( interrupted )
+ break;
+
}
DPRINTF("xenpaging got signal %d\n", interrupted);
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-devel] [PATCH 08 of 15] xenpaging: track the number of paged-out pages, (continued)
- [Xen-devel] [PATCH 08 of 15] xenpaging: track the number of paged-out pages, Olaf Hering
- [Xen-devel] [PATCH 02 of 15] xenpaging: remove obsolete comment in resume path, Olaf Hering
- [Xen-devel] [PATCH 01 of 15] xenpaging: remove filename from comment, Olaf Hering
- [Xen-devel] [PATCH 07 of 15] xenpaging: remove xc_dominfo_t from paging_t, Olaf Hering
- [Xen-devel] [PATCH 15 of 15] xenpaging: add XEN_PAGING_DIR / libxl_xenpaging_dir_path(), Olaf Hering
- [Xen-devel] [PATCH 09 of 15] xenpaging: move page add/resume loops into its own function, Olaf Hering
- [Xen-devel] [PATCH 06 of 15] xenpaging: update xenpaging_init, Olaf Hering
- [Xen-devel] [PATCH 03 of 15] xenpaging: use PERROR to print errno, Olaf Hering
- [Xen-devel] [PATCH 05 of 15] xenpaging: print gfn in failure case, Olaf Hering
- [Xen-devel] [PATCH 12 of 15] libxc: add bitmap_clear function, Olaf Hering
- [Xen-devel] [PATCH 11 of 15] xenpaging: improve mainloop exit handling,
Olaf Hering <=
|
|
|
|
|