]> git.baikalelectronics.ru Git - kernel.git/commit
kexec: check if crashk_res_low exists when exclude it from crash mem ranges
authorBaoquan He <bhe@redhat.com>
Mon, 13 Oct 2014 22:53:42 +0000 (15:53 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 14 Oct 2014 00:18:21 +0000 (02:18 +0200)
commit64e6f9369c1aad8c5a84316911c5149f05035e84
tree87a101e8d879885b8515eefc338e2e99a105b15e
parentfb5d9fd85c1aac5cbe43d19c5b3f906e3c3e59b7
kexec: check if crashk_res_low exists when exclude it from crash mem ranges

Add a check if crashk_res_low exists just like GART region does.  If
crashk_res_low doesn't exist, calling exclude_mem_range is unnecessary.

Meanwhile, since crashk_res_low has been initialized at definition, it's
safe just use "if (crashk_low_res.end)" to check if it's exist.  And this
can make it consistent with other places of check.

Signed-off-by: Baoquan He <bhe@redhat.com>
Acked-by: Vivek Goyal <vgoyal@redhat.com>
Cc: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/x86/kernel/crash.c