<div dir="ltr"><div>Hello David,<br><br>Here is the old discussion carried out on this.<br><br><a href="http://linux-kernel.2935.n7.nabble.com/Is-spin-is-locked-safe-to-use-with-BUG-ON-WARN-ON-td654800.html#a921802">http://linux-kernel.2935.n7.nabble.com/Is-spin-is-locked-safe-to-use-with-BUG-ON-WARN-ON-td654800.html#a921802</a><br>
<br></div>Regards<br>Sanjeev Sharma<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Aug 11, 2014 at 5:31 PM, sanjeev sharma <span dir="ltr"><<a href="mailto:sanjeevsharmaengg@gmail.com" target="_blank">sanjeevsharmaengg@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Hello David,<br><br></div><span style="font-size:11pt;font-family:"Calibri","sans-serif"">Do you see any problem in </span>replacing with assert_spin_locked() and here is old discusion around the<br>
<br></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Aug 11, 2014 at 5:15 PM, David Rientjes <span dir="ltr"><<a href="mailto:rientjes@google.com" target="_blank">rientjes@google.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>On Sun, 10 Aug 2014, Guenter Roeck wrote:<br>
<br>
> spin_is_locked() always returns false in uniprocessor configurations<br>
> and can therefore not be used with BUG_ON. Replace it with<br>
> assert_spin_locked(), which exists for that very purpose.<br>
><br>
<br>
</div>It may be helpful to assess whether any of these sites should be converted<br>
to lockdep_assert_held() so they have no cost when lockdep isn't enabled<br>
but still reveal problems when debugging.<br>
<div><div>--<br>
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in<br>
the body of a message to <a href="mailto:majordomo@vger.kernel.org" target="_blank">majordomo@vger.kernel.org</a><br>
More majordomo info at <a href="http://vger.kernel.org/majordomo-info.html" target="_blank">http://vger.kernel.org/majordomo-info.html</a><br>
Please read the FAQ at <a href="http://www.tux.org/lkml/" target="_blank">http://www.tux.org/lkml/</a><br>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>