From: Sebastien Dugue <sebastien.dugue@bull.net>
To: Paul Mackerras <paulus@samba.org>
Cc: linux-ppc <linuxppc-dev@ozlabs.org>,
Will Schmidt <will_schmidt@vnet.ibm.com>,
Jean Pierre Dion <jean-pierre.dion@bull.net>,
Gilles Carry <Gilles.Carry@ext.bull.net>
Subject: Re: [PATCH] powerpc/pseries: fix idle sleep early exit state
Date: Wed, 3 Dec 2008 11:07:10 +0100 [thread overview]
Message-ID: <20081203110710.2be536e8@bull.net> (raw)
In-Reply-To: <18742.21422.999737.179325@cargo.ozlabs.ibm.com>
On Wed, 3 Dec 2008 20:38:54 +1100 Paul Mackerras <paulus@samba.org> wrote:
> Sebastien Dugue writes:
>
> > In pseries_dedicated_idle_sleep(), if we need to exit idle during the
> > snooze period (i.e. need_resched or cpu has been offlined), then we should
> > re-disable the interrupts and clear TIF_POLLING_NRFLAG before leaving.
>
> Are you doing this because of a bug you actually observed, or did you
> just find this by inspection?
By inspection, and just to be consistent with the other way out. But
you're right, it's not really necessary here.
> I don't believe it's necessary to do
> these things (disabling interrupts, clearing TIF_POLLING_NRFLAG)
> because the code that calls it immediately reenables interrupts and
> sets TIF_POLLING_NRFLAG again. From arch/powerpc/kernel/idle.c (line
> 73):
>
> if (!need_resched() && !cpu_should_die())
> ppc_md.power_save();
>
> local_irq_enable();
> set_thread_flag(TIF_POLLING_NRFLAG);
>
> Paul.
>
Thanks,
Sebastien.
prev parent reply other threads:[~2008-12-03 10:07 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-27 14:52 [PATCH] powerpc/pseries: fix idle sleep early exit state Sebastien Dugue
2008-12-03 9:38 ` Paul Mackerras
2008-12-03 10:07 ` Sebastien Dugue [this message]
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=20081203110710.2be536e8@bull.net \
--to=sebastien.dugue@bull.net \
--cc=Gilles.Carry@ext.bull.net \
--cc=jean-pierre.dion@bull.net \
--cc=linuxppc-dev@ozlabs.org \
--cc=paulus@samba.org \
--cc=will_schmidt@vnet.ibm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).