Thread (4 messages) flat view 4 messages, 2 authors, 2008-01-16

Re: [PATCH] input: psmouse: fix input_dev leak in lifebook driver

From: Andres Salomon <hidden>
Date: 2008-01-16 17:57:56
Also in: lkml

On Tue, 15 Jan 2008 17:04:01 -0500
Dmitry Torokhov [off-list ref] wrote:
On Sat, Jan 12, 2008 at 03:12:52PM -0500, Andres Salomon wrote:
quoted
The lifebook driver may register a second input device, but it never
unregisters it.  This fixes that.

Signed-off-by: Andres Salomon <redacted>
Applied, thank you Andres.
Hi Dmitry,
 
There's one additional patch, I don't know if you saw it; the subject
was "check return value of input_register_device() in hil_ptr.c's init".


Also, I've found myself needing to provide my own device_attribute for
the OLPC psmouse driver; I couldn't use PSMOUSE_DEFINE_ATTR(), as its
set_helper callback calls psmouse_disable.

static DEVICE_ATTR(powered, S_IWUSR | S_IRUGO, hgpk_show_powered,
                hgpk_set_powered);

Unfortunately, in order to not be racy, hgpk_set_powered needs to
deal with psmouse_mutex.  Which method of dealing with this would
you prefer?  I could either make psmouse_mutex no longer static,
provide psmouse_mutex locking functions (declared in psmouse.h), or
put psmouse_mutex into 'struct psmouse'.  Or, if you have any other
ideas..
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help