Hi,
attached patch against 2.6.9-rc2 fixes cpufrequency scaling after resume
on pmacs. Please apply.
-- Guido
Signed-off-by: Guido Guenther <[email protected]>
--- linux-2.6.9-rc2.orig/arch/ppc/platforms/pmac_cpufreq.c 2004-09-15 09:22:54.000000000 +0200
+++ linux-2.6.9-rc2/arch/ppc/platforms/pmac_cpufreq.c 2004-09-28 14:36:20.265785384 +0200
@@ -366,12 +367,26 @@
return 0x50 + (*reg);
}
+static unsigned int __pmac pmac_cpufreq_get(unsigned int cpu)
+{
+ if (cpu)
+ return -ENODEV;
+ return cur_freq;
+}
+
+static struct freq_attr* pmac_cpufreq_attr[] = {
+ &cpufreq_freq_attr_scaling_available_freqs,
+ NULL,
+};
+
static struct cpufreq_driver pmac_cpufreq_driver = {
.verify = pmac_cpufreq_verify,
.target = pmac_cpufreq_target,
.init = pmac_cpufreq_cpu_init,
+ .get = pmac_cpufreq_get,
.name = "powermac",
.owner = THIS_MODULE,
+ .attr = pmac_cpufreq_attr,
};
On Tue, 2004-09-28 at 22:40, Guido Guenther wrote:
> Hi,
> attached patch against 2.6.9-rc2 fixes cpufrequency scaling after resume
> on pmacs. Please apply.
It's actually still not clear wether we resume at the same speed we
had when going to sleep .. especially in the PMU cpufreq case...
I didn't have time to experiment with this yet tho.
Ben.
On Wed, Sep 29, 2004 at 10:41:14PM +1000, Benjamin Herrenschmidt wrote:
> On Tue, 2004-09-28 at 22:40, Guido Guenther wrote:
> > Hi,
> > attached patch against 2.6.9-rc2 fixes cpufrequency scaling after resume
> > on pmacs. Please apply.
>
> It's actually still not clear wether we resume at the same speed we
> had when going to sleep .. especially in the PMU cpufreq case...
Thought about this too, especially since my pbook comes up with the
lower frequency after pmdisk resume. Can you think of a simple way to
read the current frequency that works an all currently supported models?
Cheers,
-- Guido
On Thu, 2004-09-30 at 17:39, Guido Guenther wrote:
> On Wed, Sep 29, 2004 at 10:41:14PM +1000, Benjamin Herrenschmidt wrote:
> > On Tue, 2004-09-28 at 22:40, Guido Guenther wrote:
> > > Hi,
> > > attached patch against 2.6.9-rc2 fixes cpufrequency scaling after resume
> > > on pmacs. Please apply.
> >
> > It's actually still not clear wether we resume at the same speed we
> > had when going to sleep .. especially in the PMU cpufreq case...
> Thought about this too, especially since my pbook comes up with the
> lower frequency after pmdisk resume. Can you think of a simple way to
> read the current frequency that works an all currently supported models?
Nope, unfortunately...
Ben.
On Thu, Sep 30, 2004 at 05:48:41PM +1000, Benjamin Herrenschmidt wrote:
> On Thu, 2004-09-30 at 17:39, Guido Guenther wrote:
> > On Wed, Sep 29, 2004 at 10:41:14PM +1000, Benjamin Herrenschmidt wrote:
> > > On Tue, 2004-09-28 at 22:40, Guido Guenther wrote:
> > > > Hi,
> > > > attached patch against 2.6.9-rc2 fixes cpufrequency scaling after resume
> > > > on pmacs. Please apply.
> > >
> > > It's actually still not clear wether we resume at the same speed we
> > > had when going to sleep .. especially in the PMU cpufreq case...
> > Thought about this too, especially since my pbook comes up with the
> > lower frequency after pmdisk resume. Can you think of a simple way to
> > read the current frequency that works an all currently supported models?
>
> Nope, unfortunately...
Should the patch be applied anyway, it still way better than the current
situation.
Cheers,
-- Guido