From: Derrick Brashear Date: Fri, 12 Feb 2010 21:16:56 +0000 (-0500) Subject: darwin vn hold dead code removal X-Git-Tag: openafs-devel-1_5_73~186 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=029b470e673ecc2d4448aa6a46fd10b6d8de4e7e;p=packages%2Fo%2Fopenafs.git darwin vn hold dead code removal pull out the unused code which tries to cope with a failed vnode hold. if we become able to do so, we can do so later Change-Id: Ib53f469feaba4c6ec6b15730315e87e75f8f9eb8 Reviewed-on: http://gerrit.openafs.org/1301 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear --- diff --git a/src/afs/DARWIN/osi_vnodeops.c b/src/afs/DARWIN/osi_vnodeops.c index 88afb9168..911ac2900 100644 --- a/src/afs/DARWIN/osi_vnodeops.c +++ b/src/afs/DARWIN/osi_vnodeops.c @@ -248,21 +248,13 @@ darwin_vn_hold(struct vnode *vp) if (vnode_get(vp)) { /* being terminated. kernel won't give us a ref. Now what? our callers don't expect us to fail */ -#if 1 - panic("vn_hold on terminating vnode"); -#else if (haveGlock) AFS_GLOCK(); return; -#endif } if (vnode_ref(vp)) { -#if 1 - panic("vn_hold on terminating vnode"); -#else vnode_put(vp); if (haveGlock) AFS_GLOCK(); return; -#endif } vnode_put(vp); #else @@ -1030,9 +1022,8 @@ afs_vop_pageout(ap) auio.uio_resid = aiov.iov_len = iosize; aiov.iov_base = (caddr_t) ioaddr; #endif -#if 1 /* USV [ */ { - /* + /* USV? * check for partial page and clear the * contents past end of the file before * releasing it in the VM page cache @@ -1043,7 +1034,6 @@ afs_vop_pageout(ap) memset((caddr_t) (ioaddr + pl_offset + io), 0, size - io); } } -#endif /* ] USV */ AFS_GLOCK(); osi_FlushPages(tvc, vop_cred); /* hold bozon lock, but not basic vnode lock */