All of lore.kernel.org
 help / color / mirror / Atom feed
From: ebiederm@xmission.com (Eric W. Biederman)
To: Andrew Morton <akpm@linux-foundation.org>
Cc: nigel@nigel.suspend2.net,
	Kexec Mailing List <kexec@lists.infradead.org>,
	linux-kernel@vger.kernel.org, "Rafael J. Wysocki" <rjw@sisk.pl>,
	Pavel Machek <pavel@ucw.cz>, Huang Ying <ying.huang@intel.com>,
	mingo@elte.hu, Linus Torvalds <torvalds@linux-foundation.org>,
	Vivek Goyal <vgoyal@redhat.com>
Subject: Re: [PATCH -v3 1/7] kexec jump: clean up #ifdef and comments
Date: Tue, 12 Aug 2008 21:47:22 -0700	[thread overview]
Message-ID: <m1ej4tikrp.fsf@frodo.ebiederm.org> (raw)
In-Reply-To: <20080812204900.db63deaa.akpm@linux-foundation.org> (Andrew Morton's message of "Tue, 12 Aug 2008 20:49:00 -0700")

Andrew Morton <akpm@linux-foundation.org> writes:

> On Tue, 12 Aug 2008 11:14:21 +0800 Huang Ying <ying.huang@intel.com> wrote:
>
>>  	xchg(&kexec_lock, 0);
>
> kernel/kexec.c: In function 'kernel_kexec':
> kernel/kexec.c:1501: warning: value computed is not used

A good question is why we are warned.

> Is there any reason why we cannot use the more conventional
> test_and_set_bit() etc, rather than this peculiarity?
>
> Or perhaps spin_trylock?

Totally odd.

Let me stop and take a look and see what has been changed.  The original
code used a xchg based read copy update scheme, which was extremely
compatible with a lot of goals.  The primary one being no blocking paths
in a successful kexec, and minimal dependence on library functions.

We need that minimal dependence to handle the kexec on panic case.

That doesn't rule out something like test_and_set_bit.

Eric

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

WARNING: multiple messages have this Message-ID (diff)
From: ebiederm@xmission.com (Eric W. Biederman)
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Huang Ying <ying.huang@intel.com>, Pavel Machek <pavel@ucw.cz>,
	nigel@nigel.suspend2.net, "Rafael J. Wysocki" <rjw@sisk.pl>,
	Vivek Goyal <vgoyal@redhat.com>,
	mingo@elte.hu, Linus Torvalds <torvalds@linux-foundation.org>,
	linux-kernel@vger.kernel.org,
	Kexec Mailing List <kexec@lists.infradead.org>
Subject: Re: [PATCH -v3 1/7] kexec jump: clean up #ifdef and comments
Date: Tue, 12 Aug 2008 21:47:22 -0700	[thread overview]
Message-ID: <m1ej4tikrp.fsf@frodo.ebiederm.org> (raw)
In-Reply-To: <20080812204900.db63deaa.akpm@linux-foundation.org> (Andrew Morton's message of "Tue, 12 Aug 2008 20:49:00 -0700")

Andrew Morton <akpm@linux-foundation.org> writes:

> On Tue, 12 Aug 2008 11:14:21 +0800 Huang Ying <ying.huang@intel.com> wrote:
>
>>  	xchg(&kexec_lock, 0);
>
> kernel/kexec.c: In function 'kernel_kexec':
> kernel/kexec.c:1501: warning: value computed is not used

A good question is why we are warned.

> Is there any reason why we cannot use the more conventional
> test_and_set_bit() etc, rather than this peculiarity?
>
> Or perhaps spin_trylock?

Totally odd.

Let me stop and take a look and see what has been changed.  The original
code used a xchg based read copy update scheme, which was extremely
compatible with a lot of goals.  The primary one being no blocking paths
in a successful kexec, and minimal dependence on library functions.

We need that minimal dependence to handle the kexec on panic case.

That doesn't rule out something like test_and_set_bit.

Eric

  parent reply	other threads:[~2008-08-13  4:53 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-12  3:14 [PATCH -v3 1/7] kexec jump: clean up #ifdef and comments Huang Ying
2008-08-12  3:14 ` Huang Ying
2008-08-13  3:49 ` Andrew Morton
2008-08-13  3:49   ` Andrew Morton
2008-08-13  4:44   ` Huang Ying
2008-08-13  4:44     ` Huang Ying
2008-08-13  4:47   ` Eric W. Biederman [this message]
2008-08-13  4:47     ` Eric W. Biederman

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=m1ej4tikrp.fsf@frodo.ebiederm.org \
    --to=ebiederm@xmission.com \
    --cc=akpm@linux-foundation.org \
    --cc=kexec@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=nigel@nigel.suspend2.net \
    --cc=pavel@ucw.cz \
    --cc=rjw@sisk.pl \
    --cc=torvalds@linux-foundation.org \
    --cc=vgoyal@redhat.com \
    --cc=ying.huang@intel.com \
    /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.