HID: lg4ff: Remove sysfs iface before deallocating memory
authorMichal Malý <madcatxster@gmail.com>
Sat, 31 Mar 2012 09:35:05 +0000 (11:35 +0200)
committerJiri Kosina <jkosina@suse.cz>
Tue, 3 Apr 2012 02:11:12 +0000 (04:11 +0200)
commit6a2e176b2d6ae6bb528c0c1a50a6332e176cda12
tree14799f485bbbf3bc0e32f744b430d0ebb2421088
parent8577dbf9d6eb07213caefb49e2017c177c5f023d
HID: lg4ff: Remove sysfs iface before deallocating memory

This patch fixes a possible race condition caused by the sysfs
interface being removed after the memory used by the interface
was already kfree'd.

Signed-off-by: Michal Malý <madcatsxter@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/hid-lg.h
drivers/hid/hid-lg4ff.c