Re: [PATCH 12/15] nvme: add Clang context annotations for nvme_queue::cq_poll_lock

From: Nilay Shroff

Date: Thu Jun 11 2026 - 00:59:04 EST


On 6/10/26 10:16 PM, Keith Busch wrote:
On Wed, Jun 10, 2026 at 07:57:32PM +0530, Nilay Shroff wrote:
Fix the warning by acquiring nvme_queue::cq_poll_lock before invoking
nvme_cqe_pending() in nvme_poll().

The check outside the lock was done on purpose, though.

Oh okay, I didn't know that. In that case we could skip
the locking around nvme_cqe_pending() and silence the
compiler warning using context_unsafe().

Thanks,
--Nilay