[BACK]Return to tmpfs_subr.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / fs / tmpfs

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/fs/tmpfs/tmpfs_subr.c between version 1.43 and 1.44

version 1.43, 2008/01/02 11:48:46 version 1.44, 2008/01/24 17:32:54
Line 337  int
Line 337  int
 tmpfs_alloc_vp(struct mount *mp, struct tmpfs_node *node, struct vnode **vpp)  tmpfs_alloc_vp(struct mount *mp, struct tmpfs_node *node, struct vnode **vpp)
 {  {
         int error;          int error;
         struct vnode *nvp;  
         struct vnode *vp;          struct vnode *vp;
   
         /* If there is already a vnode, then lock it. */          /* If there is already a vnode, then lock it. */
Line 379  tmpfs_alloc_vp(struct mount *mp, struct 
Line 378  tmpfs_alloc_vp(struct mount *mp, struct 
                 /* FALLTHROUGH */                  /* FALLTHROUGH */
         case VCHR:          case VCHR:
                 vp->v_op = tmpfs_specop_p;                  vp->v_op = tmpfs_specop_p;
                 nvp = checkalias(vp, node->tn_spec.tn_dev.tn_rdev, mp);                  spec_node_init(vp, node->tn_spec.tn_dev.tn_rdev);
                 if (nvp != NULL) {  
                         /* Discard unneeded vnode, but save its inode. */  
                         nvp->v_data = node;  
   
                         /* XXX spec_vnodeops has no locking, so we have to  
                          * do it explicitly. */  
                         vp->v_vflag &= ~VV_LOCKSWORK;  
                         VOP_UNLOCK(vp, 0);  
                         vp->v_op = spec_vnodeop_p;  
                         vgone(vp);  
   
                         /* Reinitialize aliased node. */  
                         vp = nvp;  
                         error = vn_lock(vp, LK_EXCLUSIVE | LK_RETRY);  
                         if (error != 0) {  
                                 mutex_exit(&node->tn_vlock);  
                                 return error;  
                         }  
                 }  
                 break;                  break;
   
         case VDIR:          case VDIR:

Legend:
Removed from v.1.43  
changed lines
  Added in v.1.44

CVSweb <webmaster@jp.NetBSD.org>