Messages in this thread | | | Date | Wed, 19 Jun 2013 18:11:25 -0400 | From | Jörn Engel <> | Subject | Re: [PATCH] softirq: weaken warning in local_bh_enable_ip() |
| |
On Wed, 19 June 2013 12:27:37 -1000, Linus Torvalds wrote: > > No the warning is correct, the SCSI target code needs to be fixed. You > cannot call spin_unlock_bh with interrupts disabled.
That sounds like something coverity could be taught with reasonable effort - if someone from them is listening. Not sure if sparse has enough context to do the same.
Just to play thick and make things ultra-clear, you say the following pattern is never legal, correct?
spin_lock_irq(save) ... spin_lock_bh ... spin_unlock_bh ... spin_unlock_irq(restore)
> So fix the code, don't weaken the warning.
Will do.
Jörn
-- The only real mistake is the one from which we learn nothing. -- John Powell -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |