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

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

Diff for /src/sys/fs/msdosfs/msdosfs_vfsops.c between version 1.50.4.2 and 1.50.4.3

version 1.50.4.2, 2008/01/09 01:55:44 version 1.50.4.3, 2008/03/23 02:04:56
Line 1 
Line 1 
 /*      $NetBSD$        */  /*      msdosfs_vfsops.c,v 1.50.4.2 2008/01/09 01:55:44 matt Exp        */
   
 /*-  /*-
  * Copyright (C) 1994, 1995, 1997 Wolfgang Solfrank.   * Copyright (C) 1994, 1995, 1997 Wolfgang Solfrank.
Line 48 
Line 48 
  */   */
   
 #include <sys/cdefs.h>  #include <sys/cdefs.h>
 __KERNEL_RCSID(0, "$NetBSD$");  __KERNEL_RCSID(0, "msdosfs_vfsops.c,v 1.50.4.2 2008/01/09 01:55:44 matt Exp");
   
 #if defined(_KERNEL_OPT)  #if defined(_KERNEL_OPT)
 #include "opt_quota.h"  #include "opt_quota.h"
Line 62  __KERNEL_RCSID(0, "$NetBSD$");
Line 62  __KERNEL_RCSID(0, "$NetBSD$");
 #include <sys/proc.h>  #include <sys/proc.h>
 #include <sys/kernel.h>  #include <sys/kernel.h>
 #include <sys/vnode.h>  #include <sys/vnode.h>
   #include <miscfs/genfs/genfs.h>
 #include <miscfs/specfs/specdev.h> /* XXX */    /* defines v_rdev */  #include <miscfs/specfs/specdev.h> /* XXX */    /* defines v_rdev */
 #include <sys/mount.h>  #include <sys/mount.h>
 #include <sys/buf.h>  #include <sys/buf.h>
Line 132  struct vfsops msdosfs_vfsops = {
Line 133  struct vfsops msdosfs_vfsops = {
         (int (*)(struct mount *, struct vnode *, struct timespec *)) eopnotsupp,          (int (*)(struct mount *, struct vnode *, struct timespec *)) eopnotsupp,
         vfs_stdextattrctl,          vfs_stdextattrctl,
         (void *)eopnotsupp,             /* vfs_suspendctl */          (void *)eopnotsupp,             /* vfs_suspendctl */
           genfs_renamelock_enter,
           genfs_renamelock_exit,
         msdosfs_vnodeopv_descs,          msdosfs_vnodeopv_descs,
         0,          0,
         { NULL, NULL },          { NULL, NULL },
Line 209  msdosfs_mountroot()
Line 212  msdosfs_mountroot()
         args.dirmask = 0777;          args.dirmask = 0777;
   
         if ((error = msdosfs_mountfs(rootvp, mp, l, &args)) != 0) {          if ((error = msdosfs_mountfs(rootvp, mp, l, &args)) != 0) {
                 mp->mnt_op->vfs_refcount--;                  vfs_unbusy(mp, false);
                 vfs_unbusy(mp);  
                 vfs_destroy(mp);                  vfs_destroy(mp);
                 return (error);                  return (error);
         }          }
   
         if ((error = update_mp(mp, &args)) != 0) {          if ((error = update_mp(mp, &args)) != 0) {
                 (void)msdosfs_unmount(mp, 0);                  (void)msdosfs_unmount(mp, 0);
                 vfs_unbusy(mp);                  vfs_unbusy(mp, false);
                 vfs_destroy(mp);                  vfs_destroy(mp);
                 vrele(rootvp);                  vrele(rootvp);
                 return (error);                  return (error);
Line 227  msdosfs_mountroot()
Line 229  msdosfs_mountroot()
         CIRCLEQ_INSERT_TAIL(&mountlist, mp, mnt_list);          CIRCLEQ_INSERT_TAIL(&mountlist, mp, mnt_list);
         mutex_exit(&mountlist_lock);          mutex_exit(&mountlist_lock);
         (void)msdosfs_statvfs(mp, &mp->mnt_stat);          (void)msdosfs_statvfs(mp, &mp->mnt_stat);
         vfs_unbusy(mp);          vfs_unbusy(mp, false);
         return (0);          return (0);
 }  }
   
Line 370  msdosfs_mount(mp, path, data, data_len)
Line 372  msdosfs_mount(mp, path, data, data_len)
         if ((mp->mnt_flag & MNT_UPDATE) == 0) {          if ((mp->mnt_flag & MNT_UPDATE) == 0) {
                 int xflags;                  int xflags;
   
                 /*  
                  * Disallow multiple mounts of the same device.  
                  * Disallow mounting of a device that is currently in use  
                  * (except for root, which might share swap device for  
                  * miniroot).  
                  */  
                 error = vfs_mountedon(devvp);  
                 if (error) {  
                         DPRINTF(("vfs_mountedon %d\n", error));  
                         goto fail;  
                 }  
                 if (vcount(devvp) > 1 && devvp != rootvp) {  
                         DPRINTF(("vcount %d\n", error));  
                         error = EBUSY;  
                         goto fail;  
                 }  
                 if (mp->mnt_flag & MNT_RDONLY)                  if (mp->mnt_flag & MNT_RDONLY)
                         xflags = FREAD;                          xflags = FREAD;
                 else                  else

Legend:
Removed from v.1.50.4.2  
changed lines
  Added in v.1.50.4.3

CVSweb <webmaster@jp.NetBSD.org>