summaryrefslogtreecommitdiffstats
path: root/sys/tools
diff options
context:
space:
mode:
authortruckman <truckman@FreeBSD.org>2003-06-22 21:20:06 +0000
committertruckman <truckman@FreeBSD.org>2003-06-22 21:20:06 +0000
commit01da790999f6e45aef0a3c53cbf1b030acca4371 (patch)
tree60308b04e5c9bcb6b54a9cc35336b51154350b1c /sys/tools
parent8d7672ad2e3e70b497e6d065abafeed2663c7fd2 (diff)
downloadFreeBSD-src-01da790999f6e45aef0a3c53cbf1b030acca4371.zip
FreeBSD-src-01da790999f6e45aef0a3c53cbf1b030acca4371.tar.gz
Don't check the state of the vnode interlock if the specification says
that the lock should not be checked. Skip the lock assertion checks for *vpp or any other pointer to a vnode pointer if vpp (or equivalent) is NULL.
Diffstat (limited to 'sys/tools')
-rw-r--r--sys/tools/vnode_if.awk8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/tools/vnode_if.awk b/sys/tools/vnode_if.awk
index 443a321..5cbb637 100644
--- a/sys/tools/vnode_if.awk
+++ b/sys/tools/vnode_if.awk
@@ -67,7 +67,10 @@ function add_debug_code(name, arg, pos)
{
if (arg == "vpp")
arg = "*vpp";
- if (lockdata[name, arg, pos]) {
+ if (lockdata[name, arg, pos] && (lockdata[name, arg, pos] != "-")) {
+ if (arg ~ /^\*/) {
+ printh("\tif ("substr(arg, 2)" != NULL) {");
+ }
printh("\tASSERT_VI_UNLOCKED("arg", \""uname"\");");
# Add assertions for locking
if (lockdata[name, arg, pos] == "L")
@@ -77,6 +80,9 @@ function add_debug_code(name, arg, pos)
else if (0) {
# XXX More checks!
}
+ if (arg ~ /^\*/) {
+ printh("\t}");
+ }
}
}
OpenPOWER on IntegriCloud