All of lore.kernel.org
 help / color / mirror / Atom feed
From: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
To: Clemens Ladisch <clemens@ladisch.de>
Cc: ibm-acpi-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org
Subject: Re: [ibm-acpi-devel] [PATCH] thinkpad-acpi: fix return value of volume callbacks
Date: Fri, 26 Feb 2010 21:55:01 -0300	[thread overview]
Message-ID: <20100227005501.GA25762@khazad-dum.debian.net> (raw)
In-Reply-To: <4B877A81.4030300@ladisch.de>

On Fri, 26 Feb 2010, Clemens Ladisch wrote:
> > > ALSA sends notifications to all mixer application when the value of
> > > any mixer control has changed.  To be able to avoid sending them for
> > > controls that did not actually change, it uses the return value of the
> > > .put callback: 0 means the control value did not change; 1 means it has
> > > changed (or might have changed), and a notification is to be sent.
> > > <http://www.alsa-project.org/~tiwai/writing-an-alsa-driver/ch06s05.html#control-interface-callbacks-put>
> > 
> > I am looking at it.  I think I had it like that on purpose, to trigger an
> > OSD when a volume-related hotkey is pressed even if it doesn't change the
> > state (mute when already mute, vol down when already at minimum, etc).
> 
> This is not about changes initiated by key presses but changes made
> through the ALSA mixer API.  Or does the hardware generate a hotkey
> event when software changes the volume?

The firmware doesn't send events for software changes, mostly because it
does not want, or, expect any.  These mixers are read-only by default.

-- 
  "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

      reply	other threads:[~2010-02-27  0:55 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-22  9:45 [PATCH] thinkpad-acpi: fix return value of volume callbacks Clemens Ladisch
2010-02-23  3:12 ` Henrique de Moraes Holschuh
2010-02-23  7:36   ` Clemens Ladisch
2010-02-26  0:30     ` Henrique de Moraes Holschuh
2010-02-26  7:38       ` Clemens Ladisch
2010-02-27  0:55         ` Henrique de Moraes Holschuh [this message]

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=20100227005501.GA25762@khazad-dum.debian.net \
    --to=hmh@hmh.eng.br \
    --cc=clemens@ladisch.de \
    --cc=ibm-acpi-devel@lists.sourceforge.net \
    --cc=linux-kernel@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.