s390: use KEXEC_ALL_OPTIONS
Resolves: bz2060824 Upstream: git.kernel.org/pub/scm/utils/kernel/kexec/kexec-tools.git Conflicts: None commit 91a3d0e00a5c18ee9bdd2c6c03ac64a6471e2559 Author: Sven Schnelle <svens@linux.ibm.com> Date: Thu Dec 16 12:43:53 2021 +0100 s390: use KEXEC_ALL_OPTIONS KEXEC_ALL_OPTIONS could be used instead defining the same array several times. This makes code easier to maintain when new options are added. Suggested-by: Alexander Egorenkov <egorenar@linux.ibm.com> Signed-off-by: Sven Schnelle <svens@linux.ibm.com> Reviewed-by: Alexander Egorenkov <egorenar@linux.ibm.com> Signed-off-by: Simon Horman <horms@verge.net.au> Signed-off-by: Philipp Rudo <prudo@redhat.com>
This commit is contained in:
parent
5c6595e4c0
commit
f8e3f42ec1
43
kexec-tools-2.0.23-02-s390_use_KEXEC_ALL_OPTIONS.patch
Normal file
43
kexec-tools-2.0.23-02-s390_use_KEXEC_ALL_OPTIONS.patch
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
commit 91a3d0e00a5c18ee9bdd2c6c03ac64a6471e2559
|
||||||
|
Author: Sven Schnelle <svens@linux.ibm.com>
|
||||||
|
Date: Thu Dec 16 12:43:53 2021 +0100
|
||||||
|
|
||||||
|
s390: use KEXEC_ALL_OPTIONS
|
||||||
|
|
||||||
|
KEXEC_ALL_OPTIONS could be used instead defining the same
|
||||||
|
array several times. This makes code easier to maintain when
|
||||||
|
new options are added.
|
||||||
|
|
||||||
|
Suggested-by: Alexander Egorenkov <egorenar@linux.ibm.com>
|
||||||
|
Signed-off-by: Sven Schnelle <svens@linux.ibm.com>
|
||||||
|
Reviewed-by: Alexander Egorenkov <egorenar@linux.ibm.com>
|
||||||
|
Signed-off-by: Simon Horman <horms@verge.net.au>
|
||||||
|
|
||||||
|
diff --git a/kexec/arch/s390/kexec-image.c b/kexec/arch/s390/kexec-image.c
|
||||||
|
index a52399eafd2abd4a24142f0512251598ea812ca5..209ab77ddccbd60f10989e2d9fc273324aefa76d 100644
|
||||||
|
--- a/kexec/arch/s390/kexec-image.c
|
||||||
|
+++ b/kexec/arch/s390/kexec-image.c
|
||||||
|
@@ -57,10 +57,7 @@ int image_s390_load_file(int argc, char **argv, struct kexec_info *info)
|
||||||
|
|
||||||
|
static const struct option options[] =
|
||||||
|
{
|
||||||
|
- KEXEC_OPTIONS
|
||||||
|
- {"command-line", 1, 0, OPT_APPEND},
|
||||||
|
- {"append", 1, 0, OPT_APPEND},
|
||||||
|
- {"initrd", 1, 0, OPT_RAMDISK},
|
||||||
|
+ KEXEC_ALL_OPTIONS
|
||||||
|
{0, 0, 0, 0},
|
||||||
|
};
|
||||||
|
static const char short_options[] = KEXEC_OPT_STR "";
|
||||||
|
@@ -111,10 +108,7 @@ image_s390_load(int argc, char **argv, const char *kernel_buf,
|
||||||
|
|
||||||
|
static const struct option options[] =
|
||||||
|
{
|
||||||
|
- KEXEC_OPTIONS
|
||||||
|
- {"command-line", 1, 0, OPT_APPEND},
|
||||||
|
- {"append", 1, 0, OPT_APPEND},
|
||||||
|
- {"initrd", 1, 0, OPT_RAMDISK},
|
||||||
|
+ KEXEC_ALL_OPTIONS
|
||||||
|
{0, 0, 0, 0},
|
||||||
|
};
|
||||||
|
static const char short_options[] = KEXEC_OPT_STR "";
|
@ -105,6 +105,7 @@ Requires: systemd-udev%{?_isa}
|
|||||||
# Patches 401 through 500 are meant for s390 kexec-tools enablement
|
# Patches 401 through 500 are meant for s390 kexec-tools enablement
|
||||||
#
|
#
|
||||||
Patch401: ./kexec-tools-2.0.23-01-s390_add_variable_command_line_size.patch
|
Patch401: ./kexec-tools-2.0.23-01-s390_add_variable_command_line_size.patch
|
||||||
|
Patch402: ./kexec-tools-2.0.23-02-s390_use_KEXEC_ALL_OPTIONS.patch
|
||||||
|
|
||||||
#
|
#
|
||||||
# Patches 501 through 600 are meant for ARM kexec-tools enablement
|
# Patches 501 through 600 are meant for ARM kexec-tools enablement
|
||||||
@ -136,6 +137,7 @@ tar -z -x -v -f %{SOURCE9}
|
|||||||
tar -z -x -v -f %{SOURCE19}
|
tar -z -x -v -f %{SOURCE19}
|
||||||
|
|
||||||
%patch401 -p1
|
%patch401 -p1
|
||||||
|
%patch402 -p1
|
||||||
%patch601 -p1
|
%patch601 -p1
|
||||||
%patch602 -p1
|
%patch602 -p1
|
||||||
%patch603 -p1
|
%patch603 -p1
|
||||||
|
Loading…
Reference in New Issue
Block a user