On Sun, Apr 28, 2013 at 09:32:18PM +0300, Leon Romanovsky wrote: > I think the reason of our misunderstanding is due to the name of > input_free_device call. From the code, it is device destroy function, > and the freeing itself done as an error handling of > input_register_device > (http://lxr.free-electrons.com/source/drivers/input/input.c#L2114). > How do you think we need to proceed? Do I need to send patches with > explicit call to input_free_device function? I really think the input API needs to be looked at here, this is all way too error prone. Calling input_free_device() on something allocated using devm_ looks like an error itself...