]> git.baikalelectronics.ru Git - kernel.git/commit
rfkill: Use mutex_lock() at register and add sanity check
authorMichael Buesch <mb@bu3sch.de>
Sun, 28 Oct 2007 14:16:50 +0000 (15:16 +0100)
committerDavid S. Miller <davem@sunset.davemloft.net>
Sun, 11 Nov 2007 06:00:15 +0000 (22:00 -0800)
commit96119db29b7de266d79c768cc00364c90be0b21d
treeb6b1579a2bf0bfab90736ee589fa836835ede6cc
parent1174d5ea7714019b1e080610bf252e6b29766e86
rfkill: Use mutex_lock() at register and add sanity check

Replace mutex_lock_interruptible() by mutex_lock() in rfkill_register(),
as interruptible doesn't make sense there.

Add a sanity check for rfkill->type, as that's used for an unchecked dereference
in an array and might cause hard to debug crashes if the driver sets this
to an invalid value.

Signed-off-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
net/rfkill/rfkill.c