public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
To: Andrew Lutomirski <luto@mit.edu>
Cc: Matthew Garrett <mjg59@srcf.ucam.org>,
	linux-thinkpad@linux-thinkpad.org,
	ACPI Devel Maling List <linux-acpi@vger.kernel.org>
Subject: Re: [ltp] Re: [PATCH] Set osi=Linux for the ThinkPad X200s
Date: Tue, 10 Nov 2009 15:49:08 -0200	[thread overview]
Message-ID: <20091110174908.GC23283@khazad-dum.debian.net> (raw)
In-Reply-To: <cb0375e10911100532l484e69aeyd78e422c23d730ce@mail.gmail.com>

On Tue, 10 Nov 2009, Andrew Lutomirski wrote:
> On Tue, Nov 10, 2009 at 4:24 AM, Henrique de Moraes Holschuh
> <hmh@hmh.eng.br> wrote:
> > On Mon, 09 Nov 2009, Matthew Garrett wrote:
> >> When you hit the mixer button, does the ACPI interrupt count increase?
> >> If so, we're certainly in a position to do something with it.
> >
> > It is supposed to go over the KDC.  But I would be _really_ interested on
> > any events related to volume key presses on the X200s.  I expect it is
> > issuing one of the ACPI volume notification events with OSI(Linux), and none
> > without.
> 
> On brief inspection, with OSI(Linux), mute generates no ACPI
> interrupts.  Without OSI(Linux), I see an ACPI interrupt only when the
> mixer (the one in /proc/acpi/ibm/volume) changes as a result of
> muting.  So pushing mute once generates an interrupt, but then there
> are no more interrupts until I push volume up.

This makes sense.  Mute is for muting, volume up/down is for unmuting and
volume control.  Likely, after the unmute happened, futher presses of
volume up/down will go through the KDC and be reported as normal key
presses.

We just need to track down where that ACPI interrupt is going, then.

> What's the point of the IBM mixer (/proc/acpi/ibm/volume)?  We have a
> perfectly good mixer in the form of ALSA, which already knows how to
> mute and unmute the sound and even comes with nice user interfaces
> these days.

I need to finish cleaning up volume, so that I will haver enough courage to
export it as an ALSA mixer.  I am working on that right now, actually, and
now that I figured out why I had this queasy feeling that caused me to never
merge ALSA support and I am in the process of fixing the code in question,
the ALSA mixer should finally get merged for real.

> volume key.  But pressing that different hardware volume key *also*
> changes the ALSA mixer because it generates a keypress.  In my book,
> that means that the mute button messes up the sound hardware.

Please test WITHOUT OSI(Linux).  When you press volume up/down to UNMUTE,
does it still send the key over the KDC as well?  It should "eat" that
keypress and not report it anywere...

> Do we really want every thinkpad to need a special UI to indicate the
> state of the extra hardware muting function?

We want an ALSA mixer, and it will happen, now that I am rewriting the
volume code into something that won't give me nightmares.  The other
difficult stuff has been taken care of already (such as decoupling firmware
events from userspace-visible events).

Just remember one thing: thinkpad-acpi is _OLD_.  It used to be called
ibm-acpi, and it has been around since 2.6.12.  It has private interfaces
for a lot of stuff because it predates the generic interfaces for quite a
bit. I don't know if we had ALSA on 2.6.12, but I do know we were not big on
ALSA or generic interfaces back then.

-- 
  "One disk to rule them all, One disk to find them. One disk to bring
  them all and in the darkness grind them. In the Land of Redmond
  where the shadows lie." -- The Silicon Valley Tarot
  Henrique Holschuh
--
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2009-11-10 17:49 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-09 16:47 [PATCH] Set osi=Linux for the ThinkPad X200s Andrew Lutomirski
2009-11-09 16:54 ` Matthew Garrett
2009-11-09 17:49   ` Andrew Lutomirski
2009-11-09 17:54     ` Matthew Garrett
2009-11-10  9:24       ` [ltp] " Henrique de Moraes Holschuh
2009-11-10 12:42         ` Matthew Garrett
2009-11-10 13:32         ` Andrew Lutomirski
2009-11-10 14:14           ` Matthew Garrett
2009-11-10 17:49           ` Henrique de Moraes Holschuh [this message]
2009-11-10  9:19 ` [ltp] " Henrique de Moraes Holschuh
2009-11-25  4:50 ` Len Brown
2009-11-25 17:30   ` Jerone Young
2009-11-25 18:24     ` Len Brown
2009-11-25 19:56       ` Jerone Young
2009-11-26  5:07       ` Matthew Garrett
2009-11-26  6:00         ` Andrew Lutomirski
2009-11-26 17:02           ` Stefan Monnier
2009-11-26 13:43         ` Jerone Young
2009-11-25 19:01   ` Andrew Lutomirski
2009-11-30  5:47   ` Jerone Young

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20091110174908.GC23283@khazad-dum.debian.net \
    --to=hmh@hmh.eng.br \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-thinkpad@linux-thinkpad.org \
    --cc=luto@mit.edu \
    --cc=mjg59@srcf.ucam.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox