From owner-freebsd-mobile@FreeBSD.ORG Mon Jan 2 03:28:35 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DBF741065670; Mon, 2 Jan 2012 03:28:35 +0000 (UTC) (envelope-from jhs@berklix.com) Received: from tower.berklix.org (tower.berklix.org [83.236.223.114]) by mx1.freebsd.org (Postfix) with ESMTP id 03DD48FC0A; Mon, 2 Jan 2012 03:28:34 +0000 (UTC) Received: from mart.js.berklix.net (pD9FBFB57.dip.t-dialin.net [217.251.251.87]) (authenticated bits=0) by tower.berklix.org (8.14.2/8.14.2) with ESMTP id q023EQrW066088; Mon, 2 Jan 2012 03:14:27 GMT (envelope-from jhs@berklix.com) Received: from fire.js.berklix.net (fire.js.berklix.net [192.168.91.41]) by mart.js.berklix.net (8.14.3/8.14.3) with ESMTP id q023ELaq092362; Mon, 2 Jan 2012 04:14:22 +0100 (CET) (envelope-from jhs@berklix.com) Received: from fire.js.berklix.net (localhost [127.0.0.1]) by fire.js.berklix.net (8.14.4/8.14.4) with ESMTP id q023DdG2051231; Mon, 2 Jan 2012 04:13:45 +0100 (CET) (envelope-from jhs@fire.js.berklix.net) Message-Id: <201201020313.q023DdG2051231@fire.js.berklix.net> To: mobile@freebsd.org From: "Julian H. Stacey" Organization: http://www.berklix.com BSD Linux Unix Consultancy, Munich Germany User-agent: EXMH on FreeBSD http://www.berklix.com/free/ X-URL: http://www.berklix.com/~jhs/cv/ Date: Mon, 02 Jan 2012 04:13:38 +0100 Sender: jhs@berklix.com Cc: mav@freebsd.org, Gary Jennejohn , "Clive Ashbolt \(Work\)" , "Julian H. Stacey" , Boris Kochergin , brucec@freebsd.org Subject: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Jan 2012 03:28:35 -0000 Hi mobile@freebsd.org, CC a few others. I propose to hack src/usr.sbin/powerd/powerd.c To import temperatures via sysctl, & if too high, to forcibly reduce CPU frequency, even if CPU load is high, because my new HP Pavillion notebook keeps over heating & crashing. dmesg & sysctl etc diagnostics at http://berklix.com/~jhs/hardware/hp/pavilion/dm3-1155ea/ CPU: AMD Athlon(tm) Neo X2 Dual Core Processor L335 (1595.96-MHz K8-class CPU) Origin = "AuthenticAMD" Id = 0x60fb2 Family = f Model = 6b Stepping = 2 Is this re-inventing the wheel ? Anyone else out there working on or know of similar code ? mgdiff 8.2-RELEASE/src/usr.sbin/powerd/powerd.c \ /pub/FreeBSD/branches/-current/src/usr.sbin/powerd/powerd.c does not show a lot of difference. >From http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.sbin/powerd/powerd.c I added a few people to CC particularly mav@ has an interesting comment Wed Jun 16 15:09:45 2010 UTC ( Freq sysctls are quite heavy due to set of malloc()/free() calls. Avoid reading current frequency on every period. Instead do it only after changing and periodically from time to time if somebody else change it. Also dynamically decrease sampling frequency up to 4 times on inactivity, Gary J: there's a comment at Fri Jan 9 22:10:07 2009 re. more then 2 CPUs I added Clive who may have some URL to CPU temps. To /boot/loader.conf I just added acpi_hp_load="YES" (after reboot) does not produce /dev/hpcmi Running 80% idle (just a fsck_ufs) I see: hw.acpi.thermal.tz0.temperature: 67.0C dev.acpi_hp.0.hdd_temperature: 4 Cheers, Julian -- Julian Stacey, BSD Unix Linux C Sys Eng Consultants Munich http://berklix.com Reply below not above, cumulative like a play script, & indent with "> ". Format: Plain text. Not HTML, multipart/alternative, base64, quoted-printable. From owner-freebsd-mobile@FreeBSD.ORG Mon Jan 2 04:00:50 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 93257106566B for ; Mon, 2 Jan 2012 04:00:50 +0000 (UTC) (envelope-from ume@mahoroba.org) Received: from mail.mahoroba.org (ent.mahoroba.org [IPv6:2001:2f0:104:8010::1]) by mx1.freebsd.org (Postfix) with ESMTP id 6E29B8FC08 for ; Mon, 2 Jan 2012 04:00:48 +0000 (UTC) Received: from yuga.mahoroba.org (ume@yuga.mahoroba.org [IPv6:2001:2f0:104:8010:7258:12ff:fe22:d94b]) (user=ume mech=DIGEST-MD5 bits=0) by mail.mahoroba.org (8.14.5/8.14.5) with ESMTP/inet6 id q0240CVZ041572 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 2 Jan 2012 13:00:16 +0900 (JST) (envelope-from ume@mahoroba.org) Date: Mon, 02 Jan 2012 13:00:11 +0900 Message-ID: From: Hajimu UMEMOTO To: "Julian H. Stacey" In-Reply-To: <201201020313.q023DdG2051231@fire.js.berklix.net> References: <201201020313.q023DdG2051231@fire.js.berklix.net> User-Agent: xcite1.60> Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?ISO-2022-JP-2?B?R29qGyQoRCtXGyhC?=) APEL/10.8 Emacs/23.3 (i386-portbld-freebsd9.0) MULE/6.0 (HANACHIRUSATO) X-Operating-System: FreeBSD 9.0-PRERELEASE X-PGP-Key: http://www.imasy.or.jp/~ume/publickey.asc X-PGP-Fingerprint: 1F00 0B9E 2164 70FC 6DC5 BF5F 04E9 F086 BF90 71FE Organization: Internet Mutual Aid Society, YOKOHAMA MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (mail.mahoroba.org [IPv6:2001:2f0:104:8010::1]); Mon, 02 Jan 2012 13:00:20 +0900 (JST) X-Virus-Scanned: clamav-milter 0.97.3 at asuka.mahoroba.org X-Virus-Status: Clean X-Spam-Status: No, score=-4.2 required=5.0 tests=ALL_TRUSTED,BAYES_00, RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on asuka.mahoroba.org Cc: mav@freebsd.org, Gary Jennejohn , "Clive Ashbolt \(Work\)" , Boris Kochergin , mobile@freebsd.org, brucec@freebsd.org Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Jan 2012 04:00:50 -0000 Hi, >>>>> On Mon, 02 Jan 2012 04:13:38 +0100 >>>>> "Julian H. Stacey" said: jhs> I propose to hack src/usr.sbin/powerd/powerd.c jhs> To import temperatures via sysctl, & if too high, to forcibly jhs> reduce CPU frequency, even if CPU load is high, jhs> because my new HP Pavillion notebook keeps over heating & crashing. jhs> dmesg & sysctl etc diagnostics at jhs> http://berklix.com/~jhs/hardware/hp/pavilion/dm3-1155ea/ jhs> CPU: AMD Athlon(tm) Neo X2 Dual Core Processor L335 (1595.96-MHz K8-class CPU) jhs> Origin = "AuthenticAMD" Id = 0x60fb2 Family = f Model = 6b Stepping = 2 jhs> Is this re-inventing the wheel ? jhs> Anyone else out there working on or know of similar code ? Yes, it is implemented already in the kernel, and it should be done by the ACPI passive cooling. It seems to me that your ACPI BIOS has it, and when the temperature of your CPU become over 90.0C, it will effect. hw.acpi.thermal.tz0.temperature: 67.0C hw.acpi.thermal.tz0.active: -1 hw.acpi.thermal.tz0.passive_cooling: 1 hw.acpi.thermal.tz0.thermal_flags: 0 hw.acpi.thermal.tz0._PSV: 90.0C hw.acpi.thermal.tz0._HOT: 95.0C hw.acpi.thermal.tz0._CRT: 100.0C hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 hw.acpi.thermal.tz0._TC1: 2 hw.acpi.thermal.tz0._TC2: 3 hw.acpi.thermal.tz0._TSP: 40 However, I'm not sure why your notebook keeps over heating & crashing. Sincerely, -- Hajimu UMEMOTO @ Internet Mutual Aid Society Yokohama, Japan ume@mahoroba.org ume@{,jp.}FreeBSD.org http://www.imasy.org/~ume/ From owner-freebsd-mobile@FreeBSD.ORG Mon Jan 2 06:27:33 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 99B8F106564A; Mon, 2 Jan 2012 06:27:33 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from sola.nimnet.asn.au (paqi.nimnet.asn.au [115.70.110.159]) by mx1.freebsd.org (Postfix) with ESMTP id D07348FC16; Mon, 2 Jan 2012 06:27:32 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by sola.nimnet.asn.au (8.14.2/8.14.2) with ESMTP id q025q0wk040648; Mon, 2 Jan 2012 16:52:01 +1100 (EST) (envelope-from smithi@nimnet.asn.au) Date: Mon, 2 Jan 2012 16:52:00 +1100 (EST) From: Ian Smith To: "Julian H. Stacey" In-Reply-To: <201201020313.q023DdG2051231@fire.js.berklix.net> Message-ID: <20120102153310.A66248@sola.nimnet.asn.au> References: <201201020313.q023DdG2051231@fire.js.berklix.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: Alexander Motin , brucec@freebsd.org, mobile@freebsd.org, Hajimu UMEMOTO Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Jan 2012 06:27:33 -0000 On Mon, 2 Jan 2012 04:13:38 +0100, Julian H. Stacey wrote: > Hi mobile@freebsd.org, CC a few others. Hi Julian. Trimmed some, added ume@, feel free .. > I propose to hack src/usr.sbin/powerd/powerd.c > To import temperatures via sysctl, & if too high, to forcibly > reduce CPU frequency, even if CPU load is high, > because my new HP Pavillion notebook keeps over heating & crashing. As ume@ points out, passive cooling _should_ be handling this, and in any case - even if you get a forced shutdown at CRT temp. - it shouldn't be 'crashing'. Please elaborate on 'crashing'? and at what sort of temperature this occurs? > dmesg & sysctl etc diagnostics at > http://berklix.com/~jhs/hardware/hp/pavilion/dm3-1155ea/ > CPU: AMD Athlon(tm) Neo X2 Dual Core Processor L335 (1595.96-MHz K8-class CPU) > Origin = "AuthenticAMD" Id = 0x60fb2 Family = f Model = 6b Stepping = 2 Almost too much info :) esp. with sysctl -a including the verbose dmesg, but I noticed a couple of things on a quick skim. If you run powerd -v, what sort of freqs does it usually run at, when more or less idle? Are you using default powerd settings? When running on battery can you monitor power use with acpiconf -i0 to see the actual effect on power usage of running at various lower freqs? I see dev.powernow.0.freq_settings: 1592/100000 796/35457 ie just two speeds, with dmesg showing: acpi_throttle0: on cpu0 acpi_throttle0: P_CNT from P_BLK 0x410 powernow0: on cpu0 powernow1: on cpu1 If you disabled acpi_throttle0 in loader, you won't get all those N/8 rates from throttling. I'm not sure, esp on AMD hardware, whether those rates actually provide any cooling benefit or not. I guess you've read mav@'s power tuning guide for hints on reducing power (thus, heat)? I also notice only C1 states, but using machdep.idle: amdc1e so I wonder if you're getting benefit from that? Are there BIOS settings re that? > Is this re-inventing the wheel ? > Anyone else out there working on or know of similar code ? A few people have been down this road, you'd need to search the acpi@ archives from a few years ago. Nate Lawson was then firmly opposed to the idea, but you'll find some code there, in various older PRs too, though it seems none of those are still 'open'. > mgdiff 8.2-RELEASE/src/usr.sbin/powerd/powerd.c \ > /pub/FreeBSD/branches/-current/src/usr.sbin/powerd/powerd.c > does not show a lot of difference. > > >From > http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.sbin/powerd/powerd.c > I added a few people to CC particularly mav@ has an interesting comment > Wed Jun 16 15:09:45 2010 UTC ( > Freq sysctls are quite heavy due to set of malloc()/free() > calls. Avoid reading current frequency on every period. > Instead do it only after changing and periodically from > time to time if somebody else change it. > > Also dynamically decrease sampling frequency up to 4 times > on inactivity, > > Gary J: there's a comment at Fri Jan 9 22:10:07 2009 re. more then 2 CPUs > > I added Clive who may have some URL to CPU temps. > > To > /boot/loader.conf > I just added > acpi_hp_load="YES" > (after reboot) does not produce /dev/hpcmi I don't see any mention of active cooling (ie, fan/s) in your sysctls, including acpi_hp. Here I'm running a custom script to control CPU fan via acpi_ibm (the auto fan didn't cut in till over 65C, then pumped it down to ~45C), but it seems you may not have access to fan control? You could try setting hw.acpi.thermal.user_override=1 and then set hw.acpi.thermal.tz0._PSV to something lower than 90C, perhaps much lower to see if it helps, especially if 'crashing' occurs closer to 90C than not, however: > Running 80% idle (just a fsck_ufs) I see: > hw.acpi.thermal.tz0.temperature: 67.0C > dev.acpi_hp.0.hdd_temperature: 4 67C isn't really hot on a dual core laptop with 100W rating at 1592MHz. Still, if you had it drop back immediately on idle to 796MHz, you'd be saving about 60W, which may help considerable. I expect you've done the usual check/clean airways, thermal grease etc? Just a few quick notes, I've no time for deep diving lately .. HTH. cheers, Ian From owner-freebsd-mobile@FreeBSD.ORG Mon Jan 2 15:57:29 2012 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 57FF4106564A for ; Mon, 2 Jan 2012 15:57:29 +0000 (UTC) (envelope-from tino.engel@porno-muenchen.de) Received: from ms16-1.1blu.de (ms16-1.1blu.de [89.202.0.34]) by mx1.freebsd.org (Postfix) with ESMTP id 1CD8F8FC0C for ; Mon, 2 Jan 2012 15:57:29 +0000 (UTC) Received: from [93.104.84.120] (helo=localhost.localnet) by ms16-1.1blu.de with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1RhjDW-0003is-UQ for freebsd-mobile@freebsd.org; Mon, 02 Jan 2012 15:50:27 +0100 From: Tino Engel Organization: Porno =?iso-8859-1?q?M=FCnchen?= To: freebsd-mobile@freebsd.org Date: Mon, 2 Jan 2012 15:48:46 +0100 User-Agent: KMail/1.13.7 (FreeBSD/9.0-RC3; KDE/4.7.3; amd64; ; ) References: <201201020313.q023DdG2051231@fire.js.berklix.net> In-Reply-To: <201201020313.q023DdG2051231@fire.js.berklix.net> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Message-Id: <201201021548.46620.tino.engel@porno-muenchen.de> X-Con-Id: 150583 X-Originating-IP: 93.104.84.120 Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Jan 2012 15:57:29 -0000 On Montag, 2. Januar 2012 04:13:38 Julian H. Stacey wrote: > Hi mobile@freebsd.org, CC a few others. > > I propose to hack src/usr.sbin/powerd/powerd.c > To import temperatures via sysctl, & if too high, to forcibly > reduce CPU frequency, even if CPU load is high, > because my new HP Pavillion notebook keeps over heating & crashing. > > dmesg & sysctl etc diagnostics at > http://berklix.com/~jhs/hardware/hp/pavilion/dm3-1155ea/ > CPU: AMD Athlon(tm) Neo X2 Dual Core Processor L335 (1595.96-MHz K8-class > CPU) Origin = "AuthenticAMD" Id = 0x60fb2 Family = f Model = 6b > Stepping = 2 > > Is this re-inventing the wheel ? > Anyone else out there working on or know of similar code ? > > mgdiff 8.2-RELEASE/src/usr.sbin/powerd/powerd.c \ > /pub/FreeBSD/branches/-current/src/usr.sbin/powerd/powerd.c > does not show a lot of difference. > > >From > > http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.sbin/powerd/powerd.c > I added a few people to CC particularly mav@ has an interesting comment > Wed Jun 16 15:09:45 2010 UTC ( > Freq sysctls are quite heavy due to set of malloc()/free() > calls. Avoid reading current frequency on every period. > Instead do it only after changing and periodically from > time to time if somebody else change it. > > Also dynamically decrease sampling frequency up to 4 times > on inactivity, > > Gary J: there's a comment at Fri Jan 9 22:10:07 2009 re. more then 2 > CPUs > > I added Clive who may have some URL to CPU temps. > > To > /boot/loader.conf > I just added > acpi_hp_load="YES" > (after reboot) does not produce /dev/hpcmi > > Running 80% idle (just a fsck_ufs) I see: > hw.acpi.thermal.tz0.temperature: 67.0C > dev.acpi_hp.0.hdd_temperature: 4 > > Cheers, > Julian Gr33z Julian, I have put my laptop on a poer-set-box, so the ventilators are lying free. That also help sometimes. Regards, Tino From owner-freebsd-mobile@FreeBSD.ORG Tue Jan 3 03:21:28 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6FA9F106564A; Tue, 3 Jan 2012 03:21:28 +0000 (UTC) (envelope-from sukenwoo@gmail.com) Received: from mail-vw0-f54.google.com (mail-vw0-f54.google.com [209.85.212.54]) by mx1.freebsd.org (Postfix) with ESMTP id E7BF08FC0C; Tue, 3 Jan 2012 03:21:27 +0000 (UTC) Received: by vbbfr13 with SMTP id fr13so21370515vbb.13 for ; Mon, 02 Jan 2012 19:21:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:cc:content-type; bh=2fEVaeTULYDT0uxBjBC2cvBv4/aKfATi9vdnhVokiZs=; b=blJn0ffL7I9/zTTTvRiBTQhti6FTgw18zMosDn4vRAF3R5ojmrE9C3zD7M0MkLrqzd 441QO+pppakWPc6/h+zrF6+iM7z1OB0mhoB8t2pOzJ7xV9bFOBAUupmvDzTlgG1pssJE KyOG4J2gCZgk/ph0tKhk9BiWJNhoaMYmdXoT8= MIME-Version: 1.0 Received: by 10.52.71.106 with SMTP id t10mr7957505vdu.103.1325559008680; Mon, 02 Jan 2012 18:50:08 -0800 (PST) Received: by 10.52.26.1 with HTTP; Mon, 2 Jan 2012 18:50:08 -0800 (PST) Date: Tue, 3 Jan 2012 10:50:08 +0800 Message-ID: From: suken woo To: current@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: stable@freebsd.org, mobile@freebsd.org, net@freebsd.org Subject: DLink DWL-G132 USB wifi Adapter failed under 9.0 RC3 X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Jan 2012 03:21:28 -0000 hi lists DWL-G132 failed to load on 9.0RC3 uath0: on usbus3 uath0: timeout waiting for reply to cmd 0x4 (4) uath0: could not read capability 3 uath0: could not get device capabilities device_attach: uath0 attach returned 35 and uathload lp# uathload -v -d /dev/ugen3.2 Load firmware ar5523.bin (builtin) to /dev/ugen3.2 send block 0: 151368 bytes remaining : data... : wait for ack... uathload: error reading msg (/dev/usb/3.2.1): No error: 0 usbconfig -u 3 -a 2 dump_device_desc ugen3.2: at usbus3, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0200 bDeviceClass = 0x00ff bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0000 bMaxPacketSize0 = 0x0040 idVendor = 0x2001 idProduct = 0x3a02 bcdDevice = 0x0001 iManufacturer = 0x0001 iProduct = 0x0002 iSerialNumber = 0x0003 <1.0> bNumConfigurations = 0x0001 From owner-freebsd-mobile@FreeBSD.ORG Tue Jan 3 03:33:35 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D0AB1106566B; Tue, 3 Jan 2012 03:33:35 +0000 (UTC) (envelope-from jhs@berklix.com) Received: from tower.berklix.org (tower.berklix.org [83.236.223.114]) by mx1.freebsd.org (Postfix) with ESMTP id F00CE8FC15; Tue, 3 Jan 2012 03:33:34 +0000 (UTC) Received: from mart.js.berklix.net (p5DCBCC03.dip0.t-ipconnect.de [93.203.204.3]) (authenticated bits=0) by tower.berklix.org (8.14.2/8.14.2) with ESMTP id q033XPo5084227; Tue, 3 Jan 2012 03:33:26 GMT (envelope-from jhs@berklix.com) Received: from fire.js.berklix.net (fire.js.berklix.net [192.168.91.41]) by mart.js.berklix.net (8.14.3/8.14.3) with ESMTP id q033XKZ4098310; Tue, 3 Jan 2012 04:33:20 +0100 (CET) (envelope-from jhs@berklix.com) Received: from fire.js.berklix.net (localhost [127.0.0.1]) by fire.js.berklix.net (8.14.4/8.14.4) with ESMTP id q033WRLE064421; Tue, 3 Jan 2012 04:32:34 +0100 (CET) (envelope-from jhs@fire.js.berklix.net) Message-Id: <201201030332.q033WRLE064421@fire.js.berklix.net> To: mobile@freebsd.org From: "Julian H. Stacey" Organization: http://www.berklix.com BSD Unix Linux Consultancy, Munich Germany User-agent: EXMH on FreeBSD http://www.berklix.com/free/ X-URL: http://www.berklix.com In-reply-to: Your message "Mon, 02 Jan 2012 16:52:00 +1100." <20120102153310.A66248@sola.nimnet.asn.au> Date: Tue, 03 Jan 2012 04:32:26 +0100 Sender: jhs@berklix.com X-Mailman-Approved-At: Tue, 03 Jan 2012 04:56:46 +0000 Cc: Ian Smith , Alexander Motin , Gary Jennejohn , "Clive Ashbolt \(Work\)" , "Julian H. Stacey" , Boris Kochergin , Tino Engel , brucec@freebsd.org, Hajimu UMEMOTO Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Jan 2012 03:33:35 -0000 Hi, Thanks to all of Ian, Hajimu, Tino ! Hajimu UMEMOTO wrote > Yes, it is implemented already in the kernel, and it should be done by > the ACPI passive cooling. I guess "ACPI passive cooling" means ACPI is supposed to turn down CPU frequency ? & maybe turn off anything else possible (I need to read http://en.wikipedia.org/wiki/Advanced_Configuration_and_Power_Interface & URLs beyond (PS I added one to FreeBSD page). > It seems to me that your ACPI BIOS has it, and when the temperature of > your CPU become over 90.0C, it will effect. 90 sounds terribly hot, so I compared with my Toshiba Satelite hw.acpi.thermal.tz0._PSV: 107.9C hw.acpi.thermal.tz0._HOT: -1 hw.acpi.thermal.tz0._CRT: 108.9C The plastic under my new HP notebook is too hot to comfortably hold. with top 75% idle hw.acpi.thermal.tz0.temperature: 68.0C kern.acct_chkfreq: 15 kern.timecounter.tc.i8254.frequency: 1193182 kern.timecounter.tc.ACPI-safe.frequency: 3579545 kern.timecounter.tc.HPET.frequency: 14318180 kern.timecounter.tc.TSC.frequency: 1596012059 net.inet.sctp.sack_freq: 2 machdep.acpi_timer_freq: 3579545 machdep.tsc_freq: 1596012059 machdep.i8254_freq: 1193182 dev.cpu.0.freq: 696 dev.cpu.0.freq_levels: 1592/100000 1393/87500 1194/75000 995/62500 796/35457 696/31024 597/26592 497/22160 398/17728 298/13296 199/8864 99/4432 dev.acpi_throttle.0.freq_settings: 10000/-1 8750/-1 7500/-1 6250/-1 5000/-1 3750/-1 2500/-1 1250/-1 dev.powernow.0.freq_settings: 1592/100000 796/35457 dev.powernow.1.freq_settings: 1592/100000 796/35457 > However, I'm not sure why your notebook keeps over heating & crashing. OK, Thanks Ian Smith wrote: > On Mon, 2 Jan 2012 04:13:38 +0100, Julian H. Stacey wrote: > > Hi mobile@freebsd.org, CC a few others. > > Hi Julian. Trimmed some, added ume@, feel free .. > > > I propose to hack src/usr.sbin/powerd/powerd.c > > To import temperatures via sysctl, & if too high, to forcibly > > reduce CPU frequency, even if CPU load is high, > > because my new HP Pavillion notebook keeps over heating & crashing. > > As ume@ points out, passive cooling _should_ be handling this, and in > any case - even if you get a forced shutdown at CRT temp. - it shouldn't > be 'crashing'. Please elaborate on 'crashing'? and at what sort of TCP failed, rdist & remote xterms & NFS fail, local mousepad fails. I didnt bother to try for a crash dump. I guessed damage was about to occur. > temperature this occurs? Low 80s I recall. Not sure, I thought that was so high damage would occur, so I just turned off & put an external fan under. I've reverted to default values & started a remote xterm with while (1) sysctl -a | grep temp ; date ; echo ; sleep 10 ; end Before with sysctl -a | grep temp I just got hw.acpi.thermal.tz0.temperature: 68.0C dev.acpi_hp.0.hdd_temperature: 4 after kldload amdtemp I get a lot more temperatures: dev.acpi_hp.0.hdd_temperature: 4 dev.amdtemp.0.%desc: AMD K8 Thermal Sensors dev.amdtemp.0.%driver: amdtemp dev.amdtemp.0.%parent: hostb4 dev.amdtemp.0.sensor0.core0: 51.0C dev.amdtemp.0.sensor0.core1: 49.0C dev.amdtemp.0.sensor1.core0: 58.0C dev.amdtemp.0.sensor1.core1: 56.0C dev.cpu.0.temperature: 57.0C dev.cpu.1.temperature: 57.0C hw.acpi.thermal.tz0.temperature: 66.0C > > dmesg & sysctl etc diagnostics at > > http://berklix.com/~jhs/hardware/hp/pavilion/dm3-1155ea/ > > CPU: AMD Athlon(tm) Neo X2 Dual Core Processor L335 (1595.96-MHz K8-class CPU) > > Origin = "AuthenticAMD" Id = 0x60fb2 Family = f Model = 6b Stepping = 2 > > Almost too much info :) esp. with sysctl -a including the verbose dmesg, > but I noticed a couple of things on a quick skim. Sorry I haven't got to grips which of these should be on & off so now turned on all of debug.bootverbose: 1 debug.cpufreq.verbose: 1 debug.hwpstate_verbose: 1 dev.acpi_hp.0.verbose: 0 # set to "1" in loader.conf but ignored. hw.acpi.verbose: 1 > If you run powerd -v, > what sort of freqs does it usually run at, when more or less idle? When 75 to 90% idle (from top) sysctl -a | grep freq | grep -v "cpufreq" kern.acct_chkfreq: 15 kern.timecounter.tc.i8254.frequency: 1193182 kern.timecounter.tc.ACPI-safe.frequency: 3579545 kern.timecounter.tc.HPET.frequency: 14318180 kern.timecounter.tc.TSC.frequency: 1595998039 net.inet.sctp.sack_freq: 2 machdep.acpi_timer_freq: 3579545 machdep.tsc_freq: 1595998039 machdep.i8254_freq: 1193182 dev.cpu.0.freq: 497 dev.cpu.0.freq_levels: 1592/100000 1393/87500 1194/75000 995/62500 796/35457 696/31024 597/26592 497/22160 398/17728 298/13296 199/8864 99/4432 dev.acpi_throttle.0.freq_settings: 10000/-1 8750/-1 7500/-1 6250/-1 5000/-1 3750/-1 2500/-1 1250/-1 dev.powernow.0.freq_settings: 1592/100000 796/35457 dev.powernow.1.freq_settings: 1592/100000 796/35457 On an idle machine, (with a little patch from Gary J. to allow for multiple cores: /src/bsd/fixes/FreeBSD/src/gen/usr.sbin/powerd.c.REL=8.2-RELEASE.diff running powerd -v # Using defaults powerd: using sysctl for AC line status powerd: using devd for AC line status load 64%, current freq 199 MHz (10), wanted freq 339 MHz changing clock speed from 199 MHz to 398 MHz powerd: error setting CPU frequency 398: Invalid argument load 27%, current freq 398 MHz ( 8), wanted freq 339 MHz load 7%, current freq 398 MHz ( 8), wanted freq 328 MHz load 4%, current freq 398 MHz ( 8), wanted freq 317 MHz load 8%, current freq 398 MHz ( 8), wanted freq 307 MHz load 12%, current freq 398 MHz ( 8), wanted freq 297 MHz changing clock speed from 398 MHz to 298 MHz powerd: error setting CPU frequency 298: Invalid argument load 25%, current freq 298 MHz ( 9), wanted freq 297 MHz load 7%, current freq 298 MHz ( 9), wanted freq 287 MHz load 14%, current freq 298 MHz ( 9), wanted freq 278 MHz load 15%, current freq 298 MHz ( 9), wanted freq 269 MHz load 7%, current freq 298 MHz ( 9), wanted freq 260 MHz load 6%, current freq 298 MHz ( 9), wanted freq 251 MHz load 0%, current freq 298 MHz ( 9), wanted freq 243 MHz load 4%, current freq 298 MHz ( 9), wanted freq 235 MHz load 10%, current freq 298 MHz ( 9), wanted freq 227 MHz load 0%, current freq 298 MHz ( 9), wanted freq 219 MHz load 17%, current freq 298 MHz ( 9), wanted freq 212 MHz load 0%, current freq 298 MHz ( 9), wanted freq 205 MHz load 3%, current freq 298 MHz ( 9), wanted freq 198 MHz changing clock speed from 298 MHz to 199 MHz powerd: error setting CPU frequency 199: Invalid argument load 42%, current freq 199 MHz (10), wanted freq 221 MHz changing clock speed from 199 MHz to 298 MHz powerd: error setting CPU frequency 298: Invalid argument load 33%, current freq 298 MHz ( 9), wanted freq 221 MHz load 4%, current freq 298 MHz ( 9), wanted freq 214 MHz load 10%, current freq 298 MHz ( 9), wanted freq 207 MHz load 4%, current freq 298 MHz ( 9), wanted freq 200 MHz load 4%, current freq 298 MHz ( 9), wanted freq 193 MHz changing clock speed from 298 MHz to 199 MHz powerd: error setting CPU frequency 199: Invalid argument load 57%, current freq 199 MHz (10), wanted freq 293 MHz changing clock speed from 199 MHz to 298 MHz powerd: error setting CPU frequency 298: Invalid argument load 27%, current freq 298 MHz ( 9), wanted freq 293 MHz load 3%, current freq 298 MHz ( 9), wanted freq 283 MHz load 11%, current freq 298 MHz ( 9), wanted freq 274 MHz load 9%, current freq 298 MHz ( 9), wanted freq 265 MHz load 13%, current freq 298 MHz ( 9), wanted freq 256 MHz load 7%, current freq 298 MHz ( 9), wanted freq 248 MHz load 10%, current freq 298 MHz ( 9), wanted freq 240 MHz load 0%, current freq 298 MHz ( 9), wanted freq 232 MHz load 4%, current freq 298 MHz ( 9), wanted freq 224 MHz load 0%, current freq 298 MHz ( 9), wanted freq 217 MHz load 10%, current freq 298 MHz ( 9), wanted freq 210 MHz load 10%, current freq 298 MHz ( 9), wanted freq 203 MHz load 12%, current freq 298 MHz ( 9), wanted freq 196 MHz changing clock speed from 298 MHz to 199 MHz powerd: error setting CPU frequency 199: Invalid argument load 60%, current freq 199 MHz (10), wanted freq 313 MHz changing clock speed from 199 MHz to 398 MHz > Are > you using default powerd settings? I was when it crashed too often to be useful. accepting values from /etc/defaults/rc.conf but it crashed too much, so my rc.conf is now set to give: /usr/sbin/powerd -a adaptive -b minimum -n minimum > When running on battery can you > monitor power use with acpiconf -i0 to see the actual effect on power > usage of running at various lower freqs? Wow what a nice command ! Design capacity: 57276 mWh Last full capacity: 55544 mWh Technology: secondary (rechargeable) Design voltage: 11100 mV Capacity (warn): 5554 mWh Capacity (low): 0 mWh Low/warn granularity: 555 mWh Warn/full granularity: 555 mWh Model number: 5160 Serial number: Li4402A Type: Li OEM info: Hewlett-Packard State: high Remaining capacity: 100% Remaining time: unknown Present rate: unknown Present voltage: 12375 mV Yes I could do that. I dont see anything that's going to give me instantaneous consumption readings above though, & battery state prediction is generaly not accurate. However, I can do better, I can connect a power meter between wall supply & transformer (battery will be irrelevant if full, not charging) & see how much power is going in. & a temperature probe underneath. (OK, heat emitted by screen I don't care about, (just any heat in chassis, from inefficiency converting for screen), I'll see if I can turn off screen with keys or BIOS) But I guess another way is to hack the ACPI to turn the fan on at lower threshold. ? Maybe I'll have to tweak what I got from acpidump -dt http://berklix.com/~jhs/hardware/hp/pavilion/dm3-1155ea/jhs-hp-pPavilion-dm3-1155ea.asl per: http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/acpi-debug.html > I see dev.powernow.0.freq_settings: 1592/100000 796/35457 ie just two > speeds, with dmesg showing: > acpi_throttle0: on cpu0 > acpi_throttle0: P_CNT from P_BLK 0x410 > powernow0: on cpu0 > powernow1: on cpu1 powernow & throttling all new to me, I must web search. sysctl -d dev.powernow.0.freq_settings dev.powernow.0.freq_settings: CPU frequency driver settings > If you disabled acpi_throttle0 in loader, you won't get all those N/8 > rates from throttling. I'm not sure, esp on AMD hardware, whether those > rates actually provide any cooling benefit or not. I guess you've read > mav@'s power tuning guide for hints on reducing power (thus, heat)? No I haven't. but thanks for tip I found http://people.freebsd.org/~mav/power.pdf In Russian (or some kind of Cyrillic) I only have E & German & French. I'll page through & look at syntax :-) http://people.freebsd.org/~mav/power.prd file power.prd: CDF V2 Document, Little Endian, Os 0, Version: 1.0, Code page: -535 viewed with OpenOffice. whhatever it is, not useful for this. > I also notice only C1 states, but using machdep.idle: amdc1e so I wonder > if you're getting benefit from that? Are there BIOS settings re that? I didnt know what C1 was. Found it: http://en.wikipedia.org/wiki/Advanced_Configuration_and_Power_Interface sysctl -a | grep machdep.idle machdep.idle: amdc1e machdep.idle_available: spin, amdc1e, hlt, acpi, sysctl -d machdep.idle machdep.idle: currently selected idle function sysctl -d machdep.idle_available machdep.idle_available: list of available idle functions Where are you seeing the C1 ? Wkipedia does make C1E sound more desirable. I went throught the screen BIOS a while back & found no power / temp / frequency options, was a rather limited BIOS. > > Is this re-inventing the wheel ? > > Anyone else out there working on or know of similar code ? > > A few people have been down this road, you'd need to search the acpi@ > archives from a few years ago. Nate Lawson was then firmly opposed to > the idea, but you'll find some code there, in various older PRs too, > though it seems none of those are still 'open'. Thanks, will do. > > mgdiff 8.2-RELEASE/src/usr.sbin/powerd/powerd.c \ > > /pub/FreeBSD/branches/-current/src/usr.sbin/powerd/powerd.c > > does not show a lot of difference. > > > > >From > > http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.sbin/powerd/powerd.c > > I added a few people to CC particularly mav@ has an interesting comment > > Wed Jun 16 15:09:45 2010 UTC ( > > Freq sysctls are quite heavy due to set of malloc()/free() > > calls. Avoid reading current frequency on every period. > > Instead do it only after changing and periodically from > > time to time if somebody else change it. > > > > Also dynamically decrease sampling frequency up to 4 times > > on inactivity, > > > > Gary J: there's a comment at Fri Jan 9 22:10:07 2009 re. more then 2 CPUs > > > > I added Clive who may have some URL to CPU temps. > > > > To > > /boot/loader.conf > > I just added > > acpi_hp_load="YES" > > (after reboot) does not produce /dev/hpcmi > > I don't see any mention of active cooling (ie, fan/s) in your sysctls, > including acpi_hp. Yes, been puzzling me that, There is one little fan slot, doesnt seem to blow hot right now, when under case too hot to hold. Yes I cant see revs/min > Here I'm running a custom script to control CPU fan > via acpi_ibm (the auto fan didn't cut in till over 65C, then pumped it > down to ~45C), but it seems you may not have access to fan control? I dont know how to control the fan. I'd like to see your script please, or at least commands you'r running. kldload acpi_ibm ; kldstat kernel sound.ko snd_hda.ko acpi_hp.ko acpi_wmi.ko linux.ko linux_adobe.ko radeon.ko drm.ko acpi_ibm.ko > You could try setting hw.acpi.thermal.user_override=1 and then set hw.acpi.thermal.tz0._PSV to something lower than 90C, perhaps much lower > to see if it helps, especially if 'crashing' occurs closer to 90C than > not, however: sysctl hw.acpi.thermal.tz0._PSV hw.acpi.thermal.tz0._PSV: 90.0C sysctl hw.acpi.thermal.user_override hw.acpi.thermal.user_override: 0 sysctl hw.acpi.thermal.user_override sysctl hw.acpi.thermal.tz0._PSV=60.0C sysctl -a | grep acpi.thermal hw.acpi.thermal.min_runtime: 0 hw.acpi.thermal.polling_rate: 10 hw.acpi.thermal.user_override: 1 hw.acpi.thermal.tz0.temperature: 69.0C hw.acpi.thermal.tz0.active: -1 hw.acpi.thermal.tz0.passive_cooling: 1 hw.acpi.thermal.tz0.thermal_flags: 1 hw.acpi.thermal.tz0._PSV: 60.0C hw.acpi.thermal.tz0._HOT: 95.0C hw.acpi.thermal.tz0._CRT: 100.0C hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 hw.acpi.thermal.tz0._TC1: 2 hw.acpi.thermal.tz0._TC2: 3 hw.acpi.thermal.tz0._TSP: 40 I think that's forced the frequency down, Xterm to machine is sluggish & powerd -v reports: changing clock speed from 99 MHz to 1592 MHz load 177%, current freq 99 MHz (11), wanted freq 3184 MHz changing clock speed from 99 MHz to 1592 MHz load 179%, current freq 99 MHz (11), wanted freq 3184 MHz changing clock speed from 99 MHz to 1592 MHz load 151%, current freq 99 MHz (11), wanted freq 3184 MHz sysctl hw.acpi.thermal.tz0._HOT=62.0C I dont hear or feel fan faster. ... just crashed. > > Running 80% idle (just a fsck_ufs) I see: > > hw.acpi.thermal.tz0.temperature: 67.0C > > dev.acpi_hp.0.hdd_temperature: 4 > > 67C isn't really hot on a dual core laptop with 100W rating at 1592MHz. > Still, if you had it drop back immediately on idle to 796MHz, you'd be > saving about 60W, which may help considerable. > > I expect you've done the usual check/clean airways, thermal grease etc? New notebook, used about 2 hours by mother in a clean office, then by me ditto, however yes, might be manufacturing error & lack of grease. Not opened it yet. > Just a few quick notes, I've no time for deep diving lately .. HTH. > cheers, Ian Thanks Ian, you gave me a Lot of ideas to investigate :-) Tino Engel wrote: > I have put my laptop on a poer-set-box, so the ventilators are lying free. > That also help sometimes. Yes, Thanks, I've put mine on extra rubber feet, & sometimes a fan blowing under the back when on load. I'll try local shops eg http://www.conrad.de/ce/de/FastSearch.html;jsessionid=30CC9116DFD7E7BDC51220C2755735E0.ASTPCCP11?search=laptop+unter+kuhl+luft&initial=true&categorycode= English equivalent for globale readers: http://http://www.conrad.com/websale7/?Ctx=%257bver%252f7%252fver%257d%257bst%252f417%252fst%257d%257bcmd%252f0%252fcmd%257d%257bm%252fwebsale%252fm%257d%257bs%252fconrad%252dint%252fs%257d%257bl%252fint%252fl%257d%257bp1%252f9c24b341a5c38cea506a342ea52db4cb%252fp1%257d%257bmd5%252f3b4f37d756fcc437913494526895d6cf%252fmd5%257d&dummychar=%3F&dp2=ff_search&search_input=Notebook+cooling+pad Or lash up something out of Meccano with custom placement of fan outputs. which would be OK for in office, but I want to solve the problem so I can travel with this notebook (/ "laptop burner ;-)" even if I need to run at lower frequency or force fan faster somehow. If I failed to cover something, please let me know, If nothing else I have more reading to do, then perhaps to resort to acpi@ archives & list. Thanks Ian, Hajimu, Tino ! Cheers, Julian -- Julian Stacey, BSD Unix Linux C Sys Eng Consultants Munich http://berklix.com Reply below not above, cumulative like a play script, & indent with "> ". Format: Plain text. Not HTML, multipart/alternative, base64, quoted-printable. From owner-freebsd-mobile@FreeBSD.ORG Tue Jan 3 11:24:32 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 819BC1065676; Tue, 3 Jan 2012 11:24:32 +0000 (UTC) (envelope-from mavbsd@gmail.com) Received: from mail-ee0-f54.google.com (mail-ee0-f54.google.com [74.125.83.54]) by mx1.freebsd.org (Postfix) with ESMTP id B95CF8FC1A; Tue, 3 Jan 2012 11:24:31 +0000 (UTC) Received: by eekc50 with SMTP id c50so18821383eek.13 for ; Tue, 03 Jan 2012 03:24:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=l3AhO5IagwmjRurnAoF96PhvmASeWLsGWcxndmLJJRU=; b=iZou8DhcLO5s/+MaH1psvbmDHYSb3tJRX46Uqbkxs83Le32W6YFeQ4wrQ9tivZiAvi hH3qJcA5eb0877/9XKaTsSQC4flmnUP+HZFwxUMt7t/nXXOuHtLtnOCn+fbp8igQ83sx O82upEOkapP4Q+p3Ia7u2V2HO5owommXlQ8nQ= Received: by 10.213.29.131 with SMTP id q3mr10049062ebc.65.1325588323528; Tue, 03 Jan 2012 02:58:43 -0800 (PST) Received: from mavbook.mavhome.dp.ua (pc.mavhome.dp.ua. [212.86.226.226]) by mx.google.com with ESMTPS id s16sm204268220eef.2.2012.01.03.02.58.40 (version=SSLv3 cipher=OTHER); Tue, 03 Jan 2012 02:58:41 -0800 (PST) Sender: Alexander Motin Message-ID: <4F02DF58.90101@FreeBSD.org> Date: Tue, 03 Jan 2012 12:58:32 +0200 From: Alexander Motin User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:8.0) Gecko/20111112 Thunderbird/8.0 MIME-Version: 1.0 To: "Julian H. Stacey" References: <201201030332.q033WRLE064421@fire.js.berklix.net> In-Reply-To: <201201030332.q033WRLE064421@fire.js.berklix.net> Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 7bit Cc: Ian Smith , Gary Jennejohn , "Clive Ashbolt \(Work\)" , Boris Kochergin , mobile@freebsd.org, Tino Engel , brucec@freebsd.org, Hajimu UMEMOTO Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Jan 2012 11:24:32 -0000 On 03.01.2012 05:32, Julian H. Stacey wrote: > Hajimu UMEMOTO wrote >> If you disabled acpi_throttle0 in loader, you won't get all those N/8 >> rates from throttling. I'm not sure, esp on AMD hardware, whether those >> rates actually provide any cooling benefit or not. I guess you've read >> mav@'s power tuning guide for hints on reducing power (thus, heat)? > > No I haven't. but thanks for tip I found > http://people.freebsd.org/~mav/power.pdf > In Russian (or some kind of Cyrillic) I only have E& > German& French. I'll page through& look at syntax :-) > http://people.freebsd.org/~mav/power.prd > file power.prd: > CDF V2 Document, Little Endian, Os 0, > Version: 1.0, Code page: -535 > viewed with OpenOffice. whhatever it is, not useful for this. That's my presentation about the same topic in Russian for KyivBSD 2010 conference. The mentioned guide in English can be found here: http://wiki.freebsd.org/TuningPowerConsumption I've just added there some points about AMD C1E state and its support in FreeBSD 8.x and 9.x from my knowledge. Unluckily I never had laptop with AMD CPU to really test power management there. -- Alexander Motin From owner-freebsd-mobile@FreeBSD.ORG Wed Jan 4 01:56:17 2012 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 992E6106567D for ; Wed, 4 Jan 2012 01:56:17 +0000 (UTC) (envelope-from onyx@z-up.ru) Received: from mx.z-up.ru (mx.z-up.ru [92.50.244.44]) by mx1.freebsd.org (Postfix) with ESMTP id 495FC8FC1F for ; Wed, 4 Jan 2012 01:56:17 +0000 (UTC) Received: from onyx-y550p.loc (unknown [92.50.244.253]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx.z-up.ru (Postfix) with ESMTPSA id C581C1143E for ; Wed, 4 Jan 2012 05:38:17 +0400 (GMT-4) From: Dmitry Kolosov To: freebsd-mobile@freebsd.org Date: Wed, 4 Jan 2012 05:38:30 +0400 User-Agent: KMail/1.13.7 (FreeBSD/9.0-PRERELEASE; KDE/4.7.3; i386; ; ) References: <201201020313.q023DdG2051231@fire.js.berklix.net> In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201201040538.30654.onyx@z-up.ru> Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: onyx@z-up.ru List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Jan 2012 01:56:17 -0000 > hw.acpi.thermal.tz0.temperature: 67.0C > hw.acpi.thermal.tz0.active: -1 > hw.acpi.thermal.tz0.passive_cooling: 1 > hw.acpi.thermal.tz0.thermal_flags: 0 > hw.acpi.thermal.tz0._PSV: 90.0C > hw.acpi.thermal.tz0._HOT: 95.0C > hw.acpi.thermal.tz0._CRT: 100.0C > hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 > hw.acpi.thermal.tz0._TC1: 2 > hw.acpi.thermal.tz0._TC2: 3 > hw.acpi.thermal.tz0._TSP: 40 Use hw.acpi.thermal.user_override=1 in sysctl.conf to allow override of thermal settings. Now you can set custom _PSV, _HOT and _CRIT. Worked well for me on my previous HP Pavilion dv6 series laptop. More complex resolution of overheating problem - consider to sell HP asap and get any other laptop. HP totaly failed on cooling on almost all models, they are all hothothot. -- () ascii ribbon campaign - against html mail /\ - against microsoft attachments From owner-freebsd-mobile@FreeBSD.ORG Wed Jan 4 03:49:18 2012 Return-Path: Delivered-To: freebsd-mobile@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3DAEE106566B for ; Wed, 4 Jan 2012 03:49:18 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 9B7278FC0A for ; Wed, 4 Jan 2012 03:49:17 +0000 (UTC) Received: from [10.0.0.63] (63.imp.bsdimp.com [10.0.0.63]) (authenticated bits=0) by harmony.bsdimp.com (8.14.4/8.14.3) with ESMTP id q043jhlb014658 (version=TLSv1/SSLv3 cipher=DHE-DSS-AES128-SHA bits=128 verify=NO); Tue, 3 Jan 2012 20:45:45 -0700 (MST) (envelope-from imp@bsdimp.com) Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: Warner Losh In-Reply-To: <201201040538.30654.onyx@z-up.ru> Date: Tue, 3 Jan 2012 20:45:43 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <8C8222CF-404E-48AD-B318-0D3EB9DD28BD@bsdimp.com> References: <201201020313.q023DdG2051231@fire.js.berklix.net> <201201040538.30654.onyx@z-up.ru> To: onyx@z-up.ru X-Mailer: Apple Mail (2.1084) X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.0.1 (harmony.bsdimp.com [10.0.0.6]); Tue, 03 Jan 2012 20:45:45 -0700 (MST) Cc: freebsd-mobile@FreeBSD.org Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Jan 2012 03:49:18 -0000 On Jan 3, 2012, at 6:38 PM, Dmitry Kolosov wrote: >=20 >> hw.acpi.thermal.tz0.temperature: 67.0C >> hw.acpi.thermal.tz0.active: -1 >> hw.acpi.thermal.tz0.passive_cooling: 1 >> hw.acpi.thermal.tz0.thermal_flags: 0 >> hw.acpi.thermal.tz0._PSV: 90.0C >> hw.acpi.thermal.tz0._HOT: 95.0C >> hw.acpi.thermal.tz0._CRT: 100.0C >> hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 >> hw.acpi.thermal.tz0._TC1: 2 >> hw.acpi.thermal.tz0._TC2: 3 >> hw.acpi.thermal.tz0._TSP: 40 >=20 > Use=20 > hw.acpi.thermal.user_override=3D1 > in sysctl.conf to allow override of thermal settings. Now you can set = custom=20 > _PSV, _HOT and _CRIT. Worked well for me on my previous HP Pavilion = dv6 series=20 > laptop.=20 > More complex resolution of overheating problem - consider to sell HP = asap and=20 > get any other laptop. HP totaly failed on cooling on almost all = models, they=20 > are all hothothot. I fought for two years the overheading of my HP laptop. Some of the = following might help, or they might not: (1) blow the dust out of the dang thing. HP's clog up with dust making = their fans about useless. (2) make sure the fans are spinning at full speed. (3) replace any broken fans (4) give up and get a different computer... that's what I did in the = end (although not until after the power board went out on the goofy = thing). Warner From owner-freebsd-mobile@FreeBSD.ORG Wed Jan 4 17:59:30 2012 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B840A106564A for ; Wed, 4 Jan 2012 17:59:30 +0000 (UTC) (envelope-from kob6558@gmail.com) Received: from mail-wi0-f182.google.com (mail-wi0-f182.google.com [209.85.212.182]) by mx1.freebsd.org (Postfix) with ESMTP id 440F18FC0C for ; Wed, 4 Jan 2012 17:59:29 +0000 (UTC) Received: by wibhr1 with SMTP id hr1so17341346wib.13 for ; Wed, 04 Jan 2012 09:59:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=0FA1Hwg9jCRVGFHYwDIFGl66DW82rWJEvHCzP/ulqxk=; b=IIr7hmBXCI9xNMXRNFDW6q+kGhXyEQLhJKdOn7lyVUdQqtmWFgqKoBRbRWPPXwIlZ0 ijsFG52dCKj1cHEVoCXB7uvAu1qirGsOHo7/wLCHSFmKBk0a+y0mf9o+o11muol66PV0 KTnKftNNOrx/soinh+jRcJqMFac4FlmG7mBo4= MIME-Version: 1.0 Received: by 10.180.91.201 with SMTP id cg9mr124919748wib.15.1325698269530; Wed, 04 Jan 2012 09:31:09 -0800 (PST) Received: by 10.223.158.129 with HTTP; Wed, 4 Jan 2012 09:31:09 -0800 (PST) In-Reply-To: <8C8222CF-404E-48AD-B318-0D3EB9DD28BD@bsdimp.com> References: <201201020313.q023DdG2051231@fire.js.berklix.net> <201201040538.30654.onyx@z-up.ru> <8C8222CF-404E-48AD-B318-0D3EB9DD28BD@bsdimp.com> Date: Wed, 4 Jan 2012 09:31:09 -0800 Message-ID: From: Kevin Oberman To: Warner Losh Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: onyx@z-up.ru, freebsd-mobile@freebsd.org Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Jan 2012 17:59:30 -0000 On Tue, Jan 3, 2012 at 7:45 PM, Warner Losh wrote: > > On Jan 3, 2012, at 6:38 PM, Dmitry Kolosov wrote: > > > > >> hw.acpi.thermal.tz0.temperature: 67.0C > >> hw.acpi.thermal.tz0.active: -1 > >> hw.acpi.thermal.tz0.passive_cooling: 1 > >> hw.acpi.thermal.tz0.thermal_flags: 0 > >> hw.acpi.thermal.tz0._PSV: 90.0C > >> hw.acpi.thermal.tz0._HOT: 95.0C > >> hw.acpi.thermal.tz0._CRT: 100.0C > >> hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 > >> hw.acpi.thermal.tz0._TC1: 2 > >> hw.acpi.thermal.tz0._TC2: 3 > >> hw.acpi.thermal.tz0._TSP: 40 > > > > Use > > hw.acpi.thermal.user_override=1 > > in sysctl.conf to allow override of thermal settings. Now you can set > custom > > _PSV, _HOT and _CRIT. Worked well for me on my previous HP Pavilion dv6 > series > > laptop. > > More complex resolution of overheating problem - consider to sell HP > asap and > > get any other laptop. HP totaly failed on cooling on almost all models, > they > > are all hothothot. > > I fought for two years the overheading of my HP laptop. Some of the > following might help, or they might not: > > (1) blow the dust out of the dang thing. HP's clog up with dust making > their fans about useless. > (2) make sure the fans are spinning at full speed. > (3) replace any broken fans > (4) give up and get a different computer... that's what I did in the end > (although not until after the power board went out on the goofy thing). > > Warner > While I am not about to defend HP and would never consider buying any HP system, laptop or desktop, the dust issue is common to all systems, laptop and desktop, but shows up more in laptops as they are often used in places where dust is a bigger issue and have very compact cooling systems which are far more sensitive to anything that degrades performance. It's not so much clogging. That takes a huge amount of dust and, more likely, lint. Dust is a great insulator and a thin coating of dust on the fins of a laptop heatsink will greatly diminish heat transfer. I have learned over the past decade and a half that it is really important to blow out the dust on heatsinks annually. I monitor my CPU temps with gkrellm and over the months after cleaning the heatsink idle temperature will slowly climb from fairly cool (52-55 on my old T43) to over 60. The loaded temperature will climb dramatically. A buildworld with clean heatsinks will run at 78 or 79 while a year later I will see temperatures at or near 90. While the numbers vary, I have seen the same sort of behavior on all of my laptops, about five of them. -- R. Kevin Oberman, Network Engineer E-mail: kob6558@gmail.com From owner-freebsd-mobile@FreeBSD.ORG Wed Jan 4 18:23:09 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 68939106566C; Wed, 4 Jan 2012 18:23:09 +0000 (UTC) (envelope-from jhs@berklix.com) Received: from tower.berklix.org (tower.berklix.org [83.236.223.114]) by mx1.freebsd.org (Postfix) with ESMTP id 0F7848FC08; Wed, 4 Jan 2012 18:23:08 +0000 (UTC) Received: from mart.js.berklix.net (p5DCBE8B1.dip.t-dialin.net [93.203.232.177]) (authenticated bits=0) by tower.berklix.org (8.14.2/8.14.2) with ESMTP id q04IN52O005688; Wed, 4 Jan 2012 18:23:06 GMT (envelope-from jhs@berklix.com) Received: from fire.js.berklix.net (fire.js.berklix.net [192.168.91.41]) by mart.js.berklix.net (8.14.3/8.14.3) with ESMTP id q04IMrQl008302; Wed, 4 Jan 2012 19:22:53 +0100 (CET) (envelope-from jhs@berklix.com) Received: from fire.js.berklix.net (localhost [127.0.0.1]) by fire.js.berklix.net (8.14.4/8.14.4) with ESMTP id q04IMlQJ060929; Wed, 4 Jan 2012 19:22:53 +0100 (CET) (envelope-from jhs@fire.js.berklix.net) Message-Id: <201201041822.q04IMlQJ060929@fire.js.berklix.net> To: Alexander Motin From: "Julian H. Stacey" Organization: http://www.berklix.com BSD Unix Linux Consultancy, Munich Germany User-agent: EXMH on FreeBSD http://www.berklix.com/free/ X-URL: http://www.berklix.com In-reply-to: Your message "Tue, 03 Jan 2012 12:58:32 +0200." <4F02DF58.90101@FreeBSD.org> Date: Wed, 04 Jan 2012 19:22:47 +0100 Sender: jhs@berklix.com Cc: mobile@freebsd.org Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Jan 2012 18:23:09 -0000 Alexander Motin wrote: > That's my presentation about the same topic in Russian for KyivBSD 2010 > conference. The mentioned guide in English can be found here: > http://wiki.freebsd.org/TuningPowerConsumption Thanks, I just linked to it from my http://berklix.com/~jhs/hardware/hp/pavilion/dm3-1155ea > I've just added there some points about AMD C1E state and its support in > FreeBSD 8.x and 9.x from my knowledge. Unluckily I never had laptop with > AMD CPU to really test power management there. For your page: Suggestion To help people find what "EIST frequencies" is, swap it to: ". Format: Plain text. Not HTML, multipart/alternative, base64, quoted-printable. From owner-freebsd-mobile@FreeBSD.ORG Wed Jan 4 18:45:49 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CBDB8106566C for ; Wed, 4 Jan 2012 18:45:49 +0000 (UTC) (envelope-from mavbsd@gmail.com) Received: from mail-ee0-f54.google.com (mail-ee0-f54.google.com [74.125.83.54]) by mx1.freebsd.org (Postfix) with ESMTP id 5BF238FC08 for ; Wed, 4 Jan 2012 18:45:48 +0000 (UTC) Received: by eekc50 with SMTP id c50so20084025eek.13 for ; Wed, 04 Jan 2012 10:45:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=Hh2ED0rDBnyz5HfWGDdHmzuNLpcZzotpFoceYRzN5Sk=; b=JIfleN6RR6z4YUslcJ/d16oC5LxUYnhcta2xeTGexmdz8JCRU3EuIfG7Up4ihUjZXf dFwfR+ORYUke9e4VpPzDEazwDgOlRAc19SbJjk1e3lZEv/rE4cHjMrSzL0CUuySi79/j rMoI5S0cF7IaMwXPQBnPV/LMqDFd2YolFDYb4= Received: by 10.14.127.197 with SMTP id d45mr24022689eei.91.1325702748249; Wed, 04 Jan 2012 10:45:48 -0800 (PST) Received: from mavbook2.mavhome.dp.ua (pc.mavhome.dp.ua. [212.86.226.226]) by mx.google.com with ESMTPS id s16sm222935608eef.2.2012.01.04.10.45.46 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 04 Jan 2012 10:45:46 -0800 (PST) Sender: Alexander Motin Message-ID: <4F049E58.5040404@FreeBSD.org> Date: Wed, 04 Jan 2012 20:45:44 +0200 From: Alexander Motin User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:9.0) Gecko/20111227 Thunderbird/9.0 MIME-Version: 1.0 To: "Julian H. Stacey" References: <201201041822.q04IMlQJ060929@fire.js.berklix.net> In-Reply-To: <201201041822.q04IMlQJ060929@fire.js.berklix.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: mobile@freebsd.org Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Jan 2012 18:45:49 -0000 On 01/04/12 20:22, Julian H. Stacey wrote: > Question: > In your > dev.cpu.0.freq_levels: 2400/35000 2000/28000 1600/22000 1200/16000 800/14000 > 1st numbers are frequency, what are 2nd numbers after / ? Relative power consumption under full CPU load. > Presumably not voltages, as mine have such a wide span : > dev.cpu.0.freq_levels: 1592/100000 1393/87500 1194/75000 995/62500 > 796/35457 696/31024 597/26592 497/22160 398/17728 298/13296 > 199/8864 99/4432 > (We should send-pr longer text to be produced by > sysctl -d dev.cpu.0.freq_levels > dev.cpu.0.freq_levels: CPU frequency levels > ) For EIST and probably PowerNow! frequencies it is relative power levels. But for frequencies created by throttling they are incorrect. If you disable throttling, you should see only "real" value. > Question > "It is not recommended to set the system timer tick rate below 250 HZ and" > Do you mean as shown by > kern.clockrate: { hz = 1000, tick = 1000, > Not kern.hz ? Generally kern.hz, but for freqs below 1000Hz they are equal. -- Alexander Motin From owner-freebsd-mobile@FreeBSD.ORG Thu Jan 5 07:03:33 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 72357106564A for ; Thu, 5 Jan 2012 07:03:33 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from sola.nimnet.asn.au (paqi.nimnet.asn.au [115.70.110.159]) by mx1.freebsd.org (Postfix) with ESMTP id 916DC8FC15 for ; Thu, 5 Jan 2012 07:03:31 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by sola.nimnet.asn.au (8.14.2/8.14.2) with ESMTP id q0573I0e096386; Thu, 5 Jan 2012 18:03:20 +1100 (EST) (envelope-from smithi@nimnet.asn.au) Date: Thu, 5 Jan 2012 18:03:18 +1100 (EST) From: Ian Smith To: "Julian H. Stacey" In-Reply-To: <201201030332.q033WRLE064421@fire.js.berklix.net> Message-ID: <20120105020833.U62686@sola.nimnet.asn.au> References: <201201030332.q033WRLE064421@fire.js.berklix.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: mobile@freebsd.org Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Jan 2012 07:03:33 -0000 On Tue, 3 Jan 2012, Julian H. Stacey wrote: [snip ccs, feel free .. and cutting lots .. likely my last post on this] > > As ume@ points out, passive cooling _should_ be handling this, and in > > any case - even if you get a forced shutdown at CRT temp. - it shouldn't > > be 'crashing'. Please elaborate on 'crashing'? and at what sort of > > TCP failed, rdist & remote xterms & NFS fail, local mousepad fails. I > didnt bother to try for a crash dump. I guessed damage was about to occur. Hmm. 'vmstat -i' during this state might be interesting, if console access still works, but heat related failures can look pretty random. > > temperature this occurs? > > Low 80s I recall. Not sure, I thought that was so high damage would Nah, 80 isn't so hot. Even my single-core P2-M hits 85C when CPU bound, and as you've shown, one Toshiba had 100C-plus _PSV and _CRT temps. > occur, so I just turned off & put an external fan under. I've Good, but it's winter there, eh? At 2am it was still 27C here :) > Before with > sysctl -a | grep temp > I just got > hw.acpi.thermal.tz0.temperature: 68.0C > dev.acpi_hp.0.hdd_temperature: 4 > after > kldload amdtemp > I get a lot more temperatures: Good idea. > dev.acpi_hp.0.hdd_temperature: 4 > dev.amdtemp.0.%desc: AMD K8 Thermal Sensors > dev.amdtemp.0.%driver: amdtemp > dev.amdtemp.0.%parent: hostb4 > dev.amdtemp.0.sensor0.core0: 51.0C > dev.amdtemp.0.sensor0.core1: 49.0C > dev.amdtemp.0.sensor1.core0: 58.0C > dev.amdtemp.0.sensor1.core1: 56.0C > dev.cpu.0.temperature: 57.0C > dev.cpu.1.temperature: 57.0C > hw.acpi.thermal.tz0.temperature: 66.0C tz0.temperature is reading 9C above the core sensors; that seems a lot. May tend to suggest problems with heatsinks / thermal paste etc, noting others' comments about HP machines running hot .. "lap"tops they ain't, but then apart from smaller notebooks, eeepcs etc, few are these days. > > > dmesg & sysctl etc diagnostics at > > > http://berklix.com/~jhs/hardware/hp/pavilion/dm3-1155ea/ [..] > > Almost too much info :) esp. with sysctl -a including the verbose dmesg, > > but I noticed a couple of things on a quick skim. > > Sorry I haven't got to grips which of these should be on & off so > now turned on all of > debug.bootverbose: 1 > debug.cpufreq.verbose: 1 > debug.hwpstate_verbose: 1 > dev.acpi_hp.0.verbose: 0 # set to "1" in loader.conf but ignored. > hw.acpi.verbose: 1 acpi_hp itself is loaded, so that one probably needs setting in /etc/sysctl.conf; don't know it's likely to be more informative. > > If you run powerd -v, > > what sort of freqs does it usually run at, when more or less idle? > > When 75 to 90% idle (from top) > > sysctl -a | grep freq | grep -v "cpufreq" > kern.acct_chkfreq: 15 > kern.timecounter.tc.i8254.frequency: 1193182 > kern.timecounter.tc.ACPI-safe.frequency: 3579545 > kern.timecounter.tc.HPET.frequency: 14318180 > kern.timecounter.tc.TSC.frequency: 1595998039 > net.inet.sctp.sack_freq: 2 > machdep.acpi_timer_freq: 3579545 > machdep.tsc_freq: 1595998039 > machdep.i8254_freq: 1193182 All irrelevant in this context. Timecounter used is hpet, quality 900, with acpi-safe coming in second best at 850 (dmesg). > dev.cpu.0.freq: 497 > dev.cpu.0.freq_levels: 1592/100000 1393/87500 1194/75000 995/62500 796/35457 696/31024 597/26592 497/22160 398/17728 298/13296 199/8864 99/4432 > dev.acpi_throttle.0.freq_settings: 10000/-1 8750/-1 7500/-1 6250/-1 5000/-1 3750/-1 2500/-1 1250/-1 > dev.powernow.0.freq_settings: 1592/100000 796/35457 > dev.powernow.1.freq_settings: 1592/100000 796/35457 Logging dev.cpu.0.freq vs hw.acpi.thermal.tz0.temperature is mostly all that's needed. With timestamps, and fan speed where available. Most of what I want to know routinely here is shown by: #!/bin/sh echo -n "`date` " sysctl dev.cpu.0.freq dev.cpu.0.cx_usage sysctl dev.acpi_ibm | egrep 'fan_|thermal' sysctl hw.acpi.thermal.tz0.temperature acpiconf -i0 | egrep 'State|Remain|Present|Volt' t23# t23stat # at 29C ambient Thu Jan 5 17:10:32 EST 2012 dev.cpu.0.freq: 733 dev.cpu.0.cx_usage: 0.01% 99.98% 0.00% last 766us dev.acpi_ibm.0.fan_speed: 2391 dev.acpi_ibm.0.fan_level: 1 dev.acpi_ibm.0.thermal: 49 49 46 -1 -1 -1 32 -1 hw.acpi.thermal.tz0.temperature: 49.0C State: high Remaining capacity: 100% Remaining time: unknown Present rate: 0 mW Present voltage: 12381 mV > On an idle machine, > (with a little patch from Gary J. to allow for multiple cores: > /src/bsd/fixes/FreeBSD/src/gen/usr.sbin/powerd.c.REL=8.2-RELEASE.diff Local path I guess? If the patch is trying to set cpu.1.freq it might explain eg 'powerd: error setting CPU frequency 398: Invalid argument' below? when clearly the requested freqs are being set .. we just set cpu.0.freq for all cores, there's (so far) no ability to run different cores or packages at different freqs, that I've heard of. mav@, avg@ or someone@ will correct me if I'm (yet again :) behind the times! > running powerd -v # Using defaults > powerd: using sysctl for AC line status > powerd: using devd for AC line status > load 64%, current freq 199 MHz (10), wanted freq 339 MHz > changing clock speed from 199 MHz to 398 MHz > powerd: error setting CPU frequency 398: Invalid argument > load 27%, current freq 398 MHz ( 8), wanted freq 339 MHz > load 7%, current freq 398 MHz ( 8), wanted freq 328 MHz > load 4%, current freq 398 MHz ( 8), wanted freq 317 MHz > load 8%, current freq 398 MHz ( 8), wanted freq 307 MHz > load 12%, current freq 398 MHz ( 8), wanted freq 297 MHz > changing clock speed from 398 MHz to 298 MHz > powerd: error setting CPU frequency 298: Invalid argument > load 25%, current freq 298 MHz ( 9), wanted freq 297 MHz > load 7%, current freq 298 MHz ( 9), wanted freq 287 MHz > load 14%, current freq 298 MHz ( 9), wanted freq 278 MHz > load 15%, current freq 298 MHz ( 9), wanted freq 269 MHz > load 7%, current freq 298 MHz ( 9), wanted freq 260 MHz > load 6%, current freq 298 MHz ( 9), wanted freq 251 MHz > load 0%, current freq 298 MHz ( 9), wanted freq 243 MHz > load 4%, current freq 298 MHz ( 9), wanted freq 235 MHz > load 10%, current freq 298 MHz ( 9), wanted freq 227 MHz > load 0%, current freq 298 MHz ( 9), wanted freq 219 MHz > load 17%, current freq 298 MHz ( 9), wanted freq 212 MHz > load 0%, current freq 298 MHz ( 9), wanted freq 205 MHz > load 3%, current freq 298 MHz ( 9), wanted freq 198 MHz > changing clock speed from 298 MHz to 199 MHz > powerd: error setting CPU frequency 199: Invalid argument > load 42%, current freq 199 MHz (10), wanted freq 221 MHz > changing clock speed from 199 MHz to 298 MHz > powerd: error setting CPU frequency 298: Invalid argument > load 33%, current freq 298 MHz ( 9), wanted freq 221 MHz [..] Some relative timestamps on these would give a better idea over time, but clearly it's using low freqs at low loads. > > you using default powerd settings? > > I was when it crashed too often to be useful. > accepting values from /etc/defaults/rc.conf > but it crashed too much, so my rc.conf is now set to give: > /usr/sbin/powerd -a adaptive -b minimum -n minimum Should be ok. Seems powerd is behaving as expected; if it's overheating at those low freqs (or not cooling off once idle) and it's just about brand new re dust on heatsinks etc, may be a real issue under warranty? > > When running on battery can you > > monitor power use with acpiconf -i0 to see the actual effect on power > > usage of running at various lower freqs? > > Wow what a nice command ! > Design capacity: 57276 mWh > Last full capacity: 55544 mWh > Technology: secondary (rechargeable) > Design voltage: 11100 mV > Capacity (warn): 5554 mWh > Capacity (low): 0 mWh > Low/warn granularity: 555 mWh > Warn/full granularity: 555 mWh > Model number: 5160 > Serial number: Li4402A > Type: Li > OEM info: Hewlett-Packard > State: high > Remaining capacity: 100% > Remaining time: unknown > Present rate: unknown > Present voltage: 12375 mV > > Yes I could do that. I dont see anything that's going to give me > instantaneous consumption readings above though, & battery state 'State: high' shows it's on AC, fully charged. While running ON BATTERY you should see something more like (here): State: discharging Remaining capacity: 98% Remaining time: 1:59 Present rate: 15716 mW Present voltage: 12025 mV At idle (here), ie 15.7W for the whole machine, nominally 12.5W for CPU at low speed, 19.1W at 'high' speed. Measured from the wall, actually from the house battery ammeter pre-inverter (12V solar), on AC this box draws ~18W @733 (mostly C2 state) and ~36W @1133 (working, C1 state). t23# sysctl dev.cpu | grep -v '\.%' dev.cpu.0.freq: 733 dev.cpu.0.freq_levels: 1133/19100 733/12500 dev.cpu.0.cx_supported: C1/0 C2/84 C3/120 dev.cpu.0.cx_lowest: C2 dev.cpu.0.cx_usage: 0.00% 99.99% 0.00% last 732us Your mW or mA rates will be far greater of course. To elaborate on what Alexander said a bit, your 'real' nominal CPU power ratings are: > dev.powernow.0.freq_settings: 1592/100000 796/35457 > dev.powernow.1.freq_settings: 1592/100000 796/35457 ie 100.000W @1592, and 35.457W @796MHz. I think that has to be per package, I can't believe 200W for both cores, 100W is heaps anyway. That of course is in addition to all other power use by the machine; in my case only a few watts, but your GPU alone may be using a lot, and I recall seeing some modern HPs use a common heatsink/pipes for CPU & GPU. > prediction is generaly not accurate. However, I can do better, I > can connect a power meter between wall supply & transformer > (battery will be irrelevant if full, not charging) & see how much > power is going in. & a temperature probe underneath. (OK, heat > emitted by screen I don't care about, (just any heat in chassis, > from inefficiency converting for screen), I'll see if I can turn > off screen with keys or BIOS) Yes an accurate power meter is the go, and GPUs can be a large part of total heat source in modern notebooks. Luckily I have no such issue :) I guess measuring with/without X running should show some difference? What you're looking for is your 'baseload' power draw at idle, vs when working at various rates. GLXgears may be the 'hottest' thing I know. > But I guess another way is to hack the ACPI to turn the fan on at > lower threshold. ? Maybe I'll have to tweak what I got from acpidump -dt > http://berklix.com/~jhs/hardware/hp/pavilion/dm3-1155ea/jhs-hp-pPavilion-dm3-1155ea.asl > per: > http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/acpi-debug.html No time to look now, but it's possible your AML doesn't provide access to fan/s at all, hunt through _TZ stuff. Here only acpi_ibm provides fan access and it's quite specific to IBM/Lenovo kit. acpi_hp.c may be rewarding bedtime reading, but acpi_hp(4) makes no mention of fans and such - but turning off (if unused) wifi, bluetooth & firewire will help. > > acpi_throttle0: on cpu0 > > acpi_throttle0: P_CNT from P_BLK 0x410 > > powernow0: on cpu0 > > powernow1: on cpu1 > > powernow & throttling all new to me, I must web search. > sysctl -d dev.powernow.0.freq_settings > dev.powernow.0.freq_settings: CPU frequency driver settings Start with cpufreq(4) for a good overview of all the various pieces, but most drivers (eg powernow) mentioned have scant or no docs, except code. (Warning: once you go down this rabbit hole, you may never come back! :) > > I also notice only C1 states, but using machdep.idle: amdc1e so I wonder > > if you're getting benefit from that? Are there BIOS settings re that? > > I didnt know what C1 was. Found it: > http://en.wikipedia.org/wiki/Advanced_Configuration_and_Power_Interface > > sysctl -a | grep machdep.idle > machdep.idle: amdc1e > machdep.idle_available: spin, amdc1e, hlt, acpi, > sysctl -d machdep.idle > machdep.idle: currently selected idle function > sysctl -d machdep.idle_available > machdep.idle_available: list of available idle functions > > Where are you seeing the C1 ? Wkipedia does make C1E sound more desirable. machdep.idle: amdc1e .. I know too little about how it works to comment, except that it should be a lower power mode than basic C1, and I think reading both mav's excellent article and the wikipedia one should help. True masochists can revel in days of fun, reading the whole ACPI spec. > I went throught the screen BIOS a while back & found no power > / temp / frequency options, was a rather limited BIOS. As http://wiki.freebsd.org/TuningPowerConsumption says, AMD tend to hide most of the internal C-state management. Maybe worth trying 9.0 on it? > > > /boot/loader.conf > > > I just added > > > acpi_hp_load="YES" > > > (after reboot) does not produce /dev/hpcmi Perhaps yours isn't one of acpi_hp's more-targetted models? > > I don't see any mention of active cooling (ie, fan/s) in your sysctls, > > including acpi_hp. > > Yes, been puzzling me that, There is one little fan slot, doesnt > seem to blow hot right now, when under case too hot to hold. > Yes I cant see revs/min Warner suggested more about this, and Kevin's contribution is noteworthy also. If the fan's working right, there should be HOT! air being pumped out when it's hot. A home-made stethoscope should let you hear it spin. >From everything to date, I wonder if it doesn't just have a broken fan? > > Here I'm running a custom script to control CPU fan > > via acpi_ibm (the auto fan didn't cut in till over 65C, then pumped it > > down to ~45C), but it seems you may not have access to fan control? > > I dont know how to control the fan. I'd like to see your script please, > or at least commands you'r running. Sure, below .. but I doubt much of it's any use on your HP. > kldload acpi_ibm ; kldstat > kernel sound.ko snd_hda.ko acpi_hp.ko acpi_wmi.ko linux.ko > linux_adobe.ko radeon.ko drm.ko acpi_ibm.ko I'm quite surprised it even loaded. What says sysctl dev.acpi_ibm ? > > You could try setting hw.acpi.thermal.user_override=1 and then set > hw.acpi.thermal.tz0._PSV to something lower than 90C, perhaps much lower > > to see if it helps, especially if 'crashing' occurs closer to 90C than > > not, however: > > sysctl hw.acpi.thermal.tz0._PSV > hw.acpi.thermal.tz0._PSV: 90.0C > sysctl hw.acpi.thermal.user_override > hw.acpi.thermal.user_override: 0 > sysctl hw.acpi.thermal.user_override > sysctl hw.acpi.thermal.tz0._PSV=60.0C > sysctl -a | grep acpi.thermal > hw.acpi.thermal.min_runtime: 0 > hw.acpi.thermal.polling_rate: 10 > hw.acpi.thermal.user_override: 1 > hw.acpi.thermal.tz0.temperature: 69.0C > hw.acpi.thermal.tz0.active: -1 > hw.acpi.thermal.tz0.passive_cooling: 1 > hw.acpi.thermal.tz0.thermal_flags: 1 > hw.acpi.thermal.tz0._PSV: 60.0C > hw.acpi.thermal.tz0._HOT: 95.0C > hw.acpi.thermal.tz0._CRT: 100.0C > hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 > hw.acpi.thermal.tz0._TC1: 2 > hw.acpi.thermal.tz0._TC2: 3 > hw.acpi.thermal.tz0._TSP: 40 > > I think that's forced the frequency down, Xterm to machine is sluggish > & powerd -v reports: > changing clock speed from 99 MHz to 1592 MHz > load 177%, current freq 99 MHz (11), wanted freq 3184 MHz > changing clock speed from 99 MHz to 1592 MHz > load 179%, current freq 99 MHz (11), wanted freq 3184 MHz > changing clock speed from 99 MHz to 1592 MHz > load 151%, current freq 99 MHz (11), wanted freq 3184 MHz Seems to be working. You likely never really want to run this slowly, even with hiadaptive it's going to take a while to get 'unsluggish', so even without overheating issues you may want to set debug.cpufreq.lowest to something vaguely usable, maybe 300MHz or so? However, I'd definitely try disabling throttling; all those N/8 freqs may be doing more harm than good in some contexts .. in loader.conf: hint.acpi_throttle.0.disabled=1 # possibly? also needing: hint.acpi_throttle.1.disabled=1 which should leave only the 'native' 1592 and 796 rates. Worth a try? > sysctl hw.acpi.thermal.tz0._HOT=62.0C > I dont hear or feel fan faster. > ... just crashed. !sysctl -d hw.acpi.thermal [..] hw.acpi.thermal.tz0.active: cooling is active hw.acpi.thermal.tz0.passive_cooling: enable passive (speed reduction) cooling hw.acpi.thermal.tz0.thermal_flags: thermal zone flags hw.acpi.thermal.tz0._PSV: passive cooling temp setpoint hw.acpi.thermal.tz0._HOT: too hot temp setpoint (suspend now) hw.acpi.thermal.tz0._CRT: critical temp setpoint (shutdown now) [..] So with a low _HOT it may have tried suspending? _CRT is likely more useful for a clean shutdown - unless it suspends and resumes cleanly? > > > Running 80% idle (just a fsck_ufs) I see: > > > hw.acpi.thermal.tz0.temperature: 67.0C > > > dev.acpi_hp.0.hdd_temperature: 4 > > > > 67C isn't really hot on a dual core laptop with 100W rating at 1592MHz. > > Still, if you had it drop back immediately on idle to 796MHz, you'd be > > saving about 60W, which may help considerable. > > > > I expect you've done the usual check/clean airways, thermal grease etc? > > New notebook, used about 2 hours by mother in a clean office, > then by me ditto, however yes, might be manufacturing error & lack of grease. > Not opened it yet. I guess how it runs on Windows may be the only basis for warranty .. or maybe try some Linux live CD to eliminate any possible FreeBSD issues? cheers, Ian Pardon overcommented and overdefensive (not to say paranoid) coding .. blame my IBM training in 1970 - you never really recover from that! ======= #!/bin/sh # temp_t23 smithi v0 7/11/11, tidy 12/11/11, v2 fan read delay 22/11/11 # v3 18/12/11 suspend / resume resets dev.acpi_ibm.0.fan=1 (ie auto) none=0; slow=1; fast=3 # Thinkpad T23 fan levels (1-2, 3-7 same) vhtemp=60 # above, immediately fast hitemp=50 # above twice, fan fast lotemp=45 # below twice, fan off hyst=3 # degs hysteresis on transitions log='/root/temp_t23.log' echo "`date` temp_t23 start: enabling manual fan control" >>$log sysctl dev.acpi_ibm.0.fan >/dev/null [ $? -ne 0 ] && echo "acpi_ibm not loaded?" >>$log && exit 1 t=`sysctl -n hw.acpi.thermal.tz0.temperature`; t=${t%??C} [ $t -lt 10 -o $t -gt 99 ] && echo "${t}C unbelievable!" >>$log && exit 2 sysctl dev.acpi_ibm.0.fan=0 >/dev/null # turn auto fan control OFF [ $? -ne 0 ] && echo "can't disable auto fan control!" >>$log && exit 3 [ "$1" ] && sleep=$1 || sleep=10 # seconds between samples last_t=$vhtemp # if starting hot, fan fast last_level=9 # set fan immediately level=$slow rc=0; done=0; trap "done=1" int quit term while [ $done -eq 0 ]; do if [ $t -gt $hitemp ]; then # twice or much, max fan (~4800rpm) [ $last_t -gt $hitemp -o $t -ge $vhtemp ] && level=$fast elif [ $t -lt $lotemp ]; then # below twice, fan off [ $last_t -lt $lotemp ] && level=$none else # between: after hysteresis set fan to min (~2400rpm) if [ $level -eq $fast ]; then # falling [ $t -le $(($hitemp - $hyst)) ] && level=$slow elif [ $level -eq $none ]; then # rising [ $t -ge $(($lotemp + $hyst)) ] && level=$slow fi fi if [ $level -ne $last_level ]; then sysctl dev.acpi_ibm.0.fan_level=$level >/dev/null [ $? -ne 0 ] && echo "can't set level $level" >>$log && break # for now, log all level changes # v2 fan_speed settle delay echo -n "`date` ${t}C fan_level -> $level " >>$log; sleep 5 echo "`sysctl -n dev.acpi_ibm.0.fan_speed`rpm" >>$log else sleep $sleep # catch ^C or term; done=1 fi if [ `sysctl -n dev.acpi_ibm.0.fan` -ne 0 ]; then # v3 echo -n "`date` resume: reenable manual fan at ${t}C" >>$log sysctl dev.acpi_ibm.0.fan=0 >/dev/null # back to manual fan [ $? -ne 0 ] && echo " .. FAILED!" >>$log && rc=3 && break echo >>$log fi last_level=$level last_t=$t t=`sysctl -n hw.acpi.thermal.tz0.temperature`; t=${t%??C} done if [ $done -ne 1 ]; then echo "temp_t23 error: done=$done ${t}C level=$level" >>$log [ $rc -eq 0 ] && rc=7 # not that anybody's listening :) fi echo "`date` temp_t23 end: reenabling auto fan control at ${t}C" >>$log sysctl dev.acpi_ibm.0.fan=1 >/dev/null # auto fan ON [ $? -ne 0 ] && echo " REENABLING AUTO FAN FAILED!" >>$log && rc=9 trap - int quit term exit $rc ======= Thu Jan 5 08:03:23 EST 2012 48C fan_level -> 1 2298rpm Thu Jan 5 08:27:20 EST 2012 44C fan_level -> 0 0rpm Thu Jan 5 08:30:35 EST 2012 48C fan_level -> 1 2310rpm Thu Jan 5 08:45:01 EST 2012 44C fan_level -> 0 0rpm Thu Jan 5 08:47:26 EST 2012 48C fan_level -> 1 2286rpm Thu Jan 5 14:23:35 EST 2012 52C fan_level -> 3 4936rpm Thu Jan 5 14:25:00 EST 2012 47C fan_level -> 1 2361rpm Thu Jan 5 14:43:27 EST 2012 51C fan_level -> 3 5026rpm Thu Jan 5 14:45:32 EST 2012 47C fan_level -> 1 2347rpm Thu Jan 5 15:02:58 EST 2012 52C fan_level -> 3 4952rpm Thu Jan 5 15:05:23 EST 2012 47C fan_level -> 1 2357rpm Thu Jan 5 15:22:19 EST 2012 52C fan_level -> 3 5010rpm Thu Jan 5 15:25:05 EST 2012 47C fan_level -> 1 2326rpm From owner-freebsd-mobile@FreeBSD.ORG Thu Jan 5 10:40:35 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A755B10657CC for ; Thu, 5 Jan 2012 10:40:35 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from sola.nimnet.asn.au (paqi.nimnet.asn.au [115.70.110.159]) by mx1.freebsd.org (Postfix) with ESMTP id 130808FC13 for ; Thu, 5 Jan 2012 10:40:34 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by sola.nimnet.asn.au (8.14.2/8.14.2) with ESMTP id q05AePoU003697; Thu, 5 Jan 2012 21:40:27 +1100 (EST) (envelope-from smithi@nimnet.asn.au) Date: Thu, 5 Jan 2012 21:40:25 +1100 (EST) From: Ian Smith To: "Julian H. Stacey" In-Reply-To: <20120105020833.U62686@sola.nimnet.asn.au> Message-ID: <20120105193905.S62686@sola.nimnet.asn.au> References: <201201030332.q033WRLE064421@fire.js.berklix.net> <20120105020833.U62686@sola.nimnet.asn.au> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: "Alexandre \"Sunny\" Kovalenko" , mobile@freebsd.org Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Jan 2012 10:40:35 -0000 On Thu, 5 Jan 2012, Ian Smith wrote: > ======= > #!/bin/sh > # temp_t23 smithi v0 7/11/11, tidy 12/11/11, v2 fan read delay 22/11/11 + # Credit to Alexandre "Sunny" Kovalenko whose + # earlier scripts for managing acpi_ibm resources inspired this one. > # v3 18/12/11 suspend / resume resets dev.acpi_ibm.0.fan=1 (ie auto) > none=0; slow=1; fast=3 # Thinkpad T23 fan levels (1-2, 3-7 same) And of course it was also Alexandre who (I think originally) proposed monitoring temperature to directly implement cooling via lower powerd freqs, according to old email, in Feb 2006. I'd even forgotten having reviewed and added a line or two to that patch .. if I lost my archives I'd probably have no memory left at all :) This post: http://lists.freebsd.org/pipermail/freebsd-acpi/2008-February/004521.html points to this PR: http://www.freebsd.org/cgi/query-pr.cgi?pr=bin%2F120336&cat= which was closed with reference to this post: http://docs.FreeBSD.org/cgi/mid.cgi?1203126071.833.19.camel Useless trying to apply anything like this to recent powerd sources, though. Good luck with getting its fan to go, or a warranty claim! cheers, Ian From owner-freebsd-mobile@FreeBSD.ORG Thu Jan 5 19:30:04 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 18A26106571C; Thu, 5 Jan 2012 19:30:04 +0000 (UTC) (envelope-from owner-freebsd-stable@freebsd.org) Received: from web.npulse.net (web.npulse.net [79.172.194.2]) by mx1.freebsd.org (Postfix) with SMTP id 5138D8FC1C; Thu, 5 Jan 2012 19:30:01 +0000 (UTC) Received: by web (Postfix, from userid 143) id 95DE2DC280; Tue, 3 Jan 2012 03:27:53 +0000 (UTC) Received: from mx2.freebsd.org (mx2.freebsd.org [69.147.83.53]) by web (Postfix) with ESMTP id 5E511DC275 for ; Tue, 3 Jan 2012 03:27:51 +0000 (UTC) Received: from hub.freebsd.org (hub.freebsd.org [IPv6:2001:4f8:fff6::36]) by mx2.freebsd.org (Postfix) with ESMTP id 5B1EC1A475F; Tue, 3 Jan 2012 03:21:49 +0000 (UTC) Received: from hub.freebsd.org (localhost [127.0.0.1]) by hub.freebsd.org (Postfix) with ESMTP id 454141065703; Tue, 3 Jan 2012 03:21:48 +0000 (UTC) (envelope-from owner-freebsd-stable@freebsd.org) Delivered-To: stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6FA9F106564A; Tue, 3 Jan 2012 03:21:28 +0000 (UTC) (envelope-from sukenwoo@gmail.com) Received: from mail-vw0-f54.google.com (mail-vw0-f54.google.com [209.85.212.54]) by mx1.freebsd.org (Postfix) with ESMTP id E7BF08FC0C; Tue, 3 Jan 2012 03:21:27 +0000 (UTC) Received: by vbbfr13 with SMTP id fr13so21370515vbb.13 for ; Mon, 02 Jan 2012 19:21:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:cc:content-type; bh=2fEVaeTULYDT0uxBjBC2cvBv4/aKfATi9vdnhVokiZs=; b=blJn0ffL7I9/zTTTvRiBTQhti6FTgw18zMosDn4vRAF3R5ojmrE9C3zD7M0MkLrqzd 441QO+pppakWPc6/h+zrF6+iM7z1OB0mhoB8t2pOzJ7xV9bFOBAUupmvDzTlgG1pssJE KyOG4J2gCZgk/ph0tKhk9BiWJNhoaMYmdXoT8= MIME-Version: 1.0 Received: by 10.52.71.106 with SMTP id t10mr7957505vdu.103.1325559008680; Mon, 02 Jan 2012 18:50:08 -0800 (PST) Received: by 10.52.26.1 with HTTP; Mon, 2 Jan 2012 18:50:08 -0800 (PST) Date: Tue, 3 Jan 2012 10:50:08 +0800 Message-ID: From: suken woo To: current@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Sender: owner-freebsd-stable@freebsd.org Errors-To: owner-freebsd-stable@freebsd.org Cc: stable@freebsd.org, mobile@freebsd.org, net@freebsd.org Subject: DLink DWL-G132 USB wifi Adapter failed under 9.0 RC3 X-BeenThere: freebsd-mobile@freebsd.org List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Jan 2012 19:30:04 -0000 hi lists DWL-G132 failed to load on 9.0RC3 uath0: on usbus3 uath0: timeout waiting for reply to cmd 0x4 (4) uath0: could not read capability 3 uath0: could not get device capabilities device_attach: uath0 attach returned 35 and uathload lp# uathload -v -d /dev/ugen3.2 Load firmware ar5523.bin (builtin) to /dev/ugen3.2 send block 0: 151368 bytes remaining : data... : wait for ack... uathload: error reading msg (/dev/usb/3.2.1): No error: 0 usbconfig -u 3 -a 2 dump_device_desc ugen3.2: at usbus3, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0200 bDeviceClass = 0x00ff bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0000 bMaxPacketSize0 = 0x0040 idVendor = 0x2001 idProduct = 0x3a02 bcdDevice = 0x0001 iManufacturer = 0x0001 iProduct = 0x0002 iSerialNumber = 0x0003 <1.0> bNumConfigurations = 0x0001 _______________________________________________ freebsd-stable@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscribe@freebsd.org" From owner-freebsd-mobile@FreeBSD.ORG Fri Jan 6 19:30:24 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2ACCA1065705 for ; Fri, 6 Jan 2012 19:30:24 +0000 (UTC) (envelope-from kob6558@gmail.com) Received: from mail-we0-f182.google.com (mail-we0-f182.google.com [74.125.82.182]) by mx1.freebsd.org (Postfix) with ESMTP id A53E38FC08 for ; Fri, 6 Jan 2012 19:30:23 +0000 (UTC) Received: by werb13 with SMTP id b13so1958530wer.13 for ; Fri, 06 Jan 2012 11:30:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=vzOYYXkajou8JdfonQomYqbf/bJdC8QNabVkApVdgbk=; b=bVhr05admjHunXxiTRP9SIYLjyq7M2lfiJWzjOzF2LzvS/hQkOo3HC5RH7ECjx5Mg7 ipfcVhHhgXXDPTH3b7vxMM+gurRHWx7XIxZMi7MfjRpjWqluf5onG6Q/5amdnTgg2UF4 OjS20QQoRcCk5UCc9TVLE8JuBC2T9b7gQt5f4= MIME-Version: 1.0 Received: by 10.216.143.66 with SMTP id k44mr3997399wej.56.1325876342850; Fri, 06 Jan 2012 10:59:02 -0800 (PST) Received: by 10.223.158.129 with HTTP; Fri, 6 Jan 2012 10:59:02 -0800 (PST) In-Reply-To: <20120105193905.S62686@sola.nimnet.asn.au> References: <201201030332.q033WRLE064421@fire.js.berklix.net> <20120105020833.U62686@sola.nimnet.asn.au> <20120105193905.S62686@sola.nimnet.asn.au> Date: Fri, 6 Jan 2012 10:59:02 -0800 Message-ID: From: Kevin Oberman To: Ian Smith Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: "Julian H. Stacey" , "Alexandre \"Sunny\" Kovalenko" , mobile@freebsd.org Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Jan 2012 19:30:24 -0000 On Thu, Jan 5, 2012 at 2:40 AM, Ian Smith wrote: > On Thu, 5 Jan 2012, Ian Smith wrote: > > ======= > > #!/bin/sh > > # temp_t23 smithi v0 7/11/11, tidy 12/11/11, v2 fan read delay 22/11/11 > > + # Credit to Alexandre "Sunny" Kovalenko whose > + # earlier scripts for managing acpi_ibm resources inspired this one. > > > # v3 18/12/11 suspend / resume resets dev.acpi_ibm.0.fan=1 (ie auto) > > none=0; slow=1; fast=3 # Thinkpad T23 fan levels (1-2, 3-7 same) > > And of course it was also Alexandre who (I think originally) proposed > monitoring temperature to directly implement cooling via lower powerd > freqs, according to old email, in Feb 2006. I'd even forgotten having > reviewed and added a line or two to that patch .. if I lost my archives > I'd probably have no memory left at all :) > > This post: > http://lists.freebsd.org/pipermail/freebsd-acpi/2008-February/004521.html > points to this PR: > http://www.freebsd.org/cgi/query-pr.cgi?pr=bin%2F120336&cat= > which was closed with reference to this post: > http://docs.FreeBSD.org/cgi/mid.cgi?1203126071.833.19.camel > > Useless trying to apply anything like this to recent powerd sources, > though. Good luck with getting its fan to go, or a warranty claim! > First of all, I am highly suspicious of hardware issues. Like Ian says, the temperature measured in the chip and quite a bit higher than those measured on the motherboard. Beyond that, if the die temperature gets too high, all modern CPUs kill the power supply and the system dies almost instantly. I suspect this may be what is happening to you due to poor heat transfer from the die to the heatsink from poor attachment of the heatsink or a flaw in the CPU thermal connection between the die and the thermal transfer plate on the top of the case. (The former is FAR more likely.) Beyond this, I don't think the OS should be trying to deal with this. All "modern" CPUs, Intel or AMD, support some form of TCC and, if not interfered with, it will slow the clock in increments of 12.5% as needed to keep the temperature below PSV. This is done in a combination of hardware and BIOS and is supported by FreeBSD, but FreeBSD also tries to use it to do power management and as test both by myself and, more recently by mav@, this is a bad idea. Both throttling and TCC should be disabled and I would love to see them completely removed from power management. I have read papers which make it clear that only EST and sleep (Cx) states are really useful for power management and that Cx is by far and away the most significant, but enabling deep sleep states can cause the system to lock up when combined with TCC or throttling. If you want to keep a system cool, add: performance_cx_lowest="LOW" economy_cx_lowest="LOW" to /etc/rc.conf and disable TCC and throttling in /boot/loader.conf. -- R. Kevin Oberman, Network Engineer E-mail: kob6558@gmail.com From owner-freebsd-mobile@FreeBSD.ORG Sat Jan 7 05:18:55 2012 Return-Path: Delivered-To: mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0430D106564A for ; Sat, 7 Jan 2012 05:18:55 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from sola.nimnet.asn.au (paqi.nimnet.asn.au [115.70.110.159]) by mx1.freebsd.org (Postfix) with ESMTP id D5B708FC13 for ; Sat, 7 Jan 2012 05:18:53 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by sola.nimnet.asn.au (8.14.2/8.14.2) with ESMTP id q075IdDO092607; Sat, 7 Jan 2012 16:18:40 +1100 (EST) (envelope-from smithi@nimnet.asn.au) Date: Sat, 7 Jan 2012 16:18:39 +1100 (EST) From: Ian Smith To: Kevin Oberman In-Reply-To: Message-ID: <20120107142733.Y3704@sola.nimnet.asn.au> References: <201201030332.q033WRLE064421@fire.js.berklix.net> <20120105020833.U62686@sola.nimnet.asn.au> <20120105193905.S62686@sola.nimnet.asn.au> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: "Julian H. Stacey" , "Alexandre \"Sunny\" Kovalenko" , mobile@freebsd.org Subject: Re: powerd to use sysctl to import temps to drop freq to avoid heat crash X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 07 Jan 2012 05:18:55 -0000 On Fri, 6 Jan 2012, Kevin Oberman wrote: > On Thu, Jan 5, 2012 at 2:40 AM, Ian Smith wrote: > > > On Thu, 5 Jan 2012, Ian Smith wrote: [..] > > This post: > > http://lists.freebsd.org/pipermail/freebsd-acpi/2008-February/004521.html > > points to this PR: > > http://www.freebsd.org/cgi/query-pr.cgi?pr=bin%2F120336&cat= > > which was closed with reference to this post: > > http://docs.FreeBSD.org/cgi/mid.cgi?1203126071.833.19.camel > > > > Useless trying to apply anything like this to recent powerd sources, > > though. Good luck with getting its fan to go, or a warranty claim! > First of all, I am highly suspicious of hardware issues. Like Ian says, the > temperature measured in the chip and quite a bit higher than those measured > on the motherboard. Beyond that, if the die temperature gets too high, all > modern CPUs kill the power supply and the system dies almost instantly. I > suspect this may be what is happening to you due to poor heat transfer from > the die to the heatsink from poor attachment of the heatsink or a flaw in > the CPU thermal connection between the die and the thermal transfer plate > on the top of the case. (The former is FAR more likely.) I'm agreed with your analysis of likely causes Kevin, but in this case temps measured on the chip are (at that time) ~9C _lower_ than whatever sensor provides hw.acpi.thermal.tz0.temperature - the latter being what ACPI takes as here CPU temperature. Quoting Julian's one set of data: dev.amdtemp.0.sensor0.core0: 51.0C dev.amdtemp.0.sensor0.core1: 49.0C dev.amdtemp.0.sensor1.core0: 58.0C dev.amdtemp.0.sensor1.core1: 56.0C dev.cpu.0.temperature: 57.0C dev.cpu.1.temperature: 57.0C hw.acpi.thermal.tz0.temperature: 66.0C According to amdtemp(4) (and amdtemp.c), dev.cpu.N.temperature is "Max of sensor 0 / 1", although that doesn't entirely tally with above data. Either way, hw.acpi.thermal.tz0.temperature is 8-9C higher, and it's that temperature that will be compared to _PSV, _HOT and _CRT settings. >> hw.acpi.thermal.tz0._PSV: 90.0C >> hw.acpi.thermal.tz0._HOT: 95.0C >> hw.acpi.thermal.tz0._CRT: 100.0C In other words, the CPU may not be as hot internally as it appears, re Julian's concern about damaging more than his lap :) That doesn't help the problem of course - I still think the fan's a prime suspect - but it may be indicative of why the machine is crashing. Once it hits 95C (_HOT), which is then perhaps only 85C or so on-core, it's going to try to suspend - which likely won't work anyway - which would surely appear as 'crashing'. On any machine that won't suspend (and resume), it makes little sense to allow _HOT to be reached when _CRT at least should provide a clean shutdown, disk/s sync'd etc. So Julian, I think setting _HOT higher than _CRT (to get it out of the way) might help in the meantime to at least get a clean(er) shutdown. > Beyond this, I don't think the OS should be trying to deal with this. All > "modern" CPUs, Intel or AMD, support some form of TCC and, if not > interfered with, it will slow the clock in increments of 12.5% as needed > to keep the temperature below PSV. This is done in a combination of > hardware and BIOS and is supported by FreeBSD, but FreeBSD also tries to > use it to do power management and as test both by myself and, more recently > by mav@, this is a bad idea. Both throttling and TCC should be disabled and > I would love to see them completely removed from power management. It may be they're still of some/more use on some older kit? What about offering a patch to the default loader hints, just defaulting them off, and see who bites? :) > I have read papers which make it clear that only EST and sleep (Cx) states > are really useful for power management and that Cx is by far and away the > most significant, but enabling deep sleep states can cause the system to > lock up when combined with TCC or throttling. > > If you want to keep a system cool, add: > performance_cx_lowest="LOW" > economy_cx_lowest="LOW" > to /etc/rc.conf and disable TCC and throttling in /boot/loader.conf. In Julian's case there's only C1/0, so "LOW" is the same as "HIGH"; there's no p4tcc on AMD; yes throttling {c,sh}ould be disabled, and powernow is pretty much AMD's equivalent of Intel EST, controlling both P-state frequency and core voltage. http://wiki.freebsd.org/TuningPowerConsumption has this to say about the (apparently desirable) AMD C1E state(/s): on FreeBSD 8 - "As soon as entering C1E on AMD CPUs may result in unexpected and uncontrolled entering C3 and resulting local APIC timer stop, FreeBSD 8.x blocks C1E functionality completely." while on FreeBSD 9 - "On AMD CPUs FreeBSD 9.x blocks C1E only when local APIC timer is used. If the local APIC timer was ever used since boot, C1E will be blocked till the next reboot. You may want to force some other timer to be used in order to allow C1E to work." But all of that is icing on the cake .. if the fan/s and heatsinks are working, it should only be in far more extreme cases than 'normal' use that this machine should be falling over so. cheers, Ian > -- > R. Kevin Oberman, Network Engineer > E-mail: kob6558@gmail.com