From 0f69f64f5c1de50ebea75b91800c20c585c1b4b9 Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Thu, 25 Oct 2007 15:01:59 +0100 Subject: [PATCH] hvm: In xenstore_process_logdirty_event(), if a stale shared memory key is encountered reset 'seg' to NULL so the shared memory initialization can be retried later. Signed-off-by: Ben Guthro Signed-off-by: Robert Phillips Signed-off-by: Keir Fraser --- tools/ioemu/xenstore.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/ioemu/xenstore.c b/tools/ioemu/xenstore.c index 2b2897cec7..ed85eea5f0 100644 --- a/tools/ioemu/xenstore.c +++ b/tools/ioemu/xenstore.c @@ -318,6 +318,9 @@ void xenstore_process_logdirty_event(void) if (logdirty_bitmap_size != *(uint32_t *)seg) { fprintf(logfile, "Log-dirty: got %u, calc %lu\n", *(uint32_t *)seg, logdirty_bitmap_size); + /* Stale key: wait for next watch */ + shmdt(seg); + seg = NULL; return; } -- 2.30.2