Module Name:    src
Committed By:   pgoyette
Date:           Thu Mar 15 23:23:36 UTC 2018

Modified Files:
        src/sys/modules [pgoyette-compat]: Makefile
Added Files:
        src/sys/compat/common [pgoyette-compat]: compat_60_mod.c
        src/sys/modules/compat_60 [pgoyette-compat]: Makefile

Log Message:
Initial set-up for compat_60 module


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1.2.1 src/sys/compat/common/compat_60_mod.c
cvs rdiff -u -r1.202.2.3 -r1.202.2.4 src/sys/modules/Makefile
cvs rdiff -u -r0 -r1.1.2.1 src/sys/modules/compat_60/Makefile

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

Modified files:

Index: src/sys/modules/Makefile
diff -u src/sys/modules/Makefile:1.202.2.3 src/sys/modules/Makefile:1.202.2.4
--- src/sys/modules/Makefile:1.202.2.3	Thu Mar 15 05:10:05 2018
+++ src/sys/modules/Makefile	Thu Mar 15 23:23:35 2018
@@ -1,9 +1,20 @@
-#	$NetBSD: Makefile,v 1.202.2.3 2018/03/15 05:10:05 pgoyette Exp $
+#	$NetBSD: Makefile,v 1.202.2.4 2018/03/15 23:23:35 pgoyette Exp $
 
 .include <bsd.own.mk>
 
 # For all platforms
 
+# Modules for compatability with earlier versions of NetBSD
+
+SUBDIR+=	compat    compat_70 compat_60
+.ifdef NOTYET
+SUBDIR+=	compat_50 compat_40 compat_30 compat_20 compat_16
+SUBDIR+=	compat_14 compat_13 compat_12 compat_10 compat_09
+.endif
+SUBDIR+=	compat_ossaudio
+SUBDIR+=	compat_sysv
+
+
 SUBDIR=		accf_dataready
 SUBDIR+=	accf_httpready
 SUBDIR+=	adosfs
@@ -27,13 +38,6 @@ SUBDIR+=	clockctl
 SUBDIR+=	crypto
 SUBDIR+=	coda
 SUBDIR+=	coda5
-SUBDIR+=	compat    compat_70
-#ifdef NOTYET
-SUBDIR+=	compat_60 compat_50 compat_40 compat_30 compat_20 compat_16
-SUBDIR+=	compat_14 compat_13 compat_12 compat_10 compat_09
-#endif
-SUBDIR+=	compat_ossaudio
-SUBDIR+=	compat_sysv
 SUBDIR+=	coredump
 SUBDIR+=	dbcool
 SUBDIR+=	des

Added files:

Index: src/sys/compat/common/compat_60_mod.c
diff -u /dev/null src/sys/compat/common/compat_60_mod.c:1.1.2.1
--- /dev/null	Thu Mar 15 23:23:36 2018
+++ src/sys/compat/common/compat_60_mod.c	Thu Mar 15 23:23:36 2018
@@ -0,0 +1,71 @@
+/*	$NetBSD: compat_60_mod.c,v 1.1.2.1 2018/03/15 23:23:36 pgoyette Exp $	*/
+
+/*-
+ * Copyright (c) 2008 The NetBSD Foundation, Inc.
+ * All rights reserved.
+ *
+ * This code is derived from software developed for The NetBSD Foundation
+ * by Andrew Doran.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
+ * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * Linkage for the compat module: spaghetti.
+ */
+
+#include <sys/cdefs.h>
+__KERNEL_RCSID(0, "$NetBSD: compat_60_mod.c,v 1.1.2.1 2018/03/15 23:23:36 pgoyette Exp $");
+
+#ifdef _KERNEL_OPT
+#include "opt_compat_netbsd.h"
+#include "opt_compat_43.h"
+#endif
+
+#include <sys/systm.h>
+#include <sys/module.h>
+#include <sys/sysctl.h>
+
+#include <net/if.h>
+#include <net/route.h>
+
+#include <compat/common/compat_util.h>
+#include <compat/common/compat_mod.h>
+
+#define REQUIRED_60 "compat_70"		/* XXX No compat_80 yet */
+MODULE(MODULE_CLASS_EXEC, compat_60, REQUIRED_60);
+
+static int
+compat_60_modcmd(modcmd_t cmd, void *arg)
+{
+
+	switch (cmd) {
+	case MODULE_CMD_INIT:
+		return 0;
+
+	case MODULE_CMD_FINI:
+		return 0;
+
+	default:
+		return ENOTTY;
+	}
+}

Index: src/sys/modules/compat_60/Makefile
diff -u /dev/null src/sys/modules/compat_60/Makefile:1.1.2.1
--- /dev/null	Thu Mar 15 23:23:36 2018
+++ src/sys/modules/compat_60/Makefile	Thu Mar 15 23:23:36 2018
@@ -0,0 +1,13 @@
+#	$NetBSD: Makefile,v 1.1.2.1 2018/03/15 23:23:36 pgoyette Exp $
+
+.include "../Makefile.inc"
+
+.PATH:	${S}/compat/common
+
+KMOD=	compat_60
+
+CPPFLAGS+=	-D COMPAT_60 -DCOMPAT_70 -DCOMPAT_80
+
+SRCS+=	kern_sa_60.c tty_60.c kern_time_60.c
+
+.include <bsd.kmodule.mk>

Reply via email to