git: 13a21c0c0e3d - main - VOP_WRITE_POST(): correct condition for knote activation
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 07 Jul 2025 13:45:12 UTC
The branch main has been updated by kib:
URL: https://cgit.FreeBSD.org/src/commit/?id=13a21c0c0e3db6e2c1a317031c7d1bf4651bec3d
commit 13a21c0c0e3db6e2c1a317031c7d1bf4651bec3d
Author: Konstantin Belousov <kib@FreeBSD.org>
AuthorDate: 2025-07-07 12:51:24 +0000
Commit: Konstantin Belousov <kib@FreeBSD.org>
CommitDate: 2025-07-07 13:44:21 +0000
VOP_WRITE_POST(): correct condition for knote activation
Fixes: bc4430dc203ed7b6765fb5df041bf545c50f859b
Reported by: dhw, Oleg Nauman <oleg.nauman@gmail.com>
Sponsored by: The FreeBSD Foundation
---
sys/sys/vnode.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sys/sys/vnode.h b/sys/sys/vnode.h
index 3ed469bdce6d..2c6947103c94 100644
--- a/sys/sys/vnode.h
+++ b/sys/sys/vnode.h
@@ -1032,7 +1032,7 @@ void vop_rename_fail(struct vop_rename_args *ap);
#define VOP_WRITE_POST(ap, ret) \
noffset = (ap)->a_uio->uio_offset; \
if (noffset > ooffset) { \
- if (VN_KNLIST_EMPTY((ap)->a_vp)) { \
+ if (!VN_KNLIST_EMPTY((ap)->a_vp)) { \
VFS_KNOTE_LOCKED((ap)->a_vp, NOTE_WRITE | \
(noffset > osize ? NOTE_EXTEND : 0)); \
} \