All of lore.kernel.org
 help / color / mirror / Atom feed
From: Len Brown <lenb@kernel.org>
To: Zhao Yakui <yakui.zhao@intel.com>
Cc: linux-acpi@vger.kernel.org
Subject: Re: [PATCH 5/5] ACPI: Update the t-state for every affected cpu when t-state is changed
Date: Mon, 4 Feb 2008 18:00:25 -0500	[thread overview]
Message-ID: <200802041800.25551.lenb@kernel.org> (raw)
In-Reply-To: <1201947014.22650.44.camel@yakui_zhao.sh.intel.com>

On Saturday 02 February 2008 05:10, Zhao Yakui wrote:
> On Sat, 2008-02-02 at 02:39 -0500, Len Brown wrote:
> > On Monday 28 January 2008 00:55, Zhao Yakui wrote:
> > > Subject: ACPI : Update the t-state for every affected cpu when t-state is changed
> > > >From : Zhao Yakui <yakui.zhao@intel.com>
> > > 
> > > According to ACPI spec, the _TSD object provides T-state control cross
> > > logical processor dependency information to OSPM. So the t-state
> > > coordination should be considered when T-state for one cpu is changed.
> > > 
> > > According to ACPI spec, three types of coordination are defined.
> > > SW_ALL, SW_ANY and HW_ALL.
> > 
> > > SW_ALL: it means that OSPM needs to initiate T-state transition on 
> > > all processors in the domain. It is necessary to call throttling set function
> > > for all affected cpus.
> > 
> > > SW_ANY: it means that OSPM may initiate T-state transition on any processor in 
> > > the domain. 
> > 
> > > HW_ALL: Apec only says that hardware will perform the coordination and doesn't 
> > > recommend how OSPM coordinate T-state among the affected cpus. So it is treated
> > > as the type of SW_ALL. It means that OSPM needs to initiate t-state transition
> > > on all the processors in the domain.
> > 
> > Not really. HW_ALL means that the OS can assume that the CPUs are independent,
> > and hardware will take care of any coordination needed. 
>  Hardware will be responsible for coordinating the state transition
> between multiple processors. But hardware should provide OSPM with a
> means to determine the actual state residency so that the correct state
> is entered. 

The OS has ACNT/MCNT to find the actual frequency.
We use it already in the P-state code to detect when the hardware does
soemthing funky with P-state, such as HW coordination,
TM1/TM2, or turbo mode.

> > 
> > ie. the OS should implement throttling changes on each CPU depending
> > only on that CPU's needs and not need to consider any effects on other CPUs.
> > 
> > This is not the same as SW_ALL, which tells us that all the CPUS in a domain
> > are _dependent_, and the OS must enforce that by writing the _same_ value
> > to each CPU. 
> > 
> > say you have a domain with 2 CPUS.
> > If it is HW_ALL and you throttle one cpu, then you are done. 
>    In this case , how to update the state of another cpu? Can it be
> treated as SW_ANY?  

That is the whole point of HW_ALL -- you don't have to worry
about the "other" CPU, you worry just about your local decisions
and the HW takes care of any dependencies.

> > if it is SW_ALL then if you want to throttle one cpu, then you must
> > also throttle the other. 
>    I agree. It is necessary to initiate the state transition for every
> affected cpu. 

thanks,
-Len


  reply	other threads:[~2008-02-04 23:00 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-28  5:55 [PATCH 5/5] ACPI: Update the t-state for every affected cpu when t-state is changed Zhao Yakui
2008-02-02  7:39 ` Len Brown
2008-02-02 10:10   ` Zhao Yakui
2008-02-04 23:00     ` Len Brown [this message]
2008-02-02  8:53 ` Len Brown
2008-02-02 13:04   ` Zhao, Yakui

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=200802041800.25551.lenb@kernel.org \
    --to=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=yakui.zhao@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.