Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys Regen.
details: https://anonhg.NetBSD.org/src/rev/b67ca14ca3d6
branches: trunk
changeset: 365916:b67ca14ca3d6
user: hannken <hannken%NetBSD.org@localhost>
date: Tue May 03 08:35:11 2022 +0000
description:
Regen.
diffstat:
sys/kern/vnode_if.c | 86 ++++++++++++++++++++++++++++++--
sys/rump/include/rump/rumpvnode_if.h | 6 +-
sys/rump/librump/rumpvfs/rumpvnode_if.c | 8 +-
sys/sys/vnode_if.h | 6 +-
4 files changed, 90 insertions(+), 16 deletions(-)
diffs (truncated from 466 to 300 lines):
diff -r e6982eb79acc -r b67ca14ca3d6 sys/kern/vnode_if.c
--- a/sys/kern/vnode_if.c Tue May 03 08:33:59 2022 +0000
+++ b/sys/kern/vnode_if.c Tue May 03 08:35:11 2022 +0000
@@ -1,13 +1,13 @@
-/* $NetBSD: vnode_if.c,v 1.115 2021/10/20 03:13:14 thorpej Exp $ */
+/* $NetBSD: vnode_if.c,v 1.116 2022/05/03 08:35:11 hannken Exp $ */
/*
* Warning: DO NOT EDIT! This file is automatically generated!
* (Modifications made here may easily be lost!)
*
* Created from the file:
- * NetBSD: vnode_if.src,v 1.83 2021/10/20 03:08:18 thorpej Exp
+ * NetBSD: vnode_if.src,v 1.84 2022/05/03 08:33:59 hannken Exp
* by the script:
- * NetBSD: vnode_if.sh,v 1.72 2021/10/20 03:08:18 thorpej Exp
+ * NetBSD: vnode_if.sh,v 1.74 2022/05/03 08:33:59 hannken Exp
*/
/*
@@ -40,7 +40,11 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vnode_if.c,v 1.115 2021/10/20 03:13:14 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vnode_if.c,v 1.116 2022/05/03 08:35:11 hannken Exp $");
+
+#ifdef _KERNEL_OPT
+#include "opt_vnode_lockdebug.h"
+#endif /* _KERNEL_OPT */
#include <sys/param.h>
#include <sys/mount.h>
@@ -296,6 +300,33 @@
}
}
+static inline void
+assert_vop_unlocked(vnode_t *vp, const char *str)
+{
+
+ if (VOP_ISLOCKED(vp) == LK_EXCLUSIVE)
+ panic("%s: %p %d/%d is locked but should not be",
+ str, vp, vp->v_tag, vp->v_type);
+}
+
+static inline void
+assert_vop_locked(vnode_t *vp, const char *str)
+{
+
+ if (VOP_ISLOCKED(vp) == LK_NONE)
+ panic("%s: %p %d/%d is not locked but should be",
+ str, vp, vp->v_tag, vp->v_type);
+}
+
+static inline void
+assert_vop_elocked(vnode_t *vp, const char *str)
+{
+
+ if (VOP_ISLOCKED(vp) != LK_EXCLUSIVE)
+ panic("%s: %p %d/%d is not exclusive locked but should be",
+ str, vp, vp->v_tag, vp->v_type);
+}
+
const struct vnodeop_desc vop_default_desc = {
0,
"default",
@@ -399,6 +430,7 @@
a.a_dvp = dvp;
a.a_vpp = vpp;
a.a_cnp = cnp;
+ assert_vop_locked(dvp, "vop_lookup: dvp");
error = vop_pre(dvp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -440,6 +472,7 @@
a.a_vpp = vpp;
a.a_cnp = cnp;
a.a_vap = vap;
+ assert_vop_elocked(dvp, "vop_create: dvp");
error = vop_pre(dvp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -482,6 +515,7 @@
a.a_vpp = vpp;
a.a_cnp = cnp;
a.a_vap = vap;
+ assert_vop_elocked(dvp, "vop_mknod: dvp");
error = vop_pre(dvp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -522,6 +556,7 @@
a.a_vp = vp;
a.a_mode = mode;
a.a_cred = cred;
+ assert_vop_locked(vp, "vop_open: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -557,6 +592,7 @@
a.a_vp = vp;
a.a_fflag = fflag;
a.a_cred = cred;
+ assert_vop_locked(vp, "vop_close: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -592,6 +628,7 @@
a.a_vp = vp;
a.a_accmode = accmode;
a.a_cred = cred;
+ assert_vop_locked(vp, "vop_access: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -626,6 +663,7 @@
a.a_vp = vp;
a.a_accmode = accmode;
a.a_cred = cred;
+ assert_vop_locked(vp, "vop_accessx: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -660,6 +698,7 @@
a.a_vp = vp;
a.a_vap = vap;
a.a_cred = cred;
+ assert_vop_locked(vp, "vop_getattr: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -694,6 +733,7 @@
a.a_vp = vp;
a.a_vap = vap;
a.a_cred = cred;
+ assert_vop_elocked(vp, "vop_setattr: vp");
vop_setattr_pre(&a);
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
@@ -732,6 +772,7 @@
a.a_uio = uio;
a.a_ioflag = ioflag;
a.a_cred = cred;
+ assert_vop_locked(vp, "vop_read: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -769,6 +810,7 @@
a.a_uio = uio;
a.a_ioflag = ioflag;
a.a_cred = cred;
+ assert_vop_locked(vp, "vop_write: vp");
vop_write_pre(&a);
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
@@ -805,6 +847,7 @@
a.a_vp = vp;
a.a_pos = pos;
a.a_len = len;
+ assert_vop_locked(vp, "vop_fallocate: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -839,6 +882,7 @@
a.a_vp = vp;
a.a_pos = pos;
a.a_len = len;
+ assert_vop_locked(vp, "vop_fdiscard: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -877,6 +921,7 @@
a.a_data = data;
a.a_fflag = fflag;
a.a_cred = cred;
+ assert_vop_unlocked(vp, "vop_ioctl: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -915,6 +960,7 @@
a.a_data = data;
a.a_fflag = fflag;
a.a_cred = cred;
+ assert_vop_unlocked(vp, "vop_fcntl: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -947,6 +993,7 @@
a.a_desc = VDESC(vop_poll);
a.a_vp = vp;
a.a_events = events;
+ assert_vop_unlocked(vp, "vop_poll: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_YES);
if (error)
return error;
@@ -979,6 +1026,7 @@
a.a_desc = VDESC(vop_kqfilter);
a.a_vp = vp;
a.a_kn = kn;
+ assert_vop_unlocked(vp, "vop_kqfilter: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_YES);
if (error)
return error;
@@ -1011,6 +1059,7 @@
a.a_desc = VDESC(vop_revoke);
a.a_vp = vp;
a.a_flags = flags;
+ assert_vop_unlocked(vp, "vop_revoke: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -1083,6 +1132,7 @@
a.a_flags = flags;
a.a_offlo = offlo;
a.a_offhi = offhi;
+ assert_vop_locked(vp, "vop_fsync: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -1154,6 +1204,8 @@
a.a_dvp = dvp;
a.a_vp = vp;
a.a_cnp = cnp;
+ assert_vop_elocked(dvp, "vop_remove: dvp");
+ assert_vop_locked(vp, "vop_remove: vp");
vop_remove_pre(&a);
error = vop_pre(dvp, &mp, &mpsafe, FST_NO);
if (error)
@@ -1191,6 +1243,8 @@
a.a_dvp = dvp;
a.a_vp = vp;
a.a_cnp = cnp;
+ assert_vop_elocked(dvp, "vop_link: dvp");
+ assert_vop_unlocked(vp, "vop_link: vp");
error = vop_pre(dvp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -1235,6 +1289,7 @@
a.a_tdvp = tdvp;
a.a_tvp = tvp;
a.a_tcnp = tcnp;
+ assert_vop_locked(tdvp, "vop_rename: tdvp");
error = vop_pre(fdvp, &mp, &mpsafe, FST_YES);
if (error)
return error;
@@ -1271,6 +1326,7 @@
a.a_vpp = vpp;
a.a_cnp = cnp;
a.a_vap = vap;
+ assert_vop_elocked(dvp, "vop_mkdir: dvp");
error = vop_pre(dvp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -1312,6 +1368,8 @@
a.a_dvp = dvp;
a.a_vp = vp;
a.a_cnp = cnp;
+ assert_vop_elocked(dvp, "vop_rmdir: dvp");
+ assert_vop_elocked(vp, "vop_rmdir: vp");
vop_rmdir_pre(&a);
error = vop_pre(dvp, &mp, &mpsafe, FST_NO);
if (error)
@@ -1352,6 +1410,7 @@
a.a_cnp = cnp;
a.a_vap = vap;
a.a_target = target;
+ assert_vop_elocked(dvp, "vop_symlink: dvp");
error = vop_pre(dvp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -1398,6 +1457,7 @@
a.a_eofflag = eofflag;
a.a_cookies = cookies;
a.a_ncookies = ncookies;
+ assert_vop_locked(vp, "vop_readdir: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -1432,6 +1492,7 @@
a.a_vp = vp;
a.a_uio = uio;
a.a_cred = cred;
+ assert_vop_locked(vp, "vop_readlink: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -1496,6 +1557,7 @@
a.a_desc = VDESC(vop_inactive);
a.a_vp = vp;
a.a_recycle = recycle;
+ assert_vop_elocked(vp, "vop_inactive: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
if (error)
return error;
@@ -1526,6 +1588,7 @@
struct mount *mp;
a.a_desc = VDESC(vop_reclaim);
a.a_vp = vp;
+ assert_vop_elocked(vp, "vop_reclaim: vp");
error = vop_pre(vp, &mp, &mpsafe, FST_NO);
Home |
Main Index |
Thread Index |
Old Index