From: Pavel Machek <pavel@ucw.cz>
To: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Gautham R Shenoy <ego@in.ibm.com>,
Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>,
linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org,
"Darrick J. Wong" <djwong@us.ibm.com>
Subject: Re: [PATCH v2 0/2] cpu: pseries: Offline state framework.
Date: Wed, 2 Sep 2009 22:02:14 +0200 [thread overview]
Message-ID: <20090902200214.GA1918@ucw.cz> (raw)
In-Reply-To: <1251869611.7547.38.camel@twins>
On Wed 2009-09-02 07:33:31, Peter Zijlstra wrote:
> On Fri, 2009-08-28 at 15:30 +0530, Gautham R Shenoy wrote:
> > Hi,
> >
> > This is the version 2 of the patch series to provide a cpu-offline framework
> > that enables the administrators choose the state the offline CPU must be put
> > into when multiple such states are exposed by the underlying architecture.
> >
> > Version 1 of the Patch can be found here:
> > http://lkml.org/lkml/2009/8/6/236
> >
> > The patch-series exposes the following sysfs tunables to
> > allow the system-adminstrator to choose the state of a CPU:
> >
> > To query the available hotplug states, one needs to read the sysfs tunable:
> > /sys/devices/system/cpu/cpu<number>/available_hotplug_states
> > To query or set the current state, on needs to read/write the sysfs tunable:
> > /sys/devices/system/cpu/cpu<number>/current_states
> >
> > The patchset ensures that the writes to the "current_state" sysfs file are
> > serialized against the writes to the "online" file.
> >
> > This patchset also contains the offline state driver implemented for
> > pSeries. For pSeries, we define three available_hotplug_states. They are:
> >
> > online: The processor is online.
> >
> > deallocate: This is the the default behaviour when the cpu is offlined
> > even in the absense of this driver. The CPU would call make an
> > rtas_stop_self() call and hand over the CPU back to the resource pool,
> > thereby effectively deallocating that vCPU from the LPAR.
> > NOTE: This would result in a configuration change to the LPAR
> > which is visible to the outside world.
> >
> > deactivate: This cedes the vCPU to the hypervisor which
> > in turn can put the vCPU time to the best use.
> > NOTE: This option DOES NOT result in a configuration change
> > and the vCPU would be still entitled to the LPAR to which it earlier
> > belong to.
> >
> > Awaiting your feedback.
>
> I'm still thinking this is a bad idea.
>
> The OS should only know about online/offline.
>
> Use the hypervisor interface to deal with the cpu once its offline.
>
> That is, I think this interface you propose is a layering violation.
Agreed. Plus having interface like 'go to this state during offliine'
then 'go offline' is strange/stupid. For hypervisor case, you might
want to change 'state' of cpu that is already offline.
Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
next prev parent reply other threads:[~2009-09-02 20:02 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-28 10:00 [PATCH v2 0/2] cpu: pseries: Offline state framework Gautham R Shenoy
2009-08-28 10:00 ` [PATCH v2 1/2] cpu: Offline state Framework Gautham R Shenoy
2009-09-02 4:49 ` Andrew Morton
2009-08-28 10:00 ` [PATCH v2 2/2] cpu: Implement cpu-offline-state driver for pSeries Gautham R Shenoy
2009-09-02 5:33 ` [PATCH v2 0/2] cpu: pseries: Offline state framework Peter Zijlstra
2009-09-02 20:02 ` Pavel Machek [this message]
2009-09-24 0:48 ` Benjamin Herrenschmidt
2009-09-24 7:51 ` Peter Zijlstra
2009-09-24 8:38 ` Benjamin Herrenschmidt
2009-09-24 11:33 ` Peter Zijlstra
2009-09-24 11:41 ` Arjan van de Ven
2009-09-25 7:25 ` Vaidyanathan Srinivasan
2009-09-25 7:42 ` Arjan van de Ven
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=20090902200214.GA1918@ucw.cz \
--to=pavel@ucw.cz \
--cc=a.p.zijlstra@chello.nl \
--cc=djwong@us.ibm.com \
--cc=ego@in.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=venkatesh.pallipadi@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 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).