mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-03-22 08:51:30 +03:00
FreeBSD: Remove references to DEBUG_VFS_LOCKS
This option is removed upstream in favour of plain INVARIANTS. VNASSERT is always defined so I see no reason to use it conditionally. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Signed-off-by: Mark Johnston <markj@FreeBSD.org> Closes #18136
This commit is contained in:
parent
8605bdfdda
commit
54b141fab5
@ -62,11 +62,6 @@ CFLAGS+= -DZFS_DEBUG -g
|
|||||||
CFLAGS += -DNDEBUG
|
CFLAGS += -DNDEBUG
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_VFS_DEBUG) && ${WITH_VFS_DEBUG} == "true"
|
|
||||||
# kernel must also be built with this option for this to work
|
|
||||||
CFLAGS+= -DDEBUG_VFS_LOCKS
|
|
||||||
.endif
|
|
||||||
|
|
||||||
.if defined(WITH_GCOV) && ${WITH_GCOV} == "true"
|
.if defined(WITH_GCOV) && ${WITH_GCOV} == "true"
|
||||||
CFLAGS+= -fprofile-arcs -ftest-coverage
|
CFLAGS+= -fprofile-arcs -ftest-coverage
|
||||||
.endif
|
.endif
|
||||||
|
|||||||
@ -102,14 +102,6 @@
|
|||||||
|
|
||||||
VFS_SMR_DECLARE;
|
VFS_SMR_DECLARE;
|
||||||
|
|
||||||
#ifdef DEBUG_VFS_LOCKS
|
|
||||||
#define VNCHECKREF(vp) \
|
|
||||||
VNASSERT((vp)->v_holdcnt > 0 && (vp)->v_usecount > 0, vp, \
|
|
||||||
("%s: wrong ref counts", __func__));
|
|
||||||
#else
|
|
||||||
#define VNCHECKREF(vp)
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if __FreeBSD_version >= 1400045
|
#if __FreeBSD_version >= 1400045
|
||||||
typedef uint64_t cookie_t;
|
typedef uint64_t cookie_t;
|
||||||
#else
|
#else
|
||||||
@ -1060,9 +1052,6 @@ zfs_create(znode_t *dzp, const char *name, vattr_t *vap, int excl, int mode,
|
|||||||
zfs_acl_ids_t acl_ids;
|
zfs_acl_ids_t acl_ids;
|
||||||
boolean_t fuid_dirtied;
|
boolean_t fuid_dirtied;
|
||||||
uint64_t txtype;
|
uint64_t txtype;
|
||||||
#ifdef DEBUG_VFS_LOCKS
|
|
||||||
vnode_t *dvp = ZTOV(dzp);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (is_nametoolong(zfsvfs, name))
|
if (is_nametoolong(zfsvfs, name))
|
||||||
return (SET_ERROR(ENAMETOOLONG));
|
return (SET_ERROR(ENAMETOOLONG));
|
||||||
@ -1192,7 +1181,8 @@ zfs_create(znode_t *dzp, const char *name, vattr_t *vap, int excl, int mode,
|
|||||||
getnewvnode_drop_reserve();
|
getnewvnode_drop_reserve();
|
||||||
|
|
||||||
out:
|
out:
|
||||||
VNCHECKREF(dvp);
|
VNASSERT(ZTOV(dzp)->v_holdcnt > 0 && ZTOV(dzp)->v_usecount > 0,
|
||||||
|
ZTOV(dzp), ("%s: wrong ref counts", __func__));
|
||||||
if (error == 0) {
|
if (error == 0) {
|
||||||
*zpp = zp;
|
*zpp = zp;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user