Skip to content

Commit

Permalink
Input: simplify input_free_device()
Browse files Browse the repository at this point in the history
Now that sysfs attributes that were marked for deletion can't access
their devices we do not need to set name, phys and uniq to NULL.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
  • Loading branch information
Dmitry Torokhov committed Mar 16, 2007
1 parent c8e4c77 commit 54f9e36
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions drivers/input/input.c
Original file line number Diff line number Diff line change
Expand Up @@ -1024,14 +1024,8 @@ EXPORT_SYMBOL(input_allocate_device);
*/
void input_free_device(struct input_dev *dev)
{
if (dev) {

mutex_lock(&dev->mutex);
dev->name = dev->phys = dev->uniq = NULL;
mutex_unlock(&dev->mutex);

if (dev)
input_put_device(dev);
}
}
EXPORT_SYMBOL(input_free_device);

Expand Down

0 comments on commit 54f9e36

Please sign in to comment.