File kexec-tools-xen-inhibit-file-based-syscall.patch of Package kexec-tools

From 0d8ed73516dc869a911d687de7434bb95d1b1a73 Mon Sep 17 00:00:00 2001
From: "Lee, Chun-Yi" <jlee@suse.com>
Date: Tue, 13 Oct 2015 18:31:27 +0800
Subject: [PATCH] kexec: inhibit file based syscall on XEN

To inhibit file based syscall on XEN, using old syscall to load crash
kernel.

Signed-off-by: Lee, Chun-Yi <jlee@suse.com>
---
 kexec/kexec.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

--- a/kexec/kexec.c
+++ b/kexec/kexec.c
@@ -1005,6 +1005,7 @@ void usage(void)
 	       "                      preserve context)\n"
 	       "                      to original kernel.\n"
 	       " -s, --kexec-file-syscall Use file based syscall for kexec operation\n"
+	       "                          (-s option is inhibited on XEN)\n"
 	       " -c, --kexec-syscall  Use the kexec_load syscall for for compatibility\n"
 	       "                      with systems that don't support -s (default)\n"
 	       " -a, --kexec-syscall-auto  Use file based syscall for kexec and fall\n"
@@ -1377,7 +1378,7 @@ int main(int argc, char *argv[])
 			do_reuse_initrd = 1;
 			break;
 		case OPT_KEXEC_FILE_SYSCALL:
-			do_kexec_file_syscall = 1;
+			do_kexec_file_syscall = (xen_present())? 0 : 1;
 			do_kexec_fallback = 0;
 			break;
 		case OPT_KEXEC_SYSCALL:
openSUSE Build Service is sponsored by