All of lore.kernel.org
 help / color / mirror / Atom feed
From: Xunlei Pang <xpang@redhat.com>
To: Dave Young <dyoung@redhat.com>, Yinghai Lu <yinghai@kernel.org>
Cc: Baoquan He <bhe@redhat.com>, Xunlei Pang <xlpang@redhat.com>,
	"kexec@lists.infradead.org" <kexec@lists.infradead.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	"Eric W. Biederman" <ebiederm@xmission.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Vivek Goyal <vgoyal@redhat.com>
Subject: Re: [PATCH v2 1/2] kexec: Introduce "/sys/kernel/kexec_crash_low_size"
Date: Wed, 24 Aug 2016 19:37:09 +0800	[thread overview]
Message-ID: <57BD86E5.30704@redhat.com> (raw)
In-Reply-To: <20160824082031.GA13889@dhcp-128-65.nay.redhat.com>

On 2016/08/24 at 16:20, Dave Young wrote:
> On 08/23/16 at 06:11pm, Yinghai Lu wrote:
>> On Wed, Aug 17, 2016 at 1:20 AM, Dave Young <dyoung@redhat.com> wrote:
>>> On 08/17/16 at 09:50am, Xunlei Pang wrote:
>>>> "/sys/kernel/kexec_crash_size" only handles crashk_res, it
>>>> is fine in most cases, but sometimes we have crashk_low_res.
>>>> For example, when "crashkernel=size[KMG],high" combined with
>>>> "crashkernel=size[KMG],low" is used for 64-bit x86.
>>>>
>>>> Like crashk_res, we introduce the corresponding sysfs file
>>>> "/sys/kernel/kexec_crash_low_size" for crashk_low_res.
>>>>
>>>> So, the exact total reserved memory is the sum of the two.
>>>>
>>>> crashk_low_res can also be shrunk via this new interface,
>>>> and users should be aware of what they are doing.
>> ...
>>>> @@ -218,6 +238,7 @@ static struct attribute * kernel_attrs[] = {
>>>>  #ifdef CONFIG_KEXEC_CORE
>>>>       &kexec_loaded_attr.attr,
>>>>       &kexec_crash_loaded_attr.attr,
>>>> +     &kexec_crash_low_size_attr.attr,
>>>>       &kexec_crash_size_attr.attr,
>>>>       &vmcoreinfo_attr.attr,
>>>>  #endif
>> would be better if you can use attribute_group .is_visible to control showing of
>> crash_low_size only when the crash_base is above 4G.
> I have same feeling that it looks odd to show low in sysfs in case no
> crashkernel=,high being used. Even if crashkernel=,high is used only in
> x86 the resource crashk_low is in common code. What do you think to move
> it to x86?

If want to put some restriction on it, I'd prefer to move crashk_low to arch x86, to make
it x86-specific.

We can show the interface unconditionally. If it isn't used, its size is 0, it doesn't matter.

Regards,
Xunlei

>
> Thanks
> Dave
>
>> Thanks
>>
>> Yinghai
>>
>> _______________________________________________
>> kexec mailing list
>> kexec@lists.infradead.org
>> http://lists.infradead.org/mailman/listinfo/kexec


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

WARNING: multiple messages have this Message-ID (diff)
From: Xunlei Pang <xpang@redhat.com>
To: Dave Young <dyoung@redhat.com>, Yinghai Lu <yinghai@kernel.org>
Cc: Baoquan He <bhe@redhat.com>, Xunlei Pang <xlpang@redhat.com>,
	"kexec@lists.infradead.org" <kexec@lists.infradead.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	"Eric W. Biederman" <ebiederm@xmission.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Vivek Goyal <vgoyal@redhat.com>
Subject: Re: [PATCH v2 1/2] kexec: Introduce "/sys/kernel/kexec_crash_low_size"
Date: Wed, 24 Aug 2016 19:37:09 +0800	[thread overview]
Message-ID: <57BD86E5.30704@redhat.com> (raw)
In-Reply-To: <20160824082031.GA13889@dhcp-128-65.nay.redhat.com>

On 2016/08/24 at 16:20, Dave Young wrote:
> On 08/23/16 at 06:11pm, Yinghai Lu wrote:
>> On Wed, Aug 17, 2016 at 1:20 AM, Dave Young <dyoung@redhat.com> wrote:
>>> On 08/17/16 at 09:50am, Xunlei Pang wrote:
>>>> "/sys/kernel/kexec_crash_size" only handles crashk_res, it
>>>> is fine in most cases, but sometimes we have crashk_low_res.
>>>> For example, when "crashkernel=size[KMG],high" combined with
>>>> "crashkernel=size[KMG],low" is used for 64-bit x86.
>>>>
>>>> Like crashk_res, we introduce the corresponding sysfs file
>>>> "/sys/kernel/kexec_crash_low_size" for crashk_low_res.
>>>>
>>>> So, the exact total reserved memory is the sum of the two.
>>>>
>>>> crashk_low_res can also be shrunk via this new interface,
>>>> and users should be aware of what they are doing.
>> ...
>>>> @@ -218,6 +238,7 @@ static struct attribute * kernel_attrs[] = {
>>>>  #ifdef CONFIG_KEXEC_CORE
>>>>       &kexec_loaded_attr.attr,
>>>>       &kexec_crash_loaded_attr.attr,
>>>> +     &kexec_crash_low_size_attr.attr,
>>>>       &kexec_crash_size_attr.attr,
>>>>       &vmcoreinfo_attr.attr,
>>>>  #endif
>> would be better if you can use attribute_group .is_visible to control showing of
>> crash_low_size only when the crash_base is above 4G.
> I have same feeling that it looks odd to show low in sysfs in case no
> crashkernel=,high being used. Even if crashkernel=,high is used only in
> x86 the resource crashk_low is in common code. What do you think to move
> it to x86?

If want to put some restriction on it, I'd prefer to move crashk_low to arch x86, to make
it x86-specific.

We can show the interface unconditionally. If it isn't used, its size is 0, it doesn't matter.

Regards,
Xunlei

>
> Thanks
> Dave
>
>> Thanks
>>
>> Yinghai
>>
>> _______________________________________________
>> kexec mailing list
>> kexec@lists.infradead.org
>> http://lists.infradead.org/mailman/listinfo/kexec

  reply	other threads:[~2016-08-24 11:37 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-17  1:50 [PATCH v2 1/2] kexec: Introduce "/sys/kernel/kexec_crash_low_size" Xunlei Pang
2016-08-17  1:50 ` Xunlei Pang
2016-08-17  1:50 ` [PATCH v2 2/2] kexec: Consider crashk_low_res in sanity_check_segment_list() Xunlei Pang
2016-08-17  1:50   ` Xunlei Pang
2016-08-17  7:24   ` Dave Young
2016-08-17  7:24     ` Dave Young
2016-08-17  7:43     ` Xunlei Pang
2016-08-17  7:43       ` Xunlei Pang
2016-08-17  8:20 ` [PATCH v2 1/2] kexec: Introduce "/sys/kernel/kexec_crash_low_size" Dave Young
2016-08-17  8:20   ` Dave Young
2016-08-24  1:11   ` Yinghai Lu
2016-08-24  1:11     ` Yinghai Lu
2016-08-24  8:20     ` Dave Young
2016-08-24  8:20       ` Dave Young
2016-08-24 11:37       ` Xunlei Pang [this message]
2016-08-24 11:37         ` Xunlei Pang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=57BD86E5.30704@redhat.com \
    --to=xpang@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=bhe@redhat.com \
    --cc=dyoung@redhat.com \
    --cc=ebiederm@xmission.com \
    --cc=kexec@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=vgoyal@redhat.com \
    --cc=xlpang@redhat.com \
    --cc=yinghai@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.