Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys Change all vfsops to use C99 designated initializers.



details:   https://anonhg.NetBSD.org/src/rev/052966c6aca5
branches:  trunk
changeset: 328017:052966c6aca5
user:      hannken <hannken%NetBSD.org@localhost>
date:      Sun Mar 23 15:21:15 2014 +0000

description:
Change all vfsops to use C99 designated initializers.

No functional changes intended.

diffstat:

 sys/coda/coda_vfsops.c              |  52 +++++++++++++++++------------------
 sys/fs/adosfs/advfsops.c            |  50 ++++++++++++++++------------------
 sys/fs/cd9660/cd9660_vfsops.c       |  52 +++++++++++++++++------------------
 sys/fs/filecorefs/filecore_vfsops.c |  51 ++++++++++++++++------------------
 sys/fs/hfs/hfs_vfsops.c             |  50 ++++++++++++++++------------------
 sys/fs/msdosfs/msdosfs_vfsops.c     |  52 +++++++++++++++++------------------
 sys/fs/nilfs/nilfs_vfsops.c         |  52 +++++++++++++++++------------------
 sys/fs/ntfs/ntfs_vfsops.c           |  52 +++++++++++++++++------------------
 sys/fs/ptyfs/ptyfs_vfsops.c         |  51 ++++++++++++++++------------------
 sys/fs/puffs/puffs_vfsops.c         |  50 ++++++++++++++++------------------
 sys/fs/smbfs/smbfs_vfsops.c         |  52 +++++++++++++++++------------------
 sys/fs/sysvbfs/sysvbfs.c            |  52 ++++++++++++++++-------------------
 sys/fs/tmpfs/tmpfs_vfsops.c         |  50 ++++++++++++++++------------------
 sys/fs/udf/udf_vfsops.c             |  52 +++++++++++++++++------------------
 sys/fs/union/union_vfsops.c         |  51 ++++++++++++++++------------------
 sys/fs/unionfs/unionfs_vfsops.c     |  46 ++++++++++++++-----------------
 sys/fs/v7fs/v7fs_extern.c           |  53 +++++++++++++++++-------------------
 sys/miscfs/deadfs/dead_vfsops.c     |  52 +++++++++++++++++------------------
 sys/miscfs/fdesc/fdesc_vfsops.c     |  50 ++++++++++++++++------------------
 sys/miscfs/kernfs/kernfs_vfsops.c   |  51 ++++++++++++++++------------------
 sys/miscfs/nullfs/null_vfsops.c     |  50 ++++++++++++++++------------------
 sys/miscfs/overlay/overlay_vfsops.c |  50 ++++++++++++++++------------------
 sys/miscfs/procfs/procfs_vfsops.c   |  51 ++++++++++++++++------------------
 sys/miscfs/umapfs/umap_vfsops.c     |  50 ++++++++++++++++------------------
 sys/nfs/nfs_vfsops.c                |  51 ++++++++++++++++------------------
 sys/ufs/chfs/chfs_vfsops.c          |  49 ++++++++++++++++------------------
 sys/ufs/ext2fs/ext2fs_vfsops.c      |  52 +++++++++++++++++------------------
 sys/ufs/ffs/ffs_vfsops.c            |  52 +++++++++++++++++------------------
 sys/ufs/lfs/lfs_vfsops.c            |  52 +++++++++++++++++------------------
 sys/ufs/mfs/mfs_vfsops.c            |  51 ++++++++++++++++------------------
 30 files changed, 720 insertions(+), 809 deletions(-)

diffs (truncated from 2139 to 300 lines):

diff -r e09852c7a84b -r 052966c6aca5 sys/coda/coda_vfsops.c
--- a/sys/coda/coda_vfsops.c    Sun Mar 23 14:44:55 2014 +0000
+++ b/sys/coda/coda_vfsops.c    Sun Mar 23 15:21:15 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: coda_vfsops.c,v 1.79 2014/02/25 18:30:08 pooka Exp $   */
+/*     $NetBSD: coda_vfsops.c,v 1.80 2014/03/23 15:21:15 hannken Exp $ */
 
 /*
  *
@@ -45,7 +45,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: coda_vfsops.c,v 1.79 2014/02/25 18:30:08 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: coda_vfsops.c,v 1.80 2014/03/23 15:21:15 hannken Exp $");
 
 #ifndef _KERNEL_OPT
 #define        NVCODA 4
@@ -101,31 +101,29 @@
 };
 
 struct vfsops coda_vfsops = {
-    MOUNT_CODA,
-    256,               /* This is the pathname, unlike every other fs */
-    coda_mount,
-    coda_start,
-    coda_unmount,
-    coda_root,
-    (void *)eopnotsupp,        /* vfs_quotactl */
-    coda_nb_statvfs,
-    coda_sync,
-    coda_vget,
-    (void *)eopnotsupp,        /* vfs_fhtovp */
-    (void *)eopnotsupp,        /* vfs_vptofh */
-    coda_init,
-    NULL,              /* vfs_reinit */
-    coda_done,
-    (int (*)(void)) eopnotsupp,
-    (int (*)(struct mount *, struct vnode *, struct timespec *)) eopnotsupp,
-    vfs_stdextattrctl,
-    (void *)eopnotsupp,        /* vfs_suspendctl */
-    genfs_renamelock_enter,
-    genfs_renamelock_exit,
-       (void *)eopnotsupp,
-    coda_vnodeopv_descs,
-    0,                 /* vfs_refcount */
-    { NULL, NULL },    /* vfs_list */
+       .vfs_name = MOUNT_CODA,
+       .vfs_min_mount_data = 256,
+                       /* This is the pathname, unlike every other fs */
+       .vfs_mount = coda_mount,
+       .vfs_start = coda_start,
+       .vfs_unmount = coda_unmount,
+       .vfs_root = coda_root,
+       .vfs_quotactl = (void *)eopnotsupp,
+       .vfs_statvfs = coda_nb_statvfs,
+       .vfs_sync = coda_sync,
+       .vfs_vget = coda_vget,
+       .vfs_fhtovp = (void *)eopnotsupp,
+       .vfs_vptofh = (void *)eopnotsupp,
+       .vfs_init = coda_init,
+       .vfs_done = coda_done,
+       .vfs_mountroot = (void *)eopnotsupp,
+       .vfs_snapshot = (void *)eopnotsupp,
+       .vfs_extattrctl = vfs_stdextattrctl,
+       .vfs_suspendctl = (void *)eopnotsupp,
+       .vfs_renamelock_enter = genfs_renamelock_enter,
+       .vfs_renamelock_exit = genfs_renamelock_exit,
+       .vfs_fsync = (void *)eopnotsupp,
+       .vfs_opv_descs = coda_vnodeopv_descs
 };
 
 static int
diff -r e09852c7a84b -r 052966c6aca5 sys/fs/adosfs/advfsops.c
--- a/sys/fs/adosfs/advfsops.c  Sun Mar 23 14:44:55 2014 +0000
+++ b/sys/fs/adosfs/advfsops.c  Sun Mar 23 15:21:15 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: advfsops.c,v 1.68 2014/02/25 18:30:10 pooka Exp $      */
+/*     $NetBSD: advfsops.c,v 1.69 2014/03/23 15:21:15 hannken Exp $    */
 
 /*
  * Copyright (c) 1994 Christian E. Hopps
@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: advfsops.c,v 1.68 2014/02/25 18:30:10 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: advfsops.c,v 1.69 2014/03/23 15:21:15 hannken Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_netbsd.h"
@@ -785,31 +785,27 @@
 };
 
 struct vfsops adosfs_vfsops = {
-       MOUNT_ADOSFS,
-       sizeof (struct adosfs_args),
-       adosfs_mount,
-       adosfs_start,
-       adosfs_unmount,
-       adosfs_root,
-       (void *)eopnotsupp,             /* vfs_quotactl */
-       adosfs_statvfs,
-       adosfs_sync,
-       adosfs_vget,
-       adosfs_fhtovp,
-       adosfs_vptofh,
-       adosfs_init,
-       NULL,
-       adosfs_done,
-       NULL,                           /* vfs_mountroot */
-       (int (*)(struct mount *, struct vnode *, struct timespec *)) eopnotsupp,
-       vfs_stdextattrctl,
-       (void *)eopnotsupp,             /* vfs_suspendctl */
-       genfs_renamelock_enter,
-       genfs_renamelock_exit,
-       (void *)eopnotsupp,
-       adosfs_vnodeopv_descs,
-       0,
-       { NULL, NULL },
+       .vfs_name = MOUNT_ADOSFS,
+       .vfs_min_mount_data = sizeof (struct adosfs_args),
+       .vfs_mount = adosfs_mount,
+       .vfs_start = adosfs_start,
+       .vfs_unmount = adosfs_unmount,
+       .vfs_root = adosfs_root,
+       .vfs_quotactl = (void *)eopnotsupp,
+       .vfs_statvfs = adosfs_statvfs,
+       .vfs_sync = adosfs_sync,
+       .vfs_vget = adosfs_vget,
+       .vfs_fhtovp = adosfs_fhtovp,
+       .vfs_vptofh = adosfs_vptofh,
+       .vfs_init = adosfs_init,
+       .vfs_done = adosfs_done,
+       .vfs_snapshot = (void *)eopnotsupp,
+       .vfs_extattrctl = vfs_stdextattrctl,
+       .vfs_suspendctl = (void *)eopnotsupp,
+       .vfs_renamelock_enter = genfs_renamelock_enter,
+       .vfs_renamelock_exit = genfs_renamelock_exit,
+       .vfs_fsync = (void *)eopnotsupp,
+       .vfs_opv_descs = adosfs_vnodeopv_descs
 };
 
 static int
diff -r e09852c7a84b -r 052966c6aca5 sys/fs/cd9660/cd9660_vfsops.c
--- a/sys/fs/cd9660/cd9660_vfsops.c     Sun Mar 23 14:44:55 2014 +0000
+++ b/sys/fs/cd9660/cd9660_vfsops.c     Sun Mar 23 15:21:15 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: cd9660_vfsops.c,v 1.81 2014/02/25 18:30:10 pooka Exp $ */
+/*     $NetBSD: cd9660_vfsops.c,v 1.82 2014/03/23 15:21:15 hannken Exp $       */
 
 /*-
  * Copyright (c) 1994
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cd9660_vfsops.c,v 1.81 2014/02/25 18:30:10 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cd9660_vfsops.c,v 1.82 2014/03/23 15:21:15 hannken Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_netbsd.h"
@@ -92,31 +92,29 @@
 };
 
 struct vfsops cd9660_vfsops = {
-       MOUNT_CD9660,
-       sizeof (struct iso_args),
-       cd9660_mount,
-       cd9660_start,
-       cd9660_unmount,
-       cd9660_root,
-       (void *)eopnotsupp,
-       cd9660_statvfs,
-       cd9660_sync,
-       cd9660_vget,
-       cd9660_fhtovp,
-       cd9660_vptofh,
-       cd9660_init,
-       cd9660_reinit,
-       cd9660_done,
-       cd9660_mountroot,
-       (int (*)(struct mount *, struct vnode *, struct timespec *)) eopnotsupp,
-       vfs_stdextattrctl,
-       (void *)eopnotsupp,             /* vfs_suspendctl */
-       genfs_renamelock_enter,
-       genfs_renamelock_exit,
-       (void *)eopnotsupp,
-       cd9660_vnodeopv_descs,
-       0,      /* refcount */
-       { NULL, NULL } /* list */
+       .vfs_name = MOUNT_CD9660,
+       .vfs_min_mount_data = sizeof (struct iso_args),
+       .vfs_mount = cd9660_mount,
+       .vfs_start = cd9660_start,
+       .vfs_unmount = cd9660_unmount,
+       .vfs_root = cd9660_root,
+       .vfs_quotactl = (void *)eopnotsupp,
+       .vfs_statvfs = cd9660_statvfs,
+       .vfs_sync = cd9660_sync,
+       .vfs_vget = cd9660_vget,
+       .vfs_fhtovp = cd9660_fhtovp,
+       .vfs_vptofh = cd9660_vptofh,
+       .vfs_init = cd9660_init,
+       .vfs_reinit = cd9660_reinit,
+       .vfs_done = cd9660_done,
+       .vfs_mountroot = cd9660_mountroot,
+       .vfs_snapshot = (void *)eopnotsupp,
+       .vfs_extattrctl = vfs_stdextattrctl,
+       .vfs_suspendctl = (void *)eopnotsupp,
+       .vfs_renamelock_enter = genfs_renamelock_enter,
+       .vfs_renamelock_exit = genfs_renamelock_exit,
+       .vfs_fsync = (void *)eopnotsupp,
+       .vfs_opv_descs = cd9660_vnodeopv_descs
 };
 
 static const struct genfs_ops cd9660_genfsops = {
diff -r e09852c7a84b -r 052966c6aca5 sys/fs/filecorefs/filecore_vfsops.c
--- a/sys/fs/filecorefs/filecore_vfsops.c       Sun Mar 23 14:44:55 2014 +0000
+++ b/sys/fs/filecorefs/filecore_vfsops.c       Sun Mar 23 15:21:15 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: filecore_vfsops.c,v 1.74 2014/02/25 18:30:10 pooka Exp $       */
+/*     $NetBSD: filecore_vfsops.c,v 1.75 2014/03/23 15:21:15 hannken Exp $     */
 
 /*-
  * Copyright (c) 1994 The Regents of the University of California.
@@ -66,7 +66,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: filecore_vfsops.c,v 1.74 2014/02/25 18:30:10 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: filecore_vfsops.c,v 1.75 2014/03/23 15:21:15 hannken Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_netbsd.h"
@@ -107,31 +107,28 @@
 };
 
 struct vfsops filecore_vfsops = {
-       MOUNT_FILECORE,
-       sizeof (struct filecore_args),
-       filecore_mount,
-       filecore_start,
-       filecore_unmount,
-       filecore_root,
-       (void *)eopnotsupp,             /* vfs_quotactl */
-       filecore_statvfs,
-       filecore_sync,
-       filecore_vget,
-       filecore_fhtovp,
-       filecore_vptofh,
-       filecore_init,
-       filecore_reinit,
-       filecore_done,
-       NULL,                           /* filecore_mountroot */
-       (int (*)(struct mount *, struct vnode *, struct timespec *)) eopnotsupp,
-       vfs_stdextattrctl,
-       (void *)eopnotsupp,             /* vfs_suspendctl */
-       genfs_renamelock_enter,
-       genfs_renamelock_exit,
-       (void *)eopnotsupp,
-       filecore_vnodeopv_descs,
-       0,
-       { NULL, NULL }
+       .vfs_name = MOUNT_FILECORE,
+       .vfs_min_mount_data = sizeof (struct filecore_args),
+       .vfs_mount = filecore_mount,
+       .vfs_start = filecore_start,
+       .vfs_unmount = filecore_unmount,
+       .vfs_root = filecore_root,
+       .vfs_quotactl = (void *)eopnotsupp,
+       .vfs_statvfs = filecore_statvfs,
+       .vfs_sync = filecore_sync,
+       .vfs_vget = filecore_vget,
+       .vfs_fhtovp = filecore_fhtovp,
+       .vfs_vptofh = filecore_vptofh,
+       .vfs_init = filecore_init,
+       .vfs_reinit = filecore_reinit,
+       .vfs_done = filecore_done,
+       .vfs_snapshot = (void *)eopnotsupp,
+       .vfs_extattrctl = vfs_stdextattrctl,
+       .vfs_suspendctl = (void *)eopnotsupp,
+       .vfs_renamelock_enter = genfs_renamelock_enter,
+       .vfs_renamelock_exit = genfs_renamelock_exit,
+       .vfs_fsync = (void *)eopnotsupp,
+       .vfs_opv_descs = filecore_vnodeopv_descs
 };
 
 static const struct genfs_ops filecore_genfsops = {
diff -r e09852c7a84b -r 052966c6aca5 sys/fs/hfs/hfs_vfsops.c
--- a/sys/fs/hfs/hfs_vfsops.c   Sun Mar 23 14:44:55 2014 +0000
+++ b/sys/fs/hfs/hfs_vfsops.c   Sun Mar 23 15:21:15 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: hfs_vfsops.c,v 1.29 2012/06/13 22:56:50 joerg Exp $    */
+/*     $NetBSD: hfs_vfsops.c,v 1.30 2014/03/23 15:21:15 hannken Exp $  */
 
 /*-
  * Copyright (c) 2005, 2007 The NetBSD Foundation, Inc.
@@ -99,7 +99,7 @@
  */



Home | Main Index | Thread Index | Old Index