All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86: Support large number of memory ranges
@ 2017-03-23 11:16 Xunlei Pang
  2017-03-23 13:27 ` Ramsay, Frank
  0 siblings, 1 reply; 3+ messages in thread
From: Xunlei Pang @ 2017-03-23 11:16 UTC (permalink / raw)
  To: kexec; +Cc: Xunlei Pang, Dave Young, Frank Ramsay

We got a problem on one SGI 64TB machine, the current kexec-tools
failed to work due to the insufficient ranges(MAX_MEMORY_RANGES)
allowed which is defined as 1024(less than the ranges on the machine).
The kcore header is insufficient due to the same reason as well.

To solve this, this patch simply doubles "MAX_MEMORY_RANGES" and
"KCORE_ELF_HEADERS_SIZE".

Cc: Frank Ramsay <frank.ramsay@hpe.com>
Signed-off-by: Xunlei Pang <xlpang@redhat.com>
---
 kexec/arch/i386/kexec-x86.h | 2 +-
 kexec/crashdump.h           | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/kexec/arch/i386/kexec-x86.h b/kexec/arch/i386/kexec-x86.h
index 33df352..51855f8 100644
--- a/kexec/arch/i386/kexec-x86.h
+++ b/kexec/arch/i386/kexec-x86.h
@@ -1,7 +1,7 @@
 #ifndef KEXEC_X86_H
 #define KEXEC_X86_H
 
-#define MAX_MEMORY_RANGES 1024
+#define MAX_MEMORY_RANGES 2048
 
 enum coretype {
 	CORE_TYPE_UNDEF = 0,
diff --git a/kexec/crashdump.h b/kexec/crashdump.h
index 86e1ef2..18bd691 100644
--- a/kexec/crashdump.h
+++ b/kexec/crashdump.h
@@ -7,8 +7,8 @@ extern int get_xen_vmcoreinfo(uint64_t *addr, uint64_t *len);
 
 /* Need to find a better way to determine per cpu notes section size. */
 #define MAX_NOTE_BYTES		1024
-/* Expecting ELF headers to fit in 32K. Increase it if you need more. */
-#define KCORE_ELF_HEADERS_SIZE  32768
+/* Expecting ELF headers to fit in 64K. Increase it if you need more. */
+#define KCORE_ELF_HEADERS_SIZE  65536
 /* The address of the ELF header is passed to the secondary kernel
  * using the kernel command line option memmap=nnn.
  * The smallest unit the kernel accepts is in kilobytes,
-- 
1.8.3.1


_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86: Support large number of memory ranges
  2017-03-23 11:16 [PATCH] x86: Support large number of memory ranges Xunlei Pang
@ 2017-03-23 13:27 ` Ramsay, Frank
  2017-03-24  6:44   ` Simon Horman
  0 siblings, 1 reply; 3+ messages in thread
From: Ramsay, Frank @ 2017-03-23 13:27 UTC (permalink / raw)
  To: Xunlei Pang, kexec; +Cc: Dave Young

acking I tested this
Tested-by: Frank Ramsay <frank.ramsay@hpe.com>

________________________________________
From: Xunlei Pang <xlpang@redhat.com>
Sent: Thursday, March 23, 2017 7:16:59 AM
To: kexec@lists.infradead.org
Cc: Dave Young; Xunlei Pang; Ramsay, Frank
Subject: [PATCH] x86: Support large number of memory ranges

We got a problem on one SGI 64TB machine, the current kexec-tools
failed to work due to the insufficient ranges(MAX_MEMORY_RANGES)
allowed which is defined as 1024(less than the ranges on the machine).
The kcore header is insufficient due to the same reason as well.

To solve this, this patch simply doubles "MAX_MEMORY_RANGES" and
"KCORE_ELF_HEADERS_SIZE".

Cc: Frank Ramsay <frank.ramsay@hpe.com>
Signed-off-by: Xunlei Pang <xlpang@redhat.com>
---
 kexec/arch/i386/kexec-x86.h | 2 +-
 kexec/crashdump.h           | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/kexec/arch/i386/kexec-x86.h b/kexec/arch/i386/kexec-x86.h
index 33df352..51855f8 100644
--- a/kexec/arch/i386/kexec-x86.h
+++ b/kexec/arch/i386/kexec-x86.h
@@ -1,7 +1,7 @@
 #ifndef KEXEC_X86_H
 #define KEXEC_X86_H

-#define MAX_MEMORY_RANGES 1024
+#define MAX_MEMORY_RANGES 2048

 enum coretype {
        CORE_TYPE_UNDEF = 0,
diff --git a/kexec/crashdump.h b/kexec/crashdump.h
index 86e1ef2..18bd691 100644
--- a/kexec/crashdump.h
+++ b/kexec/crashdump.h
@@ -7,8 +7,8 @@ extern int get_xen_vmcoreinfo(uint64_t *addr, uint64_t *len);

 /* Need to find a better way to determine per cpu notes section size. */
 #define MAX_NOTE_BYTES         1024
-/* Expecting ELF headers to fit in 32K. Increase it if you need more. */
-#define KCORE_ELF_HEADERS_SIZE  32768
+/* Expecting ELF headers to fit in 64K. Increase it if you need more. */
+#define KCORE_ELF_HEADERS_SIZE  65536
 /* The address of the ELF header is passed to the secondary kernel
  * using the kernel command line option memmap=nnn.
  * The smallest unit the kernel accepts is in kilobytes,
--
1.8.3.1


_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86: Support large number of memory ranges
  2017-03-23 13:27 ` Ramsay, Frank
@ 2017-03-24  6:44   ` Simon Horman
  0 siblings, 0 replies; 3+ messages in thread
From: Simon Horman @ 2017-03-24  6:44 UTC (permalink / raw)
  To: Ramsay, Frank; +Cc: kexec, Dave Young, Xunlei Pang

On Thu, Mar 23, 2017 at 01:27:08PM +0000, Ramsay, Frank wrote:
> ________________________________________
> From: Xunlei Pang <xlpang@redhat.com>
> Sent: Thursday, March 23, 2017 7:16:59 AM
> To: kexec@lists.infradead.org
> Cc: Dave Young; Xunlei Pang; Ramsay, Frank
> Subject: [PATCH] x86: Support large number of memory ranges
> 
> We got a problem on one SGI 64TB machine, the current kexec-tools
> failed to work due to the insufficient ranges(MAX_MEMORY_RANGES)
> allowed which is defined as 1024(less than the ranges on the machine).
> The kcore header is insufficient due to the same reason as well.
> 
> To solve this, this patch simply doubles "MAX_MEMORY_RANGES" and
> "KCORE_ELF_HEADERS_SIZE".
> 
> Cc: Frank Ramsay <frank.ramsay@hpe.com>
> Signed-off-by: Xunlei Pang <xlpang@redhat.com>
> 
> acking I tested this
> Tested-by: Frank Ramsay <frank.ramsay@hpe.com>

Thanks, applied.

_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-03-24  6:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-23 11:16 [PATCH] x86: Support large number of memory ranges Xunlei Pang
2017-03-23 13:27 ` Ramsay, Frank
2017-03-24  6:44   ` Simon Horman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.