2006-05-16 16:00:17

by Stas Sergeev

[permalink] [raw]
Subject: Re: [patch] add input_enable_device()

Hello.

Andrew Morton wrote:
> Separate functions input_enable_device(struct input_handle *handle) and
> input_disable_device(struct input_handle *handle) would be preferred.
Right, and here it goes.

---
add input_enable_device() and input_disable_device()

Signed-off-by: Stas Sergeev <[email protected]>
CC: Dmitry Torokhov <[email protected]>
CC: Vojtech Pavlik <[email protected]>



Attachments:
input_en2.diff (1.61 kB)

2006-05-16 16:06:56

by Andrew Morton

[permalink] [raw]
Subject: Re: [patch] add input_enable_device()

Stas Sergeev <[email protected]> wrote:
>
> add input_enable_device() and input_disable_device()
>
> Signed-off-by: Stas Sergeev <[email protected]>
> CC: Dmitry Torokhov <[email protected]>
> CC: Vojtech Pavlik <[email protected]>

uh, that's not a complete changelog - it describes what the code does
(which is obvious), but doesn't describe why it does it.

iirc it had to do with the pc-speaker driver, but I don't seem to be able
to locate the original email.

2006-05-16 16:29:43

by Stas Sergeev

[permalink] [raw]
Subject: Re: [patch] add input_enable_device()

Hello.

Andrew Morton wrote:
> iirc it had to do with the pc-speaker driver, but I don't seem to be able
> to locate the original email.
OK, sorry, I haven't realized its important.

---
The patch below adds input_enable_device() and input_disable_device()
to the input subsystem, that allows to enable and disable the input
devices. The reason to have it, is the snd-pcsp PC-Speaker driver in
an ALSA tree that needs an ability to disable the pcspkr driver.

Signed-off-by: Stas Sergeev <[email protected]>
CC: Dmitry Torokhov <[email protected]>
CC: Vojtech Pavlik <[email protected]>


Attachments:
input_en2.diff (1.61 kB)

2006-05-16 16:44:16

by Chase Venters

[permalink] [raw]
Subject: Re: [patch] add input_enable_device()

On Tue, 16 May 2006, Stas Sergeev wrote:

> Hello.
>
> Andrew Morton wrote:
>> iirc it had to do with the pc-speaker driver, but I don't seem to be able
>> to locate the original email.
> OK, sorry, I haven't realized its important.
>
> ---
> The patch below adds input_enable_device() and input_disable_device()
> to the input subsystem, that allows to enable and disable the input
> devices. The reason to have it, is the snd-pcsp PC-Speaker driver in
> an ALSA tree that needs an ability to disable the pcspkr driver.
>
> Signed-off-by: Stas Sergeev <[email protected]>
> CC: Dmitry Torokhov <[email protected]>
> CC: Vojtech Pavlik <[email protected]>
>
>

> --- a/include/linux/input.h 2006-04-05 17:10:01.000000000 +0400
> +++ b/include/linux/input.h 2006-04-05 17:36:49.000000000 +0400
> @@ -878,7 +878,7 @@
>
> struct pt_regs *regs;
> int state;
> -
> + int disabled;
> int sync;
>
> int abs[ABS_MAX + 1];

Why eat an entire word here? It seems we already have a "dynalloc"
boolean/int... perhaps some of these things could be rolled up into a
bitfield.

Cheers,
Chase