On Sun, 2010-06-27 at 23:34 -0400, Jarod Wilson wrote:
> On Sun, Jun 27, 2010 at 7:17 PM, Andy Walls <[email protected]> wrote:

> > Mauro and Jarrod,
> >
> > When ir_register_input() fails, it doesn't indicate whether or not it
> > was able to register the input_dev or not.  To me it looks like it can
> > return with failure with the input_dev either way depending on the case.
> > This makes proper cleanup of the input_dev in my cx23885_input_init()
> > function difficult in the failure case, since the input subsystem has
> > two different deallocators depending on if the device had been
> > registered or not.
> 
> Hm. I've done a double-take a few times now, but if
> input_register_device is successful, and something later in
> __ir_input_register fails, input_unregister_device *does* get called
> within __ir_input_register, so all you should have to do is call
> input_free_device in your init function's error path, no?


I couldn't quite tell (with the constant stream of intteruptions I get
at times).  That's why I asked. :)

I'll double check today once I'm done with getting the CX23888 IR Tx
working.

Regards,
Andy

--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to