Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=ad1c3ba7e54fc38b119c1a7d5c98f9ffb8227fdb
Commit:     ad1c3ba7e54fc38b119c1a7d5c98f9ffb8227fdb
Parent:     45a98fc622ae700eed34eb2be00743910d50dbe1
Author:     Horms <[EMAIL PROTECTED]>
AuthorDate: Tue Dec 12 18:08:10 2006 +0900
Committer:  Tony Luck <[EMAIL PROTECTED]>
CommitDate: Tue Dec 12 10:11:37 2006 -0800

    [IA64] Kexec/Kdump: honour non-zero crashkernel offset.
    
    There seems to be a value in both allowing the kernel to determine
    the base offset of the crashkernel automatically and allowing
    users's to sepcify it.
    
    The old behaviour on ia64, which is still the current behaviour on
    most architectures is for the user to always specify the address.
    Recently ia64 was changed so that it is always automatically determined.
    
    With this patch the kernel automatically determines the offset if
    the supplied value is 0, otherwise it uses the value provided.
    
    This should probably be backed by a documentation change.
    
    Signed-Off-By: Simon Horman <[EMAIL PROTECTED]>
    Signed-off-by: Tony Luck <[EMAIL PROTECTED]>
---
 arch/ia64/kernel/setup.c |   14 ++++++++++----
 1 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/arch/ia64/kernel/setup.c b/arch/ia64/kernel/setup.c
index 66377ba..be39845 100644
--- a/arch/ia64/kernel/setup.c
+++ b/arch/ia64/kernel/setup.c
@@ -256,7 +256,7 @@ reserve_memory (void)
 
 #ifdef CONFIG_KEXEC
        /* [EMAIL PROTECTED] specifies the size to reserve for a crash
-        * kernel.(offset is ingored for keep compatibility with other archs)
+        * kernel. If offset is 0, then it is determined automatically.
         * By reserving this memory we guarantee that linux never set's it
         * up as a DMA target.Useful for holding code to do something
         * appropriate after a kernel panic.
@@ -266,10 +266,16 @@ reserve_memory (void)
                unsigned long base, size;
                if (from) {
                        size = memparse(from + 12, &from);
+                       if (*from == '@')
+                               base = memparse(from+1, &from);
+                       else
+                               base = 0;
                        if (size) {
-                               sort_regions(rsvd_region, n);
-                               base = kdump_find_rsvd_region(size,
-                               rsvd_region, n);
+                               if (!base) {
+                                       sort_regions(rsvd_region, n);
+                                       base = kdump_find_rsvd_region(size,
+                                                               rsvd_region, n);
+                                       }
                                if (base != ~0UL) {
                                        rsvd_region[n].start =
                                                (unsigned long)__va(base);
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to