From: Andrew Cooper Subject: [PATCH 1/5] tools/xc_restore: Initialise console and store mfns Date: Mon, 25 Nov 2013 11:05:47 +0000 Message-ID: <1385377551-20826-2-git-send-email-andrew.cooper3@citrix.com> References: <1385377551-20826-1-git-send-email-andrew.cooper3@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1385377551-20826-1-git-send-email-andrew.cooper3@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Xen-devel Cc: Andrew Cooper , Ian Jackson , Ian Campbell List-Id: xen-devel@lists.xenproject.org If the console or store mfn chunks are not present in the migration stream, stack junk gets reported for the mfns. XenServer had a very hard to track down VM corruption issue caused by exactly this issue. Xenconsoled would connect to a junk mfn and incremented the ring pointer if the junk happend to look like a valid gfn. Coverity ID: 1056093 1056094 Signed-off-by: Andrew Cooper CC: Ian Campbell CC: Ian Jackson --- tools/xcutils/xc_restore.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/xcutils/xc_restore.c b/tools/xcutils/xc_restore.c index 5ec90ac..4ea261b 100644 --- a/tools/xcutils/xc_restore.c +++ b/tools/xcutils/xc_restore.c @@ -23,7 +23,7 @@ main(int argc, char **argv) xc_interface *xch; int io_fd, ret; int superpages; - unsigned long store_mfn, console_mfn; + unsigned long store_mfn = 0, console_mfn = 0; xentoollog_level lvl; xentoollog_logger *l; -- 1.7.10.4