Re: [PATCH v2] arm: redefine OPT_APPEND and OPT_RAMDISK

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Apr 15, 2020 at 12:58:45PM +0200, Łukasz Stelmach wrote:
> Redefine OPT_APPEND to avoid clash with OPT_KEXEC_SYSCALL_AUTO.
> Redefine OPT_RAMDISK to avoid such problems in the future
> 
> Signed-off-by: Łukasz Stelmach <l.stelmach@xxxxxxxxxxx>

Hi Łukasz,

I am slightly concerned that this will break things for users.
But OTOH perhaps we already broke things when adding OPT_KEXEC_SYSCALL_AUTO.
Do you have any thoughts on this?

> ---
>  kexec/arch/arm/include/arch/options.h | 6 +++---
>  kexec/arch/arm/kexec-zImage-arm.c     | 2 +-
>  2 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/kexec/arch/arm/include/arch/options.h b/kexec/arch/arm/include/arch/options.h
> index abbf349..6fabfb7 100644
> --- a/kexec/arch/arm/include/arch/options.h
> +++ b/kexec/arch/arm/include/arch/options.h
> @@ -4,12 +4,12 @@
>  #define OPT_DT_NO_OLD_ROOT	(OPT_MAX+0)
>  #define OPT_ARCH_MAX		(OPT_MAX+1)
>  
> -#define OPT_APPEND	'a'
> -#define OPT_RAMDISK	'r'
>  #define OPT_DTB		(OPT_ARCH_MAX+0)
>  #define OPT_ATAGS	(OPT_ARCH_MAX+1)
>  #define OPT_IMAGE_SIZE	(OPT_ARCH_MAX+2)
>  #define OPT_PAGE_OFFSET	(OPT_ARCH_MAX+3)
> +#define OPT_APPEND	(OPT_ARCH_MAX+4)
> +#define OPT_RAMDISK	(OPT_ARCH_MAX+5)
>  
>  /* Options relevant to the architecture (excluding loader-specific ones),
>   * in this case none:
> @@ -45,7 +45,7 @@
>  	{ "image-size",		1, 0, OPT_IMAGE_SIZE }, \
>  	{ "page-offset",	1, 0, OPT_PAGE_OFFSET },
>  
> -#define KEXEC_ALL_OPT_STR KEXEC_ARCH_OPT_STR "a:r:s:"
> +#define KEXEC_ALL_OPT_STR KEXEC_ARCH_OPT_STR ""
>  
>  extern unsigned int kexec_arm_image_size;
>  
> diff --git a/kexec/arch/arm/kexec-zImage-arm.c b/kexec/arch/arm/kexec-zImage-arm.c
> index 2a7eea9..d1aa8f6 100644
> --- a/kexec/arch/arm/kexec-zImage-arm.c
> +++ b/kexec/arch/arm/kexec-zImage-arm.c
> @@ -418,7 +418,7 @@ int zImage_arm_load(int argc, char **argv, const char *buf, off_t len,
>  		{ "page-offset",	1, 0, OPT_PAGE_OFFSET },
>  		{ 0, 			0, 0, 0 },
>  	};
> -	static const char short_options[] = KEXEC_ARCH_OPT_STR "a:r:";
> +	static const char short_options[] = KEXEC_ARCH_OPT_STR "";
>  
>  	/*
>  	 * Parse the command line arguments
> -- 
> 2.25.0
> 

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




[Index of Archives]     [LM Sensors]     [Linux Sound]     [ALSA Users]     [ALSA Devel]     [Linux Audio Users]     [Linux Media]     [Kernel]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux