Re: [PATCH] firmware: Do not use WARN_ON(!spin_is_locked())

2014-08-13 Thread Theodore Ts'o
On Wed, Aug 13, 2014 at 04:02:01PM +0100, Matt Fleming wrote: > On Wed, 13 Aug, at 07:37:37AM, Guenter Roeck wrote: > > > > WARN_ON and WARN_ON_SMP are unconditional. lockdep_assert_held() > > is only active if lockdep debugging is enabled. Not knowing the code, > > nor the reason why the uncondit

Re: [PATCH] firmware: Do not use WARN_ON(!spin_is_locked())

2014-08-13 Thread Matt Fleming
On Wed, 13 Aug, at 07:37:37AM, Guenter Roeck wrote: > > WARN_ON and WARN_ON_SMP are unconditional. lockdep_assert_held() > is only active if lockdep debugging is enabled. Not knowing the code, > nor the reason why the unconditional method was chosen, I prefer > to refrain from functional changes a

Re: [PATCH] firmware: Do not use WARN_ON(!spin_is_locked())

2014-08-13 Thread Peter Zijlstra
On Wed, Aug 13, 2014 at 03:18:36PM +0100, Matt Fleming wrote: > On Sun, 10 Aug, at 08:54:13PM, Guenter Roeck wrote: > > spin_is_locked() always returns false for uniprocessor configurations, > > so do not use WARN_ON with it. WARN_ON_SMP() exists for that very > > purpose and must be used instead.

Re: [PATCH] firmware: Do not use WARN_ON(!spin_is_locked())

2014-08-13 Thread Guenter Roeck
On 08/13/2014 07:18 AM, Matt Fleming wrote: On Sun, 10 Aug, at 08:54:13PM, Guenter Roeck wrote: spin_is_locked() always returns false for uniprocessor configurations, so do not use WARN_ON with it. WARN_ON_SMP() exists for that very purpose and must be used instead. Good catch, though I worry

Re: [PATCH] firmware: Do not use WARN_ON(!spin_is_locked())

2014-08-13 Thread Matt Fleming
On Sun, 10 Aug, at 08:54:13PM, Guenter Roeck wrote: > spin_is_locked() always returns false for uniprocessor configurations, > so do not use WARN_ON with it. WARN_ON_SMP() exists for that very > purpose and must be used instead. Good catch, though I worry that WARN_ON_SMP() doesn't seem to be a v

[PATCH] firmware: Do not use WARN_ON(!spin_is_locked())

2014-08-10 Thread Guenter Roeck
spin_is_locked() always returns false for uniprocessor configurations, so do not use WARN_ON with it. WARN_ON_SMP() exists for that very purpose and must be used instead. Signed-off-by: Guenter Roeck --- drivers/firmware/efi/vars.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) d