From owner-freebsd-acpi@FreeBSD.ORG Sun Mar 10 14:15:38 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E22A2F73; Sun, 10 Mar 2013 14:15:38 +0000 (UTC) (envelope-from kron24@gmail.com) Received: from mail-ea0-x22d.google.com (mail-ea0-x22d.google.com [IPv6:2a00:1450:4013:c01::22d]) by mx1.freebsd.org (Postfix) with ESMTP id 4F0C8E87; Sun, 10 Mar 2013 14:15:38 +0000 (UTC) Received: by mail-ea0-f173.google.com with SMTP id h14so785695eak.4 for ; Sun, 10 Mar 2013 07:15:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:message-id:date:from:user-agent:mime-version:to:cc :subject:references:in-reply-to:content-type :content-transfer-encoding; bh=nks5yfg7v66vVHXS/RElmLy9zpbQW3lcGY/sY07PEx8=; b=YrclbGE+DaTqEEnHmJFYIDn/pIBxENMTgTJeHM7+poX6x2Q5URKwUkb+JgA2782uL7 RuQYf7pWHi/rE7cQ6ursuhsDx7VHDdMx7Td7zzGNgiuMit/7o+p+VLvbJzE+eZI5/Rta UHQDXREK/srZLDN5JUxUWfYwy/JrbTg7QRKpZHOvCKQWBuTG2kFxpvx9vb4Ev8osgd5U D1pnkDOj/7bp0YccRWeuh4LFNaytJtNjNiNI+v7TDoLNf/bRV7BenZGsOb+eZ9Brrnmn r/xhLKG1B5wtsZR5VN0KK4N8LKcKUKYbDzSD9jRI8WDVPsDTjkhY23QjONWGzoMkJh/k XSYg== X-Received: by 10.14.3.70 with SMTP id 46mr26804206eeg.2.1362924937432; Sun, 10 Mar 2013 07:15:37 -0700 (PDT) Received: from nbvk.local (uidzr185150.sattnet.cz. [212.96.185.150]) by mx.google.com with ESMTPS id k7sm18411180een.8.2013.03.10.07.15.35 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 10 Mar 2013 07:15:36 -0700 (PDT) Message-ID: <513C9587.1040801@gmail.com> Date: Sun, 10 Mar 2013 15:15:35 +0100 From: kron User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130309 Thunderbird/17.0.4 MIME-Version: 1.0 To: Andriy Gapon Subject: Re: panics due to buggy ACPI in Dell Latitude E6530? References: <512E24CD.9090404@gmail.com> <512E397D.1070406@FreeBSD.org> <513395D1.8090500@gmail.com> <5135EF5D.2050909@FreeBSD.org> In-Reply-To: <5135EF5D.2050909@FreeBSD.org> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-acpi@FreeBSD.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 Mar 2013 14:15:38 -0000 On 2013/03/05 14:13, Andriy Gapon wrote: > on 03/03/2013 20:26 kron said the following: >> #5 0xffffffff806abc53 in calltrap () at exception.S:228 >> #6 0xffffffff802bc850 in AcpiOsAcquireObject (Cache=0xfffffe00093a14a0) >> at /usr/src/sys/contrib/dev/acpica/utilities/utcache.c:310 >> #7 0xffffffff802bf481 in AcpiUtCreateInternalObjectDbg ( >> ModuleName=0xffffffff8071c1a6 "dsutils", LineNumber=703, >> ComponentId=64,. >> Type=1) at /usr/src/sys/contrib/dev/acpica/utilities/utobject.c:437 > > Did this panic happen even with hw.acpi.osname="Linux" or did you revert that to > reproduce the panic? > > In either case, could you please try the following patch (it is against recent > stable/9) ? > http://people.freebsd.org/~avg/OsdSynch-9.diff > > P.S. this is not a final version of the patch, but rather a work in progress. > Hi Andriy, I'm sorry to say the patch didn't make a difference. The crashdump and ACPI errors from /var/log/messages look the same as before. However, I found a new message ACPI Warning: Expected EISAID is larger than 32 bits: 0xFFFFFFFFFFFFFFFF, truncating (20110527/exutils-440) just before the flood of ACPI Error: No object attached to node 0xfffffe000849d980 (20110527/exresnte-138) ACPI Error: Method execution failed [\_SB_.BAT0._HID] (Node 0xfffffe000849d980), AE_AML_NO_OPERAND (20110527/uteval-113) until the panic (general protection fault) happened. BR Oli From owner-freebsd-acpi@FreeBSD.ORG Mon Mar 11 11:06:38 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 61AA0A80 for ; Mon, 11 Mar 2013 11:06:38 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) by mx1.freebsd.org (Postfix) with ESMTP id 3AE5C7B8 for ; Mon, 11 Mar 2013 11:06:38 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.6/8.14.6) with ESMTP id r2BB6cZj088881 for ; Mon, 11 Mar 2013 11:06:38 GMT (envelope-from owner-bugmaster@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.6/8.14.6/Submit) id r2BB6bFU088879 for freebsd-acpi@FreeBSD.org; Mon, 11 Mar 2013 11:06:37 GMT (envelope-from owner-bugmaster@FreeBSD.org) Date: Mon, 11 Mar 2013 11:06:37 GMT Message-Id: <201303111106.r2BB6bFU088879@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: gnats set sender to owner-bugmaster@FreeBSD.org using -f From: FreeBSD bugmaster To: freebsd-acpi@FreeBSD.org Subject: Current problem reports assigned to freebsd-acpi@FreeBSD.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Mar 2013 11:06:38 -0000 Note: to view an individual PR, use: http://www.freebsd.org/cgi/query-pr.cgi?pr=(number). The following is a listing of current problems submitted by FreeBSD users. These represent problem reports covering all versions including experimental development code and obsolete releases. S Tracker Resp. Description -------------------------------------------------------------------------------- o kern/174766 acpi [acpi] Random acpi panic o kern/174504 acpi [ACPI] Suspend/resume broken on Lenovo x220 o kern/171305 acpi [acpi] acpi_tz0: _CRT value is absurd, ignored (256.0C o kern/164329 acpi [acpi] hw.acpi.thermal.tz0.temperature shows strange v o kern/163268 acpi [acpi_hp] [patch] fix driver detach in absence of CMI o kern/162859 acpi [acpi] ACPI battery/acline monitoring partialy working o kern/161715 acpi [acpi] Dell E6520 doesn't resume after ACPI suspend o kern/161713 acpi [acpi] Suspend on Dell E6520 o kern/160838 acpi [acpi] ACPI Battery Monitor Non-Functional o kern/160419 acpi [acpi_thermal] acpi_thermal kernel thread high CPU usa o kern/158689 acpi [acpi] value of sysctl hw.acpi.thermal.polling_rate ne o kern/154955 acpi [acpi] Keyboard or ACPI doesn't work on Lenovo S10-3 o kern/152438 acpi [acpi]: patch to acpi_asus(4) to add extra sysctls for o kern/152098 acpi [acpi] Lenovo T61p does not resume o i386/146715 acpi [acpi] Suspend works, resume not on a HP Probook 4510s o kern/145306 acpi [acpi]: Can't change brightness on HP ProBook 4510s o i386/143798 acpi [acpi] shutdown problem with SiS K7S5A o kern/143420 acpi [acpi] ACPI issues with Toshiba o kern/142009 acpi [acpi] [panic] Panic in AcpiNsGetAttachedObject o kern/139088 acpi [acpi] ACPI Exception: AE_AML_INFINITE_LOOP error o amd64/138210 acpi [acpi] acer aspire 5536 ACPI problems (S3, brightness, o kern/137042 acpi [acpi] hp laptop's lcd not wakes up after suspend to r o i386/136008 acpi [acpi] Dell Vostro 1310 will not shutdown (Requires us o kern/132602 acpi [acpi] ACPI Problem with Intel SS4200: System does not p kern/128634 acpi [patch] fix acpi_asus(4) in asus a6f laptop o bin/126162 acpi [acpi] ACPI autoload failed : loading required module o kern/123039 acpi [acpi] ACPI AML_BUFFER_LIMIT errors during boot a i386/122887 acpi [panic] [atkbdc] 7.0-RELEASE on IBM HS20 panics immed s kern/112544 acpi [acpi] [patch] Add High Precision Event Timer Driver f o kern/105537 acpi [acpi] problems in acpi on HP Compaq nc6320 o kern/91594 acpi [acpi] FreeBSD > 5.4 w/ACPI fails to detect Intel Pro/ o kern/73823 acpi [request] acpi / power-on by timer support o kern/56024 acpi ACPI suspend drains battery while in S3 33 problems total. From owner-freebsd-acpi@FreeBSD.ORG Tue Mar 12 21:16:22 2013 Return-Path: Delivered-To: freebsd-acpi@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id D3A76E17; Tue, 12 Mar 2013 21:16:22 +0000 (UTC) (envelope-from crees@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) by mx1.freebsd.org (Postfix) with ESMTP id AF5AD8A8; Tue, 12 Mar 2013 21:16:22 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.6/8.14.6) with ESMTP id r2CLGLFE082411; Tue, 12 Mar 2013 21:16:21 GMT (envelope-from crees@freefall.freebsd.org) Received: (from crees@localhost) by freefall.freebsd.org (8.14.6/8.14.6/Submit) id r2CLGLOJ082410; Tue, 12 Mar 2013 21:16:21 GMT (envelope-from crees) Date: Tue, 12 Mar 2013 21:16:21 GMT Message-Id: <201303122116.r2CLGLOJ082410@freefall.freebsd.org> To: crees@FreeBSD.org, freebsd-bugs@FreeBSD.org, freebsd-acpi@FreeBSD.org From: crees@FreeBSD.org Subject: Re: kern/165381: [cpufreq] powerd(8) eats CPUs for breakfast X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Mar 2013 21:16:22 -0000 Synopsis: [cpufreq] powerd(8) eats CPUs for breakfast Responsible-Changed-From-To: freebsd-bugs->freebsd-acpi Responsible-Changed-By: crees Responsible-Changed-When: Tue Mar 12 21:16:07 UTC 2013 Responsible-Changed-Why: This appears to be a rather serious issue-- anyone know about powerd on amd? http://www.freebsd.org/cgi/query-pr.cgi?pr=165381 From owner-freebsd-acpi@FreeBSD.ORG Tue Mar 12 22:03:25 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 4D8FA21E; Tue, 12 Mar 2013 22:03:25 +0000 (UTC) (envelope-from kob6558@gmail.com) Received: from mail-ob0-x232.google.com (mail-ob0-x232.google.com [IPv6:2607:f8b0:4003:c01::232]) by mx1.freebsd.org (Postfix) with ESMTP id 00F70AC4; Tue, 12 Mar 2013 22:03:24 +0000 (UTC) Received: by mail-ob0-f178.google.com with SMTP id wd20so378754obb.9 for ; Tue, 12 Mar 2013 15:03:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=8taRkigNtAMlx7OlAmuodJNwYtOirB5jyIsR40elJT8=; b=vkAqZ390mjUF1FLjcNmgUUQIzU9qxRnI0Ii/PIZQHz+GKpyo3ijhykGMVzPYMyrpKj XNQL8JUhxQlJSc2zwPtPw1r7MEJgZXAsDCgrA75r5shgaGcV3+EyRa4HuRIXNJC8MRs0 1g4NsEaZFCOkVtM9YIYl/JyN/2rt6jjwgFClBUgFpgS56nldqSeY+lk7q5DTL2B+CYGT /Yzxojv/OU1OJdq302sj63KbV5f/KaKdAYog56WYlzgWzN2Y6q4jtV7ARR6bGsPF4C2f KK7Evcx61ERwPyNkepZgBPTQZwGH1Mmcoy/Qh1zmlz6iDNVLyWYsO29KT13zy23Z4VGH oQ8w== MIME-Version: 1.0 X-Received: by 10.60.22.69 with SMTP id b5mr14161672oef.38.1363125804558; Tue, 12 Mar 2013 15:03:24 -0700 (PDT) Sender: kob6558@gmail.com Received: by 10.76.11.165 with HTTP; Tue, 12 Mar 2013 15:03:24 -0700 (PDT) In-Reply-To: <201303122116.r2CLGLOJ082410@freefall.freebsd.org> References: <201303122116.r2CLGLOJ082410@freefall.freebsd.org> Date: Tue, 12 Mar 2013 15:03:24 -0700 X-Google-Sender-Auth: PtOXDiKU0YQScAs1cQOsvU5aVwg Message-ID: Subject: Re: kern/165381: [cpufreq] powerd(8) eats CPUs for breakfast From: Kevin Oberman To: crees@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: freebsd-bugs@freebsd.org, freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Mar 2013 22:03:25 -0000 On Tue, Mar 12, 2013 at 2:16 PM, wrote: > Synopsis: [cpufreq] powerd(8) eats CPUs for breakfast > > Responsible-Changed-From-To: freebsd-bugs->freebsd-acpi > Responsible-Changed-By: crees > Responsible-Changed-When: Tue Mar 12 21:16:07 UTC 2013 > Responsible-Changed-Why: > This appears to be a rather serious issue-- anyone know about powerd on > amd? > > http://www.freebsd.org/cgi/query-pr.cgi?pr=165381 > _______________________________________________ > > I suspect that you are getting bitten by issues of conflict between C-states and cpufreq. I suggest that you disable TCC (which is intended for thermal control, not power management) and see if that helps. TCC/throttling is designed to slow down the CPU dramatically when the CPU temperature approaches unsafe levels and normally is relevant onl,y when the CPU is busy. Throttling, either by TCC, also called P4TCC even though its only association with the Pentium4 is that it was introduced on those chips, or the older manual throttling can reduce the CPU to using only 1 in 8 clock cycles if the CPU is idle. This should be fine, but when combined with SpeedStep or the AMD equivalent (PowerNOW!) and C-states, it can cause the system to deadlock. It essentially goes to sleep and never wakes up again, the effective equivalent of halting. Since C-states are the biggest win for power saving, it is especially important that these be used. To disable TCC and throttling, add the following two lines to your /boot/loader.conf file: hint.p4tcc.0.disabled=1 hint.acpu_throttle.0.disabled=1 You should also confirm that the hw.acpi.cx_lowest sysctl is set to "C8". Since both SpeedStep/PowerNOW! and C-states do reduce both power consumption and idle temperature quite effectively, they should be used. -- R. Kevin Oberman, Network Engineer E-mail: rkoberman@gmail.com From owner-freebsd-acpi@FreeBSD.ORG Tue Mar 12 22:08:00 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7CE563D5 for ; Tue, 12 Mar 2013 22:08:00 +0000 (UTC) (envelope-from seanbru@yahoo-inc.com) Received: from mrout2-b.corp.bf1.yahoo.com (mrout2-b.corp.bf1.yahoo.com [98.139.253.105]) by mx1.freebsd.org (Postfix) with ESMTP id 3896CAF7 for ; Tue, 12 Mar 2013 22:07:59 +0000 (UTC) Received: from [127.0.0.1] (proxy6.corp.yahoo.com [216.145.48.19]) by mrout2-b.corp.bf1.yahoo.com (8.14.4/8.14.4/y.out) with ESMTP id r2CLvHt6081546 for ; Tue, 12 Mar 2013 14:57:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=yahoo-inc.com; s=cobra; t=1363125439; bh=VXXzyDeeD2Mp9D/s0hZczObQylGl+3bXUNTydCJLSqE=; h=Subject:From:Reply-To:To:Content-Type:Date:Message-ID: Mime-Version:Content-Transfer-Encoding; b=A3mMsRT07j+9Mw6DBqUSsanFMFSs9R88xZcWDVNwZLaJ/1nNVQ1BLvmXsNLmQA1Ey qEJvBtfgMsrTi8NyRLJiJ/clKa+poKP4rNyYF15kbFFWmcT2ND9tBgcTxiAdXrwBNc scIJXULaxNBCjF/6J7l64yKuOI2/HInjD+WHEn08= Subject: thinkpad keys T520 From: Sean Bruno To: freebsd-acpi@FreeBSD.org Content-Type: text/plain; charset="us-ascii" Date: Wed, 13 Mar 2013 06:57:17 +0900 Message-ID: <1363125437.79135.2.camel@localhost> Mime-Version: 1.0 X-Mailer: Evolution 2.32.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit X-Milter-Version: master.31+4-gbc07cd5+ X-CLX-ID: 125438000 X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: sbruno@FreeBSD.org List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Mar 2013 22:08:00 -0000 the Fn key seems to send the system the same key command as the power button *should* send. This leads to many problems on this machine. How can I start tracing code the key strokes for keys that are not the normal keyboard keys? e.g. the Fn key or vol up/down and the power button? If I load acpi_ibm(4), it doesn't seem to ever get used so I am confused as to where to start. Sean From owner-freebsd-acpi@FreeBSD.ORG Tue Mar 12 22:57:00 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 3C9926AF; Tue, 12 Mar 2013 22:57:00 +0000 (UTC) (envelope-from kob6558@gmail.com) Received: from mail-ob0-x22f.google.com (mail-ob0-x22f.google.com [IPv6:2607:f8b0:4003:c01::22f]) by mx1.freebsd.org (Postfix) with ESMTP id EA94DE97; Tue, 12 Mar 2013 22:56:59 +0000 (UTC) Received: by mail-ob0-f175.google.com with SMTP id uz6so411163obc.6 for ; Tue, 12 Mar 2013 15:56:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=XGf1QHPr3TmCn1ZRdWlUFtoKHbuvTz5EtT1sFKPJvxs=; b=OS/Fo8hpBwcEKoocU53QCckynTkTj0ikJfnBectS/HLdIQBdGidgpol6fdFdmgBMSg qgHojdh5vNTNcCwoD745KwcJepjDPtUvnF5t1yPe+XdaKaPNXN5LwtyLSt95ze8vxLw2 WEy0p9sGfFa6bAIh4rTYRkam+ejRvvbSb/EL4MNT1DcsZtUOsktd4FOM8mTE++RkbEe7 3Corwdng10Sq5LXaMuwDcjwZUVhSdvdoCHhCuHy/thuPnR1+IPD7dF3jwtpyFwELYXHM qHSpWStr5lQK8740mVnim56kSBxGbFeg7TwO4lA7TyYv9/2ASR/GTD9pNp3HOBJ3aN54 +0Fg== MIME-Version: 1.0 X-Received: by 10.182.122.41 with SMTP id lp9mr10436412obb.65.1363129019480; Tue, 12 Mar 2013 15:56:59 -0700 (PDT) Sender: kob6558@gmail.com Received: by 10.76.11.165 with HTTP; Tue, 12 Mar 2013 15:56:59 -0700 (PDT) In-Reply-To: <1363125437.79135.2.camel@localhost> References: <1363125437.79135.2.camel@localhost> Date: Tue, 12 Mar 2013 15:56:59 -0700 X-Google-Sender-Auth: sf8rXS3G4JDNrIXlB0Mtnm4sT2A Message-ID: Subject: Re: thinkpad keys T520 From: Kevin Oberman To: sbruno@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Mar 2013 22:57:00 -0000 On Tue, Mar 12, 2013 at 2:57 PM, Sean Bruno wrote: > the Fn key seems to send the system the same key command as the power > button *should* send. This leads to many problems on this machine. > > How can I start tracing code the key strokes for keys that are not the > normal keyboard keys? e.g. the Fn key or vol up/down and the power > button? > > If I load acpi_ibm(4), it doesn't seem to ever get used so I am confused > as to where to start. > > Sean, I'm confused. I also have a T520, but the Fn key does not seem to mis-behave on it at all. I have not gotten brightness adjustment to work correctly to this point, but Fn has never triggered a power operation for me. Your statement about acpi_ibm(4) is also baffling as I have no problems with it with 9.1-Stable or head. It was broken in some earlier versions before the Lenovo ID was added. Does your ThinkLight turn on and off if you set dev.acpi_ibm.0.thinklight? When you press Fn+PgUp? Both work on my T520. Perhaps I am not completely understanding the issue. -- R. Kevin Oberman, Network Engineer E-mail: rkoberman@gmail.com From owner-freebsd-acpi@FreeBSD.ORG Tue Mar 12 23:22:07 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 9CA77111; Tue, 12 Mar 2013 23:22:07 +0000 (UTC) (envelope-from seanwbruno@gmail.com) Received: from mail-pb0-f42.google.com (mail-pb0-f42.google.com [209.85.160.42]) by mx1.freebsd.org (Postfix) with ESMTP id 6BCECAF; Tue, 12 Mar 2013 23:22:07 +0000 (UTC) Received: by mail-pb0-f42.google.com with SMTP id xb4so373959pbc.1 for ; Tue, 12 Mar 2013 16:22:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:subject:from:to:cc:in-reply-to:references:content-type :date:message-id:mime-version:x-mailer:content-transfer-encoding; bh=XOhWqJP3o7XVAQVhtSXly+yrO62dygcNY9kqM7Fi7fo=; b=pMfIsa+D0BBNp0+5wKzmUySDMyv6CG2Ep+jdVZdroN0161CDnaCSo4kyYxg6jnYL1w DXpuW75DLH/xIjoB/6Tj3yDrHxd2AiSsxtApIQkX/hdpCKRVz2l4ai/8SPvzqyQr2PEd H1UTi0bzzgrPAuwyswHBardIrHqHh1Hv4efpOPm/2QsUTcuoFzvecdH/GPbJML7lEgoB 0/OMINN0KKFBm9HrOXTL5mMrm0i2tBbp0vBsuYiTGtxoTpHRA/6BV0QMSkydeQ+UfPIy 8xx4XpCaYy3LMY1OXYx1bntR56EQ7MvDaDSiznhOOIaNAKXNh4ISKJKidItjTsNYxlOB I3Yg== X-Received: by 10.68.227.202 with SMTP id sc10mr40689697pbc.109.1363130526700; Tue, 12 Mar 2013 16:22:06 -0700 (PDT) Received: from [172.40.3.206] ([122.212.234.130]) by mx.google.com with ESMTPS id kt5sm26887848pbc.30.2013.03.12.16.22.03 (version=SSLv3 cipher=RC4-SHA bits=128/128); Tue, 12 Mar 2013 16:22:05 -0700 (PDT) Subject: Re: thinkpad keys T520 From: Sean Bruno To: Kevin Oberman In-Reply-To: References: <1363125437.79135.2.camel@localhost> Content-Type: text/plain; charset="us-ascii" Date: Wed, 13 Mar 2013 08:22:02 +0900 Message-ID: <1363130522.79135.8.camel@localhost> Mime-Version: 1.0 X-Mailer: Evolution 2.32.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit Cc: freebsd-acpi@freebsd.org, hiren panchasara X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Mar 2013 23:22:07 -0000 On Tue, 2013-03-12 at 15:56 -0700, Kevin Oberman wrote: > On Tue, Mar 12, 2013 at 2:57 PM, Sean Bruno > wrote: > the Fn key seems to send the system the same key command as > the power > button *should* send. This leads to many problems on this > machine. > > How can I start tracing code the key strokes for keys that are > not the > normal keyboard keys? e.g. the Fn key or vol up/down and the > power > button? > > If I load acpi_ibm(4), it doesn't seem to ever get used so I > am confused > as to where to start. > > Sean, > > I'm confused. I also have a T520, but the Fn key does not seem to > mis-behave on it at all. I have not gotten brightness adjustment to > work correctly to this point, but Fn has never triggered a power > operation for me. Your statement about acpi_ibm(4) is also baffling as > I have no problems with it with 9.1-Stable or head. It was broken in > some earlier versions before the Lenovo ID was added. > > Does your ThinkLight turn on and off if you set > dev.acpi_ibm.0.thinklight? When you press Fn+PgUp? Both work on my > T520. > > Perhaps I am not completely understanding the issue. > > -- > R. Kevin Oberman, Network Engineer > E-mail: rkoberman@gmail.com On my T520, I do not need acpi_ibm(4) for the thinklight to function. It works with/without the module loaded. Hiren and I found adding this to the driver section of xorg.conf allows the fn-brightness keys to work: Option "RegistryDwords" "EnableBrightnessControl=1" The audio "mute" button actually seems to be working through the sound driver. The fn key seems to generate an unhandled APIC0 event, that is processed somewhere as a shutdown event. I'm using XFCE4 as my desktop and all the parts that come with it. Sean From owner-freebsd-acpi@FreeBSD.ORG Tue Mar 12 23:25:25 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id DEB0D153 for ; Tue, 12 Mar 2013 23:25:25 +0000 (UTC) (envelope-from lists@eitanadler.com) Received: from mail-wi0-x22d.google.com (mail-wi0-x22d.google.com [IPv6:2a00:1450:400c:c05::22d]) by mx1.freebsd.org (Postfix) with ESMTP id 76327BD for ; Tue, 12 Mar 2013 23:25:25 +0000 (UTC) Received: by mail-wi0-f173.google.com with SMTP id hq4so2313972wib.6 for ; Tue, 12 Mar 2013 16:25:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=x-received:mime-version:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; bh=806HLWYFUxzwJc7aoCsyKzbT62juJbPZOpUAiPSt3AY=; b=f4CZpRJIo74NRps/m0SXtsEUv8zNQ454hKpHqgrdqI9vwxwMBOA5zoHkzalEKX0HKf hK6FVy9vJL41+G+qq8pQ63JVbxRSgJhZJ6VfHyW0pmrYTytsbnnWF6JG/amdCBquk/kV WbMV6Ryx/s2UBCGJer9i7BInB/FDKcjZ3FGV4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:in-reply-to:references:from:date:message-id :subject:to:cc:content-type:x-gm-message-state; bh=806HLWYFUxzwJc7aoCsyKzbT62juJbPZOpUAiPSt3AY=; b=Gx/1czyL8mQGMhqSjoQE0+exXE6tw9YXBTkNPHz8AVwEYRJ0BfhEW1o4m77XcTh2UK wjzHsfQVdQ2yqIc/qymy1UBr+eaySdPQT9MjFImTP3NnktMxhvQ3hBlzBEff5Eb/pvdO rp3+20m4R9GHq3eOwo14rFq2v6P8RayK/nldkfHC3xjQhBGMxw3O/O7Z+NFbFng9yMk3 YIo86zkvav6Sj34NeK1Ynq/Xj5D6uyaXQaXe5NMvRh5YIoaYrq9AshsOmjHnzjjHmPvW 7hF3U0pQI0CbYCwo99DIm4OW4PYaUjGRHK0LZFcD2Z/QsQvJGu9P4tQpJCjAWMrvm+/d KR3Q== X-Received: by 10.180.79.227 with SMTP id m3mr23222731wix.12.1363130724602; Tue, 12 Mar 2013 16:25:24 -0700 (PDT) MIME-Version: 1.0 Received: by 10.194.108.106 with HTTP; Tue, 12 Mar 2013 16:24:54 -0700 (PDT) In-Reply-To: <1363130522.79135.8.camel@localhost> References: <1363125437.79135.2.camel@localhost> <1363130522.79135.8.camel@localhost> From: Eitan Adler Date: Tue, 12 Mar 2013 19:24:54 -0400 Message-ID: Subject: Re: thinkpad keys T520 To: Sean Bruno Content-Type: text/plain; charset=UTF-8 X-Gm-Message-State: ALoCoQkvf724l7VShoW1nSRt6u85DRvJX76q2oKzdU2uIlFYPPKrzSBd7tiZQRq7TJ36MGUpbkv+ Cc: Kevin Oberman , freebsd-acpi@freebsd.org, hiren panchasara X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Mar 2013 23:25:25 -0000 On 12 March 2013 19:22, Sean Bruno wrote:> > Hiren and I found adding this to the driver section of xorg.conf allows > the fn-brightness keys to work: Which section? InputDriver? -- Eitan Adler From owner-freebsd-acpi@FreeBSD.ORG Tue Mar 12 23:27:08 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 26E63273 for ; Tue, 12 Mar 2013 23:27:08 +0000 (UTC) (envelope-from hiren.panchasara@gmail.com) Received: from mail-ea0-x22f.google.com (mail-ea0-x22f.google.com [IPv6:2a00:1450:4013:c01::22f]) by mx1.freebsd.org (Postfix) with ESMTP id 8EE42D2 for ; Tue, 12 Mar 2013 23:27:07 +0000 (UTC) Received: by mail-ea0-f175.google.com with SMTP id o10so142567eaj.34 for ; Tue, 12 Mar 2013 16:27:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=N6Fs/z1zDRyZNftMR7jNcgKTOd3ZvOrvNrJvgv6x/fg=; b=I3Kq9lPukNtnNEOLB9PL8TOERmIHgkGAS4/FgTvk+DdtT2t4MHMh5sUTASkDCtyVun 04258EZkn50a5xHZw4JlnLNUa1cDSR17oMRk0Xz8a8JvkVz33BUkGCzFwqT8ZyLT8M1h SPQLOTZHqUvzNwIbvig3DXaEGXyXgAZ12j8wlaRi1C5vdGFoT1OZr9RogndVd1GALBGo 3sHOKG0AKMcUd1Fj0Tf9hEpza/ok4qX9Tp3DoQj1nndjVyuYHoNpMOubNN3sqrPEw3fs j7rT7/GRtnnqfCAqiqIrt8lSiW43yuzrZOKK/jQ7JdeYb8Xt6OkYjUaAl6bokyVs859B 8oDg== MIME-Version: 1.0 X-Received: by 10.14.216.198 with SMTP id g46mr38119268eep.30.1363130826616; Tue, 12 Mar 2013 16:27:06 -0700 (PDT) Received: by 10.14.133.204 with HTTP; Tue, 12 Mar 2013 16:27:06 -0700 (PDT) In-Reply-To: References: <1363125437.79135.2.camel@localhost> <1363130522.79135.8.camel@localhost> Date: Tue, 12 Mar 2013 16:27:06 -0700 Message-ID: Subject: Re: thinkpad keys T520 From: hiren panchasara To: Eitan Adler Content-Type: text/plain; charset=UTF-8 Cc: Kevin Oberman , freebsd-acpi@freebsd.org, Sean Bruno X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Mar 2013 23:27:08 -0000 On Tue, Mar 12, 2013 at 4:24 PM, Eitan Adler wrote: > On 12 March 2013 19:22, Sean Bruno wrote:> >> Hiren and I found adding this to the driver section of xorg.conf allows >> the fn-brightness keys to work: > > Which section? InputDriver? In you "Screen" section. Mine looks like this: Section "Screen" Identifier "Screen0" Device "Card0" Monitor "Monitor0" DefaultDepth 24 Option "RegistryDwords" "EnableBrightnessControl=1" SubSection "Display" Viewport 0 0 Depth 24 Modes "1024x768" EndSubSection EndSection cheers, Hiren > > > > > -- > Eitan Adler From owner-freebsd-acpi@FreeBSD.ORG Wed Mar 13 02:46:12 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id BDD27491; Wed, 13 Mar 2013 02:46:12 +0000 (UTC) (envelope-from hiren.panchasara@gmail.com) Received: from mail-ve0-f182.google.com (mail-ve0-f182.google.com [209.85.128.182]) by mx1.freebsd.org (Postfix) with ESMTP id 61BC8A2B; Wed, 13 Mar 2013 02:46:12 +0000 (UTC) Received: by mail-ve0-f182.google.com with SMTP id ox1so390168veb.41 for ; Tue, 12 Mar 2013 19:46:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=+yBjRX9ZPSBE6h3AINKn72deTTJUEKnvANNbFCEdkGA=; b=mMfDvKF7gAhDoUM1e0wRAtvxtEIH/mkBmPNu0iowTK11+OGxcuL6GR1gPj1F2ofZJx pRm1wkFNc4dypilOzxS01/afwSs3LngHeG5VvzIoaHEqCg9wpo44CfVW1gu7TyUTC3ZU fnaaecSNtvYFU77JZ21hh9XTYg24ijw39G3eZ30z3BuqR6WtzWaqjUtnlDg/ssRh6dpG bwKWKSPbQvVI0+HqCLXbn4i/iD//pLjyFK2ltFpcJnf7NVaHEKVTLJnnuVWZ6DqlunzI 68cxdfnIAJCTspg+8AS+DUlFegRdR7ExxE0QDg+oLK7ZLG7MT02eLirmKvw8DOpmhY5q PGzA== MIME-Version: 1.0 X-Received: by 10.52.19.200 with SMTP id h8mr6437738vde.60.1363142285205; Tue, 12 Mar 2013 19:38:05 -0700 (PDT) Received: by 10.58.198.107 with HTTP; Tue, 12 Mar 2013 19:38:05 -0700 (PDT) In-Reply-To: <1363130522.79135.8.camel@localhost> References: <1363125437.79135.2.camel@localhost> <1363130522.79135.8.camel@localhost> Date: Tue, 12 Mar 2013 19:38:05 -0700 Message-ID: Subject: Re: thinkpad keys T520 From: hiren panchasara To: Sean Bruno Content-Type: text/plain; charset=UTF-8 Cc: Kevin Oberman , freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Mar 2013 02:46:12 -0000 On Tue, Mar 12, 2013 at 4:22 PM, Sean Bruno wrote: > On Tue, 2013-03-12 at 15:56 -0700, Kevin Oberman wrote: >> On Tue, Mar 12, 2013 at 2:57 PM, Sean Bruno >> wrote: >> the Fn key seems to send the system the same key command as >> the power >> button *should* send. This leads to many problems on this >> machine. >> >> How can I start tracing code the key strokes for keys that are >> not the >> normal keyboard keys? e.g. the Fn key or vol up/down and the >> power >> button? >> >> If I load acpi_ibm(4), it doesn't seem to ever get used so I >> am confused >> as to where to start. As Sean pointed out, we are on this mysterious journey to find out what happens when buttons are pressed. I am playing with my T420 to understand how physical button press event is sent down to acpi_ibm via devd. I've started putting "device_printf" inside acpi_ibm to see if individual functions are getting called or not. I was not seeing anything in dmesg until I set following: sysctl dev.acpi_ibm.0.events=1 >From the manpage, it seems, this tunable enables ACPI events and set the eventmask to availmask. where eventmask is how things are laid out specific to your hardware and availmask is what all you want to intercept by acpi_ibm. Is this a correct assumption or I am completely off the track here? Also, I am trying to find out pin layout for T420 and T520 as acpi_ibm(4) lists for T41p. If someone can help me find it, that will be awesome. Thanks in advance, Hiren >> >> Sean, >> >> I'm confused. I also have a T520, but the Fn key does not seem to >> mis-behave on it at all. I have not gotten brightness adjustment to >> work correctly to this point, but Fn has never triggered a power >> operation for me. Your statement about acpi_ibm(4) is also baffling as >> I have no problems with it with 9.1-Stable or head. It was broken in >> some earlier versions before the Lenovo ID was added. >> >> Does your ThinkLight turn on and off if you set >> dev.acpi_ibm.0.thinklight? When you press Fn+PgUp? Both work on my >> T520. >> >> Perhaps I am not completely understanding the issue. >> >> -- >> R. Kevin Oberman, Network Engineer >> E-mail: rkoberman@gmail.com > > > On my T520, I do not need acpi_ibm(4) for the thinklight to function. > It works with/without the module loaded. > > Hiren and I found adding this to the driver section of xorg.conf allows > the fn-brightness keys to work: > Option "RegistryDwords" "EnableBrightnessControl=1" > > The audio "mute" button actually seems to be working through the sound > driver. > > The fn key seems to generate an unhandled APIC0 event, that is processed > somewhere as a shutdown event. I'm using XFCE4 as my desktop and all > the parts that come with it. > > Sean > From owner-freebsd-acpi@FreeBSD.ORG Wed Mar 13 14:40:41 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 759FE3FA; Wed, 13 Mar 2013 14:40:41 +0000 (UTC) (envelope-from hiren.panchasara@gmail.com) Received: from mail-ea0-x22b.google.com (mail-ea0-x22b.google.com [IPv6:2a00:1450:4013:c01::22b]) by mx1.freebsd.org (Postfix) with ESMTP id DC51EABD; Wed, 13 Mar 2013 14:40:40 +0000 (UTC) Received: by mail-ea0-f171.google.com with SMTP id b15so479886eae.16 for ; Wed, 13 Mar 2013 07:40:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=rdpRLM6cR3loyIRcUEw4m/HadCbo6afHSda86vx2JY8=; b=fXh2S7DzOGr0YVVJP3KO+syFAQKGMRhiM3z2XfQGjKugAc6WZFh/22qNNMTn88PTRt 7AaVs7Fwd+sN+6dqj4EG5afVx2SMgm13MEzuxJ/hMSW2AiChes46rfDIXi5lzV34856a 8hgpAS+5LnKadtT5t8nFYbV1UhjaU+vXyOa6h//yJ71BPIbdSMkKCpr6L4vFa5/NpKvZ ip965zspMxTvmCVyFDKhvLsGjZLoIH8bR06acI6ARwYBKldPLRX4NFmkWSx+bh+aiyr6 lSUoLu5Wt7GVUbipNDDowRm9qS8W6XxRIHUNTqXDAtVHQW6yf7+oLLW+LWr9D31zBwBj hUYw== MIME-Version: 1.0 X-Received: by 10.14.219.129 with SMTP id m1mr11196612eep.16.1363185639200; Wed, 13 Mar 2013 07:40:39 -0700 (PDT) Received: by 10.14.133.204 with HTTP; Wed, 13 Mar 2013 07:40:39 -0700 (PDT) In-Reply-To: References: <1363125437.79135.2.camel@localhost> <1363130522.79135.8.camel@localhost> Date: Wed, 13 Mar 2013 07:40:39 -0700 Message-ID: Subject: Re: thinkpad keys T520 From: hiren panchasara To: Sean Bruno Content-Type: text/plain; charset=UTF-8 Cc: Kevin Oberman , freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Mar 2013 14:40:41 -0000 On Tue, Mar 12, 2013 at 7:38 PM, hiren panchasara wrote: > On Tue, Mar 12, 2013 at 4:22 PM, Sean Bruno wrote: >> On Tue, 2013-03-12 at 15:56 -0700, Kevin Oberman wrote: >>> On Tue, Mar 12, 2013 at 2:57 PM, Sean Bruno >>> wrote: >>> the Fn key seems to send the system the same key command as >>> the power >>> button *should* send. This leads to many problems on this >>> machine. >>> >>> How can I start tracing code the key strokes for keys that are >>> not the >>> normal keyboard keys? e.g. the Fn key or vol up/down and the >>> power >>> button? >>> >>> If I load acpi_ibm(4), it doesn't seem to ever get used so I >>> am confused >>> as to where to start. > > As Sean pointed out, we are on this mysterious journey to find out > what happens when buttons are pressed. > I am playing with my T420 to understand how physical button press > event is sent down to acpi_ibm via devd. > I've started putting "device_printf" inside acpi_ibm to see if > individual functions are getting called or not. > I was not seeing anything in dmesg until I set following: > > sysctl dev.acpi_ibm.0.events=1 It seems, I also need to do: sysctl dev.acpi_ibm.0.handlerevents='0x01 0x02 0x03.....whatever I need'. I am setting all the things from 0x01 to 0x17 as acpi_ibm(4) manpage says although I do not know exact mapping for T420 that I am using. I am poking in acpi_ibm_eventhandler() to see what events its getting when I press different keys. Interesting part is that it is generating and catching brightness increase/decrease and thinklight events but volume increase/decrease and mute button is not even generating any events. Are those being intercepted by something else? probably sound drivers? Also, all the interesting bits on my T420 looks like this: $ sysctl dev.acpi_ibm.0 dev.acpi_ibm.0.%desc: IBM ThinkPad ACPI Extras dev.acpi_ibm.0.%driver: acpi_ibm dev.acpi_ibm.0.%location: handle=\_SB_.PCI0.LPC_.EC__.HKEY dev.acpi_ibm.0.%pnpinfo: _HID=LEN0068 _UID=0 dev.acpi_ibm.0.%parent: acpi0 dev.acpi_ibm.0.initialmask: 2060 dev.acpi_ibm.0.availmask: 134217727 dev.acpi_ibm.0.events: 1 dev.acpi_ibm.0.eventmask: 134217727 dev.acpi_ibm.0.hotkey: 1331 dev.acpi_ibm.0.lcd_brightness: 7 dev.acpi_ibm.0.volume: 10 dev.acpi_ibm.0.mute: 0 dev.acpi_ibm.0.thinklight: 0 dev.acpi_ibm.0.bluetooth: 0 dev.acpi_ibm.0.wlan: 1 dev.acpi_ibm.0.fan_speed: 65535 dev.acpi_ibm.0.fan_level: 0 dev.acpi_ibm.0.fan: 1 dev.acpi_ibm.0.handlerevents: 0x01 0x02 0x03 0x04 0x05 0x06 0x07 0x08 0x09 0x0a 0x0b 0x0c 0x0d 0x0e 0x0f 0x10 0x11 0x13 0x15 0x16 0x17 I am unclear in the sense that how all different components like devd, acpi_ibm and sound drivers work together. Puzzling journey continues :-) cheers, Hiren > > From the manpage, it seems, this tunable enables ACPI events and set > the eventmask to availmask. > > where eventmask is how things are laid out specific to your hardware > and availmask is what all you want to intercept by acpi_ibm. > > Is this a correct assumption or I am completely off the track here? > > Also, I am trying to find out pin layout for T420 and T520 as > acpi_ibm(4) lists for T41p. If someone can help me find it, that will > be awesome. > > Thanks in advance, > Hiren > >>> >>> Sean, >>> >>> I'm confused. I also have a T520, but the Fn key does not seem to >>> mis-behave on it at all. I have not gotten brightness adjustment to >>> work correctly to this point, but Fn has never triggered a power >>> operation for me. Your statement about acpi_ibm(4) is also baffling as >>> I have no problems with it with 9.1-Stable or head. It was broken in >>> some earlier versions before the Lenovo ID was added. >>> >>> Does your ThinkLight turn on and off if you set >>> dev.acpi_ibm.0.thinklight? When you press Fn+PgUp? Both work on my >>> T520. >>> >>> Perhaps I am not completely understanding the issue. >>> >>> -- >>> R. Kevin Oberman, Network Engineer >>> E-mail: rkoberman@gmail.com >> >> >> On my T520, I do not need acpi_ibm(4) for the thinklight to function. >> It works with/without the module loaded. >> >> Hiren and I found adding this to the driver section of xorg.conf allows >> the fn-brightness keys to work: >> Option "RegistryDwords" "EnableBrightnessControl=1" >> >> The audio "mute" button actually seems to be working through the sound >> driver. >> >> The fn key seems to generate an unhandled APIC0 event, that is processed >> somewhere as a shutdown event. I'm using XFCE4 as my desktop and all >> the parts that come with it. >> >> Sean >> From owner-freebsd-acpi@FreeBSD.ORG Fri Mar 15 08:00:55 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 048D3B73; Fri, 15 Mar 2013 08:00:55 +0000 (UTC) (envelope-from hiren.panchasara@gmail.com) Received: from mail-ee0-f45.google.com (mail-ee0-f45.google.com [74.125.83.45]) by mx1.freebsd.org (Postfix) with ESMTP id 0F8F68DE; Fri, 15 Mar 2013 08:00:53 +0000 (UTC) Received: by mail-ee0-f45.google.com with SMTP id b57so1413946eek.4 for ; Fri, 15 Mar 2013 01:00:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=DU8BerhEMYC968xSS+5ccxOyncQTIDxbSKFONpniv3o=; b=V0CnSeK+j/+blmKRz1PX/HLLHphtFR5YXWQ58IamIC6V5DpKwhab6Y5PbA+n1VjM3B 6vKQvJEcjirjXoYEwx8qwZ8e9RujHdropyj2Ny1UNqtcM/7ZfxD0AermV3qOORkgHHWx 8mEvRjDfDfxgW9PnKa9a4JBYb4T3mPhhBOFWnUtrmFT60+QN+D44eXK5v1NGrT84sIrk GjJFrsSJPtbRT4g/rGK5w+hSP4MM/7jLEolm45vW2vKKYkyipo5lzvw4VvAF8tYELTqX V4USjiSlq+wflc2/9zjlT1Yc04AXjfdVgMqGMHqm+tUuMAdYWaqXU2tTFrGXnrxUv2xP DrRg== MIME-Version: 1.0 X-Received: by 10.14.216.198 with SMTP id g46mr15410442eep.30.1363334452890; Fri, 15 Mar 2013 01:00:52 -0700 (PDT) Received: by 10.14.133.204 with HTTP; Fri, 15 Mar 2013 01:00:52 -0700 (PDT) In-Reply-To: References: <1363125437.79135.2.camel@localhost> <1363130522.79135.8.camel@localhost> Date: Fri, 15 Mar 2013 01:00:52 -0700 Message-ID: Subject: Re: thinkpad keys T520 From: hiren panchasara To: Sean Bruno Content-Type: text/plain; charset=UTF-8 Cc: Kevin Oberman , markus@freebsd.org, freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 15 Mar 2013 08:00:55 -0000 On Wed, Mar 13, 2013 at 7:40 AM, hiren panchasara wrote: > On Tue, Mar 12, 2013 at 7:38 PM, hiren panchasara > wrote: >> On Tue, Mar 12, 2013 at 4:22 PM, Sean Bruno wrote: >>> On Tue, 2013-03-12 at 15:56 -0700, Kevin Oberman wrote: >>>> On Tue, Mar 12, 2013 at 2:57 PM, Sean Bruno >>>> wrote: >>>> the Fn key seems to send the system the same key command as >>>> the power >>>> button *should* send. This leads to many problems on this >>>> machine. >>>> >>>> How can I start tracing code the key strokes for keys that are >>>> not the >>>> normal keyboard keys? e.g. the Fn key or vol up/down and the >>>> power >>>> button? >>>> >>>> If I load acpi_ibm(4), it doesn't seem to ever get used so I >>>> am confused >>>> as to where to start. >> >> As Sean pointed out, we are on this mysterious journey to find out >> what happens when buttons are pressed. >> I am playing with my T420 to understand how physical button press >> event is sent down to acpi_ibm via devd. >> I've started putting "device_printf" inside acpi_ibm to see if >> individual functions are getting called or not. >> I was not seeing anything in dmesg until I set following: >> >> sysctl dev.acpi_ibm.0.events=1 I've a possible stupid question here. Why do I need to explicitly set this variable when I am already loading acpi_ibm.ko ? > > It seems, I also need to do: > sysctl dev.acpi_ibm.0.handlerevents='0x01 0x02 0x03.....whatever I need'. Also, why not set catch all the possible events when acpi_ibm.ko gets loaded? I have a 2-fold question: Is acpi_ibm any useful without these 2 sysctls set? and is there any side effect of setting these sysctls by default that I am not aware of? cheers, Hiren > I am setting all the things from 0x01 to 0x17 as acpi_ibm(4) manpage > says although I do not know exact mapping for T420 that I am using. > > I am poking in acpi_ibm_eventhandler() to see what events its getting > when I press different keys. > > Interesting part is that it is generating and catching brightness > increase/decrease and thinklight events but volume increase/decrease > and mute button is not even generating any events. Are those being > intercepted by something else? probably sound drivers? > > Also, all the interesting bits on my T420 looks like this: > > $ sysctl dev.acpi_ibm.0 > dev.acpi_ibm.0.%desc: IBM ThinkPad ACPI Extras > dev.acpi_ibm.0.%driver: acpi_ibm > dev.acpi_ibm.0.%location: handle=\_SB_.PCI0.LPC_.EC__.HKEY > dev.acpi_ibm.0.%pnpinfo: _HID=LEN0068 _UID=0 > dev.acpi_ibm.0.%parent: acpi0 > dev.acpi_ibm.0.initialmask: 2060 > dev.acpi_ibm.0.availmask: 134217727 > dev.acpi_ibm.0.events: 1 > dev.acpi_ibm.0.eventmask: 134217727 > dev.acpi_ibm.0.hotkey: 1331 > dev.acpi_ibm.0.lcd_brightness: 7 > dev.acpi_ibm.0.volume: 10 > dev.acpi_ibm.0.mute: 0 > dev.acpi_ibm.0.thinklight: 0 > dev.acpi_ibm.0.bluetooth: 0 > dev.acpi_ibm.0.wlan: 1 > dev.acpi_ibm.0.fan_speed: 65535 > dev.acpi_ibm.0.fan_level: 0 > dev.acpi_ibm.0.fan: 1 > dev.acpi_ibm.0.handlerevents: 0x01 0x02 0x03 0x04 0x05 0x06 0x07 0x08 > 0x09 0x0a 0x0b 0x0c 0x0d 0x0e 0x0f 0x10 0x11 0x13 0x15 0x16 0x17 > > I am unclear in the sense that how all different components like devd, > acpi_ibm and sound drivers work together. > > Puzzling journey continues :-) > > cheers, > Hiren > >> >> From the manpage, it seems, this tunable enables ACPI events and set >> the eventmask to availmask. >> >> where eventmask is how things are laid out specific to your hardware >> and availmask is what all you want to intercept by acpi_ibm. >> >> Is this a correct assumption or I am completely off the track here? >> >> Also, I am trying to find out pin layout for T420 and T520 as >> acpi_ibm(4) lists for T41p. If someone can help me find it, that will >> be awesome. >> >> Thanks in advance, >> Hiren >> >>>> >>>> Sean, >>>> >>>> I'm confused. I also have a T520, but the Fn key does not seem to >>>> mis-behave on it at all. I have not gotten brightness adjustment to >>>> work correctly to this point, but Fn has never triggered a power >>>> operation for me. Your statement about acpi_ibm(4) is also baffling as >>>> I have no problems with it with 9.1-Stable or head. It was broken in >>>> some earlier versions before the Lenovo ID was added. >>>> >>>> Does your ThinkLight turn on and off if you set >>>> dev.acpi_ibm.0.thinklight? When you press Fn+PgUp? Both work on my >>>> T520. >>>> >>>> Perhaps I am not completely understanding the issue. >>>> >>>> -- >>>> R. Kevin Oberman, Network Engineer >>>> E-mail: rkoberman@gmail.com >>> >>> >>> On my T520, I do not need acpi_ibm(4) for the thinklight to function. >>> It works with/without the module loaded. >>> >>> Hiren and I found adding this to the driver section of xorg.conf allows >>> the fn-brightness keys to work: >>> Option "RegistryDwords" "EnableBrightnessControl=1" >>> >>> The audio "mute" button actually seems to be working through the sound >>> driver. >>> >>> The fn key seems to generate an unhandled APIC0 event, that is processed >>> somewhere as a shutdown event. I'm using XFCE4 as my desktop and all >>> the parts that come with it. >>> >>> Sean >>> From owner-freebsd-acpi@FreeBSD.ORG Sat Mar 16 08:10:31 2013 Return-Path: Delivered-To: acpi@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id CF4304AB for ; Sat, 16 Mar 2013 08:10:31 +0000 (UTC) (envelope-from seanwbruno@gmail.com) Received: from mail-pb0-f44.google.com (mail-pb0-f44.google.com [209.85.160.44]) by mx1.freebsd.org (Postfix) with ESMTP id 85B706FE for ; Sat, 16 Mar 2013 08:10:31 +0000 (UTC) Received: by mail-pb0-f44.google.com with SMTP id wz12so4798849pbc.31 for ; Sat, 16 Mar 2013 01:10:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:subject:from:reply-to:to:cc:content-type:date:message-id :mime-version:x-mailer:content-transfer-encoding; bh=li8Q6Y8P9HRNNa/f67s3SBsHo9qK3UzyzW5I2Z4fzS8=; b=iqX3dasB44F6nQ9thU2GJk8XiYNCr0kvEQsR5DnjzNgeJbbq9JVVG+CgJqfPpEZd9X snJ5XbfRRfi1b0xMWHxlHkCvcOzWcCacMGUijaKhhp09LwsfgkpI4c71rSLbAMLiPkBd x2z0lOK9x/asIwjty/+VzeRGznedFovs34W6Rm7g/hdnrtECedCKDyHQ4pGkPkWDJz/s 2d1PPlrHNikPdOQIzeZyiSYUkEVMB/RL76q0kH1ZE+rCLa77jL1E1PKXG1XOl4aSshyz XnMRZCrhQVPqOoInFzGMvQJC9bNIfFRM9h6X4PC/ihuoywDOvvVAC5XZLgNqVIgNATy0 ouyQ== X-Received: by 10.66.241.71 with SMTP id wg7mr185676pac.155.1363421424983; Sat, 16 Mar 2013 01:10:24 -0700 (PDT) Received: from [192.168.11.253] ([180.42.49.96]) by mx.google.com with ESMTPS id fh1sm189860pac.1.2013.03.16.01.10.22 (version=SSLv3 cipher=RC4-SHA bits=128/128); Sat, 16 Mar 2013 01:10:24 -0700 (PDT) Subject: ACPI Debugging From: Sean Bruno To: acpi@freebsd.org Content-Type: text/plain; charset="us-ascii" Date: Sat, 16 Mar 2013 17:10:20 +0900 Message-ID: <1363421420.1670.3.camel@localhost> Mime-Version: 1.0 X-Mailer: Evolution 2.32.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: sbruno@freebsd.org List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 16 Mar 2013 08:10:31 -0000 Been trying to get ACPI Debugging working via http://www.freebsd.org/doc/handbook/acpi-debug.html and am not getting any output. We've compiled with options ACPI_DEBUG, set debug.acpi.enable_debug_objects, debug.acpi.layer=ACPI_ALL_DRIVERS and debug.acpi.level=ACPI_LV_VERBOSE I'm not sure anything is happening as there doesn't appear to be anything further in the system logs. What obvious bit of sorcery am I missing here? Sean From owner-freebsd-acpi@FreeBSD.ORG Sat Mar 16 09:06:15 2013 Return-Path: Delivered-To: acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 161BA243; Sat, 16 Mar 2013 09:06:15 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 23398862; Sat, 16 Mar 2013 09:06:13 +0000 (UTC) Received: from porto.starpoint.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id LAA06726; Sat, 16 Mar 2013 11:06:11 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1UGn47-0004OL-GO; Sat, 16 Mar 2013 11:06:11 +0200 Message-ID: <51443603.5080809@FreeBSD.org> Date: Sat, 16 Mar 2013 11:06:11 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130220 Thunderbird/17.0.3 MIME-Version: 1.0 To: sbruno@FreeBSD.org Subject: Re: ACPI Debugging References: <1363421420.1670.3.camel@localhost> In-Reply-To: <1363421420.1670.3.camel@localhost> X-Enigmail-Version: 1.5.1 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: acpi@FreeBSD.org, Sean Bruno X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 16 Mar 2013 09:06:15 -0000 on 16/03/2013 10:10 Sean Bruno said the following: > Been trying to get ACPI Debugging working via > http://www.freebsd.org/doc/handbook/acpi-debug.html and am not getting > any output. > > We've compiled with options ACPI_DEBUG, set > debug.acpi.enable_debug_objects, debug.acpi.layer=ACPI_ALL_DRIVERS and > debug.acpi.level=ACPI_LV_VERBOSE > > I'm not sure anything is happening as there doesn't appear to be > anything further in the system logs. > > What obvious bit of sorcery am I missing here? Last time I tried this it used to work for me with the following in loader.conf: debug.acpi.layer="ACPI_UTILITIES ACPI_OS_SERVICES" debug.acpi.level="ACPI_LV_MUTEX" -- Andriy Gapon From owner-freebsd-acpi@FreeBSD.ORG Sat Mar 16 09:19:25 2013 Return-Path: Delivered-To: acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B7920427; Sat, 16 Mar 2013 09:19:25 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id C3C358C4; Sat, 16 Mar 2013 09:19:24 +0000 (UTC) Received: from porto.starpoint.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id LAA06791; Sat, 16 Mar 2013 11:19:23 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1UGnGs-0004PR-LM; Sat, 16 Mar 2013 11:19:22 +0200 Message-ID: <5144391D.9000504@FreeBSD.org> Date: Sat, 16 Mar 2013 11:19:25 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130220 Thunderbird/17.0.3 MIME-Version: 1.0 To: sbruno@FreeBSD.org Subject: Re: ACPI Debugging References: <1363421420.1670.3.camel@localhost> <51443603.5080809@FreeBSD.org> In-Reply-To: <51443603.5080809@FreeBSD.org> X-Enigmail-Version: 1.5.1 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: acpi@FreeBSD.org, Sean Bruno X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 16 Mar 2013 09:19:25 -0000 on 16/03/2013 11:06 Andriy Gapon said the following: > on 16/03/2013 10:10 Sean Bruno said the following: >> debug.acpi.level=ACPI_LV_VERBOSE BTW, please also note what acpi(4) says about this level as opposed to e.g. ACPI_LV_VERBOSITY3. -- Andriy Gapon