[PATCH v2]kexec:i386:kexec-bzImage: Fix pass garbage command line to new kernel

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

 



On Mon, Apr 08, 2013 at 05:51:52PM +0800, Zhang Yanfei wrote:

> This is obviously wrong. 
Yes, it is obviously wrong
> Purgatory may append a kexec_jump_back_entry= argument into the commandline. It is
> an argument belongs to the commandline. So why there is a buf filled with 0 
> (alloc_command_line_len) before it in the commandline buf.
Kernel will copy all the COMMAND_LINE_SIZE len buffer pointer by 
cmd_line_ptr, but kexec-bzImage just prepare a very shorter buffer
in the below line check failed code path:

if (info->kexec_flags & (KEXEC_ON_CRASH | KEXEC_PRESERVE_CONTEXT))

in the check sucess code path, it seems good by below line:
modified_cmdline = xmalloc(COMMAND_LINE_SIZE);




[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