Source-Changes-HG archive

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

[src/pgoyette-compat]: src/sys/compat Rename if_[45]0_{init, fini} entry point...



details:   https://anonhg.NetBSD.org/src/rev/dbf5e3b05ba6
branches:  pgoyette-compat
changeset: 321152:dbf5e3b05ba6
user:      pgoyette <pgoyette%NetBSD.org@localhost>
date:      Mon Apr 16 03:41:34 2018 +0000

description:
Rename if_[45]0_{init,fini} entry points to more appropriate and more
consistent uipc_syscalls_[45]0_{init,fini} and remove some multiple
declarations.

diffstat:

 sys/compat/common/compat_40_mod.c    |  10 +++++-----
 sys/compat/common/compat_50_mod.c    |  10 +++++-----
 sys/compat/common/compat_mod.h       |  10 +++++-----
 sys/compat/common/if_40.h            |   4 +---
 sys/compat/common/uipc_syscalls_40.c |   9 +++++----
 sys/compat/common/uipc_syscalls_50.c |  10 ++++++----
 sys/compat/sys/sockio.h              |   9 +--------
 7 files changed, 28 insertions(+), 34 deletions(-)

diffs (237 lines):

diff -r bb5e04693361 -r dbf5e3b05ba6 sys/compat/common/compat_40_mod.c
--- a/sys/compat/common/compat_40_mod.c Mon Apr 16 02:03:04 2018 +0000
+++ b/sys/compat/common/compat_40_mod.c Mon Apr 16 03:41:34 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: compat_40_mod.c,v 1.1.2.1 2018/03/27 07:29:43 pgoyette Exp $   */
+/*     $NetBSD: compat_40_mod.c,v 1.1.2.2 2018/04/16 03:41:34 pgoyette Exp $   */
 
 /*-
  * Copyright (c) 2018 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: compat_40_mod.c,v 1.1.2.1 2018/03/27 07:29:43 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: compat_40_mod.c,v 1.1.2.2 2018/04/16 03:41:34 pgoyette Exp $");
 
 #include <sys/systm.h>
 #include <sys/module.h>
@@ -56,7 +56,7 @@
        error = vfs_syscalls_40_init();
        if (error != 0)
                return error;
-       if_40_init();
+       uipc_syscalls_40_init();
        sysmon_power_40_init();
 
        return error;
@@ -68,10 +68,10 @@
        int error = 0;
 
        sysmon_power_40_fini();
-       if_40_fini();
+       uipc_syscalls_40_fini();
        error = vfs_syscalls_40_fini();
        if (error != 0) {
-               if_40_init();
+               uipc_syscalls_40_init();
                sysmon_power_40_init();
        }
 
diff -r bb5e04693361 -r dbf5e3b05ba6 sys/compat/common/compat_50_mod.c
--- a/sys/compat/common/compat_50_mod.c Mon Apr 16 02:03:04 2018 +0000
+++ b/sys/compat/common/compat_50_mod.c Mon Apr 16 03:41:34 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: compat_50_mod.c,v 1.1.2.7 2018/03/24 23:52:19 pgoyette Exp $   */
+/*     $NetBSD: compat_50_mod.c,v 1.1.2.8 2018/04/16 03:41:34 pgoyette Exp $   */
 
 /*-
  * Copyright (c) 2018 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: compat_50_mod.c,v 1.1.2.7 2018/03/24 23:52:19 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: compat_50_mod.c,v 1.1.2.8 2018/04/16 03:41:34 pgoyette Exp $");
 
 #include <sys/systm.h>
 #include <sys/module.h>
@@ -79,7 +79,7 @@
                goto err3;
 
        uvm_50_init();
-       if_50_init();
+       uipc_syscalls_50_init();
        clockctl_50_init();
        if_spppsubr_50_init();
        cryptodev_50_init();
@@ -112,7 +112,7 @@
        cryptodev_50_fini();
        if_spppsubr_50_fini();
        clockctl_50_fini();
-       if_50_fini();
+       uipc_syscalls_50_fini();
        uvm_50_fini();
 
        error = vfs_syscalls_50_fini();
@@ -142,7 +142,7 @@
        vfs_syscalls_50_init();
  err1:
        uvm_50_init();
-       if_50_init();
+       uipc_syscalls_50_init();
        clockctl_50_init();
        if_spppsubr_50_init();
        cryptodev_50_init();
diff -r bb5e04693361 -r dbf5e3b05ba6 sys/compat/common/compat_mod.h
--- a/sys/compat/common/compat_mod.h    Mon Apr 16 02:03:04 2018 +0000
+++ b/sys/compat/common/compat_mod.h    Mon Apr 16 03:41:34 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: compat_mod.h,v 1.1.42.18 2018/04/03 08:29:44 pgoyette Exp $    */
+/*     $NetBSD: compat_mod.h,v 1.1.42.19 2018/04/16 03:41:34 pgoyette Exp $    */
 
 /*-
  * Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -75,15 +75,15 @@
 void uvm_50_fini(void);
 int vfs_syscalls_50_init(void);
 int vfs_syscalls_50_fini(void);
-void if_50_init(void);
-void if_50_fini(void);
+void uipc_syscalls_50_init(void);
+void uipc_syscalls_50_fini(void);
 #endif
 
 #ifdef COMPAT_40
 int compat_40_init(void);
 int compat_40_fini(void);
-void if_40_init(void);
-void if_40_fini(void);
+void uipc_syscalls_40_init(void);
+void uipc_syscalls_40_fini(void);
 int vfs_syscalls_40_init(void);
 int vfs_syscalls_40_fini(void);
 void sysmon_power_40_init(void);
diff -r bb5e04693361 -r dbf5e3b05ba6 sys/compat/common/if_40.h
--- a/sys/compat/common/if_40.h Mon Apr 16 02:03:04 2018 +0000
+++ b/sys/compat/common/if_40.h Mon Apr 16 03:41:34 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_40.h,v 1.1.2.2 2018/03/06 23:31:29 pgoyette Exp $   */
+/*     $NetBSD: if_40.h,v 1.1.2.3 2018/04/16 03:41:34 pgoyette Exp $   */
 
 /*-
  * Copyright (c) 2016 The NetBSD Foundation, Inc.
@@ -41,8 +41,6 @@
 extern int (*vec_compat_ifioctl)(struct socket *, u_long, u_long, 
     void *, struct lwp *);
 
-void if_40_init(void);
-void if_40_fini(void);
 #endif
 
 #endif /* !_COMPAT_IF_40_H_ */
diff -r bb5e04693361 -r dbf5e3b05ba6 sys/compat/common/uipc_syscalls_40.c
--- a/sys/compat/common/uipc_syscalls_40.c      Mon Apr 16 02:03:04 2018 +0000
+++ b/sys/compat/common/uipc_syscalls_40.c      Mon Apr 16 03:41:34 2018 +0000
@@ -1,9 +1,9 @@
-/*     $NetBSD: uipc_syscalls_40.c,v 1.15.2.8 2018/04/16 01:59:56 pgoyette Exp $       */
+/*     $NetBSD: uipc_syscalls_40.c,v 1.15.2.9 2018/04/16 03:41:34 pgoyette Exp $       */
 
 /* written by Pavel Cahyna, 2006. Public domain. */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: uipc_syscalls_40.c,v 1.15.2.8 2018/04/16 01:59:56 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: uipc_syscalls_40.c,v 1.15.2.9 2018/04/16 03:41:34 pgoyette Exp $");
 
 /*
  * System call interface to the socket abstraction.
@@ -23,6 +23,7 @@
 #include <compat/sys/sockio.h>
 
 #include <compat/common/if_40.h>
+#include <compat/common/compat_mod.h>
 
 /*
  * Return interface configuration
@@ -162,14 +163,14 @@
 }
 
 void      
-if_40_init(void)
+uipc_syscalls_40_init(void)
 {
  
        vec_compat_ifconf = compat_ifconf;
 }
  
 void
-if_40_fini(void)
+uipc_syscalls_40_fini(void)
 {
  
        vec_compat_ifconf = (void *)enosys;
diff -r bb5e04693361 -r dbf5e3b05ba6 sys/compat/common/uipc_syscalls_50.c
--- a/sys/compat/common/uipc_syscalls_50.c      Mon Apr 16 02:03:04 2018 +0000
+++ b/sys/compat/common/uipc_syscalls_50.c      Mon Apr 16 03:41:34 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: uipc_syscalls_50.c,v 1.3.56.5 2018/04/16 01:59:56 pgoyette Exp $       */
+/*     $NetBSD: uipc_syscalls_50.c,v 1.3.56.6 2018/04/16 03:41:34 pgoyette Exp $       */
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: uipc_syscalls_50.c,v 1.3.56.5 2018/04/16 01:59:56 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: uipc_syscalls_50.c,v 1.3.56.6 2018/04/16 03:41:34 pgoyette Exp $");
 
 #include <sys/param.h>
 #include <sys/kernel.h>
@@ -56,6 +56,8 @@
 #include <compat/sys/sockio.h>
 #include <compat/sys/if.h>
 
+#include <compat/common/compat_mod.h>
+
 /*ARGSUSED*/
 static int
 compat_ifdatareq(struct lwp *l, u_long cmd, void *data)
@@ -99,14 +101,14 @@
 /* Save and restore compat vector as needed */
 
 void
-if_50_init(void)
+uipc_syscalls_50_init(void)
 {
 
        vec_compat_ifdatareq = compat_ifdatareq;
 }
 
 void
-if_50_fini(void)
+uipc_syscalls_50_fini(void)
 {
 
        vec_compat_ifdatareq = (void *)enosys;
diff -r bb5e04693361 -r dbf5e3b05ba6 sys/compat/sys/sockio.h
--- a/sys/compat/sys/sockio.h   Mon Apr 16 02:03:04 2018 +0000
+++ b/sys/compat/sys/sockio.h   Mon Apr 16 03:41:34 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: sockio.h,v 1.10.58.4 2018/04/16 01:59:57 pgoyette Exp $        */
+/*     $NetBSD: sockio.h,v 1.10.58.5 2018/04/16 03:41:34 pgoyette Exp $        */
 
 /*-
  * Copyright (c) 1982, 1986, 1990, 1993, 1994
@@ -181,11 +181,4 @@
                    (oi)->ifi_lastchange.tv_usec * 1000; \
        } while (/*CONSTCOND*/0)
 
-#ifdef _KERNEL
-
-void if_50_init(void);
-void if_50_fini(void);
-
-#endif
-
 #endif /* _COMPAT_SYS_SOCKIO_H_ */



Home | Main Index | Thread Index | Old Index