lkml.org 
[lkml]   [2020]   [Aug]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 1/2] kexec: Add quick kexec support for kernel
From
Date

On 8/17/2020 9:42 PM, Pavel Machek wrote:
> Hi!
>
>> +config QUICK_KEXEC
>> + bool "Support for quick kexec"
>> + depends on KEXEC_CORE
>> + help
>> + Say y here to enable this feature.
>
> ?
>
>> + It use reserved memory to accelerate kexec, just like crash
>
> uses
>
>> + kexec, load new kernel and initrd to reserved memory, and
>> + boot new kernel on that memory. It will save the time of
>> + relocating kernel.
>
> loads a new.... boots new...
>
>> IORES_DESC_DEVICE_PRIVATE_MEMORY = 6,
>> IORES_DESC_RESERVED = 7,
>> IORES_DESC_SOFT_RESERVED = 8,
>> +#ifdef CONFIG_QUICK_KEXEC
>> + IORES_DESC_QUICK_KEXEC = 9,
>> +#endif
>> };
>
> Remove ifdef.
>
>> /*
>> diff --git a/include/linux/kexec.h b/include/linux/kexec.h
>> index 9e93bef52968..976bf9631070 100644
>> --- a/include/linux/kexec.h
>> +++ b/include/linux/kexec.h
>> @@ -269,9 +269,12 @@ struct kimage {
>> unsigned long control_page;
>>
>> /* Flags to indicate special processing */
>> - unsigned int type : 1;
>> + unsigned int type : 2;
>> #define KEXEC_TYPE_DEFAULT 0
>> #define KEXEC_TYPE_CRASH 1
>> +#ifdef CONFIG_QUICK_KEXEC
>> +#define KEXEC_TYPE_QUICK 2
>> +#endif
>> unsigned int preserve_context : 1;
>
> Here, too.
>
>> +++ b/include/uapi/linux/kexec.h
>> @@ -12,6 +12,9 @@
>> /* kexec flags for different usage scenarios */
>> #define KEXEC_ON_CRASH 0x00000001
>> #define KEXEC_PRESERVE_CONTEXT 0x00000002
>> +#ifdef CONFIG_QUICK_KEXEC
>> +#define KEXEC_QUICK 0x00000004
>> +#endif
>> #define KEXEC_ARCH_MASK 0xffff0000
>
> And here.
>
> Pavel
>
> .
>

Thanks a lot for your review.

Sang Yan.

\
 
 \ /
  Last update: 2020-08-18 08:51    [W:0.082 / U:0.268 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site