firmware: Do not use WARN_ON(!spin_is_locked())
authorGuenter Roeck <linux@roeck-us.net>
Wed, 13 Aug 2014 18:21:34 +0000 (11:21 -0700)
committerJiri Slaby <jslaby@suse.cz>
Wed, 17 Sep 2014 14:55:02 +0000 (16:55 +0200)
commit2617e71a8abc3fe12f44ed36e1cad3820a75d37c
tree52b6e3b08bb9c44021bbf6ef58c41c9398fd9c38
parentf008331068945523ff12ff13f6d07d7303e0e8a9
firmware: Do not use WARN_ON(!spin_is_locked())

commit aee530cfecf4f3ec83b78406bac618cec35853f8 upstream.

spin_is_locked() always returns false for uniprocessor configurations
in several architectures, so do not use WARN_ON with it.
Use lockdep_assert_held() instead to also reduce overhead in
non-debug kernels.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Matt Fleming <matt.fleming@intel.com>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
drivers/firmware/efi/vars.c