Re: [ibm-acpi-devel] [ltp] Re: CALL FOR TESTING: thinkpad-acpi BETA release 0.14-20070708

2007-07-16 Thread Peter Jordan
Henrique de Moraes Holschuh, 07/16/07 23:08:

> On Mon, 16 Jul 2007, Peter Jordan wrote:
>> Henrique de Moraes Holschuh, 07/16/07 21:44:
>> How?
> 
> HAL fdi file, or using input-kbd.
> 

input-kbd works, thank you.

PJ


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


[ibm-acpi-devel] thinkpad-acpi 16-level brightness on X61s

2007-07-16 Thread Henrique de Moraes Holschuh
Peter, since your thinkpad has a lot of brightness levels, maybe you could
send me the output of:

hexdump -C /dev/nvram

with the display in a very low brightness level, and also with the display
in the highest brightness level ?

Thanks.

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

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] [ltp] Re: CALL FOR TESTING: thinkpad-acpi BETA release 0.14-20070708

2007-07-16 Thread Henrique de Moraes Holschuh
On Mon, 16 Jul 2007, Peter Jordan wrote:
> Henrique de Moraes Holschuh, 07/16/07 21:44:
> > On Mon, 16 Jul 2007, Peter Jordan wrote:
> >> Peter Jordan, 07/16/07 19:08:
> >>> Henrique de Moraes Holschuh, 07/16/07 18:12:
>  On Mon, 16 Jul 2007, Peter Jordan wrote:
> > Henrique de Moraes Holschuh, 07/16/07 17:16:
> > $ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_all_mask
> > 0x00ff
> >
> > And what can i do now?
>  Compile it with*out* THINKPAD_ACPI_INPUT_ENABLED, and do this to enable
>  hotkeys:
> 
>  echo 1 > /sys/bus/platform/devices/thinkpad_acpi/hotkey_enable
>  cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask > 
>  /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask
> 
>  And re-test :-) You are not enabling all hotkeys you want...
> 
>  If you want to use THINKPAD_ACPI_INPUT_ENABLED, you need updated 
>  userspace.
> 
> >>>
> >>> Ok, with "THINKPAD_ACPI_INPUT_ENABLED NOT SET" and "cat
> >>> /sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask >
> >>> /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask" input-utils finds
> >>> all keys without fn+f4, fn+f10, the volume keys, and the thinklight key,
> >>> but all keys work fine.
> >>>
> >>> let me know if i can give you any other information.
> >>>
> >>> btw: /proc/acpi/ibm/volume says "level  ( is 0-15)" but
> >>> the range on my R60 is 0 to 14.
> >>>
> >> followup:
> >> acpid does not find the thinkvantage key
> > 
> > It won't, unless you remap it to KEY_UNKOWN or KEY_RESERVED. 
> 
> How?

HAL fdi file, or using input-kbd.

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

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] [ltp] Re: CALL FOR TESTING: thinkpad-acpi BETA release 0.14-20070708

2007-07-16 Thread Peter Jordan
Henrique de Moraes Holschuh, 07/16/07 21:44:

> On Mon, 16 Jul 2007, Peter Jordan wrote:
>> Peter Jordan, 07/16/07 19:08:
>>> Henrique de Moraes Holschuh, 07/16/07 18:12:
 On Mon, 16 Jul 2007, Peter Jordan wrote:
> Henrique de Moraes Holschuh, 07/16/07 17:16:
> $ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_all_mask
> 0x00ff
>
> And what can i do now?
 Compile it with*out* THINKPAD_ACPI_INPUT_ENABLED, and do this to enable
 hotkeys:

 echo 1 > /sys/bus/platform/devices/thinkpad_acpi/hotkey_enable
 cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask > 
 /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask

 And re-test :-) You are not enabling all hotkeys you want...

 If you want to use THINKPAD_ACPI_INPUT_ENABLED, you need updated userspace.

>>>
>>> Ok, with "THINKPAD_ACPI_INPUT_ENABLED NOT SET" and "cat
>>> /sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask >
>>> /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask" input-utils finds
>>> all keys without fn+f4, fn+f10, the volume keys, and the thinklight key,
>>> but all keys work fine.
>>>
>>> let me know if i can give you any other information.
>>>
>>> btw: /proc/acpi/ibm/volume says "level  ( is 0-15)" but
>>> the range on my R60 is 0 to 14.
>>>
>> followup:
>> acpid does not find the thinkvantage key
> 
> It won't, unless you remap it to KEY_UNKOWN or KEY_RESERVED. 

How?

> But input-events should find it.  Does it?

Yes, it does:

22:24:50.255136: EV_KEY KEY_VENDOR pressed
22:24:50.255142: EV_SYN code=0 value=0
22:24:50.255144: EV_KEY KEY_VENDOR released
22:24:50.255146: EV_SYN code=0 value=0


PJ


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] [ltp] Re: CALL FOR TESTING: thinkpad-acpi BETA release 0.14-20070708

2007-07-16 Thread Henrique de Moraes Holschuh
On Mon, 16 Jul 2007, Peter Jordan wrote:
> Peter Jordan, 07/16/07 19:08:
> > Henrique de Moraes Holschuh, 07/16/07 18:12:
> >> On Mon, 16 Jul 2007, Peter Jordan wrote:
> >>> Henrique de Moraes Holschuh, 07/16/07 17:16:
> >>> $ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_all_mask
> >>> 0x00ff
> >>>
> >>> And what can i do now?
> >> Compile it with*out* THINKPAD_ACPI_INPUT_ENABLED, and do this to enable
> >> hotkeys:
> >>
> >> echo 1 > /sys/bus/platform/devices/thinkpad_acpi/hotkey_enable
> >> cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask > 
> >> /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask
> >>
> >> And re-test :-) You are not enabling all hotkeys you want...
> >>
> >> If you want to use THINKPAD_ACPI_INPUT_ENABLED, you need updated userspace.
> >>
> > 
> > 
> > Ok, with "THINKPAD_ACPI_INPUT_ENABLED NOT SET" and "cat
> > /sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask >
> > /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask" input-utils finds
> > all keys without fn+f4, fn+f10, the volume keys, and the thinklight key,
> > but all keys work fine.
> > 
> > let me know if i can give you any other information.
> > 
> > btw: /proc/acpi/ibm/volume says "level  ( is 0-15)" but
> > the range on my R60 is 0 to 14.
> > 
> followup:
> acpid does not find the thinkvantage key

It won't, unless you remap it to KEY_UNKOWN or KEY_RESERVED.  But
input-events should find it.  Does it?

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

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] [ltp] Re: CALL FOR TESTING: thinkpad-acpi BETA release 0.14-20070708

2007-07-16 Thread Peter Jordan
Peter Jordan, 07/16/07 19:08:

> Henrique de Moraes Holschuh, 07/16/07 18:12:
> 
>> On Mon, 16 Jul 2007, Peter Jordan wrote:
>>> Henrique de Moraes Holschuh, 07/16/07 17:16:
>>> $ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_all_mask
>>> 0x00ff
>>>
>>> And what can i do now?
>> Compile it with*out* THINKPAD_ACPI_INPUT_ENABLED, and do this to enable
>> hotkeys:
>>
>> echo 1 > /sys/bus/platform/devices/thinkpad_acpi/hotkey_enable
>> cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask > 
>> /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask
>>
>> And re-test :-) You are not enabling all hotkeys you want...
>>
>> If you want to use THINKPAD_ACPI_INPUT_ENABLED, you need updated userspace.
>>
> 
> 
> Ok, with "THINKPAD_ACPI_INPUT_ENABLED NOT SET" and "cat
> /sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask >
> /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask" input-utils finds
> all keys without fn+f4, fn+f10, the volume keys, and the thinklight key,
> but all keys work fine.
> 
> let me know if i can give you any other information.
> 
> btw: /proc/acpi/ibm/volume says "level  ( is 0-15)" but
> the range on my R60 is 0 to 14.
> 
followup:
acpid does not find the thinkvantage key

PJ


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] ACPI: thinkpad-acpi: add input device support to hotkey subdriver

2007-07-16 Thread Matthew Garrett
On Mon, Jul 16, 2007 at 03:19:11PM -0300, Henrique de Moraes Holschuh wrote:

> Anyway, if the input layer is really not the place for "passive key
> presses", then my decision to not issue input events for such stuff is the
> correct one.

That wasn't my interpretation of what Dmitry said - it's not a generic 
event layer, but when you have keys that generate events that would be 
useful to userspace then I think it makes absolute sense to send them.

> Brightness can be notified through ACPI (ACPI 3.0b has standard events for
> this), or it could be done through an improved backlight sysfs class.  It
> will require work either way, because you don't want ACPI video processing
> these synthezised events, or because you need to get backlight to be
> poll()/select() or inotify()-friendly if you don't want to add another
> dumbass userspace polling loop.

The simple fact of the matter is that when you get outside the range of 
the standard qwerty keys, the semantics of the buttons become hardware 
dependent. The behaviour of KEY_SWITCHVIDEOMODE is going to vary wildly 
between hardware. Wlan control may be active or passive (and the 
standard adopted there appears to be to send KEY_WLAN regardless). Dells 
will trigger a dock unplug event automatically if you hit the dock 
unplug button - Thinkpads won't.

I think it makes absolute sense to get these notifications in the same 
way wherever possible, and then let userspace handle them as 
appropriate. On modern Thinkpads I need to alter whichever backlight 
interface is most appropriate to the machine in question (something that 
itself is going to differ between Thinkpads and, say, Macs) whereas in 
older ones I just want to pop up a notification with the new brightness. 

I realise your concern about breaking existing userspace, but as far as 
I can tell there /is/ no existing userspace to break. Hal does the right 
thing already, and there's nothing else that listens for key brightness 
events on Thinkpads.

> Built-in headphone/speaker volume can be notified and controlled through an
> ALSA mixer.  It won't be a nice poll-less thing, but I can trap the ACPI hot
> key events as a hint to update the mixer state, and if ALSA lets me do it,
> issue mixer changed notifications.

ALSA lets you do that.

-- 
Matthew Garrett | [EMAIL PROTECTED]

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] ACPI: thinkpad-acpi: make the input event mode the default

2007-07-16 Thread Henrique de Moraes Holschuh
On Mon, 16 Jul 2007, Dmitry Torokhov wrote:
> I will add a comment to input.h to the effect that KEY_SWITCHVIDEOMODE
> is to switch between available outputs (LCD/Monitor/TV-Out/Whatnot).
> Right now couple of RCs are using it for different purposes (cycling
> through inputs I think) so we should do somethig about these.

I will add KEY_SWITCHVIDEOMODE to FN+F7 (thinkpad cycle output video port
key), 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

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] ACPI: thinkpad-acpi: add input device support to hotkey subdriver

2007-07-16 Thread Henrique de Moraes Holschuh
On Mon, 16 Jul 2007, Matthew Garrett wrote:
> On Mon, Jul 16, 2007 at 11:46:26AM -0400, Dmitry Torokhov wrote:
> > How do you know that this is a "passive keypress"? Can you put another
> > (better) soundcard in a docking station? Woudl the firmware still
> > control that card (doubtful)? Do we want the same keys to control that
> > card's volume?
> 
> This is absolutely possible. In that case I'd expect the hotkeys to 
> start controlling the card mixer's volume, but that's a policy decision 
> that would have to be taken in userspace by an application aware of 
> everything that's happened.

The moment you screw up with the thinkpad builtin mixer, you are screwing
with the emergency notification system (system beeps).  They go *only*
through that mixer, and their signal is not routed through the builtin AC97
(and probably not through HDA either) mixers.   I would stay well away from
trying to override what these buttons do.

In fact, the thinkpad volume buttons are (in most thinkpads, I don't speak
for the new *61 models, they may be different) the "button version" of a
small volume dial near the headphone jack.

They were NOT made to be used in any other way, they DO NOT work in any
other way in Windows, and the firmware does NOT cooperate to let you use
them in any other way.

This whole issue is mainly caused by a refusal to understand this simple
fact.  THOSE BUTTONS ARE NOT GENERIC VOLUME CONTROL BUTTONS unless you hack
the firmware on anything but the very newest X61, R61 and T61... and maybe
even on them.

(and if you hack the firmware, you can get thinkpad-acpi to do what you want
with just the right sysfs setting).

IMO, if you want to use hot keys to control the AC97/HDA/soundcard mixer
volume in a typical thinkpad where the volume buttons are handled in
firmware, just assign Fn+Insert and Fn+delete to VOLUME_UP and VOLUME_DOWN,
they are right to the side of HOME/END (brightness up/down) anyway.

Anyway, if the input layer is really not the place for "passive key
presses", then my decision to not issue input events for such stuff is the
correct one.

Brightness can be notified through ACPI (ACPI 3.0b has standard events for
this), or it could be done through an improved backlight sysfs class.  It
will require work either way, because you don't want ACPI video processing
these synthezised events, or because you need to get backlight to be
poll()/select() or inotify()-friendly if you don't want to add another
dumbass userspace polling loop.

Built-in headphone/speaker volume can be notified and controlled through an
ALSA mixer.  It won't be a nice poll-less thing, but I can trap the ACPI hot
key events as a hint to update the mixer state, and if ALSA lets me do it,
issue mixer changed notifications.

And thinklight toggle key presses can be notified through the LED class,
although that one is such an useless notification, that I simply don't know
if I should bother with it.

That covers all thinkpad "passive" EV_KEY events.

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

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] [ltp] Re: CALL FOR TESTING: thinkpad-acpi BETA release 0.14-20070708

2007-07-16 Thread Peter Jordan
Henrique de Moraes Holschuh, 07/16/07 18:12:

> On Mon, 16 Jul 2007, Peter Jordan wrote:
>> Henrique de Moraes Holschuh, 07/16/07 17:16:
>> $ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_all_mask
>> 0x00ff
>>
>> And what can i do now?
> 
> Compile it with*out* THINKPAD_ACPI_INPUT_ENABLED, and do this to enable
> hotkeys:
> 
> echo 1 > /sys/bus/platform/devices/thinkpad_acpi/hotkey_enable
> cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask > 
> /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask
> 
> And re-test :-) You are not enabling all hotkeys you want...
> 
> If you want to use THINKPAD_ACPI_INPUT_ENABLED, you need updated userspace.
> 


Ok, with "THINKPAD_ACPI_INPUT_ENABLED NOT SET" and "cat
/sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask >
/sys/bus/platform/devices/thinkpad_acpi/hotkey_mask" input-utils finds
all keys without fn+f4, fn+f10, the volume keys, and the thinklight key,
but all keys work fine.

let me know if i can give you any other information.

btw: /proc/acpi/ibm/volume says "level  ( is 0-15)" but
the range on my R60 is 0 to 14.

PJ


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] [ltp] Re: CALL FOR TESTING: thinkpad-acpi BETA release 0.14-20070708

2007-07-16 Thread Henrique de Moraes Holschuh
On Mon, 16 Jul 2007, Peter Jordan wrote:
> Henrique de Moraes Holschuh, 07/16/07 17:16:
> > On Mon, 16 Jul 2007, Peter Jordan wrote:
> >> Henrique de Moraes Holschuh, 07/15/07 22:19:
> >> $ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask
> >> 0x
> > 
> > That mask will *NOT* enable any extended hotkeys.
> > 
> > That said, I need the output of hotkey_all_mask (not hotkey_mask) to know
> > what the firmware is reporting as its capabilities...
> > 
> 
> $ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_all_mask
> 0x00ff
> 
> >> With thinkpad-acpi v 0.15 all fn+f* hotkeys does not work too; but $xev
> >> find them.
> > 
> > That's because you probably configured the driver to enable the input device
> > by default.  Which does enable every active hotkey by default (unlike the
> > old behaviour), but routes them over to the input device.
> 
> And what can i do now?

Compile it with*out* THINKPAD_ACPI_INPUT_ENABLED, and do this to enable
hotkeys:

echo 1 > /sys/bus/platform/devices/thinkpad_acpi/hotkey_enable
cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_recommended_mask > 
/sys/bus/platform/devices/thinkpad_acpi/hotkey_mask

And re-test :-) You are not enabling all hotkeys you want...

If you want to use THINKPAD_ACPI_INPUT_ENABLED, you need updated userspace.

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

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] ACPI: thinkpad-acpi: add input device support to hotkey subdriver

2007-07-16 Thread Matthew Garrett
On Mon, Jul 16, 2007 at 11:46:26AM -0400, Dmitry Torokhov wrote:

> How do you know that this is a "passive keypress"? Can you put another
> (better) soundcard in a docking station? Woudl the firmware still
> control that card (doubtful)? Do we want the same keys to control that
> card's volume?

This is absolutely possible. In that case I'd expect the hotkeys to 
start controlling the card mixer's volume, but that's a policy decision 
that would have to be taken in userspace by an application aware of 
everything that's happened.

-- 
Matthew Garrett | [EMAIL PROTECTED]

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] ACPI: thinkpad-acpi: add input device support to hotkey subdriver

2007-07-16 Thread Dmitry Torokhov
On 7/15/07, Henrique de Moraes Holschuh <[EMAIL PROTECTED]> wrote:
> On Sun, 15 Jul 2007, Matthew Garrett wrote:
> > On Sun, Jul 15, 2007 at 05:59:34PM -0300, Henrique de Moraes Holschuh wrote:
> > > *HAL* does.  HAL is *not* all there is to userspace.  The input layer is 
> > > not
> > > an interface between the kernel and HAL, it is an interface between kernel
> > > and userspace.
> >
> > Hal is the only piece of userspace that knows how to speak to more than
> > one type of backlight in any useful way, which makes it the de-facto
> > reference for how userspace interprets these keys.
>
> Since when does system-specific programs not count?
>
> Anyway, the idea of "special cases" that are not exposed anywhere and
> requires out-of-band information to be handled correctly is just broken IMO.
> This goes triple for an interface whose only canon documentation is the
> current kernel code, so you can't even tell people to read somewhere how to
> properly use it.
>
> Since we have detected the need for passive events, I'd much rather that
> information was added to the input layer itself, instead of being
> synthesized later.
>

I am unconvinced that input layer is the proper place to add such
information. These are events signalling state change of some device.
In case of volume changes these events do not refect change in
keyboard state but rather some other device (sound card) so I would
expect these events be coming from there.
I also do not want to convert input layer into kitchen sink of generic
userspace notifications. Laptop "battery removed" does not belong to
input. "Network cable removed" does not belong to input. "Hard driver
dying" does not belong to input.

> > > Add that knowledge to the input layer, and I will agree.  Add it to every
> > > consumer of input events, and I will concede.  Until then, it is good that
> > > HAL can overcome the lack of such information in the input layer, but that
> > > doesn't make it the right way to use the input layer.
> >
> > The fact that keys share event codes doesn't mean that these keycodes
> > are going to have identical semantics on all hardware. One solution to
> > that would be to avoid ever sending these keycodes, but that would make
> > having them defined in the first place a bit silly. Since they /are/
> > there, it makes sense to use them.
>
> I see a keycode defined in the USB HID spec for use in stuff that only knows
> active handling -- passive doesn't even make any sense for them -- and its
> reflect on the kernel input layer.
>
> There _are_ a few platforms where *one* of the built-in devices need a
> different handling, and that's just because the firmware won't cooperate.
> But if I plug a USB keyboard on a thinkpad, for example, I need the proper
> (active) handling of the event.
>
> I definately think "avoid ever sending these keycodes" in this instance is
> the right way to go, until we can actually issue a "this is a passive key
> press" event.
>

How do you know that this is a "passive keypress"? Can you put another
(better) soundcard in a docking station? Woudl the firmware still
control that card (doubtful)? Do we want the same keys to control that
card's volume?

-- 
Dmitry

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] [ltp] Re: CALL FOR TESTING: thinkpad-acpi BETA release 0.14-20070708

2007-07-16 Thread Peter Jordan
Henrique de Moraes Holschuh, 07/16/07 17:16:

> On Mon, 16 Jul 2007, Peter Jordan wrote:
>> Henrique de Moraes Holschuh, 07/15/07 22:19:
>> $ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask
>> 0x
> 
> That mask will *NOT* enable any extended hotkeys.
> 
> That said, I need the output of hotkey_all_mask (not hotkey_mask) to know
> what the firmware is reporting as its capabilities...
> 

$ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_all_mask
0x00ff

>> With thinkpad-acpi v 0.15 all fn+f* hotkeys does not work too; but $xev
>> find them.
> 
> That's because you probably configured the driver to enable the input device
> by default.  Which does enable every active hotkey by default (unlike the
> old behaviour), but routes them over to the input device.
> 

And what can i do now?

PJ


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] ACPI: thinkpad-acpi: make the input event mode the default

2007-07-16 Thread Dmitry Torokhov
On 7/15/07, Henrique de Moraes Holschuh <[EMAIL PROTECTED]> wrote:
> On Mon, 16 Jul 2007, Matthew Garrett wrote:
> >
> > Having checked other drivers, it looks like KEY_SWITCHVIDEOMODE is the
> > one used for video toggling. If that's not actually how people are using
> > it, we need to fix that - if it is, I'd just go for it.
>
> This looks like a breakage warning to me.  Better decide once and for all
> what this keycode is supposed to do, and document it.  Because switching
> video mode is not "switch video output mode", and can easily be confused
> with "switch screen resolution", "switch video mode between expanded and
> normal" or whatever.
>

I will add a comment to input.h to the effect that KEY_SWITCHVIDEOMODE
is to switch between available outputs (LCD/Monitor/TV-Out/Whatnot).
Right now couple of RCs are using it for different purposes (cycling
through inputs I think) so we should do somethig about these.

-- 
Dmitry

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] how to get OSD without tpb?

2007-07-16 Thread Henrique de Moraes Holschuh
On Sun, 15 Jul 2007, Chris Hanson wrote:
> I've been playing around with the new input-event support in 
> thinkpad-acpi, and by and large it works well.  (I'm using a T60p, 
> Debian unstable, linux 2.6.22.1 with thinkpad-acpi 0.15-20070714.)  I 
> seem to be getting most of the input events I expect
> 
> However, when I disable tpb, although all the functions still work as 
> expected, I don't get any on-screen display.  I have gnome-osd 
> installed, so I'm guessing I need to handle this manually using 
> gnome-osd-client?  Or am I missing something?  I don't want to use tpb 
> if it's avoidable.

You will need either new HAL, or to do some tweaking.  Getting this to work
in userspace needs bleeding-edge stuff, AFAIK.   I would tell you exactly
what to do, but I don't know that :(

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

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] [ltp] Re: CALL FOR TESTING: thinkpad-acpi BETA release 0.14-20070708

2007-07-16 Thread Henrique de Moraes Holschuh
On Mon, 16 Jul 2007, Peter Jordan wrote:
> Henrique de Moraes Holschuh, 07/15/07 22:19:
> > On Sun, 15 Jul 2007, Peter Jordan wrote:
> >> Henrique de Moraes Holschuh, 07/15/07 21:08:
> >>> On Sun, 15 Jul 2007, Peter Jordan wrote:
>  Peter Jordan, 07/15/07 15:56:
>  Do you need more informations?
> >>> dmidecode and acpidump output would be useful, if I don't have them 
> >>> already.
> >>> Also, one will have to track down where the thinkvantage button went.
> >>>
> >>> Does tpb still find it ?
> >>>
> >> Yes, tpb finds it.
> > 
> > What does thinkpad-acpi reports as
> > /sys/bus/platform/devices/thinkpad_acpi/hotkey_all_mask ?
> 
> $ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask
> 0x

That mask will *NOT* enable any extended hotkeys.

That said, I need the output of hotkey_all_mask (not hotkey_mask) to know
what the firmware is reporting as its capabilities...

> With thinkpad-acpi v 0.15 all fn+f* hotkeys does not work too; but $xev
> find them.

That's because you probably configured the driver to enable the input device
by default.  Which does enable every active hotkey by default (unlike the
old behaviour), but routes them over to the input device.

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

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel


Re: [ibm-acpi-devel] [ltp] Re: CALL FOR TESTING: thinkpad-acpi BETA release 0.14-20070708

2007-07-16 Thread Peter Jordan
Henrique de Moraes Holschuh, 07/15/07 22:19:

> On Sun, 15 Jul 2007, Peter Jordan wrote:
>> Henrique de Moraes Holschuh, 07/15/07 21:08:
>>> On Sun, 15 Jul 2007, Peter Jordan wrote:
 Peter Jordan, 07/15/07 15:56:
 Do you need more informations?
>>> dmidecode and acpidump output would be useful, if I don't have them already.
>>> Also, one will have to track down where the thinkvantage button went.
>>>
>>> Does tpb still find it ?
>>>
>> Yes, tpb finds it.
> 
> What does thinkpad-acpi reports as
> /sys/bus/platform/devices/thinkpad_acpi/hotkey_all_mask ?
> 

$ cat /sys/bus/platform/devices/thinkpad_acpi/hotkey_mask
0x

With thinkpad-acpi v 0.15 all fn+f* hotkeys does not work too; but $xev
find them.

PJ


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
ibm-acpi-devel mailing list
ibm-acpi-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel