On 10/05/2016 03:49 PM, Ming Lei wrote:
We can use srcu read lock for BLOCKING and rcu read lock for non-BLOCKING,
by putting *_read_lock() and *_read_unlock() into two wrappers, which
should minimize the cost of srcu read lock & unlock and the code is still easy
to read & verify.

Hello Ming,

The lock checking algorithms in the sparse and smatch static checkers are unable to deal with code of the type "if (condition) (un)lock()". So unless someone has a better proposal my preference is to use the approach from the patch at the start of this e-mail thread.

Thanks,

Bart.

--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to