[PATCH v3 03/57] scsi: sg: Prepare for enabling lock context analysis
Bart Van Assche <[email protected]> Thu, 30 Jul 2026 15:44:46 -0700
| Newsgroups | org.kernel.vger.linux-scsi |
|---|---|
| Message-ID | <854b4d05787854fb71e3d9387bfe5293a38409be.1785451174.git.bvanassche@acm.org> |
Annotate open_wait() with __must_hold() since it unlocks and locks a mutex. Signed-off-by: Bart Van Assche <[email protected]> --- drivers/scsi/sg.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/scsi/sg.c b/drivers/scsi/sg.c index 74cd4e8a61c2..dd3ca717ed13 100644 --- a/drivers/scsi/sg.c +++ b/drivers/scsi/sg.c @@ -245,6 +245,7 @@ static int sg_allow_access(struct file *filp, unsigned char *cmd) static int open_wait(Sg_device *sdp, int flags) + __must_hold(&sdp->open_rel_lock) { int retval = 0;