Accepting request 579009 from home:ptesarik:branches:Kernel:kdump

- kdump-calibrate-do-not-add-KDUMP_PHYS_LOAD-to-RAM.patch:
  calibrate: Do not add KDUMP_PHYS_LOAD to required RAM.
- kdump-bootloader-filter-out-KDUMPTOOL_FLAGS.patch: bootloader:
  Filter out KDUMPTOOL_FLAGS (bsc#1072584).

OBS-URL: https://build.opensuse.org/request/show/579009
OBS-URL: https://build.opensuse.org/package/show/Kernel:kdump/kdump?expand=0&rev=153
This commit is contained in:
Petr Tesařík 2018-02-22 13:17:16 +00:00 committed by Git OBS Bridge
parent 3c5fd0a412
commit b33257d653
4 changed files with 68 additions and 0 deletions

View File

@ -0,0 +1,28 @@
From: Petr Tesarik <ptesarik@suse.com>
Date: Thu, 22 Feb 2018 14:03:26 +0100
Subject: bootloader: Filter out KDUMPTOOL_FLAGS
References: bsc#1072584
Upstream: merged
Git-commit: df216d1815eae7e8c4b139e0676696de4dc447d2
The bootloader update filters out all parameters starting with
KDUMP_, MAKEDUMPFILE_ or fadump. KDUMPTOOL_FLAGS does not match, so
it is not removed and consequently multiple instances may appear on
the command line.
Signed-off-by: Petr Tesarik <ptesarik@suse.com>
---
init/kdump-bootloader.pl | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/init/kdump-bootloader.pl
+++ b/init/kdump-bootloader.pl
@@ -26,7 +26,7 @@ if ($ARGV[0] eq "--get") {
my $param = $rawparam;
$param =~ s/"//g;
$param =~ s/=(.*)//;
- if (! ($param =~ /^(KDUMP|MAKEDUMPFILE)_|^fadump$/)) {
+ if (! ($param =~ /^KDUMP(TOOL)?_|^MAKEDUMPFILE_|^fadump$/)) {
$result .= " " if length($result);
$result .= $rawparam;
}

View File

@ -0,0 +1,28 @@
From: Petr Tesarik <ptesarik@suse.com>
Date: Tue, 20 Feb 2018 20:44:40 +0100
Subject: calibrate: Do not add KDUMP_PHYS_LOAD to required RAM
Upstream: merged
Git-commit: b70cbda10aa73f72f2324b8f9bf58918b59c9a86
The memory between 0 and KDUMP_PHYS_LOAD is not really allocated to
the panic kernel. It is added to the requirement merely to calculate
the memmap size for pages in this range.
Signed-off-by: Petr Tesarik <ptesarik@suse.com>
---
kdumptool/calibrate.cc | 4 ++++
1 file changed, 4 insertions(+)
--- a/kdumptool/calibrate.cc
+++ b/kdumptool/calibrate.cc
@@ -968,6 +968,10 @@ void Calibrate::execute()
required = prev + align_memmap(maxpfn) * SIZE_STRUCT_PAGE;
Debug::debug()->dbg("Maximum memmap size: %lu KiB", required - prev);
+ // Memory between 0 and KDUMP_PHYS_LOAD is not really allocated,
+ // so subtract it again after memmap has been sized.
+ required -= KDUMP_PHYS_LOAD;
+
// Make sure there is enough space at boot
Debug::debug()->dbg("Total run-time size: %lu KiB", required);
if (required < bootsize)

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Thu Feb 22 13:10:33 UTC 2018 - ptesarik@suse.com
- kdump-calibrate-do-not-add-KDUMP_PHYS_LOAD-to-RAM.patch:
calibrate: Do not add KDUMP_PHYS_LOAD to required RAM.
- kdump-bootloader-filter-out-KDUMPTOOL_FLAGS.patch: bootloader:
Filter out KDUMPTOOL_FLAGS (bsc#1072584).
-------------------------------------------------------------------
Fri Feb 9 17:46:06 UTC 2018 - ptesarik@suse.com

View File

@ -85,6 +85,8 @@ Patch35: %{name}-calibrate-update-user-space-requirements.patch
Patch36: %{name}-bail-out-if-no-default-interface.patch
Patch37: %{name}-fix-missing-index-of-kdump_Host.patch
Patch38: %{name}-nsswitch.conf-filtering.patch
Patch39: %{name}-calibrate-do-not-add-KDUMP_PHYS_LOAD-to-RAM.patch
Patch40: %{name}-bootloader-filter-out-KDUMPTOOL_FLAGS.patch
BuildRequires: asciidoc
BuildRequires: cmake
BuildRequires: gcc-c++
@ -185,6 +187,8 @@ cp %{S:1} tests/data/
%patch36 -p1
%patch37 -p1
%patch38 -p1
%patch39 -p1
%patch40 -p1
%build
export CFLAGS="%{optflags}"