From owner-freebsd-stable@FreeBSD.ORG Wed May 12 14:17:02 2010 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 1385F106566C for ; Wed, 12 May 2010 14:17:02 +0000 (UTC) (envelope-from oberman@es.net) Received: from mailgw.es.net (mail1.es.net [198.129.252.210]) by mx1.freebsd.org (Postfix) with ESMTP id EE7688FC12 for ; Wed, 12 May 2010 14:17:01 +0000 (UTC) Received: from ptavv.es.net (ptavv.es.net [IPv6:2001:400:910::29]) by mailgw.es.net (8.14.3/8.14.3) with ESMTP id o4CDvPSs007998 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 12 May 2010 06:57:25 -0700 Received: from ptavv.es.net (localhost [127.0.0.1]) by ptavv.es.net (Tachyon Server) with ESMTP id 7D85F1CC24; Wed, 12 May 2010 06:57:24 -0700 (PDT) To: David DEMELIER In-reply-to: Your message of "Wed, 12 May 2010 15:35:51 +0200." Date: Wed, 12 May 2010 06:57:24 -0700 From: "Kevin Oberman" Message-Id: <20100512135724.7D85F1CC24@ptavv.es.net> X-Proofpoint-Virus-Version: vendor=fsecure engine=1.12.8161:2.4.5, 1.2.40, 4.0.166 definitions=2010-05-12_03:2010-02-06, 2010-05-12, 2010-05-12 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 ipscore=0 phishscore=0 bulkscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx engine=5.0.0-0908210000 definitions=main-1005120065 Cc: Giovanni Trematerra , freebsd-stable@freebsd.org Subject: Re: Kernel panic when unpluggin AC adaptor X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 May 2010 14:17:02 -0000 > Date: Wed, 12 May 2010 15:35:51 +0200 > From: David DEMELIER > Sender: owner-freebsd-stable@freebsd.org > > Hi, I tested your patch and it didn't panic. I checked the dev.cpu > sysctl nodes to see if the CPU freq is changing or not. > > I unplugged the cable : > markand@Melon ~ $ sysctl dev.cpu > dev.cpu.0.%desc: ACPI CPU > dev.cpu.0.%driver: cpu > dev.cpu.0.%location: handle=\_PR_.CPU0 > dev.cpu.0.%pnpinfo: _HID=none _UID=0 > dev.cpu.0.%parent: acpi0 > dev.cpu.0.freq: 450 > dev.cpu.0.freq_levels: 2101/35000 1837/30625 1600/23888 1400/20902 > 1200/15000 1050/13125 900/11250 750/9375 600/7500 450/5625 300/3750 > 150/1875 > dev.cpu.0.cx_supported: C1/1 C2/1 C3/162 > dev.cpu.0.cx_lowest: C3 > dev.cpu.0.cx_usage: 0.00% 99.99% 0.00% last 131us > dev.cpu.1.%desc: ACPI CPU > dev.cpu.1.%driver: cpu > dev.cpu.1.%location: handle=\_PR_.CPU1 > dev.cpu.1.%pnpinfo: _HID=none _UID=0 > dev.cpu.1.%parent: acpi0 > dev.cpu.1.cx_supported: C1/1 C2/1 C3/162 > dev.cpu.1.cx_lowest: C3 > dev.cpu.1.cx_usage: 0.00% 99.99% 0.00% last 260us > > I plugged the cable : > > markand@Melon ~ $ sysctl dev.cpu > dev.cpu.0.%desc: ACPI CPU > dev.cpu.0.%driver: cpu > dev.cpu.0.%location: handle=\_PR_.CPU0 > dev.cpu.0.%pnpinfo: _HID=none _UID=0 > dev.cpu.0.%parent: acpi0 > dev.cpu.0.freq: 2101 > dev.cpu.0.freq_levels: 2101/35000 1837/30625 1600/23888 1400/20902 > 1200/15000 1050/13125 900/11250 750/9375 600/7500 450/5625 300/3750 > 150/1875 > dev.cpu.0.cx_supported: C1/1 C2/57 > dev.cpu.0.cx_lowest: C1 > dev.cpu.0.cx_usage: 100.00% 0.00% last 497us > dev.cpu.1.%desc: ACPI CPU > dev.cpu.1.%driver: cpu > dev.cpu.1.%location: handle=\_PR_.CPU1 > dev.cpu.1.%pnpinfo: _HID=none _UID=0 > dev.cpu.1.%parent: acpi0 > dev.cpu.1.cx_supported: C1/1 C2/57 > dev.cpu.1.cx_lowest: C1 > dev.cpu.1.cx_usage: 100.00% 0.00% last 497us > > Of course I enabled > > # Little power management. > performance_cx_lowest="HIGH" > performance_cpu_freq=${performance_cx_lowest} > economy_cx_lowest="LOW" > economy_cpu_freq=${economy_cx_lowest} > > in my /etc/rc.conf, it the behavior expected ? I won't say that it is expected, but it is not unusual. It looks like more and more laptops don't offer higher 'C' states when on AC power. My ThinkPad gives me C3 on AC power and adds C4 on battery. You have an awful lot of available frequencies. I really recommend turning off TCC/Throttling, if they are active. They don't really save power and can cause problems at low values. They also impact powerd's responsiveness to changes in CPU load. What you REALLY want are the true power management clock/voltage step which are usually between 2 and 6. My old T30 only had two. My not quite as old T43 has 5 ranging from 2 GHz down to 800 MHz. I really wish TCC and throttling would be disabled by default or totally removed. they were intended for thermal management, not power management. -- R. Kevin Oberman, Network Engineer Energy Sciences Network (ESnet) Ernest O. Lawrence Berkeley National Laboratory (Berkeley Lab) E-mail: oberman@es.net Phone: +1 510 486-8634 Key fingerprint:059B 2DDF 031C 9BA3 14A4 EADA 927D EBB3 987B 3751