cpufreq Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [RFC] cpufreq_get()
@ 2004-01-22 19:06 Ducrot Bruno
  2004-01-22 20:56 ` Dominik Brodowski
  0 siblings, 1 reply; 4+ messages in thread
From: Ducrot Bruno @ 2004-01-22 19:06 UTC (permalink / raw)
  To: cpufreq

I'm planing to add the cpufreq_get() in struct cpufreq_driver,
but in a hardware fashion, eventually replacing the name by
something more appropriate.

Rational:
- almost all drivers that I know (powernow-k7, speedstep-*,
  longrun, and Im looking the PPC version) can implement it,
  the only one that I am aware for which it is not possible is
  the ACPI performance IO driver.

- by accessing driver->cpufreq_get() via a sysfs, we can verify if
  the 3 mains governors works.  Even for longrun, we
  can verify that the frequency is between min and max.

- we can compare /proc/cpuinfo with the result of cpufreq_get(),
  helping in debugging things.

- people may want to monitor the real frequency in their applet,
  so this help for having a more consistent API (google for 
  wmlongrun, for example).

- It is required for the ARM architecture anyway.

-- 
Ducrot Bruno

--  Which is worse:  ignorance or apathy?
--  Don't know.  Don't care.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RFC] cpufreq_get()
  2004-01-22 19:06 [RFC] cpufreq_get() Ducrot Bruno
@ 2004-01-22 20:56 ` Dominik Brodowski
  2004-01-23 10:03   ` Ducrot Bruno
  0 siblings, 1 reply; 4+ messages in thread
From: Dominik Brodowski @ 2004-01-22 20:56 UTC (permalink / raw)
  To: Ducrot Bruno; +Cc: cpufreq


[-- Attachment #1.1: Type: text/plain, Size: 498 bytes --]

On Thu, Jan 22, 2004 at 08:06:49PM +0100, Ducrot Bruno wrote:
> I'm planing to add the cpufreq_get() in struct cpufreq_driver,
> but in a hardware fashion, eventually replacing the name by
> something more appropriate.

I appreciate this suggestion.

>   Even for longrun, we
>   can verify that the frequency is between min and max.

For ->range() drivers [I intend to rename ->setpolicy() to ->range()], we
should leave the ->get() function optional in case the speed isn't
detectable.

	Dominik

[-- Attachment #1.2: Type: application/pgp-signature, Size: 189 bytes --]

[-- Attachment #2: Type: text/plain, Size: 143 bytes --]

_______________________________________________
Cpufreq mailing list
Cpufreq@www.linux.org.uk
http://www.linux.org.uk/mailman/listinfo/cpufreq

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RFC] cpufreq_get()
  2004-01-22 20:56 ` Dominik Brodowski
@ 2004-01-23 10:03   ` Ducrot Bruno
  2004-01-24 20:34     ` Dominik Brodowski
  0 siblings, 1 reply; 4+ messages in thread
From: Ducrot Bruno @ 2004-01-23 10:03 UTC (permalink / raw)
  To: cpufreq

On Thu, Jan 22, 2004 at 09:56:20PM +0100, Dominik Brodowski wrote:
> On Thu, Jan 22, 2004 at 08:06:49PM +0100, Ducrot Bruno wrote:
> > I'm planing to add the cpufreq_get() in struct cpufreq_driver,
> > but in a hardware fashion, eventually replacing the name by
> > something more appropriate.
> 
> I appreciate this suggestion.

Fine.

> 
> >   Even for longrun, we
> >   can verify that the frequency is between min and max.
> 
> For ->range() drivers [I intend to rename ->setpolicy() to ->range()], we
> should leave the ->get() function optional in case the speed isn't
> detectable.

Anyway, this must be optional because the ACPI performance driver can't
detect speed...

-- 
Ducrot Bruno

--  Which is worse:  ignorance or apathy?
--  Don't know.  Don't care.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RFC] cpufreq_get()
  2004-01-23 10:03   ` Ducrot Bruno
@ 2004-01-24 20:34     ` Dominik Brodowski
  0 siblings, 0 replies; 4+ messages in thread
From: Dominik Brodowski @ 2004-01-24 20:34 UTC (permalink / raw)
  To: Ducrot Bruno; +Cc: cpufreq


[-- Attachment #1.1: Type: text/plain, Size: 270 bytes --]

On Fri, Jan 23, 2004 at 11:03:34AM +0100, Ducrot Bruno wrote:
> Anyway, this must be optional because the ACPI performance driver can't
> detect speed...

The hardware variant, yes. But for ACPI we can return what the cpufreq core
thinks the current speed is.

	Dominik

[-- Attachment #1.2: Type: application/pgp-signature, Size: 189 bytes --]

[-- Attachment #2: Type: text/plain, Size: 143 bytes --]

_______________________________________________
Cpufreq mailing list
Cpufreq@www.linux.org.uk
http://www.linux.org.uk/mailman/listinfo/cpufreq

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-01-24 20:34 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-01-22 19:06 [RFC] cpufreq_get() Ducrot Bruno
2004-01-22 20:56 ` Dominik Brodowski
2004-01-23 10:03   ` Ducrot Bruno
2004-01-24 20:34     ` Dominik Brodowski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox