kexec: provide crashinfo_maxaddr_bits if !CONFIG_KEXEC
PATCH 1/1 kexec: provide crashinfo_maxaddr_bits if !CONFIG_KEXEC
From: David Vrabel <[email protected]>
Fix the build where !CONFIG_KEXEC (e.g., arm) by providing a default crashinfo_maxaddr_bits.
Signed-off-by David Vrabel <[email protected]>
---
Andy,
A cleaner fix might be to replace MEMF_bits(crashinfo_max_addr_bits) with a function (e.g., crashinfo_mem_flags()), and provide an inline stub when !CONFIG_KEXEC.
David
--- xen/drivers/char/console.c | 2 -- xen/include/xen/kexec.h | 8 ++++++++ 2 files changed, 8 insertions(+), 2 deletions(-)
xen/drivers/char/console.c +0 -2
@@ -22,9 +22,7 @@#include <xen/guest_access.h> #include <xen/shutdown.h> #include <xen/vga.h> -#ifdef CONFIG_KEXEC #include <xen/kexec.h> -#endif #include <asm/debugger.h> #include <asm/div64.h> #include <xen/hypercall.h> /* for do_console_io */
xen/include/xen/kexec.h +8 -0
@@ -1,6 +1,8 @@#ifndef __XEN_KEXEC_H__#define __XEN_KEXEC_H__ +#ifdef CONFIG_KEXEC +#include <public/kexec.h> #include <asm/percpu.h> #include <xen/elfcore.h>
@@ -76,6 +78,12 @@ void vmcoreinfo_append_str(const char *fmt, ...) vmcoreinfo_append_str("OFFSET(%s.%s)=%lu\n", #name, #field, \ (unsigned long)offsetof(struct name, sub.field)) +#else /* !CONFIG_KEXEC */ + +#define crashinfo_maxaddr_bits 0 + +#endif +#endif /* __XEN_KEXEC_H__ */ /*
Signature · 1 line
1.7.2.5
Quoted 6 lines · David Vrabel
From: David Vrabel <[email protected]>
Fix the build where !CONFIG_KEXEC (e.g., arm) by providing a default
crashinfo_maxaddr_bits.Signed-off-by David Vrabel <[email protected]>
Acked-by Andrew Cooper <[email protected]>
Quoted 53 lines
---
Andy,A cleaner fix might be to replace
MEMF_bits(crashinfo_max_addr_bits)with a function (e.g.,crashinfo_mem_flags()), and provide an inline stub when !CONFIG_KEXEC.David
--- xen/drivers/char/console.c | 2 -- xen/include/xen/kexec.h | 8 ++++++++ 2 files changed, 8 insertions(+), 2 deletions(-)xen/drivers/char/console.c +0
-2@@ -22,9 +22,7 @@#include <xen/guest_access.h> #include <xen/shutdown.h> #include <xen/vga.h> -#ifdef CONFIG_KEXEC #include <xen/kexec.h> -#endif #include <asm/debugger.h> #include <asm/div64.h> #include <xen/hypercall.h> /* for do_console_io */ xen/include/xen/kexec.h +8
-0@@ -1,6 +1,8 @@#ifndef __XEN_KEXEC_H__#define __XEN_KEXEC_H__ +#ifdef CONFIG_KEXEC +#include <public/kexec.h> #include <asm/percpu.h> #include <xen/elfcore.h> @@ -76,6 +78,12 @@ void vmcoreinfo_append_str(const char *fmt, ...) vmcoreinfo_append_str("OFFSET(%s.%s)=%lu\n", #name, #field, \ (unsigned long)offsetof(struct name, sub.field)) +#else /* !CONFIG_KEXEC */ + +#define crashinfo_maxaddr_bits 0 + +#endif +#endif /* __XEN_KEXEC_H__ */ /*
Signature · 2 lines
Andrew Cooper - Dom0 Kernel Engineer, Citrix XenServer T: +44 (0)1223 225 900, http://www.citrix.com