From: "Dmitry Torokhov" <dmitry.torokhov@gmail.com>
To: "Linus Torvalds" <torvalds@linux-foundation.org>
Cc: "Matthew Garrett" <mjg59@srcf.ucam.org>,
"Henrique de Moraes Holschuh" <hmh@hmh.eng.br>,
"Jeremy Katz" <katzj@redhat.com>,
linux-kernel@vger.kernel.org, davej@redhat.com
Subject: Re: [PATCH] Map volume and brightness events on thinkpads
Date: Wed, 17 Oct 2007 11:57:18 -0400 [thread overview]
Message-ID: <d120d5000710170857i3f534544pe9cab0ca6c1b0aa4@mail.gmail.com> (raw)
In-Reply-To: <alpine.LFD.0.999.0710161325570.6887@woody.linux-foundation.org>
On 10/16/07, Linus Torvalds <torvalds@linux-foundation.org> wrote:
>
> On Tue, 16 Oct 2007, Dmitry Torokhov wrote:
> >
> > I agree that these are 2 different events. My argument is that
> > "VOLUME_UP_NOTIFY" event is similar to "BATTERY_OUT_NOTIFY",
> > "DOCK_UNDOCK_NOTIFY", etc, etc and should be sent not through input
> > layer but through a generic (yet to be designed) notification
> > mechanism. Something lighter than input. Something like uevents over
> > netlink.
>
> Well, I'd argue that:
>
> - it's going to be the same entity that cares in both cases (ie anybody
> who is ready to accept VOLUME_UP keypresses is also the exact same
> party that also wants to know if VOLUME_UP happened *independently*)
>
> Ergo: making it a separate "generic" notification is actually totally
> counterproductive, because it just adds complexity.
That is a good argument. If there are no other users for this other
transport then I agree, inventing it just for keypress notifications
is bad idea.
> - it really is a keypress. Yes, it's a keypress with side effects, but
> it still tends to have a distinct source, and as such it is interesting
> *as* a keypress.
>
> IOW: it should have all the same "incidental" side effects as any other
> keypress. Example: I think it's reasonable to consider it an event as
> far as the screen saver is concerned. In other words, it's not *just* a
> "volume was raised" event. It's a "volume was raised, and the user
> actually pressed a key to do so".
>
This is a good argument for having 2 separate types of events but not
for which transport shoudl be used to deliver it.
> So I do think they are keypresses, although I also suspect that like many
> other magical keys, the "NOTIFY" version is often also totally hidden by
> hardware/firmware interactions (ie I'm pretty sure that many of those
> special keys will never be visible at all to the OS, because the firmware
> hides the fact that they were pressed entirely!)
>
Yes, on my old Inspiron brightness is completely handled by firmware.
There is no ACPI, nor keyboard events generated whatsoever.
OK, I guess I would like to hear once again from userspace guys -
DBUS/HAL/etc. Do they see a need for a generic interface that can be
used for all kinds of events, not only related to keypresses. If they
say that they only care about notifications arising from keypresses
then I will add EV_NOTIFY type of events to input layer. What events
would we need? I can imagine:
KEY_BRIGHTNESSUP_NOTIFY
KEY_BRIGHTNESSDOWN_NOTIFY
KEY_BRIGHTNESSMIN_NOTIFY
KEY_BRIGHTNESSMAX_NOTIFY
KEY_VOLUMEUP_NOTIFY
KEY_VOLUMEDOWN_NOTIFY
KEY_MUTE_NOTIFY
KEY_DISPLAYSWITCH_NOTIFY
KEY_WIFI_NOTIFY
What else? And it better have "key" in its name, BATTERY_OUT_NOTIFY
won't fly ;)
--
Dmitry
next prev parent reply other threads:[~2007-10-17 15:57 UTC|newest]
Thread overview: 47+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-15 20:45 Jeremy Katz
2007-10-15 21:07 ` Henrique de Moraes Holschuh
2007-10-15 21:27 ` Jeremy Katz
2007-10-16 9:12 ` Henrique de Moraes Holschuh
2007-10-15 21:43 ` Arjan van de Ven
2007-10-16 3:38 ` Jesse Barnes
2007-10-16 8:36 ` Henrique de Moraes Holschuh
2007-10-16 8:49 ` Jesse Barnes
2007-10-16 9:18 ` Henrique de Moraes Holschuh
2007-10-17 2:40 ` Jesse Barnes
2007-10-17 6:25 ` Henrique de Moraes Holschuh
2007-10-17 6:32 ` Jesse Barnes
2007-10-17 6:39 ` Henrique de Moraes Holschuh
2007-10-16 13:00 ` Matthew Garrett
2007-10-16 14:11 ` Henrique de Moraes Holschuh
2007-10-16 14:21 ` Matthew Garrett
2007-10-16 14:31 ` Henrique de Moraes Holschuh
2007-10-16 14:40 ` Matthew Garrett
2007-10-16 16:56 ` Henrique de Moraes Holschuh
2007-10-16 18:46 ` Matthew Garrett
2007-10-16 19:14 ` Linus Torvalds
2007-10-16 19:20 ` Matthew Garrett
2007-10-16 20:02 ` Henrique de Moraes Holschuh
2007-10-16 20:15 ` Dmitry Torokhov
2007-10-16 20:12 ` Dmitry Torokhov
2007-10-16 20:11 ` Jeremy Katz
2007-10-16 20:19 ` Dmitry Torokhov
2007-10-16 20:32 ` Linus Torvalds
2007-10-17 15:57 ` Dmitry Torokhov [this message]
2007-10-17 16:28 ` Matthew Garrett
2007-10-17 17:35 ` Henrique de Moraes Holschuh
2007-10-17 18:59 ` Dmitry Torokhov
2007-10-17 20:42 ` Henrique de Moraes Holschuh
2007-10-18 14:37 ` Dmitry Torokhov
2007-10-18 22:39 ` Henrique de Moraes Holschuh
2007-10-23 15:54 ` Dmitry Torokhov
2007-10-23 23:34 ` Henrique de Moraes Holschuh
2007-10-16 20:48 ` Kok, Auke
2007-10-16 20:55 ` Matthew Garrett
2007-10-16 21:18 ` Dmitry Torokhov
2007-10-16 20:32 ` Dave Airlie
2007-10-16 14:27 ` Dmitry Torokhov
2007-10-16 14:54 ` Matthew Garrett
2007-10-16 15:54 ` Dmitry Torokhov
2007-10-16 15:59 ` Matthew Garrett
2007-10-16 18:53 ` Matthew Garrett
2007-10-16 19:23 ` Renato S. Yamane
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=d120d5000710170857i3f534544pe9cab0ca6c1b0aa4@mail.gmail.com \
--to=dmitry.torokhov@gmail.com \
--cc=davej@redhat.com \
--cc=hmh@hmh.eng.br \
--cc=katzj@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mjg59@srcf.ucam.org \
--cc=torvalds@linux-foundation.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
all inboxes | Powered by JetHome®