From owner-acpi-jp@jp.FreeBSD.org Wed Mar 24 08:11:42 2004
Received: (from daemon@localhost)
	by castle.jp.FreeBSD.org (8.11.6p2+3.4W/8.11.3) id i2NNBgZ64924;
	Wed, 24 Mar 2004 08:11:42 +0900 (JST)
	(envelope-from owner-acpi-jp@jp.FreeBSD.org)
Received: from mta4-svc.business.ntl.com (mta4-svc.business.ntl.com [62.253.164.44])
	by castle.jp.FreeBSD.org (8.11.6p2+3.4W/8.11.3) with ESMTP/inet id i2NNBfd64919
	for <acpi-jp@jp.FreeBSD.org>; Wed, 24 Mar 2004 08:11:41 +0900 (JST)
	(envelope-from bruce@cran.org.uk)
Received: from box1.cran ([82.2.88.163]) by mta4-svc.business.ntl.com
          (InterMail vM.4.01.03.37 201-229-121-137-20020806) with ESMTP
          id <20040323231133.ZINU9319.mta4-svc.business.ntl.com@box1.cran>
          for <acpi-jp@jp.FreeBSD.org>; Tue, 23 Mar 2004 23:11:33 +0000
Received: from box1.cran (localhost.cran [127.0.0.1])
	by box1.cran (8.12.11/8.12.11) with ESMTP id i2NN9mYE025262
	for <acpi-jp@jp.FreeBSD.org>; Tue, 23 Mar 2004 23:09:48 GMT
	(envelope-from brucec@box1.cran)
Received: (from brucec@localhost)
	by box1.cran (8.12.11/8.12.11/Submit) id i2NN9lVW025261
	for acpi-jp@jp.FreeBSD.org; Tue, 23 Mar 2004 23:09:47 GMT
	(envelope-from brucec)
From: Bruce Cran <bruce@cran.org.uk>
To: acpi-jp@jp.FreeBSD.org
Message-ID: <20040323230947.GA778@box1.cran>
References: <20040316143411.GA4468@portege.clkao.org> <20040316100826.S95770@root.org>
Mime-Version: 1.0
Content-Type: multipart/mixed; boundary="7JfCtLOvnd9MIVvH"
Content-Disposition: inline
In-Reply-To: <20040316100826.S95770@root.org>
User-Agent: Mutt/1.5.6i
Reply-To: acpi-jp@jp.FreeBSD.org
Precedence: list
Date: Tue, 23 Mar 2004 23:09:47 +0000
X-Sequence: acpi-jp 3141
Subject: [acpi-jp 3141] Re: acpi FADT and throttle problems
Sender: owner-acpi-jp@jp.FreeBSD.org
X-Originator: bruce@cran.org.uk
X-Distribute: distribute version 2.1 (Alpha) patchlevel 24e+040307


--7JfCtLOvnd9MIVvH
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

On Tue, Mar 16, 2004 at 10:10:36AM -0800, Nate Lawson wrote:
> On Tue, 16 Mar 2004, Chia-liang Kao wrote:
> > I have some problems with throttling my Toshiba 3490.
> >
> > acpidump -t shows me: DUTY_OFFSET=1, DUTY_WIDTH=0 in FADT, so i don't
> > have the hw.acpi.throttle MIB at all. while my dmesg says:
> > CPU: Intel Pentium III (500.02-MHz 686-class CPU)
> >   Origin = "GenuineIntel"  Id = 0x686  Stepping = 6
> >
> > So it looks like it should be able to trottle. Is it possible to
> > override the FADT or fix it somehow?
> 
> Throttling is related to the chipset as well as CPU.  The system designer
> specified 0 for the width for a reason.  You should try the acpi_toshiba
> driver.  It provides throttling sysctls of its own.  If you absolutely
> have to try ACPI throttling, you can just remove the check for cpu_width
> == 0 in acpi_cpu.c.
> 
> -Nate

I'm seeing a regression in the new ACPI system on my Dell Inpiron 8500.  It
has a 2GHz P4-M, which has the standard 8 steps from 100-8.5%.   It used
to throttle, but now it stays at full speed whatever I set 
hw.acpi.cpu.throttle_state to.   I can confirm this by running a program which
basically does:

volatile uint64_t tsc1, tsc2;
asm("rdtsc" : "=A" (tsc1));
sleep(1);
asm("rdtsc" : "=A" (tsc2));
printf("cpu clock is running at %lluHz\n", tsc2-tsc1);

It's just a quick hack, but I've seen it stay permanently 
around 2 billion when running normally, and 1.2 billion
when I disable SpeedStep in the BIOS setup.   When I unplug
the AC, I get a message about performance states changing, but
nothing else happens - in particular, none of the sysctls are 
changed.

I've attached the dmesg, I can also obtain the AML if needed.

--
Bruce Cran  

--7JfCtLOvnd9MIVvH
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="dmesg.txt"

Copyright (c) 1992-2004 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
	The Regents of the University of California. All rights reserved.
FreeBSD 5.2-CURRENT #0: Sun Mar 21 02:20:14 GMT 2004
    brucec@box2.cran:/usr/obj/usr/src/sys/MYKERNEL
Preloaded elf kernel "/boot/kernel/kernel" at 0xc0965000.
Preloaded elf module "/boot/modules/nvidia.ko" at 0xc09651cc.
Preloaded elf module "/boot/kernel/linux.ko" at 0xc0965278.
Preloaded elf module "/boot/kernel/acpi.ko" at 0xc0965324.
Timecounter "i8254" frequency 1193182 Hz quality 0
CPU: Mobile Intel(R) Pentium(R) 4 - M CPU 2.00GHz (1196.48-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf27  Stepping = 7
  Features=0xbfebf9ff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
real memory  = 536535040 (511 MB)
avail memory = 515301376 (491 MB)
Pentium Pro MTRR support enabled
cpu0 on motherboard
npx0: [FAST]
npx0: <math processor> on motherboard
npx0: INT 16 interface
acpi0: <DELL CPi R  > on motherboard
pcibios: BIOS version 2.10
Found $PIR table, 9 entries at 0xc00fc590
Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000
acpi_timer0: <24-bit timer at 3.579545MHz> port 0x808-0x80b on acpi0
acpi_cpu0: <CPU> on acpi0
acpi_tz0: <Thermal Zone> on acpi0
acpi_acad0: <AC Adapter> on acpi0
acpi_cmbat0: <Control Method Battery> on acpi0
acpi_cmbat1: <Control Method Battery> on acpi0
acpi_lid0: <Control Method Lid Switch> on acpi0
acpi_button0: <Power Button> on acpi0
acpi_button1: <Sleep Button> on acpi0
pcib0: <ACPI Host-PCI bridge> port 0xcf8-0xcff on acpi0
pci0: <ACPI PCI bus> on pcib0
pcib0: slot 29 INTA is routed to irq 11
pcib0: slot 29 INTB is routed to irq 11
pcib0: slot 29 INTC is routed to irq 11
pcib0: slot 29 INTD is routed to irq 11
pcib0: slot 31 INTB is routed to irq 11
pcib0: slot 31 INTB is routed to irq 11
agp0: <Intel 82845 host to AGP bridge> mem 0xe8000000-0xefffffff at device 0.0 on pci0
pcib1: <ACPI PCI-PCI bridge> at device 1.0 on pci0
pci1: <ACPI PCI bus> on pcib1
pcib1: slot 0 INTA is routed to irq 11
nvidia0: <GeForce4 4200 Go> mem 0xf0000000-0xf3ffffff,0xfc000000-0xfcffffff irq 11 at device 0.0 on pci1
uhci0: <Intel 82801DB (ICH4) USB controller USB-A> port 0xbf80-0xbf9f irq 11 at device 29.0 on pci0
usb0: <Intel 82801DB (ICH4) USB controller USB-A> on uhci0
usb0: USB revision 1.0
uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
uhci1: <Intel 82801DB (ICH4) USB controller USB-B> port 0xbf40-0xbf5f irq 11 at device 29.1 on pci0
usb1: <Intel 82801DB (ICH4) USB controller USB-B> on uhci1
usb1: USB revision 1.0
uhub1: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub1: 2 ports with 2 removable, self powered
uhci2: <Intel 82801DB (ICH4) USB controller USB-C> port 0xbf20-0xbf3f irq 11 at device 29.2 on pci0
usb2: <Intel 82801DB (ICH4) USB controller USB-C> on uhci2
usb2: USB revision 1.0
uhub2: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub2: 2 ports with 2 removable, self powered
ehci0: <EHCI (generic) USB 2.0 controller> mem 0xf4fffc00-0xf4ffffff irq 11 at device 29.7 on pci0
ehci_pci_attach: companion usb0
ehci_pci_attach: companion usb1
ehci_pci_attach: companion usb2
usb3: EHCI version 1.0
usb3: companion controllers, 2 ports each: usb0 usb1 usb2
usb3: <EHCI (generic) USB 2.0 controller> on ehci0
usb3: USB revision 2.0
uhub3: (0x8086) EHCI root hub, class 9/0, rev 2.00/1.00, addr 1
uhub3: 6 ports with 6 removable, self powered
pcib2: <ACPI PCI-PCI bridge> at device 30.0 on pci0
pci2: <ACPI PCI bus> on pcib2
pcib2: slot 0 INTA is routed to irq 11
pcib2: slot 1 INTA is routed to irq 11
bfe0: <Broadcom BCM4401 Fast Ethernet> mem 0xfaffe000-0xfaffffff irq 11 at device 0.0 on pci2
miibus0: <MII bus> on bfe0
bmtphy0: <BCM4401 10/100baseTX PHY> on miibus0
bmtphy0:  10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
bfe0: Ethernet address: 00:0b:db:19:0b:2d
cbb0: <TI4510 PCI-CardBus Bridge> at device 1.0 on pci2
cardbus0: <CardBus bus> on cbb0
pccard0: <16-bit PCCard bus> on cbb0
pcib2: slot 1 INTA is routed to irq 11
cbb0: [MPSAFE]
fwohci0: vendor=104c, dev=8029
fwohci0: <1394 Open Host Controller Interface> mem 0xfaff8000-0xfaffbfff,0xfaffd800-0xfaffdfff irq 11 at device 1.1 on pci2
fwohci0: OHCI version 1.10 (ROM=0)
fwohci0: No. of Isochronous channel is 4.
fwohci0: EUI64 36:4f:c0:00:0c:4a:54:10
fwohci0: Phy 1394a available S400, 2 ports.
fwohci0: Link S400, max_rec 2048 bytes.
firewire0: <IEEE1394(FireWire) bus> on fwohci0
sbp0: <SBP-2/SCSI over FireWire> on firewire0
fwohci0: Initiate bus reset
fwohci0: node_id=0xc800ffc0, gen=1, CYCLEMASTER mode
firewire0: 1 nodes, maxhop <= 0, cable IRM = 0 (me)
firewire0: bus manager 0 (me)
isab0: <PCI-ISA bridge> at device 31.0 on pci0
isa0: <ISA bus> on isab0
atapci0: <Intel ICH4 UDMA100 controller> port 0xbfa0-0xbfaf,0x374-0x377,0x170-0x177,0x3f4-0x3f7,0x1f0-0x1f7 at device 31.1 on pci0
ata0: at 0x1f0 irq 14 on atapci0
ata0: [MPSAFE]
ata1: at 0x170 irq 15 on atapci0
ata1: [MPSAFE]
pci0: <multimedia, audio> at device 31.5 (no driver attached)
pci0: <simple comms> at device 31.6 (no driver attached)
atkbdc0: <Keyboard controller (i8042)> port 0x64,0x60 irq 1 on acpi0
atkbd0: <AT Keyboard> flags 0x1 irq 1 on atkbdc0
kbd0 at atkbd0
psm0: <PS/2 Mouse> irq 12 on atkbdc0
psm0: model GlidePoint, device ID 0
sio0 port 0x3f8-0x3ff irq 4 on acpi0
sio0: type 16550A
sio1 port 0x280-0x287,0x2f8-0x2ff irq 3 drq 3 on acpi0
sio1: type 16550A
ppc0 port 0x778-0x77b,0x378-0x37f irq 7 drq 1 on acpi0
ppc0: SMC-like chipset (ECP/EPP/PS2/NIBBLE) in COMPATIBLE mode
ppc0: FIFO with 16/16/8 bytes threshold
ppbus0: <Parallel port bus> on ppc0
lpt0: <Printer> on ppbus0
lpt0: Interrupt-driven port
ppi0: <Parallel I/O> on ppbus0
orm0: <Option ROMs> at iomem 0xcf800-0xcffff,0xc0000-0xcf7ff on isa0
pmtimer0 on isa0
sc0: <System console> at flags 0x100 on isa0
sc0: VGA <16 virtual consoles, flags=0x300>
vga0: <Generic ISA VGA> at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0
Timecounter "TSC" frequency 1196476884 Hz quality 800
Timecounters tick every 10.000 msec
acpi_cpu: throttling enabled, 8 steps (100% to 12.5%), currently 100.0%
acpi_cpu0: Performance states changed
ad0: 28615MB <HITACHI_DK23EA-30> [58140/16/63] at ata0-master UDMA100
acd0: DVDROM <TOSHIBA DVD-ROM SD-C2612> at ata1-master PIO4
Mounting root from ufs:/dev/ad0s1a
wi0: <MELCO WLI-PCM-L11> at port 0x100-0x13f irq 11 function 0 config 1 on pccard0
wi0: using Lucent Technologies, WaveLAN/IEEE
wi0: Lucent Firmware: Station (8.36.1)
wi0: Ethernet address: 00:02:2d:91:fa:9b
wi0: 11b rates: 1Mbps 2Mbps 5.5Mbps 11Mbps

--7JfCtLOvnd9MIVvH--
