2001-02-03 22:51:35

by Andrew Tridgell

[permalink] [raw]
Subject: setting cpu speed on crusoe

Junichi Morita and I have worked out how to access the crusoe
"longrun" settings on the crusoe based VAIO. This allows you to enable
power saving mode and slow the cpu down. It should help battery life a
lot.

the following will enable power saving and set the cpu to the slowest
speed:

setpci -s 0:0.0 a8.b=11

and this will restore you to max speed:

setpci -s 0:0.0 a8.b=0e

the bits are:

LRON bit0: long run "on" - I'm not really sure what this does
LRRV bit1-3: cpu speed
LREN bit4: seems to enable variable speed

the info came from a dump of the AML off the box like this:

00001e24: Scope PCI0 (\_SB_.PCI0)
00001e30: OpRegion LRCR (\_SB_.PCI0.LRCR)
00001e36: PCI_Config
00001e37: 0xa8
00001e39: 0x04
00001e3b: Field
00001e3e: LRCR (00001e30)
00001e42: AccessType: ByteAcc; LockRule: NoLock; UpdateRule: Preserve
00001e43: NamedField (1 bits at 0x0:0) LRON
00001e48: NamedField (3 bits at 0x0:1) LRRV
00001e4d: NamedField (1 bits at 0x0:4) LREN

the patch to acpidisasm to give the bit offsets and lengths for named
fields is available from
http://www.samba.org/ftp/unpacked/picturebook/acpi.patch






2001-02-11 10:48:53

by Pavel Machek

[permalink] [raw]
Subject: Re: setting cpu speed on crusoe

Hi!

> Junichi Morita and I have worked out how to access the crusoe
> "longrun" settings on the crusoe based VAIO. This allows you to enable
> power saving mode and slow the cpu down. It should help battery life a
> lot.

There is no documentation? I thought transmeta is linux-friendly
company ;-).

Pavel

> the following will enable power saving and set the cpu to the slowest
> speed:
>
> setpci -s 0:0.0 a8.b=11
>
> and this will restore you to max speed:
>
> setpci -s 0:0.0 a8.b=0e
>
> the bits are:
>
> LRON bit0: long run "on" - I'm not really sure what this does

Did you try just asking linus?

> LRRV bit1-3: cpu speed
> LREN bit4: seems to enable variable speed


--
I'm [email protected]. "In my country we have almost anarchy and I don't care."
Panos Katsaloulis describing me w.r.t. patents at [email protected]

2001-02-13 17:35:29

by Linus Torvalds

[permalink] [raw]
Subject: Re: setting cpu speed on crusoe



On Sat, 10 Feb 2001, Pavel Machek wrote:
>
> > Junichi Morita and I have worked out how to access the crusoe
> > "longrun" settings on the crusoe based VAIO. This allows you to enable
> > power saving mode and slow the cpu down. It should help battery life a
> > lot.
>
> There is no documentation? I thought transmeta is linux-friendly
> company ;-).

We are, but the documentation we mean for internal use sometimes tends to
be in the "not good enough to be released" category.

Anyway, the register the above is touching has nothing to do with
"longrun", but with "coolrun" - it's the temperature control, not the CPU
speed control. Now, obviously, CPU speed and temperature do have tons of
things in common, which is why it gives somewhat expected results.

We're going through our docs and we have internal programs that we'll
release for this so that you'll not just have docs but actually working
code too. It just needs to be cleaned up a bit, and go through the proper
channels (ever wonder why open source gets deveoped faster?). It really
should be "any day now".

Linus

2001-02-14 14:32:19

by Ookhoi

[permalink] [raw]
Subject: Re: setting cpu speed on crusoe

Hi Daniel,

> > We're going through our docs and we have internal programs that
> > we'll release for this so that you'll not just have docs but
> > actually working code too. It just needs to be cleaned up a bit, and
> > go through the proper channels (ever wonder why open source gets
> > deveoped faster?). It really should be "any day now".
>
> Working code is better anyway (and in this case, it's first). Go to
> your favorite kernel.org mirror and check out
>
> /pub/linux/utils/cpu/crusoe/longrun-0.9.tar.gz
>
> It does everything you could ever want and more, as long as you
> include the CPUID and MSR devices in your kernel, set up the devices
> correctly, etc.

Very cool. :-) Will we also be able to do a software upgrade of the cpu
code morphing software in the future?

Ookhoi

2001-02-14 11:45:22

by Daniel Quinlan

[permalink] [raw]
Subject: Re: setting cpu speed on crusoe

Linus Torvalds <[email protected]> writes:

> We're going through our docs and we have internal programs that we'll
> release for this so that you'll not just have docs but actually working
> code too. It just needs to be cleaned up a bit, and go through the proper
> channels (ever wonder why open source gets deveoped faster?). It really
> should be "any day now".

Working code is better anyway (and in this case, it's first). Go to
your favorite kernel.org mirror and check out

/pub/linux/utils/cpu/crusoe/longrun-0.9.tar.gz

It does everything you could ever want and more, as long as you include
the CPUID and MSR devices in your kernel, set up the devices correctly,
etc.

Dan

2001-03-19 12:51:21

by Ookhoi

[permalink] [raw]
Subject: is it possible to upgrade crusoe code morphing software with linux?

Hi Daniel,

This is a message from 14 Feb.

> Linus Torvalds <[email protected]> writes:
>
> > We're going through our docs and we have internal programs that we'll
> > release for this so that you'll not just have docs but actually working
> > code too. It just needs to be cleaned up a bit, and go through the proper
> > channels (ever wonder why open source gets deveoped faster?). It really
> > should be "any day now".
>
> Working code is better anyway (and in this case, it's first). Go to
> your favorite kernel.org mirror and check out
>
> /pub/linux/utils/cpu/crusoe/longrun-0.9.tar.gz
>
> It does everything you could ever want and more, as long as you include
> the CPUID and MSR devices in your kernel, set up the devices correctly,
> etc.

longrun works great, thank you. :-)
But I read this:

http://news.cnet.com/news/0-1006-200-3665351.html

Transmeta, Intel in a battle for notebooks By Michael Kanellos
Staff Writer, CNET News.com
November 13, 2000, 2:25 p.m. PT

comdex LAS VEGAS--Transmeta and Intel will slug it out next year with
a slew of low-powered chips for notebooks.

Comdex 2000: Back to the future In the first quarter of next year,
Transmeta announced Monday, it will release version 4.2 of its
code-morphing software that significantly reduces processor power
consumption. Code-morphing software is a software layer on top of a
chip that picks up a number of the duties that would normally be
handled by the chip itself and thereby cuts power consumption.

"We made a substantial difference (in power consumption) in
essentially what is the same silicon," Dave Ditzel, Transmeta CEO,
said Monday in an interview with CNET News.com at the Comdex trade
show here.

Now I searched http://www.transmeta.com and can't find a thing about where to
get the upgrade or the tools to perform the upgrade. Are they available
somewhere or is there an eta?

dmesg:
CPU: Processor revision 1.3.1.2, 600 MHz
CPU: Code Morphing Software revision 4.1.4-7-51
CPU: 20000805 23:30 official release 4.1.4#2
CPU: Transmeta(tm) Crusoe(tm) Processor TM5600 stepping 03

I would love to upgrade to version 4.2 :-)

Thanks!

Ookhoi