[Devel] [PATCH hci-8.1 2/5] drivers/md/push_backup: clear pb->alive under pb->lock
Andrey Zhadchenko
andrey.zhadchenko at virtuozzo.com
Tue Nov 3 02:38:46 MSK 2026
Although it is harmless in practice, it may potentially trigger
KCSAN. Besides, most other users handle this only under the pb->lock.
https://virtuozzo.atlassian.net/browse/VSTOR-152912
Signed-off-by: Andrey Zhadchenko <andrey.zhadchenko at virtuozzo.com>
---
drivers/md/dm-push-backup.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/md/dm-push-backup.c b/drivers/md/dm-push-backup.c
index 9a6252f2b21e2..1ae4ccc208ffa 100644
--- a/drivers/md/dm-push-backup.c
+++ b/drivers/md/dm-push-backup.c
@@ -581,7 +581,9 @@ static int pb_message(struct dm_target *ti, unsigned int argc, char **argv,
if (!pb->map)
return -EBADF;
+ spin_lock_irq(&pb->lock);
pb->alive = false;
+ spin_unlock_irq(&pb->lock);
wake_up_interruptible(&pb->waitq); /* pb->alive = false */
}
--
2.43.5
More information about the Devel
mailing list