1*63241Sbostic# Given a vnode, follow its mount pointers 2*63241Sbosticdefine vchain 3*63241Sbostic 4*63241Sbostic set $num = 0 5*63241Sbostic 6*63241Sbostic set $vp=(struct vnode *)$arg0 7*63241Sbostic while ($vp) 8*63241Sbostic printf "vp: 0x%x freef: 0x%x usecount: %d flags: 0x%x\n", $vp, $vp->v_freef, $vp->v_usecount, $vp->v_flag 9*63241Sbostic set $num++ 10*63241Sbostic set $vp = $vp->v_mountf 11*63241Sbostic end 12*63241Sbostic printf "Number of vnodes: %d\n", $num 13*63241Sbosticend 14*63241Sbostic 15*63241Sbosticdefine vprint 16*63241Sbostic set $vp=(struct vnode *)$arg0 17*63241Sbostic set $ip=(struct inode *)$vp->v_data 18*63241Sbosticend 19*63241Sbostic 20*63241Sbosticdefine vall 21*63241Sbostic set $mp=rootfs 22*63241Sbostic while ($mp) 23*63241Sbostic vchain $mp->mnt_mounth 24*63241Sbostic set $mp=$mp->mnt_next 25*63241Sbostic end 26*63241Sbosticend 27