CVS commit: [pgoyette-compat] src/sys/modules
Module Name:src Committed By: pgoyette Date: Tue Sep 11 07:01:10 UTC 2018 Modified Files: src/sys/modules [pgoyette-compat]: Makefile src/sys/modules/compat_netbsd32 [pgoyette-compat]: Makefile Added Files: src/sys/modules/compat_netbsd32_43 [pgoyette-compat]: Makefile Log Message: Get ready for compat_netbsd32_43 module To generate a diff of this commit: cvs rdiff -u -r1.202.2.28 -r1.202.2.29 src/sys/modules/Makefile cvs rdiff -u -r1.20.12.5 -r1.20.12.6 src/sys/modules/compat_netbsd32/Makefile cvs rdiff -u -r0 -r1.1.2.1 src/sys/modules/compat_netbsd32_43/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.28 src/sys/modules/Makefile:1.202.2.29 --- src/sys/modules/Makefile:1.202.2.28 Tue Sep 11 04:20:50 2018 +++ src/sys/modules/Makefile Tue Sep 11 07:01:10 2018 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.202.2.28 2018/09/11 04:20:50 pgoyette Exp $ +# $NetBSD: Makefile,v 1.202.2.29 2018/09/11 07:01:10 pgoyette Exp $ .include @@ -271,7 +271,7 @@ SUBDIR+= compat_netbsd32_09 compat_netbs SUBDIR+= compat_netbsd32_13 compat_netbsd32_20 SUBDIR+= compat_netbsd32_30 compat_netbsd32_50 SUBDIR+= compat_netbsd32_60 compat_netbsd32_80 -#SUBDIR+= compat_netbsd32_43 +SUBDIR+= compat_netbsd32_43 SUBDIR+= compat_netbsd32_mqueue SUBDIR+= compat_netbsd32_nfssrv SUBDIR+= compat_netbsd32_ptrace @@ -285,7 +285,7 @@ SUBDIR+= compat_netbsd32_09 compat_netbs SUBDIR+= compat_netbsd32_13 compat_netbsd32_20 SUBDIR+= compat_netbsd32_30 compat_netbsd32_50 SUBDIR+= compat_netbsd32_60 compat_netbsd32_80 -#SUBDIR+= compat_netbsd32_43 +SUBDIR+= compat_netbsd32_43 SUBDIR+= compat_netbsd32_mqueue SUBDIR+= compat_netbsd32_nfssrv SUBDIR+= compat_netbsd32_ptrace Index: src/sys/modules/compat_netbsd32/Makefile diff -u src/sys/modules/compat_netbsd32/Makefile:1.20.12.5 src/sys/modules/compat_netbsd32/Makefile:1.20.12.6 --- src/sys/modules/compat_netbsd32/Makefile:1.20.12.5 Tue Sep 11 05:01:35 2018 +++ src/sys/modules/compat_netbsd32/Makefile Tue Sep 11 07:01:10 2018 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.20.12.5 2018/09/11 05:01:35 pgoyette Exp $ +# $NetBSD: Makefile,v 1.20.12.6 2018/09/11 07:01:10 pgoyette Exp $ .include "../Makefile.inc" .include "../Makefile.assym" @@ -26,7 +26,6 @@ CPPFLAGS+= -DNTP -DKTRACE -DMODULAR .PATH: ${S}/compat/netbsd32 SRCS+= netbsd32_compat_10.c # belongs to compat_netbsd32_sysvipc_10 SRCS+= netbsd32_compat_14.c # belongs to compat_netbsd32_sysvipc_14 -SRCS+= netbsd32_compat_43.c SRCS+= netbsd32_core.c netbsd32_event.c SRCS+= netbsd32_exec_elf32.c SRCS+= netbsd32_execve.c netbsd32_fs.c Added files: Index: src/sys/modules/compat_netbsd32_43/Makefile diff -u /dev/null src/sys/modules/compat_netbsd32_43/Makefile:1.1.2.1 --- /dev/null Tue Sep 11 07:01:10 2018 +++ src/sys/modules/compat_netbsd32_43/Makefile Tue Sep 11 07:01:10 2018 @@ -0,0 +1,14 @@ +# $NetBSD: Makefile,v 1.1.2.1 2018/09/11 07:01:10 pgoyette Exp $ + +.include "../Makefile.inc" + +.PATH: ${S}/compat/netbsd32 + +KMOD= compat_netbsd32_80 + +CPPFLAGS+= -DCOMPAT_NETBSD32 +CPPFLAGS+= -DCOMPAT_80 + +SRCS+= netbsd32_compat_80.c + +.include
CVS commit: src/usr.sbin/sysinst
Module Name:src Committed By: martin Date: Tue Sep 11 08:05:18 UTC 2018 Modified Files: src/usr.sbin/sysinst: defs.h main.c menus.mi msg.mi.de msg.mi.en msg.mi.es msg.mi.fr msg.mi.pl net.c Log Message: Split the host name used for ftp transfers from the one used for http transfers. This is slightly inconsistent, as directories are still shared - but this allows us to default to cdn/nycdn for http (which don't support ftp). To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/usr.sbin/sysinst/defs.h cvs rdiff -u -r1.7 -r1.8 src/usr.sbin/sysinst/main.c \ src/usr.sbin/sysinst/msg.mi.de src/usr.sbin/sysinst/msg.mi.es cvs rdiff -u -r1.13 -r1.14 src/usr.sbin/sysinst/menus.mi cvs rdiff -u -r1.11 -r1.12 src/usr.sbin/sysinst/msg.mi.en cvs rdiff -u -r1.10 -r1.11 src/usr.sbin/sysinst/msg.mi.fr cvs rdiff -u -r1.9 -r1.10 src/usr.sbin/sysinst/msg.mi.pl cvs rdiff -u -r1.24 -r1.25 src/usr.sbin/sysinst/net.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.sbin/sysinst/defs.h diff -u src/usr.sbin/sysinst/defs.h:1.15 src/usr.sbin/sysinst/defs.h:1.16 --- src/usr.sbin/sysinst/defs.h:1.15 Sat Sep 8 20:01:19 2018 +++ src/usr.sbin/sysinst/defs.h Tue Sep 11 08:05:18 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: defs.h,v 1.15 2018/09/08 20:01:19 martin Exp $ */ +/* $NetBSD: defs.h,v 1.16 2018/09/11 08:05:18 martin Exp $ */ /* * Copyright 1997 Piermont Information Systems Inc. @@ -340,6 +340,10 @@ int clean_xfer_dir; #define SYSINST_FTP_HOST "ftp.NetBSD.org" #endif +#if !defined(SYSINST_HTTP_HOST) +#define SYSINST_HTTP_HOST "cdn.NetBSD.org" +#endif + #if !defined(SYSINST_FTP_DIR) #if defined(NETBSD_OFFICIAL_RELEASE) #define SYSINST_FTP_DIR "pub/NetBSD/NetBSD-" REL @@ -355,6 +359,9 @@ int clean_xfer_dir; #if !defined(SYSINST_PKG_HOST) #define SYSINST_PKG_HOST "ftp.NetBSD.org" #endif +#if !defined(SYSINST_PKG_HTTP_HOST) +#define SYSINST_PKG_HTTP_HOST "cdn.NetBSD.org" +#endif #if !defined(SYSINST_PKG_DIR) #define SYSINST_PKG_DIR "pub/pkgsrc/packages/NetBSD" @@ -363,6 +370,9 @@ int clean_xfer_dir; #if !defined(SYSINST_PKGSRC_HOST) #define SYSINST_PKGSRC_HOST SYSINST_PKG_HOST #endif +#if !defined(SYSINST_PKGSRC_HTTP_HOST) +#define SYSINST_PKGSRC_HTTP_HOST SYSINST_PKG_HTTP_HOST +#endif /* Abs. path we extract binary sets from */ char ext_dir_bin[STRSIZE]; @@ -388,13 +398,17 @@ char pkgsrc_dir[STRSIZE]; /* User shell */ const char *ushell; +#define XFER_FTP 0 +#define XFER_HTTP 1 +#define XFER_MAX XFER_HTTP + struct ftpinfo { -char host[STRSIZE]; +char xfer_host[XFER_MAX+1][STRSIZE]; char dir[STRSIZE] ; char user[SSTRSIZE]; char pass[STRSIZE]; char proxy[STRSIZE]; -const char *xfer_type; /* "ftp" or "http" */ +unsigned int xfer; /* XFER_FTP for "ftp" or XFER_HTTP for "http" */ }; /* use the same struct for sets ftp and to build pkgpath */ @@ -500,12 +514,13 @@ int get_real_geom(const char *, struct d /* from net.c */ extern int network_up; extern char net_namesvr[STRSIZE]; -int get_via_ftp(const char *); +int get_via_ftp(unsigned int); int get_via_nfs(void); int config_network(void); void mnt_net_config(void); void make_url(char *, struct ftpinfo *, const char *); int get_pkgsrc(void); +const char *url_proto(unsigned int); /* From run.c */ int collect(int, char **, const char *, ...) __printflike(3, 4); Index: src/usr.sbin/sysinst/main.c diff -u src/usr.sbin/sysinst/main.c:1.7 src/usr.sbin/sysinst/main.c:1.8 --- src/usr.sbin/sysinst/main.c:1.7 Thu May 4 16:26:10 2017 +++ src/usr.sbin/sysinst/main.c Tue Sep 11 08:05:18 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: main.c,v 1.7 2017/05/04 16:26:10 sevan Exp $ */ +/* $NetBSD: main.c,v 1.8 2018/09/11 08:05:18 martin Exp $ */ /* * Copyright 1997 Piermont Information Systems Inc. @@ -91,7 +91,8 @@ static const struct f_arg fflagopts[] = {"xfer dir", "/usr/INSTALL", xfer_dir, sizeof xfer_dir}, {"ext dir", "", ext_dir_bin, sizeof ext_dir_bin}, {"ext src dir", "", ext_dir_src, sizeof ext_dir_src}, - {"ftp host", SYSINST_FTP_HOST, ftp.host, sizeof ftp.host}, + {"ftp host", SYSINST_FTP_HOST, ftp.xfer_host[XFER_FTP], sizeof ftp.xfer_host[XFER_FTP]}, + {"http host", SYSINST_HTTP_HOST, ftp.xfer_host[XFER_HTTP], sizeof ftp.xfer_host[XFER_HTTP]}, {"ftp dir", SYSINST_FTP_DIR, ftp.dir, sizeof ftp.dir}, {"ftp prefix", "/" MACH "/binary/sets", set_dir_bin, sizeof set_dir_bin}, {"ftp src prefix", "/source/sets", set_dir_src, sizeof set_dir_src}, @@ -108,13 +109,15 @@ static const struct f_arg fflagopts[] = {"targetroot mount", "/targetroot", targetroot_mnt, sizeof targetroot_mnt}, {"dist postfix", ".tgz", dist_postfix, sizeof dist_postfix}, {"diskname", "mydisk", bsddiskname, sizeof bsddiskname}, - {"pkg host", SYSINST_PKG_HOST, pkg.host, sizeof pkg.host}, + {"pkg host", SYSINST_PKG_HOST, pkg.xfer_host[XFER_FTP], sizeof pkg.xfer_host[XFER_FTP]}, + {"pkg http host", SY
CVS commit: [pgoyette-compat] src/sys/sys
Module Name:src Committed By: pgoyette Date: Tue Sep 11 08:25:44 UTC 2018 Modified Files: src/sys/sys [pgoyette-compat]: module.h Log Message: Define vector for compat_netbsd32 version of sys_modctl() To generate a diff of this commit: cvs rdiff -u -r1.41.14.12 -r1.41.14.13 src/sys/sys/module.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/sys/module.h diff -u src/sys/sys/module.h:1.41.14.12 src/sys/sys/module.h:1.41.14.13 --- src/sys/sys/module.h:1.41.14.12 Mon Sep 10 22:50:52 2018 +++ src/sys/sys/module.h Tue Sep 11 08:25:43 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: module.h,v 1.41.14.12 2018/09/10 22:50:52 pgoyette Exp $ */ +/* $NetBSD: module.h,v 1.41.14.13 2018/09/11 08:25:43 pgoyette Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -218,7 +218,8 @@ void module_print(const char *, ...) __p extern char module_base[MODULE_BASE_SIZE]; extern const char *module_machine; -extern int (*vec_compat32_80_modctl)(struct lwp *, +struct netbsd32_modctl_args; +extern int (*vec_compat32_80_modctl)(struct lwp *, const struct netbsd32_modctl_args *, register_t *); extern int compat32_80_modctl_compat_stub(struct lwp *, const struct netbsd32_modctl_args *, register_t *);
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Tue Sep 11 08:35:28 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: syscalls.master Log Message: Insert "MODULAR compat_netbsd32_43" as neeed To generate a diff of this commit: cvs rdiff -u -r1.120.2.9 -r1.120.2.10 src/sys/compat/netbsd32/syscalls.master Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/syscalls.master diff -u src/sys/compat/netbsd32/syscalls.master:1.120.2.9 src/sys/compat/netbsd32/syscalls.master:1.120.2.10 --- src/sys/compat/netbsd32/syscalls.master:1.120.2.9 Tue Sep 11 06:11:59 2018 +++ src/sys/compat/netbsd32/syscalls.master Tue Sep 11 08:35:27 2018 @@ -1,4 +1,4 @@ - $NetBSD: syscalls.master,v 1.120.2.9 2018/09/11 06:11:59 pgoyette Exp $ + $NetBSD: syscalls.master,v 1.120.2.10 2018/09/11 08:35:27 pgoyette Exp $ ; from: NetBSD: syscalls.master,v 1.81 1998/07/05 08:49:50 jonathan Exp ; @(#)syscalls.master 8.2 (Berkeley) 1/13/94 @@ -73,7 +73,8 @@ 7 COMPAT_50 MODULAR compat_netbsd32_50 \ { int|netbsd32||wait4(int pid, netbsd32_intp status, \ int options, netbsd32_rusage50p_t rusage); } -8 COMPAT_43 { int|netbsd32||ocreat(netbsd32_charp path, \ +8 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||ocreat(netbsd32_charp path, \ mode_t mode); } 9 STD { int|netbsd32||link(netbsd32_charp path, \ netbsd32_charp link); } @@ -91,7 +92,8 @@ 18 COMPAT_20 MODULAR compat_netbsd32_20 \ { int|netbsd32||getfsstat(netbsd32_statfsp_t buf, \ netbsd32_long bufsize, int flags); } -19 COMPAT_43 { netbsd32_long|netbsd32||olseek(int fd, \ +19 COMPAT_43 MODULAR compat_netbsd32_43 \ + { netbsd32_long|netbsd32||olseek(int fd, \ netbsd32_long offset, int whence); } 20 NOARGS { pid_t|sys||getpid(void); } 21 STD { int|netbsd32||mount(netbsd32_charp type, \ @@ -127,10 +129,12 @@ netbsd32_u_long flags); } 36 NOARGS { void|sys||sync(void); } 37 STD { int|netbsd32||kill(int pid, int signum); } -38 COMPAT_43 { int|netbsd32||stat43(netbsd32_charp path, \ +38 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||stat43(netbsd32_charp path, \ netbsd32_stat43p_t ub); } 39 NOARGS { pid_t|sys||getppid(void); } -40 COMPAT_43 { int|netbsd32||lstat43(netbsd32_charp path, \ +40 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||lstat43(netbsd32_charp path, \ netbsd32_stat43p_t ub); } 41 STD { int|netbsd32||dup(int fd); } 42 NOARGS { int|sys||pipe(void); } @@ -169,8 +173,10 @@ netbsd32_charpp argp, netbsd32_charpp envp); } 60 STD { mode_t|netbsd32||umask(mode_t newmask); } 61 STD { int|netbsd32||chroot(netbsd32_charp path); } -62 COMPAT_43 { int|netbsd32||fstat43(int fd, netbsd32_stat43p_t sb); } -63 COMPAT_43 { int|netbsd32||ogetkerninfo(int op, \ +62 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||fstat43(int fd, netbsd32_stat43p_t sb); } +63 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||ogetkerninfo(int op, \ netbsd32_charp where, netbsd32_intp size, \ int arg); } 64 COMPAT_43 { int|sys||getpagesize(void); } ogetpagesize @@ -183,7 +189,8 @@ 68 OBSOL vwrite 69 OBSOL sbrk 70 OBSOL sstk -71 COMPAT_43 { int|netbsd32||ommap(netbsd32_voidp addr, \ +71 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||ommap(netbsd32_voidp addr, \ netbsd32_size_t len, int prot, int flags, int fd, \ netbsd32_long pos); } 72 STD { int|netbsd32||ovadvise(int anom); } vadvise @@ -213,9 +220,11 @@ 86 COMPAT_50 MODULAR compat_netbsd32_50 \ { int|netbsd32||getitimer(int which, \ netbsd32_itimerval50p_t itv); } -87 COMPAT_43 { int|netbsd32||ogethostname(netbsd32_charp hostname, \ +87 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||ogethostname(netbsd32_charp hostname, \ u_int len); } -88 COMPAT_43 { int|netbsd32||osethostname(netbsd32_charp hostname, \ +88 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||osethostname(netbsd32_charp hostname, \ u_int len); } 89 COMPAT_43 { int|sys||getdtablesize(void); } ogetdtablesize 90 STD { int|netbsd32||dup2(int from, int to); } @@ -235,12 +244,15 @@ int protocol); } 98 STD { int|netbsd32||connect(int s, \ netbsd32_sockaddrp_t name, int namelen); } -99 COMPAT_43 { int|netbsd32||oaccept(int s, netbsd32_voidp name, \ +99 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||oaccept(int s, netbsd32_voidp name, \ netbsd32_intp anamelen); } 100 STD { int|netbsd32||getpriority(int which, int who); } -101 COMPAT_43 { int|netbsd32||osend(int s, netbsd32_voidp buf, \ +101 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||osend(int s, netbsd32_voidp buf, \ int len, int flags); } -102 COMPAT_43 { int|netbsd32||orecv(int s, netbsd32_voidp buf, \ +102 COMPAT_43 MODULAR compat_netbsd32_43 \ + { int|netbsd32||orecv(int s, netbsd32_void
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Tue Sep 11 08:36:29 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_syscall.h netbsd32_syscallargs.h netbsd32_syscalls.c netbsd32_syscalls_autoload.c netbsd32_sysent.c netbsd32_systrace_args.c Log Message: Regen To generate a diff of this commit: cvs rdiff -u -r1.134.2.6 -r1.134.2.7 \ src/sys/compat/netbsd32/netbsd32_syscall.h cvs rdiff -u -r1.134.2.5 -r1.134.2.6 \ src/sys/compat/netbsd32/netbsd32_syscallargs.h cvs rdiff -u -r1.132.2.6 -r1.132.2.7 \ src/sys/compat/netbsd32/netbsd32_syscalls.c cvs rdiff -u -r1.13.2.5 -r1.13.2.6 \ src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c cvs rdiff -u -r1.132.2.5 -r1.132.2.6 \ src/sys/compat/netbsd32/netbsd32_sysent.c cvs rdiff -u -r1.24.2.5 -r1.24.2.6 \ src/sys/compat/netbsd32/netbsd32_systrace_args.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/netbsd32_syscall.h diff -u src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.6 src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.7 --- src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.6 Tue Sep 11 06:12:17 2018 +++ src/sys/compat/netbsd32/netbsd32_syscall.h Tue Sep 11 08:36:29 2018 @@ -1,10 +1,10 @@ -/* $NetBSD: netbsd32_syscall.h,v 1.134.2.6 2018/09/11 06:12:17 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscall.h,v 1.134.2.7 2018/09/11 08:36:29 pgoyette Exp $ */ /* * System call numbers. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.9 2018/09/11 06:11:59 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.10 2018/09/11 08:35:27 pgoyette Exp */ #ifndef _NETBSD32_SYS_SYSCALL_H_ Index: src/sys/compat/netbsd32/netbsd32_syscallargs.h diff -u src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.5 src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.6 --- src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.5 Tue Sep 11 06:12:17 2018 +++ src/sys/compat/netbsd32/netbsd32_syscallargs.h Tue Sep 11 08:36:29 2018 @@ -1,10 +1,10 @@ -/* $NetBSD: netbsd32_syscallargs.h,v 1.134.2.5 2018/09/11 06:12:17 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscallargs.h,v 1.134.2.6 2018/09/11 08:36:29 pgoyette Exp $ */ /* * System call argument lists. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.9 2018/09/11 06:11:59 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.10 2018/09/11 08:35:27 pgoyette Exp */ #ifndef _NETBSD32_SYS_SYSCALLARGS_H_ Index: src/sys/compat/netbsd32/netbsd32_syscalls.c diff -u src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.6 src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.7 --- src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.6 Tue Sep 11 06:12:17 2018 +++ src/sys/compat/netbsd32/netbsd32_syscalls.c Tue Sep 11 08:36:29 2018 @@ -1,14 +1,14 @@ -/* $NetBSD: netbsd32_syscalls.c,v 1.132.2.6 2018/09/11 06:12:17 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscalls.c,v 1.132.2.7 2018/09/11 08:36:29 pgoyette Exp $ */ /* * System call names. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.9 2018/09/11 06:11:59 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.10 2018/09/11 08:35:27 pgoyette Exp */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.132.2.6 2018/09/11 06:12:17 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.132.2.7 2018/09/11 08:36:29 pgoyette Exp $"); #if defined(_KERNEL_OPT) #if defined(_KERNEL_OPT) Index: src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c diff -u src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c:1.13.2.5 src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c:1.13.2.6 --- src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c:1.13.2.5 Tue Sep 11 06:12:17 2018 +++ src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c Tue Sep 11 08:36:29 2018 @@ -1,38 +1,65 @@ -/* $NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.5 2018/09/11 06:12:17 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.6 2018/09/11 08:36:29 pgoyette Exp $ */ /* * System call autoload table. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.9 2018/09/11 06:11:59 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.10 2018/09/11 08:35:27 pgoyette Exp */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.5 2018/09/11 06:12:17 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.6 2018/09/11 08:36:29 pgoyette Exp $"); #include static struct sc_autoload netbsd32_syscalls_autoload[] = { { NETBSD32_SYS_compat_50_netbsd32_wait4, "compat_netbsd32_50" }, + { NETBSD32_SYS_compat_43_netbsd32_ocreat, "
CVS commit: [pgoyette-compat] src/sys/modules/compat_netbsd32_43
Module Name:src Committed By: pgoyette Date: Tue Sep 11 08:41:27 UTC 2018 Modified Files: src/sys/modules/compat_netbsd32_43 [pgoyette-compat]: Makefile Log Message: Use the real version numbers, not just the ones from the template. To generate a diff of this commit: cvs rdiff -u -r1.1.2.1 -r1.1.2.2 src/sys/modules/compat_netbsd32_43/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/compat_netbsd32_43/Makefile diff -u src/sys/modules/compat_netbsd32_43/Makefile:1.1.2.1 src/sys/modules/compat_netbsd32_43/Makefile:1.1.2.2 --- src/sys/modules/compat_netbsd32_43/Makefile:1.1.2.1 Tue Sep 11 07:01:10 2018 +++ src/sys/modules/compat_netbsd32_43/Makefile Tue Sep 11 08:41:27 2018 @@ -1,14 +1,14 @@ -# $NetBSD: Makefile,v 1.1.2.1 2018/09/11 07:01:10 pgoyette Exp $ +# $NetBSD: Makefile,v 1.1.2.2 2018/09/11 08:41:27 pgoyette Exp $ .include "../Makefile.inc" .PATH: ${S}/compat/netbsd32 -KMOD= compat_netbsd32_80 +KMOD= compat_netbsd32_43 CPPFLAGS+= -DCOMPAT_NETBSD32 -CPPFLAGS+= -DCOMPAT_80 +CPPFLAGS+= -DCOMPAT_43 -SRCS+= netbsd32_compat_80.c +SRCS+= netbsd32_compat_43.c .include
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Tue Sep 11 08:42:23 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_compat_43.c Log Message: Make compat_netbsd32_43 into a stand-alone module. To generate a diff of this commit: cvs rdiff -u -r1.54.14.2 -r1.54.14.3 \ src/sys/compat/netbsd32/netbsd32_compat_43.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/netbsd32_compat_43.c diff -u src/sys/compat/netbsd32/netbsd32_compat_43.c:1.54.14.2 src/sys/compat/netbsd32/netbsd32_compat_43.c:1.54.14.3 --- src/sys/compat/netbsd32/netbsd32_compat_43.c:1.54.14.2 Mon May 21 04:36:03 2018 +++ src/sys/compat/netbsd32/netbsd32_compat_43.c Tue Sep 11 08:42:23 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_compat_43.c,v 1.54.14.2 2018/05/21 04:36:03 pgoyette Exp $ */ +/* $NetBSD: netbsd32_compat_43.c,v 1.54.14.3 2018/09/11 08:42:23 pgoyette Exp $ */ /* * Copyright (c) 1998, 2001 Matthew R. Green @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_43.c,v 1.54.14.2 2018/05/21 04:36:03 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_43.c,v 1.54.14.3 2018/09/11 08:42:23 pgoyette Exp $"); #if defined(_KERNEL_OPT) #include "opt_compat_43.h" @@ -35,6 +35,7 @@ __KERNEL_RCSID(0, "$NetBSD: netbsd32_com #include #include +#include #include #include #include @@ -45,6 +46,7 @@ __KERNEL_RCSID(0, "$NetBSD: netbsd32_com #include #include #include +#include #include #include #include @@ -54,6 +56,7 @@ __KERNEL_RCSID(0, "$NetBSD: netbsd32_com #include #include +#include #include #include @@ -67,10 +70,11 @@ __KERNEL_RCSID(0, "$NetBSD: netbsd32_com SYS_DEF(compat_43_netbsd32_sethostid); SYS_DEF(compat_43_netbsd32_killpg); SYS_DEF(compat_43_netbsd32_sigblock); -SYS_DEF(compat_43_netbsd32_sigblock); SYS_DEF(compat_43_netbsd32_sigsetmask); #undef SYS_DEF +extern struct emul emul_netbsd32; + static void netbsd32_from_stat(const struct stat *sb, struct netbsd32_stat43 *sp32) { @@ -708,3 +712,83 @@ compat_43_netbsd32_osigstack(struct lwp return error; } + +static struct syscall_package compat_netbsd32_43_syscalls[] = { + { NETBSD32_SYS_compat_43_netbsd32_ocreat, 0, + (sy_call_t *)compat_43_netbsd32_ocreat }, + { NETBSD32_SYS_compat_43_netbsd32_olseek, 0, + (sy_call_t *)compat_43_netbsd32_olseek }, + { NETBSD32_SYS_compat_43_netbsd32_stat43, 0, + (sy_call_t *)compat_43_netbsd32_stat43 }, + { NETBSD32_SYS_compat_43_netbsd32_lstat43, 0, + (sy_call_t *)compat_43_netbsd32_lstat43 }, + { NETBSD32_SYS_compat_43_netbsd32_fstat43, 0, + (sy_call_t *)compat_43_netbsd32_fstat43 }, + { NETBSD32_SYS_compat_43_netbsd32_otruncate, 0, + (sy_call_t *)compat_43_netbsd32_otruncate }, + { NETBSD32_SYS_compat_43_netbsd32_oftruncate, 0, + (sy_call_t *)compat_43_netbsd32_oftruncate }, + { NETBSD32_SYS_compat_43_netbsd32_ogetdirentries, 0, + (sy_call_t *)compat_43_netbsd32_ogetdirentries }, + { NETBSD32_SYS_compat_43_netbsd32_ogetkerninfo, 0, + (sy_call_t *)compat_43_netbsd32_ogetkerninfo }, + { NETBSD32_SYS_compat_43_netbsd32_ogethostname, 0, + (sy_call_t *)compat_43_netbsd32_ogethostname }, + { NETBSD32_SYS_compat_43_netbsd32_osethostname, 0, + (sy_call_t *)compat_43_netbsd32_osethostname }, + { NETBSD32_SYS_compat_43_netbsd32_sethostid, 0, + (sy_call_t *)compat_43_netbsd32_sethostid }, + { NETBSD32_SYS_compat_43_netbsd32_ogetrlimit, 0, + (sy_call_t *)compat_43_netbsd32_ogetrlimit }, + { NETBSD32_SYS_compat_43_netbsd32_osetrlimit, 0, + (sy_call_t *)compat_43_netbsd32_osetrlimit }, + { NETBSD32_SYS_compat_43_netbsd32_killpg, 0, + (sy_call_t *)compat_43_netbsd32_killpg }, + { NETBSD32_SYS_compat_43_netbsd32_ommap, 0, + (sy_call_t *)compat_43_netbsd32_ommap }, + { NETBSD32_SYS_compat_43_netbsd32_oaccept, 0, + (sy_call_t *)compat_43_netbsd32_oaccept }, + { NETBSD32_SYS_compat_43_netbsd32_osend, 0, + (sy_call_t *)compat_43_netbsd32_osend }, + { NETBSD32_SYS_compat_43_netbsd32_orecv, 0, + (sy_call_t *)compat_43_netbsd32_orecv }, + { NETBSD32_SYS_compat_43_netbsd32_orecvmsg, 0, + (sy_call_t *)compat_43_netbsd32_orecvmsg }, + { compat_43_netbsd32_osendmsg, 0, + (sy_call_t *)compat_43_netbsd32_osendmsg }, + { NETBSD32_SYS_compat_43_netbsd32_orecvfrom, 0, + (sy_call_t *)compat_43_netbsd32_orecvfrom }, + { NETBSD32_SYS_compat_43_netbsd32_ogetsockname, 0, + (sy_call_t *)compat_43_netbsd32_ogetsockname }, + { NETBSD32_SYS_compat_43_netbsd32_ogetpeername, 0, + (sy_call_t *)compat_43_netbsd32_ogetpeername }, + { NETBSD32_SYS_compat_43_netbsd32_osigvec, 0, + (sy_call_t *)compat_43_netbsd32_osigvec }, + { NETBSD32_SYS_compat_43_netbsd32_sigblock, 0, + (sy_call_t *)compat_43_netbsd32_sigblock }, + { NETBSD32_SYS_compat_43_netbsd32_sigsetmask, 0, + (sy_call_t *)compat_43_netbsd32_sigsetmask }, + { NETBSD32_SYS_com
CVS commit: [pgoyette-compat] src/doc
Module Name:src Committed By: pgoyette Date: Tue Sep 11 08:42:45 UTC 2018 Modified Files: src/doc [pgoyette-compat]: TODO.compat-module Log Message: Update To generate a diff of this commit: cvs rdiff -u -r1.1.2.2 -r1.1.2.3 src/doc/TODO.compat-module Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/TODO.compat-module diff -u src/doc/TODO.compat-module:1.1.2.2 src/doc/TODO.compat-module:1.1.2.3 --- src/doc/TODO.compat-module:1.1.2.2 Mon Sep 10 08:49:25 2018 +++ src/doc/TODO.compat-module Tue Sep 11 08:42:45 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: TODO.compat-module,v 1.1.2.2 2018/09/10 08:49:25 pgoyette Exp $ */ +/* $NetBSD: TODO.compat-module,v 1.1.2.3 2018/09/11 08:42:45 pgoyette Exp $ */ DONE @@ -46,8 +46,9 @@ DONE TODO - Required for branch merge -1. Replace version-specific parts of the compat_netbsd32 module with -individual modules. Update dependencies accordingly. +1. Replace version-specific parts of the compat_netbsd32 module (and +also the compat_netbsd32_sysv module) with individual modules. Update +dependencies accordingly. TODO - Not required for branch merge
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Tue Sep 11 08:51:55 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_compat_43.c Log Message: Typo To generate a diff of this commit: cvs rdiff -u -r1.54.14.3 -r1.54.14.4 \ src/sys/compat/netbsd32/netbsd32_compat_43.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/netbsd32_compat_43.c diff -u src/sys/compat/netbsd32/netbsd32_compat_43.c:1.54.14.3 src/sys/compat/netbsd32/netbsd32_compat_43.c:1.54.14.4 --- src/sys/compat/netbsd32/netbsd32_compat_43.c:1.54.14.3 Tue Sep 11 08:42:23 2018 +++ src/sys/compat/netbsd32/netbsd32_compat_43.c Tue Sep 11 08:51:55 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_compat_43.c,v 1.54.14.3 2018/09/11 08:42:23 pgoyette Exp $ */ +/* $NetBSD: netbsd32_compat_43.c,v 1.54.14.4 2018/09/11 08:51:55 pgoyette Exp $ */ /* * Copyright (c) 1998, 2001 Matthew R. Green @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_43.c,v 1.54.14.3 2018/09/11 08:42:23 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_43.c,v 1.54.14.4 2018/09/11 08:51:55 pgoyette Exp $"); #if defined(_KERNEL_OPT) #include "opt_compat_43.h" @@ -754,7 +754,7 @@ static struct syscall_package compat_net (sy_call_t *)compat_43_netbsd32_orecv }, { NETBSD32_SYS_compat_43_netbsd32_orecvmsg, 0, (sy_call_t *)compat_43_netbsd32_orecvmsg }, - { compat_43_netbsd32_osendmsg, 0, + { NETBSD32_SYS_compat_43_netbsd32_osendmsg, 0, (sy_call_t *)compat_43_netbsd32_osendmsg }, { NETBSD32_SYS_compat_43_netbsd32_orecvfrom, 0, (sy_call_t *)compat_43_netbsd32_orecvfrom },
CVS commit: [pgoyette-compat] src/distrib/sets/lists/modules
Module Name:src Committed By: pgoyette Date: Tue Sep 11 09:05:32 UTC 2018 Modified Files: src/distrib/sets/lists/modules [pgoyette-compat]: ad.arm ad.mips md.amd64 Log Message: More fixing of placement of version number in module name To generate a diff of this commit: cvs rdiff -u -r1.10.12.2 -r1.10.12.3 src/distrib/sets/lists/modules/ad.arm \ src/distrib/sets/lists/modules/ad.mips cvs rdiff -u -r1.75.2.4 -r1.75.2.5 src/distrib/sets/lists/modules/md.amd64 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/modules/ad.arm diff -u src/distrib/sets/lists/modules/ad.arm:1.10.12.2 src/distrib/sets/lists/modules/ad.arm:1.10.12.3 --- src/distrib/sets/lists/modules/ad.arm:1.10.12.2 Tue Sep 11 06:46:24 2018 +++ src/distrib/sets/lists/modules/ad.arm Tue Sep 11 09:05:32 2018 @@ -1,4 +1,4 @@ -# $NetBSD: ad.arm,v 1.10.12.2 2018/09/11 06:46:24 pgoyette Exp $ +# $NetBSD: ad.arm,v 1.10.12.3 2018/09/11 09:05:32 pgoyette Exp $ ./@MODULEDIR@/compat_netbsd32 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32/compat_netbsd32.kmod base-kernel-modules kmod @@ -23,7 +23,7 @@ ./@MODULEDIR@/compat_netbsd32_80 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_80/compat_netbsd32_80.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_43 base-kernel-modules kmod -./@MODULEDIR@/compat_netbsd32_43/compat_netbsd32.kmod_43 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_43/compat_netbsd32_43.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_mqueue base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_mqueue/compat_netbsd32_mqueue.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_nfssrv base-kernel-modules kmod Index: src/distrib/sets/lists/modules/ad.mips diff -u src/distrib/sets/lists/modules/ad.mips:1.10.12.2 src/distrib/sets/lists/modules/ad.mips:1.10.12.3 --- src/distrib/sets/lists/modules/ad.mips:1.10.12.2 Tue Sep 11 06:46:24 2018 +++ src/distrib/sets/lists/modules/ad.mips Tue Sep 11 09:05:32 2018 @@ -1,4 +1,4 @@ -# $NetBSD: ad.mips,v 1.10.12.2 2018/09/11 06:46:24 pgoyette Exp $ +# $NetBSD: ad.mips,v 1.10.12.3 2018/09/11 09:05:32 pgoyette Exp $ ./@MODULEDIR@/compat_netbsd32 base-kernel-modules kmod,arch64,nocompatmodules ./@MODULEDIR@/compat_netbsd32/compat_netbsd32.kmod base-kernel-modules kmod,arch64,nocompatmodules ./@MODULEDIR@/compat_netbsd32_09 base-kernel-modules kmod @@ -22,7 +22,7 @@ ./@MODULEDIR@/compat_netbsd32_80 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_80/compat_netbsd32_80.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_43 base-kernel-modules kmod -./@MODULEDIR@/compat_netbsd32_43/compat_netbsd32.kmod_43 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_43/compat_netbsd32_43.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_mqueue base-kernel-modules kmod,arch64,nocompatmodules ./@MODULEDIR@/compat_netbsd32_mqueue/compat_netbsd32_mqueue.kmod base-kernel-modules kmod,arch64,nocompatmodules ./@MODULEDIR@/compat_netbsd32_nfssrv base-kernel-modules kmod,arch64,nocompatmodules Index: src/distrib/sets/lists/modules/md.amd64 diff -u src/distrib/sets/lists/modules/md.amd64:1.75.2.4 src/distrib/sets/lists/modules/md.amd64:1.75.2.5 --- src/distrib/sets/lists/modules/md.amd64:1.75.2.4 Tue Sep 11 06:46:24 2018 +++ src/distrib/sets/lists/modules/md.amd64 Tue Sep 11 09:05:32 2018 @@ -1,4 +1,4 @@ -# $NetBSD: md.amd64,v 1.75.2.4 2018/09/11 06:46:24 pgoyette Exp $ +# $NetBSD: md.amd64,v 1.75.2.5 2018/09/11 09:05:32 pgoyette Exp $ # # NOTE that there are two sets of files here: # @MODULEDIR@ and amd64-xen @@ -76,7 +76,7 @@ ./@MODULEDIR@/compat_netbsd32_80 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_80/compat_netbsd32_80.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_43 base-kernel-modules kmod -./@MODULEDIR@/compat_netbsd32_43/compat_netbsd32.kmod_43 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_43/compat_netbsd32_43.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_mqueue base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_mqueue/compat_netbsd32_mqueue.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_nfssrv base-kernel-modules kmod
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Tue Sep 11 09:22:51 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_compat_80.c Log Message: Remove unused variable To generate a diff of this commit: cvs rdiff -u -r1.1.2.2 -r1.1.2.3 src/sys/compat/netbsd32/netbsd32_compat_80.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/netbsd32_compat_80.c diff -u src/sys/compat/netbsd32/netbsd32_compat_80.c:1.1.2.2 src/sys/compat/netbsd32/netbsd32_compat_80.c:1.1.2.3 --- src/sys/compat/netbsd32/netbsd32_compat_80.c:1.1.2.2 Tue Sep 11 05:48:07 2018 +++ src/sys/compat/netbsd32/netbsd32_compat_80.c Tue Sep 11 09:22:51 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_compat_80.c,v 1.1.2.2 2018/09/11 05:48:07 pgoyette Exp $ */ +/* $NetBSD: netbsd32_compat_80.c,v 1.1.2.3 2018/09/11 09:22:51 pgoyette Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -29,7 +29,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_80.c,v 1.1.2.2 2018/09/11 05:48:07 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_80.c,v 1.1.2.3 2018/09/11 09:22:51 pgoyette Exp $"); #include #include @@ -156,9 +156,6 @@ netbsd32_80_modctl(struct lwp *lwp, cons struct netbsd32_iovec iov; int error; void *arg; -#ifdef MODULAR - uintptr_t loadtype; -#endif arg = SCARG_P32(uap, arg);
CVS commit: src/sys/arch/arm/samsung
Module Name:src Committed By: jmcneill Date: Tue Sep 11 10:05:31 UTC 2018 Modified Files: src/sys/arch/arm/samsung: exynos_uart.c Log Message: Make this driver MPSAFE To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/samsung/exynos_uart.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/arm/samsung/exynos_uart.c diff -u src/sys/arch/arm/samsung/exynos_uart.c:1.1 src/sys/arch/arm/samsung/exynos_uart.c:1.2 --- src/sys/arch/arm/samsung/exynos_uart.c:1.1 Thu Jul 5 13:11:58 2018 +++ src/sys/arch/arm/samsung/exynos_uart.c Tue Sep 11 10:05:31 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: exynos_uart.c,v 1.1 2018/07/05 13:11:58 jmcneill Exp $ */ +/* $NetBSD: exynos_uart.c,v 1.2 2018/09/11 10:05:31 jmcneill Exp $ */ /*- * Copyright (c) 2013-2018 The NetBSD Foundation, Inc. @@ -33,7 +33,7 @@ #include -__KERNEL_RCSID(1, "$NetBSD: exynos_uart.c,v 1.1 2018/07/05 13:11:58 jmcneill Exp $"); +__KERNEL_RCSID(1, "$NetBSD: exynos_uart.c,v 1.2 2018/09/11 10:05:31 jmcneill Exp $"); #define cn_trap() \ do {\ @@ -77,6 +77,7 @@ struct exynos_uart_softc { device_t sc_dev; bus_space_tag_t sc_bst; bus_space_handle_t sc_bsh; + kmutex_t sc_lock; u_int sc_freq; void *sc_ih; @@ -186,6 +187,7 @@ exynos_uart_attach(device_t parent, devi sc->sc_dev = self; sc->sc_bst = faa->faa_bst; + mutex_init(&sc->sc_lock, MUTEX_DEFAULT, IPL_HIGH); sc->sc_console = is_console; if (is_console) { sc->sc_bsh = exynos_uart_cnsc.sc_bsh; @@ -259,13 +261,13 @@ static int exynos_uart_cngetc(dev_t dev) { struct exynos_uart_softc * const sc = &exynos_uart_cnsc; - uint32_t status; + uint32_t ufstat; int s, c; s = splserial(); - status = RD4(sc, SSCOM_UTRSTAT); - if ((status & UTRSTAT_RXREADY) == 0) { + ufstat = RD4(sc, SSCOM_UFSTAT); + if (__SHIFTOUT(ufstat, UFSTAT_RXCOUNT) == 0) { splx(s); return -1; } @@ -334,6 +336,8 @@ exynos_uart_open(dev_t dev, int flag, in return EBUSY; } + mutex_enter(&sc->sc_lock); + if ((tp->t_state & TS_ISOPEN) == 0 && tp->t_wopen == 0) { tp->t_dev = dev; ttychars(tp); @@ -354,6 +358,8 @@ exynos_uart_open(dev_t dev, int flag, in /* Enable RX and error interrupts */ WR4(sc, SSCOM_UINTM, ~0u & ~(UINT_RXD|UINT_ERROR)); + mutex_exit(&sc->sc_lock); + return tp->t_linesw->l_open(dev, tp); } @@ -364,12 +370,16 @@ exynos_uart_close(dev_t dev, int flag, i device_lookup_private(&exuart_cd, minor(dev)); struct tty *tp = sc->sc_tty; + mutex_enter(&sc->sc_lock); + tp->t_linesw->l_close(tp, flag); ttyclose(tp); /* Disable interrupts */ WR4(sc, SSCOM_UINTM, ~0u); + mutex_exit(&sc->sc_lock); + return 0; } @@ -447,8 +457,6 @@ exynos_uart_start(struct tty *tp) } tp->t_state |= TS_BUSY; - splx(s); - for (brem = q_to_b(&tp->t_outq, sc->sc_buf, sizeof(sc->sc_buf)); brem > 0; brem--, p++) { @@ -459,7 +467,6 @@ exynos_uart_start(struct tty *tp) SSCOM_UTXH, *p); } - s = spltty(); tp->t_state &= ~TS_BUSY; if (ttypull(tp)) { tp->t_state |= TS_TIMEOUT; @@ -473,47 +480,51 @@ exynos_uart_param(struct tty *tp, struct { struct exynos_uart_softc *sc = tp->t_sc; - if (tp->t_ospeed == t->c_ospeed && - tp->t_cflag == t->c_cflag) - return 0; - - uint32_t ulcon = 0, ubrdiv; - switch (ISSET(t->c_cflag, CSIZE)) { - case CS5: - ulcon |= ULCON_LENGTH_5; - break; - case CS6: - ulcon |= ULCON_LENGTH_6; - break; - case CS7: - ulcon |= ULCON_LENGTH_7; - break; - case CS8: - ulcon |= ULCON_LENGTH_8; - break; - } - switch (ISSET(t->c_cflag, PARENB|PARODD)) { - case PARENB|PARODD: - ulcon |= ULCON_PARITY_ODD; - break; - case PARENB: - ulcon |= ULCON_PARITY_EVEN; - break; - default: - ulcon |= ULCON_PARITY_NONE; - break; - } - if (ISSET(t->c_cflag, CSTOPB)) - ulcon |= ULCON_STOP; - WR4(sc, SSCOM_ULCON, ulcon); + mutex_enter(&sc->sc_lock); + + if (tp->t_cflag != t->c_cflag) { + uint32_t ulcon = 0; + switch (ISSET(t->c_cflag, CSIZE)) { + case CS5: + ulcon |= ULCON_LENGTH_5; + break; + case CS6: + ulcon |= ULCON_LENGTH_6; + break; + case CS7: + ulcon |= ULCON_LENGTH_7; + break; + case CS8: + ulcon |= ULCON_LENGTH_8; + break; + } + switch (ISSET(t->c_cflag, PARENB|PARODD)) { + case PARENB|PARODD: + ulcon |= ULCON_PARITY_ODD; + break; + case PARENB: + ulcon |= ULCON_PARITY_EVEN; + break; + default: + ulcon |= ULCON_PARITY_NONE; + break; + } + if (ISSET(t->c_cflag, CSTOPB)) + ulcon |= ULCON_STOP; + WR4(sc, SSCOM_ULCON, ulcon); + } - ubrdiv = (sc->sc_freq / 16) / t->c_ospeed - 1; - WR4(sc, SSCOM_UBRDIV, ubrdiv); + if (tp->t_ospeed != t->c_ospeed) { + const uint32_t ubrdiv = (sc->sc_freq / 16) / t->c_ospeed - 1; + WR4(sc, SSCOM_UBRDIV, ubrdiv); + } tp->t_ispeed = t->c_ispeed; tp->t_ospeed = t->c_ospeed; tp->t_cflag = t->c_cflag; + mutex_exit(&sc->sc_lock); + return 0; } @@ -524,6 +535,8 @@ exynos_uart_intr(
CVS commit: src/sys/arch
Module Name:src Committed By: jmcneill Date: Tue Sep 11 10:06:53 UTC 2018 Modified Files: src/sys/arch/arm/samsung: exynos_platform.c files.exynos mct.c src/sys/arch/evbarm/conf: EXYNOS src/sys/arch/evbarm/exynos: exynos_start.S Log Message: Add Exynos5 SMP support. To generate a diff of this commit: cvs rdiff -u -r1.14 -r1.15 src/sys/arch/arm/samsung/exynos_platform.c \ src/sys/arch/arm/samsung/mct.c cvs rdiff -u -r1.31 -r1.32 src/sys/arch/arm/samsung/files.exynos cvs rdiff -u -r1.32 -r1.33 src/sys/arch/evbarm/conf/EXYNOS cvs rdiff -u -r1.7 -r1.8 src/sys/arch/evbarm/exynos/exynos_start.S Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/arm/samsung/exynos_platform.c diff -u src/sys/arch/arm/samsung/exynos_platform.c:1.14 src/sys/arch/arm/samsung/exynos_platform.c:1.15 --- src/sys/arch/arm/samsung/exynos_platform.c:1.14 Wed Aug 22 07:43:02 2018 +++ src/sys/arch/arm/samsung/exynos_platform.c Tue Sep 11 10:06:53 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: exynos_platform.c,v 1.14 2018/08/22 07:43:02 skrll Exp $ */ +/* $NetBSD: exynos_platform.c,v 1.15 2018/09/11 10:06:53 jmcneill Exp $ */ /*- * Copyright (c) 2017 Jared D. McNeill @@ -34,7 +34,7 @@ #include "ukbd.h" #include -__KERNEL_RCSID(0, "$NetBSD: exynos_platform.c,v 1.14 2018/08/22 07:43:02 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: exynos_platform.c,v 1.15 2018/09/11 10:06:53 jmcneill Exp $"); #include #include @@ -65,11 +65,73 @@ void exynos_platform_early_putchar(char) #define EXYNOS_IOPHYSTOVIRT(a) \ ((vaddr_t)(((a) - EXYNOS_CORE_PBASE) + EXYNOS_CORE_VBASE)) +#define EXYNOS5800_PMU_BASE 0x1004 +#define EXYNOS5800_PMU_SIZE 0x2 +#define EXYNOS5800_PMU_CORE_CONFIG(n) (0x2000 + 0x80 * (n)) +#define EXYNOS5800_PMU_CORE_STATUS(n) (0x2004 + 0x80 * (n)) +#define EXYNOS5800_PMU_CORE_POWER_EN 0x3 +#define EXYNOS5800_SYSRAM_BASE 0x0207301c +#define EXYNOS5800_SYSRAM_SIZE 0x4 + +static void +exynos5800_mp_bootstrap(void) +{ +#if defined(MULTIPROCESSOR) + extern void cortex_mpstart(void); + bus_space_tag_t bst = &armv7_generic_bs_tag; + bus_space_handle_t pmu_bsh, sysram_bsh; + uint32_t val, started = 0; + int n; + + arm_cpu_max = 1 + __SHIFTOUT(armreg_l2ctrl_read(), L2CTRL_NUMCPU); + + bus_space_map(bst, EXYNOS5800_PMU_BASE, EXYNOS5800_PMU_SIZE, 0, &pmu_bsh); + bus_space_map(bst, EXYNOS5800_SYSRAM_BASE, EXYNOS5800_SYSRAM_SIZE, 0, &sysram_bsh); + + bus_space_write_4(bst, sysram_bsh, 0, (uint32_t)cortex_mpstart); + bus_space_barrier(bst, sysram_bsh, 0, 4, BUS_SPACE_BARRIER_READ | BUS_SPACE_BARRIER_WRITE); + + for (n = 1; n < arm_cpu_max; n++) { + bus_space_write_4(bst, pmu_bsh, EXYNOS5800_PMU_CORE_CONFIG(n), + EXYNOS5800_PMU_CORE_POWER_EN); + for (u_int i = 0x0100; i > 0; i--) { + val = bus_space_read_4(bst, pmu_bsh, EXYNOS5800_PMU_CORE_STATUS(n)); + if ((val & EXYNOS5800_PMU_CORE_POWER_EN) == EXYNOS5800_PMU_CORE_POWER_EN) { +started |= __BIT(n); +break; + } + } + } + + for (u_int i = 0x1000; i > 0; i--) { + arm_dmb(); + if (arm_cpu_hatched == started) + break; + } + + bus_space_unmap(bst, sysram_bsh, EXYNOS5800_SYSRAM_SIZE); + bus_space_unmap(bst, pmu_bsh, EXYNOS5800_PMU_SIZE); +#endif +} + +static struct of_compat_data mp_compat_data[] = { + { "samsung,exynos5800", (uintptr_t)exynos5800_mp_bootstrap }, + { NULL } +}; + static void exynos_platform_bootstrap(void) { exynos_bootstrap(EXYNOS_CORE_VBASE); + + void (*mp_bootstrap)(void) = NULL; + const struct of_compat_data *cd = of_search_compatible(OF_finddevice("/"), mp_compat_data); + if (cd) + mp_bootstrap = (void (*)(void))cd->data; + + if (mp_bootstrap) + mp_bootstrap(); } static void @@ -168,6 +230,9 @@ exynos5_platform_devmap(void) DEVMAP_ENTRY(EXYNOS5_AUDIOCORE_VBASE, EXYNOS5_AUDIOCORE_PBASE, EXYNOS5_AUDIOCORE_SIZE), + DEVMAP_ENTRY(EXYNOS5_SYSRAM_VBASE, + EXYNOS5_SYSRAM_PBASE, + EXYNOS5_SYSRAM_SIZE), DEVMAP_ENTRY_END }; Index: src/sys/arch/arm/samsung/mct.c diff -u src/sys/arch/arm/samsung/mct.c:1.14 src/sys/arch/arm/samsung/mct.c:1.15 --- src/sys/arch/arm/samsung/mct.c:1.14 Mon Jul 2 12:49:37 2018 +++ src/sys/arch/arm/samsung/mct.c Tue Sep 11 10:06:53 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: mct.c,v 1.14 2018/07/02 12:49:37 jmcneill Exp $ */ +/* $NetBSD: mct.c,v 1.15 2018/09/11 10:06:53 jmcneill Exp $ */ /*- * Copyright (c) 2014-2018 The NetBSD Foundation, Inc. @@ -29,9 +29,12 @@ * POSSIBILITY OF SUCH DAMAGE. */ +#include "opt_arm_timer.h" +#include "opt_multiprocessor.h" + #include -__KERNEL_RCSID(1, "$NetBSD: mct.c,v 1.14 2018/07/02 12:49:37 jmcneill Exp $"); +__KERNEL_RCSID(1, "$NetBSD: mct.c,v 1.15 2018/09/11 10:06:53 jmcneill Exp $"); #include #include @@ -53,6 +56,15 @@ __KERNEL_RCSID(1, "$NetBSD: mct.c,v 1.14 #include #include +#if defined(MULTIPROCESSOR) +#if !defined(__HAVE_GENERIC_CPU_INITCLOCKS) +#error MULTI
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Tue Sep 11 21:18:33 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32.h netbsd32_compat_09.c netbsd32_compat_12.c netbsd32_compat_13.c netbsd32_compat_20.c netbsd32_compat_30.c netbsd32_compat_43.c netbsd32_compat_50.c netbsd32_compat_60.c netbsd32_exec.h netbsd32_ipc.c netbsd32_mqueue.c netbsd32_nfssvc.c netbsd32_ptrace.c Log Message: Put the ``extern struct emul'' into the netbsd32_netbsd.h header so it doesn't have to be separately declared in each source file. Thanks mrg@ To generate a diff of this commit: cvs rdiff -u -r1.116.2.3 -r1.116.2.4 src/sys/compat/netbsd32/netbsd32.h cvs rdiff -u -r1.18.86.4 -r1.18.86.5 \ src/sys/compat/netbsd32/netbsd32_compat_09.c cvs rdiff -u -r1.33.36.6 -r1.33.36.7 \ src/sys/compat/netbsd32/netbsd32_compat_12.c cvs rdiff -u -r1.26.28.5 -r1.26.28.6 \ src/sys/compat/netbsd32/netbsd32_compat_13.c cvs rdiff -u -r1.36.10.7 -r1.36.10.8 \ src/sys/compat/netbsd32/netbsd32_compat_20.c cvs rdiff -u -r1.31.16.6 -r1.31.16.7 \ src/sys/compat/netbsd32/netbsd32_compat_30.c cvs rdiff -u -r1.54.14.4 -r1.54.14.5 \ src/sys/compat/netbsd32/netbsd32_compat_43.c cvs rdiff -u -r1.32.16.5 -r1.32.16.6 \ src/sys/compat/netbsd32/netbsd32_compat_50.c cvs rdiff -u -r1.3.2.5 -r1.3.2.6 src/sys/compat/netbsd32/netbsd32_compat_60.c cvs rdiff -u -r1.33 -r1.33.12.1 src/sys/compat/netbsd32/netbsd32_exec.h cvs rdiff -u -r1.18.16.2 -r1.18.16.3 src/sys/compat/netbsd32/netbsd32_ipc.c cvs rdiff -u -r1.6.18.2 -r1.6.18.3 src/sys/compat/netbsd32/netbsd32_mqueue.c cvs rdiff -u -r1.5 -r1.5.16.1 src/sys/compat/netbsd32/netbsd32_nfssvc.c cvs rdiff -u -r1.5 -r1.5.2.1 src/sys/compat/netbsd32/netbsd32_ptrace.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/netbsd32.h diff -u src/sys/compat/netbsd32/netbsd32.h:1.116.2.3 src/sys/compat/netbsd32/netbsd32.h:1.116.2.4 --- src/sys/compat/netbsd32/netbsd32.h:1.116.2.3 Thu Sep 6 06:55:46 2018 +++ src/sys/compat/netbsd32/netbsd32.h Tue Sep 11 21:18:32 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32.h,v 1.116.2.3 2018/09/06 06:55:46 pgoyette Exp $ */ +/* $NetBSD: netbsd32.h,v 1.116.2.4 2018/09/11 21:18:32 pgoyette Exp $ */ /* * Copyright (c) 1998, 2001, 2008, 2015 Matthew R. Green @@ -1164,4 +1164,12 @@ struct iovec *netbsd32_get_iov(struct ne #ifdef SYSCTL_SETUP_PROTO SYSCTL_SETUP_PROTO(netbsd32_sysctl_emul_setup); #endif /* SYSCTL_SETUP_PROTO */ + +/* + * Finally, declare emul_netbsd32 as this is needed in lots of + * places when calling syscall_{,dis}establish() + */ + +extern struct emul emul_netbsd32; + #endif /* _COMPAT_NETBSD32_NETBSD32_H_ */ Index: src/sys/compat/netbsd32/netbsd32_compat_09.c diff -u src/sys/compat/netbsd32/netbsd32_compat_09.c:1.18.86.4 src/sys/compat/netbsd32/netbsd32_compat_09.c:1.18.86.5 --- src/sys/compat/netbsd32/netbsd32_compat_09.c:1.18.86.4 Tue Sep 11 05:00:42 2018 +++ src/sys/compat/netbsd32/netbsd32_compat_09.c Tue Sep 11 21:18:32 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_compat_09.c,v 1.18.86.4 2018/09/11 05:00:42 pgoyette Exp $ */ +/* $NetBSD: netbsd32_compat_09.c,v 1.18.86.5 2018/09/11 21:18:32 pgoyette Exp $ */ /* * Copyright (c) 1998 Matthew R. Green @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_09.c,v 1.18.86.4 2018/09/11 05:00:42 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_09.c,v 1.18.86.5 2018/09/11 21:18:32 pgoyette Exp $"); #include #include @@ -46,8 +46,6 @@ __KERNEL_RCSID(0, "$NetBSD: netbsd32_com #include #include -extern struct emul emul_netbsd32; - int compat_09_netbsd32_ogetdomainname(struct lwp *l, const struct compat_09_netbsd32_ogetdomainname_args *uap, register_t *retval) { Index: src/sys/compat/netbsd32/netbsd32_compat_12.c diff -u src/sys/compat/netbsd32/netbsd32_compat_12.c:1.33.36.6 src/sys/compat/netbsd32/netbsd32_compat_12.c:1.33.36.7 --- src/sys/compat/netbsd32/netbsd32_compat_12.c:1.33.36.6 Tue Sep 11 05:00:42 2018 +++ src/sys/compat/netbsd32/netbsd32_compat_12.c Tue Sep 11 21:18:32 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_compat_12.c,v 1.33.36.6 2018/09/11 05:00:42 pgoyette Exp $ */ +/* $NetBSD: netbsd32_compat_12.c,v 1.33.36.7 2018/09/11 21:18:32 pgoyette Exp $ */ /* * Copyright (c) 1998, 2001 Matthew R. Green @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_12.c,v 1.33.36.6 2018/09/11 05:00:42 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_12.c,v 1.33.36.7 2018/09/11 21:18:32 pgoyette Exp $"); #if defined(_KERNEL_OPT) #include "opt_compat_netbsd.h" @@ -54,8 +54,6 @@ __KERNEL_RCSID(0, "$NetBSD: netbsd32_com #include #include -extern struct emul emul_netbsd32; - static void netbsd32_stat12_to_netbsd32(struct stat12 *, struct netbsd32_stat12 *); Index: src/sys/compat/net
CVS commit: [pgoyette-compat] src/sys
Module Name:src Committed By: pgoyette Date: Tue Sep 11 23:26:21 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_compat_50.c netbsd32_mod.c src/sys/modules/compat_netbsd32 [pgoyette-compat]: Makefile src/sys/modules/compat_netbsd32_50 [pgoyette-compat]: Makefile Log Message: Move netbsd32_rndpseudo_50.c out of the main netbsd32 module and into the module that handles netbsd32_50 compatability. To generate a diff of this commit: cvs rdiff -u -r1.32.16.6 -r1.32.16.7 \ src/sys/compat/netbsd32/netbsd32_compat_50.c cvs rdiff -u -r1.13.16.5 -r1.13.16.6 src/sys/compat/netbsd32/netbsd32_mod.c cvs rdiff -u -r1.20.12.6 -r1.20.12.7 src/sys/modules/compat_netbsd32/Makefile cvs rdiff -u -r1.1.2.2 -r1.1.2.3 src/sys/modules/compat_netbsd32_50/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/compat/netbsd32/netbsd32_compat_50.c diff -u src/sys/compat/netbsd32/netbsd32_compat_50.c:1.32.16.6 src/sys/compat/netbsd32/netbsd32_compat_50.c:1.32.16.7 --- src/sys/compat/netbsd32/netbsd32_compat_50.c:1.32.16.6 Tue Sep 11 21:18:32 2018 +++ src/sys/compat/netbsd32/netbsd32_compat_50.c Tue Sep 11 23:26:21 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_compat_50.c,v 1.32.16.6 2018/09/11 21:18:32 pgoyette Exp $ */ +/* $NetBSD: netbsd32_compat_50.c,v 1.32.16.7 2018/09/11 23:26:21 pgoyette Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -36,7 +36,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_50.c,v 1.32.16.6 2018/09/11 21:18:32 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_50.c,v 1.32.16.7 2018/09/11 23:26:21 pgoyette Exp $"); #if defined(_KERNEL_OPT) #include "opt_compat_netbsd.h" @@ -65,6 +65,7 @@ __KERNEL_RCSID(0, "$NetBSD: netbsd32_com #include #include #include +#include #include #include @@ -72,6 +73,7 @@ __KERNEL_RCSID(0, "$NetBSD: netbsd32_com #include #include #include +#include #if defined(COMPAT_50) @@ -992,15 +994,24 @@ MODULE(MODULE_CLASS_EXEC, compat_netbsd3 static int compat_netbsd32_50_modcmd(modcmd_t cmd, void *arg) { + int ret; switch (cmd) { case MODULE_CMD_INIT: -return syscall_establish(&emul_netbsd32, + vec_compat32_50_rnd_ioctl = compat32_50_rnd_ioctl; +ret = syscall_establish(&emul_netbsd32, compat_netbsd32_50_syscalls); + if (ret) + vec_compat32_50_rnd_ioctl = (void *)enosys; + return ret; case MODULE_CMD_FINI: -return syscall_disestablish(&emul_netbsd32, + vec_compat32_50_rnd_ioctl = (void *)enosys; +ret = syscall_disestablish(&emul_netbsd32, compat_netbsd32_50_syscalls); + if (ret) + vec_compat32_50_rnd_ioctl = compat32_50_rnd_ioctl; + return ret; default: return ENOTTY; Index: src/sys/compat/netbsd32/netbsd32_mod.c diff -u src/sys/compat/netbsd32/netbsd32_mod.c:1.13.16.5 src/sys/compat/netbsd32/netbsd32_mod.c:1.13.16.6 --- src/sys/compat/netbsd32/netbsd32_mod.c:1.13.16.5 Tue Sep 11 04:53:42 2018 +++ src/sys/compat/netbsd32/netbsd32_mod.c Tue Sep 11 23:26:21 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_mod.c,v 1.13.16.5 2018/09/11 04:53:42 pgoyette Exp $ */ +/* $NetBSD: netbsd32_mod.c,v 1.13.16.6 2018/09/11 23:26:21 pgoyette Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_mod.c,v 1.13.16.5 2018/09/11 04:53:42 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_mod.c,v 1.13.16.6 2018/09/11 23:26:21 pgoyette Exp $"); #ifdef _KERNEL_OPT #include "opt_execfmt.h" @@ -44,11 +44,9 @@ __KERNEL_RCSID(0, "$NetBSD: netbsd32_mod #include #include #include -#include #include #include -#include # define DEPS1 "compat_09,ksem" @@ -114,21 +112,20 @@ compat_netbsd32_modcmd(modcmd_t cmd, voi netbsd32_sysctl_init(); error = exec_add(netbsd32_execsw, __arraycount(netbsd32_execsw)); - vec_compat32_50_rnd_ioctl = compat32_50_rnd_ioctl; vec_compat32_80_modctl = compat32_80_modctl_compat_stub; if (error != 0) { - vec_compat32_50_rnd_ioctl = (void *)enosys; vec_compat32_80_modctl = (void *)enosys; netbsd32_sysctl_fini(); } return error; case MODULE_CMD_FINI: - vec_compat32_50_rnd_ioctl = (void *)enosys; vec_compat32_80_modctl = (void *)enosys; error = exec_remove(netbsd32_execsw, __arraycount(netbsd32_execsw)); - if (error == 0) + if (error) + vec_compat32_80_modctl = compat32_80_modctl_compat_stub; + else netbsd32_sysctl_fini(); return error; Index: src/sys/modules/compat_netbsd32/Makefile diff -u src/sys/modules/compat_netbsd32/Makefile:1.20.12.6 src/sys/modules/compat_netbsd32/Makefile:1.20.12.7 --- src/sys/modules/compat_netbsd32/Makefile:1.20.12.6 Tue Sep 11 07:01:10 2018 +++ src/sys/modules/compat_netbsd32/Makefile Tue Sep 11 23:26:21
CVS commit: [pgoyette-compat] src/sys
Module Name:src Committed By: pgoyette Date: Tue Sep 11 23:58:47 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_compat_30.c netbsd32_compat_50.c netbsd32_time.c syscalls.master src/sys/modules/compat_netbsd32 [pgoyette-compat]: Makefile src/sys/modules/compat_netbsd32_30 [pgoyette-compat]: Makefile src/sys/modules/compat_netbsd32_50 [pgoyette-compat]: Makefile Log Message: Move the NTP compat_30 and compat_50 routines into the version-specific modules. To generate a diff of this commit: cvs rdiff -u -r1.31.16.7 -r1.31.16.8 \ src/sys/compat/netbsd32/netbsd32_compat_30.c cvs rdiff -u -r1.32.16.7 -r1.32.16.8 \ src/sys/compat/netbsd32/netbsd32_compat_50.c cvs rdiff -u -r1.49 -r1.49.12.1 src/sys/compat/netbsd32/netbsd32_time.c cvs rdiff -u -r1.120.2.10 -r1.120.2.11 \ src/sys/compat/netbsd32/syscalls.master cvs rdiff -u -r1.20.12.7 -r1.20.12.8 src/sys/modules/compat_netbsd32/Makefile cvs rdiff -u -r1.1.2.2 -r1.1.2.3 src/sys/modules/compat_netbsd32_30/Makefile cvs rdiff -u -r1.1.2.3 -r1.1.2.4 src/sys/modules/compat_netbsd32_50/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/compat/netbsd32/netbsd32_compat_30.c diff -u src/sys/compat/netbsd32/netbsd32_compat_30.c:1.31.16.7 src/sys/compat/netbsd32/netbsd32_compat_30.c:1.31.16.8 --- src/sys/compat/netbsd32/netbsd32_compat_30.c:1.31.16.7 Tue Sep 11 21:18:32 2018 +++ src/sys/compat/netbsd32/netbsd32_compat_30.c Tue Sep 11 23:58:46 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_compat_30.c,v 1.31.16.7 2018/09/11 21:18:32 pgoyette Exp $ */ +/* $NetBSD: netbsd32_compat_30.c,v 1.31.16.8 2018/09/11 23:58:46 pgoyette Exp $ */ /* * Copyright (c) 1998, 2001 Matthew R. Green @@ -27,7 +27,11 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_30.c,v 1.31.16.7 2018/09/11 21:18:32 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_30.c,v 1.31.16.8 2018/09/11 23:58:46 pgoyette Exp $"); + +#if defined(_KERNEL_OPT) +#include +#endif #include #include @@ -297,6 +301,34 @@ compat_30_netbsd32_fhopen(struct lwp *l, return (compat_30_sys_fhopen(l, &ua, retval)); } +#ifdef NTP +int +compat_30_netbsd32_ntp_gettime(struct lwp *l, const struct compat_30_netbsd32_ntp_gettime_args *uap, register_t *retval) +{ + /* { + syscallarg(netbsd32_ntptimevalp_t) ntvp; + } */ + struct netbsd32_ntptimeval30 ntv32; + struct ntptimeval ntv; + int error = 0; + + if (SCARG_P32(uap, ntvp)) { + ntp_gettime(&ntv); + + ntv32.time.tv_sec = ntv.time.tv_sec; + ntv32.time.tv_usec = ntv.time.tv_nsec / 1000; + ntv32.maxerror = (netbsd32_long)ntv.maxerror; + ntv32.esterror = (netbsd32_long)ntv.esterror; + error = copyout(&ntv32, SCARG_P32(uap, ntvp), sizeof(ntv32)); + } + if (!error) { + *retval = ntp_timestatus(); + } + + return (error); +} +#endif + static struct syscall_package compat_netbsd32_30_syscalls[] = { { NETBSD32_SYS_compat_30_netbsd32_getdents, 0, (sy_call_t *)compat_30_netbsd32_getdents }, @@ -318,6 +350,8 @@ static struct syscall_package compat_net (sy_call_t *)compat_30_netbsd32___fhstat30 }, { NETBSD32_SYS_compat_30_netbsd32_fhopen, 0, (sy_call_t *)compat_30_netbsd32_fhopen }, + { NETBSD32_SYS_compat_30_netbsd32_ntp_gettime, 0, + (sy_call_t *)compat_30_netbsd32_ntp_gettime }, { 0, 0, NULL } }; Index: src/sys/compat/netbsd32/netbsd32_compat_50.c diff -u src/sys/compat/netbsd32/netbsd32_compat_50.c:1.32.16.7 src/sys/compat/netbsd32/netbsd32_compat_50.c:1.32.16.8 --- src/sys/compat/netbsd32/netbsd32_compat_50.c:1.32.16.7 Tue Sep 11 23:26:21 2018 +++ src/sys/compat/netbsd32/netbsd32_compat_50.c Tue Sep 11 23:58:46 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_compat_50.c,v 1.32.16.7 2018/09/11 23:26:21 pgoyette Exp $ */ +/* $NetBSD: netbsd32_compat_50.c,v 1.32.16.8 2018/09/11 23:58:46 pgoyette Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -36,12 +36,14 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_50.c,v 1.32.16.7 2018/09/11 23:26:21 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_50.c,v 1.32.16.8 2018/09/11 23:58:46 pgoyette Exp $"); #if defined(_KERNEL_OPT) #include "opt_compat_netbsd.h" +#include #endif + #include #include #include @@ -929,6 +931,36 @@ compat_50_netbsd32_quotactl(struct lwp * return (compat_50_sys_quotactl(l, &ua, retval)); } +int +compat_50_netbsd32_ntp_gettime(struct lwp *l, +const struct compat_50_netbsd32_ntp_gettime_args *uap, register_t *retval) +{ + /* { + syscallarg(netbsd32_ntptimeval50p_t) ntvp; + } */ + struct netbsd32_ntptimeval50 ntv32; + struct ntptimeval ntv; + int error = 0; + + if (SCARG_P32(uap, ntvp)) { + ntp_gettime(&ntv); + + ntv32.time.tv_sec = (int32_t)ntv.time.tv_sec; + ntv32.time.tv_nsec = ntv.time.tv_nsec; + ntv32.maxerror = (netbsd32_long)ntv.maxerror; + ntv
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Wed Sep 12 00:00:32 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_syscall.h netbsd32_syscallargs.h netbsd32_syscalls.c netbsd32_syscalls_autoload.c netbsd32_sysent.c netbsd32_systrace_args.c Log Message: Regen with updated module information for ntp 30 and 50 compat calls To generate a diff of this commit: cvs rdiff -u -r1.134.2.7 -r1.134.2.8 \ src/sys/compat/netbsd32/netbsd32_syscall.h cvs rdiff -u -r1.134.2.6 -r1.134.2.7 \ src/sys/compat/netbsd32/netbsd32_syscallargs.h cvs rdiff -u -r1.132.2.7 -r1.132.2.8 \ src/sys/compat/netbsd32/netbsd32_syscalls.c cvs rdiff -u -r1.13.2.6 -r1.13.2.7 \ src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c cvs rdiff -u -r1.132.2.6 -r1.132.2.7 \ src/sys/compat/netbsd32/netbsd32_sysent.c cvs rdiff -u -r1.24.2.6 -r1.24.2.7 \ src/sys/compat/netbsd32/netbsd32_systrace_args.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/netbsd32_syscall.h diff -u src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.7 src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.8 --- src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.7 Tue Sep 11 08:36:29 2018 +++ src/sys/compat/netbsd32/netbsd32_syscall.h Wed Sep 12 00:00:31 2018 @@ -1,10 +1,10 @@ -/* $NetBSD: netbsd32_syscall.h,v 1.134.2.7 2018/09/11 08:36:29 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscall.h,v 1.134.2.8 2018/09/12 00:00:31 pgoyette Exp $ */ /* * System call numbers. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.10 2018/09/11 08:35:27 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.11 2018/09/11 23:58:46 pgoyette Exp */ #ifndef _NETBSD32_SYS_SYSCALL_H_ Index: src/sys/compat/netbsd32/netbsd32_syscallargs.h diff -u src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.6 src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.7 --- src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.6 Tue Sep 11 08:36:29 2018 +++ src/sys/compat/netbsd32/netbsd32_syscallargs.h Wed Sep 12 00:00:31 2018 @@ -1,10 +1,10 @@ -/* $NetBSD: netbsd32_syscallargs.h,v 1.134.2.6 2018/09/11 08:36:29 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscallargs.h,v 1.134.2.7 2018/09/12 00:00:31 pgoyette Exp $ */ /* * System call argument lists. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.10 2018/09/11 08:35:27 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.11 2018/09/11 23:58:46 pgoyette Exp */ #ifndef _NETBSD32_SYS_SYSCALLARGS_H_ Index: src/sys/compat/netbsd32/netbsd32_syscalls.c diff -u src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.7 src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.8 --- src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.7 Tue Sep 11 08:36:29 2018 +++ src/sys/compat/netbsd32/netbsd32_syscalls.c Wed Sep 12 00:00:31 2018 @@ -1,14 +1,14 @@ -/* $NetBSD: netbsd32_syscalls.c,v 1.132.2.7 2018/09/11 08:36:29 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscalls.c,v 1.132.2.8 2018/09/12 00:00:31 pgoyette Exp $ */ /* * System call names. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.10 2018/09/11 08:35:27 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.11 2018/09/11 23:58:46 pgoyette Exp */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.132.2.7 2018/09/11 08:36:29 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.132.2.8 2018/09/12 00:00:31 pgoyette Exp $"); #if defined(_KERNEL_OPT) #if defined(_KERNEL_OPT) Index: src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c diff -u src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c:1.13.2.6 src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c:1.13.2.7 --- src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c:1.13.2.6 Tue Sep 11 08:36:29 2018 +++ src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c Wed Sep 12 00:00:31 2018 @@ -1,14 +1,14 @@ -/* $NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.6 2018/09/11 08:36:29 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.7 2018/09/12 00:00:31 pgoyette Exp $ */ /* * System call autoload table. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.10 2018/09/11 08:35:27 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.11 2018/09/11 23:58:46 pgoyette Exp */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.6 2018/09/11 08:36:29 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.7 2018/09/12 00:00:31 pgoyette Exp $"); #include static struct sc_autoload netbsd32_syscalls_autoload[] = { @@ -69,6 +69,7 @@ static struct sc_autoload netbsd32_
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Wed Sep 12 00:20:53 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: syscalls.master Log Message: The netbsd32 40 mount code belongs in a netbsd32 40 module To generate a diff of this commit: cvs rdiff -u -r1.120.2.11 -r1.120.2.12 \ src/sys/compat/netbsd32/syscalls.master Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/syscalls.master diff -u src/sys/compat/netbsd32/syscalls.master:1.120.2.11 src/sys/compat/netbsd32/syscalls.master:1.120.2.12 --- src/sys/compat/netbsd32/syscalls.master:1.120.2.11 Tue Sep 11 23:58:46 2018 +++ src/sys/compat/netbsd32/syscalls.master Wed Sep 12 00:20:53 2018 @@ -1,4 +1,4 @@ - $NetBSD: syscalls.master,v 1.120.2.11 2018/09/11 23:58:46 pgoyette Exp $ + $NetBSD: syscalls.master,v 1.120.2.12 2018/09/12 00:20:53 pgoyette Exp $ ; from: NetBSD: syscalls.master,v 1.81 1998/07/05 08:49:50 jonathan Exp ; @(#)syscalls.master 8.2 (Berkeley) 1/13/94 @@ -96,7 +96,8 @@ { netbsd32_long|netbsd32||olseek(int fd, \ netbsd32_long offset, int whence); } 20 NOARGS { pid_t|sys||getpid(void); } -21 STD { int|netbsd32||mount(netbsd32_charp type, \ +21 COMPAT_40 MODULAR compat_netbsd32_40 \ + { int|netbsd32||mount(netbsd32_charp type, \ netbsd32_charp path, int flags, \ netbsd32_voidp data); } 22 STD { int|netbsd32||unmount(netbsd32_charp path, \
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Wed Sep 12 00:22:26 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_syscall.h netbsd32_syscallargs.h netbsd32_syscalls.c netbsd32_syscalls_autoload.c netbsd32_sysent.c netbsd32_systrace_args.c Log Message: regen To generate a diff of this commit: cvs rdiff -u -r1.134.2.8 -r1.134.2.9 \ src/sys/compat/netbsd32/netbsd32_syscall.h cvs rdiff -u -r1.134.2.7 -r1.134.2.8 \ src/sys/compat/netbsd32/netbsd32_syscallargs.h cvs rdiff -u -r1.132.2.8 -r1.132.2.9 \ src/sys/compat/netbsd32/netbsd32_syscalls.c cvs rdiff -u -r1.13.2.7 -r1.13.2.8 \ src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c cvs rdiff -u -r1.132.2.7 -r1.132.2.8 \ src/sys/compat/netbsd32/netbsd32_sysent.c cvs rdiff -u -r1.24.2.7 -r1.24.2.8 \ src/sys/compat/netbsd32/netbsd32_systrace_args.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/netbsd32_syscall.h diff -u src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.8 src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.9 --- src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.8 Wed Sep 12 00:00:31 2018 +++ src/sys/compat/netbsd32/netbsd32_syscall.h Wed Sep 12 00:22:26 2018 @@ -1,10 +1,10 @@ -/* $NetBSD: netbsd32_syscall.h,v 1.134.2.8 2018/09/12 00:00:31 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscall.h,v 1.134.2.9 2018/09/12 00:22:26 pgoyette Exp $ */ /* * System call numbers. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.11 2018/09/11 23:58:46 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.12 2018/09/12 00:20:53 pgoyette Exp */ #ifndef _NETBSD32_SYS_SYSCALL_H_ @@ -73,8 +73,8 @@ /* syscall: "getpid" ret: "pid_t" args: */ #define NETBSD32_SYS_getpid 20 -/* syscall: "netbsd32_mount" ret: "int" args: "netbsd32_charp" "netbsd32_charp" "int" "netbsd32_voidp" */ -#define NETBSD32_SYS_netbsd32_mount 21 +/* syscall: "compat_40_netbsd32_mount" ret: "int" args: "netbsd32_charp" "netbsd32_charp" "int" "netbsd32_voidp" */ +#define NETBSD32_SYS_compat_40_netbsd32_mount 21 /* syscall: "netbsd32_unmount" ret: "int" args: "netbsd32_charp" "int" */ #define NETBSD32_SYS_netbsd32_unmount 22 Index: src/sys/compat/netbsd32/netbsd32_syscallargs.h diff -u src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.7 src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.8 --- src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.7 Wed Sep 12 00:00:31 2018 +++ src/sys/compat/netbsd32/netbsd32_syscallargs.h Wed Sep 12 00:22:26 2018 @@ -1,10 +1,10 @@ -/* $NetBSD: netbsd32_syscallargs.h,v 1.134.2.7 2018/09/12 00:00:31 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscallargs.h,v 1.134.2.8 2018/09/12 00:22:26 pgoyette Exp $ */ /* * System call argument lists. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.11 2018/09/11 23:58:46 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.12 2018/09/12 00:20:53 pgoyette Exp */ #ifndef _NETBSD32_SYS_SYSCALLARGS_H_ @@ -144,13 +144,13 @@ struct compat_43_netbsd32_olseek_args { }; check_syscall_args(compat_43_netbsd32_olseek) -struct netbsd32_mount_args { +struct compat_40_netbsd32_mount_args { syscallarg(netbsd32_charp) type; syscallarg(netbsd32_charp) path; syscallarg(int) flags; syscallarg(netbsd32_voidp) data; }; -check_syscall_args(netbsd32_mount) +check_syscall_args(compat_40_netbsd32_mount) struct netbsd32_unmount_args { syscallarg(netbsd32_charp) path; @@ -2663,7 +2663,7 @@ int compat_43_netbsd32_olseek(struct lwp int sys_getpid(struct lwp *, const void *, register_t *); -int netbsd32_mount(struct lwp *, const struct netbsd32_mount_args *, register_t *); +int compat_40_netbsd32_mount(struct lwp *, const struct compat_40_netbsd32_mount_args *, register_t *); int netbsd32_unmount(struct lwp *, const struct netbsd32_unmount_args *, register_t *); Index: src/sys/compat/netbsd32/netbsd32_syscalls.c diff -u src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.8 src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.9 --- src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.8 Wed Sep 12 00:00:31 2018 +++ src/sys/compat/netbsd32/netbsd32_syscalls.c Wed Sep 12 00:22:26 2018 @@ -1,14 +1,14 @@ -/* $NetBSD: netbsd32_syscalls.c,v 1.132.2.8 2018/09/12 00:00:31 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscalls.c,v 1.132.2.9 2018/09/12 00:22:26 pgoyette Exp $ */ /* * System call names. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.11 2018/09/11 23:58:46 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.12 2018/09/12 00:20:53 pgoyette Exp */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.132.2.8 2018/09/12 00:00:31 pgoyette Exp $"); +__K
CVS commit: [pgoyette-compat] src/sys
Module Name:src Committed By: pgoyette Date: Wed Sep 12 01:05:21 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_netbsd.c src/sys/modules [pgoyette-compat]: Makefile Added Files: src/sys/modules/compat_netbsd32_40 [pgoyette-compat]: Makefile Log Message: Add a netbsd32_compat40 module, move the 4.0 mount stuff there. To generate a diff of this commit: cvs rdiff -u -r1.214.2.3 -r1.214.2.4 \ src/sys/compat/netbsd32/netbsd32_netbsd.c cvs rdiff -u -r1.202.2.29 -r1.202.2.30 src/sys/modules/Makefile cvs rdiff -u -r0 -r1.1.2.1 src/sys/modules/compat_netbsd32_40/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/compat/netbsd32/netbsd32_netbsd.c diff -u src/sys/compat/netbsd32/netbsd32_netbsd.c:1.214.2.3 src/sys/compat/netbsd32/netbsd32_netbsd.c:1.214.2.4 --- src/sys/compat/netbsd32/netbsd32_netbsd.c:1.214.2.3 Thu Sep 6 06:55:46 2018 +++ src/sys/compat/netbsd32/netbsd32_netbsd.c Wed Sep 12 01:05:21 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_netbsd.c,v 1.214.2.3 2018/09/06 06:55:46 pgoyette Exp $ */ +/* $NetBSD: netbsd32_netbsd.c,v 1.214.2.4 2018/09/12 01:05:21 pgoyette Exp $ */ /* * Copyright (c) 1998, 2001, 2008 Matthew R. Green @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_netbsd.c,v 1.214.2.3 2018/09/06 06:55:46 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_netbsd.c,v 1.214.2.4 2018/09/12 01:05:21 pgoyette Exp $"); #if defined(_KERNEL_OPT) #include "opt_ddb.h" @@ -357,28 +357,6 @@ netbsd32_break(struct lwp *l, const stru } int -netbsd32_mount(struct lwp *l, const struct netbsd32_mount_args *uap, register_t *retval) -{ -#ifdef COMPAT_40 - /* { - syscallarg(const netbsd32_charp) type; - syscallarg(const netbsd32_charp) path; - syscallarg(int) flags; - syscallarg(netbsd32_voidp) data; - } */ - struct compat_40_sys_mount_args ua; - - NETBSD32TOP_UAP(type, const char); - NETBSD32TOP_UAP(path, const char); - NETBSD32TO64_UAP(flags); - NETBSD32TOP_UAP(data, void); - return (compat_40_sys_mount(l, &ua, retval)); -#else - return ENOSYS; -#endif -} - -int netbsd32_unmount(struct lwp *l, const struct netbsd32_unmount_args *uap, register_t *retval) { /* { Index: src/sys/modules/Makefile diff -u src/sys/modules/Makefile:1.202.2.29 src/sys/modules/Makefile:1.202.2.30 --- src/sys/modules/Makefile:1.202.2.29 Tue Sep 11 07:01:10 2018 +++ src/sys/modules/Makefile Wed Sep 12 01:05:20 2018 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.202.2.29 2018/09/11 07:01:10 pgoyette Exp $ +# $NetBSD: Makefile,v 1.202.2.30 2018/09/12 01:05:20 pgoyette Exp $ .include @@ -269,8 +269,9 @@ SUBDIR+= wmimsi SUBDIR+= compat_netbsd32 SUBDIR+= compat_netbsd32_09 compat_netbsd32_12 SUBDIR+= compat_netbsd32_13 compat_netbsd32_20 -SUBDIR+= compat_netbsd32_30 compat_netbsd32_50 -SUBDIR+= compat_netbsd32_60 compat_netbsd32_80 +SUBDIR+= compat_netbsd32_30 compat_netbsd32_40 +SUBDIR+= compat_netbsd32_50 compat_netbsd32_60 +SUBDIR+= compat_netbsd32_80 SUBDIR+= compat_netbsd32_43 SUBDIR+= compat_netbsd32_mqueue SUBDIR+= compat_netbsd32_nfssrv @@ -283,8 +284,9 @@ SUBDIR+= compat_linux32 SUBDIR+= compat_netbsd32 SUBDIR+= compat_netbsd32_09 compat_netbsd32_12 SUBDIR+= compat_netbsd32_13 compat_netbsd32_20 -SUBDIR+= compat_netbsd32_30 compat_netbsd32_50 -SUBDIR+= compat_netbsd32_60 compat_netbsd32_80 +SUBDIR+= compat_netbsd32_30 compat_netbsd32_40 +SUBDIR+= compat_netbsd32_50 compat_netbsd32_60 +SUBDIR+= compat_netbsd32_80 SUBDIR+= compat_netbsd32_43 SUBDIR+= compat_netbsd32_mqueue SUBDIR+= compat_netbsd32_nfssrv Added files: Index: src/sys/modules/compat_netbsd32_40/Makefile diff -u /dev/null src/sys/modules/compat_netbsd32_40/Makefile:1.1.2.1 --- /dev/null Wed Sep 12 01:05:21 2018 +++ src/sys/modules/compat_netbsd32_40/Makefile Wed Sep 12 01:05:21 2018 @@ -0,0 +1,14 @@ +# $NetBSD: Makefile,v 1.1.2.1 2018/09/12 01:05:21 pgoyette Exp $ + +.include "../Makefile.inc" + +.PATH: ${S}/compat/netbsd32 + +KMOD= compat_netbsd32_40 + +CPPFLAGS+= -DCOMPAT_NETBSD32 +CPPFLAGS+= -DCOMPAT_40 -DCOMPAT_50 -DCOMPAT_60 -DCOMPAT_70 -DCOMPAT_80 + +SRCS+= netbsd32_compat_40.c + +.include
CVS commit: [pgoyette-compat] src/sys
Module Name:src Committed By: pgoyette Date: Wed Sep 12 01:26:40 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: files.netbsd32 netbsd32_netbsd.c src/sys/modules [pgoyette-compat]: Makefile Added Files: src/sys/modules/compat_netbsd32_16 [pgoyette-compat]: Makefile Log Message: Add a compat_netbsd32_16 to handle the sigcode stuff. To generate a diff of this commit: cvs rdiff -u -r1.39.14.2 -r1.39.14.3 src/sys/compat/netbsd32/files.netbsd32 cvs rdiff -u -r1.214.2.4 -r1.214.2.5 \ src/sys/compat/netbsd32/netbsd32_netbsd.c cvs rdiff -u -r1.202.2.30 -r1.202.2.31 src/sys/modules/Makefile cvs rdiff -u -r0 -r1.1.2.1 src/sys/modules/compat_netbsd32_16/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/compat/netbsd32/files.netbsd32 diff -u src/sys/compat/netbsd32/files.netbsd32:1.39.14.2 src/sys/compat/netbsd32/files.netbsd32:1.39.14.3 --- src/sys/compat/netbsd32/files.netbsd32:1.39.14.2 Tue Sep 11 05:00:42 2018 +++ src/sys/compat/netbsd32/files.netbsd32 Wed Sep 12 01:26:40 2018 @@ -1,4 +1,4 @@ -# $NetBSD: files.netbsd32,v 1.39.14.2 2018/09/11 05:00:42 pgoyette Exp $ +# $NetBSD: files.netbsd32,v 1.39.14.3 2018/09/12 01:26:40 pgoyette Exp $ # # config file description for machine-independent netbsd32 compat code. # included by ports that need it. @@ -37,8 +37,10 @@ file compat/netbsd32/netbsd32_compat_10. file compat/netbsd32/netbsd32_compat_12.c compat_netbsd32 & (compat_12 | compat_sunos) file compat/netbsd32/netbsd32_compat_13.c compat_netbsd32 & compat_13 file compat/netbsd32/netbsd32_compat_14.c compat_netbsd32 & compat_14 +file compat/netbsd32/netbsd32_compat_16.c compat_netbsd32 & compat_16 file compat/netbsd32/netbsd32_compat_20.c compat_netbsd32 & compat_20 file compat/netbsd32/netbsd32_compat_30.c compat_netbsd32 & compat_30 +file compat/netbsd32/netbsd32_compat_40.c compat_netbsd32 & compat_40 file compat/netbsd32/netbsd32_compat_43.c compat_netbsd32 & (compat_43 | compat_sunos | compat_linux32) file compat/netbsd32/netbsd32_compat_50.c compat_netbsd32 & compat_50 file compat/netbsd32/netbsd32_rndpseudo_50.c compat_netbsd32 & compat_50 Index: src/sys/compat/netbsd32/netbsd32_netbsd.c diff -u src/sys/compat/netbsd32/netbsd32_netbsd.c:1.214.2.4 src/sys/compat/netbsd32/netbsd32_netbsd.c:1.214.2.5 --- src/sys/compat/netbsd32/netbsd32_netbsd.c:1.214.2.4 Wed Sep 12 01:05:21 2018 +++ src/sys/compat/netbsd32/netbsd32_netbsd.c Wed Sep 12 01:26:40 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_netbsd.c,v 1.214.2.4 2018/09/12 01:05:21 pgoyette Exp $ */ +/* $NetBSD: netbsd32_netbsd.c,v 1.214.2.5 2018/09/12 01:26:40 pgoyette Exp $ */ /* * Copyright (c) 1998, 2001, 2008 Matthew R. Green @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_netbsd.c,v 1.214.2.4 2018/09/12 01:05:21 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_netbsd.c,v 1.214.2.5 2018/09/12 01:26:40 pgoyette Exp $"); #if defined(_KERNEL_OPT) #include "opt_ddb.h" @@ -102,11 +102,6 @@ void syscall(void); #define LIMITCHECK(a, b) ((a) != RLIM_INFINITY && (a) > (b)) -#ifdef COMPAT_16 -extern char netbsd32_sigcode[], netbsd32_esigcode[]; -struct uvm_object *emul_netbsd32_object; -#endif - extern struct sysctlnode netbsd32_sysctl_root; #ifdef MODULAR @@ -134,15 +129,9 @@ struct emul emul_netbsd32 = { #endif .e_sendsig = netbsd32_sendsig, .e_trapsignal = trapsignal, -#ifdef COMPAT_16 - .e_sigcode = netbsd32_sigcode, - .e_esigcode = netbsd32_esigcode, - .e_sigobject = &emul_netbsd32_object, -#else .e_sigcode = NULL, .e_esigcode = NULL, .e_sigobject = NULL, -#endif .e_setregs = netbsd32_setregs, .e_proc_exec = NULL, .e_proc_fork = NULL, Index: src/sys/modules/Makefile diff -u src/sys/modules/Makefile:1.202.2.30 src/sys/modules/Makefile:1.202.2.31 --- src/sys/modules/Makefile:1.202.2.30 Wed Sep 12 01:05:20 2018 +++ src/sys/modules/Makefile Wed Sep 12 01:26:39 2018 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.202.2.30 2018/09/12 01:05:20 pgoyette Exp $ +# $NetBSD: Makefile,v 1.202.2.31 2018/09/12 01:26:39 pgoyette Exp $ .include @@ -268,10 +268,10 @@ SUBDIR+= wmimsi || (!empty(MACHINE_ARCH:Mmips64*) && !defined(BSD_MK_COMPAT_FILE)) SUBDIR+= compat_netbsd32 SUBDIR+= compat_netbsd32_09 compat_netbsd32_12 -SUBDIR+= compat_netbsd32_13 compat_netbsd32_20 -SUBDIR+= compat_netbsd32_30 compat_netbsd32_40 -SUBDIR+= compat_netbsd32_50 compat_netbsd32_60 -SUBDIR+= compat_netbsd32_80 +SUBDIR+= compat_netbsd32_13 compat_netbsd32_16 +SUBDIR+= compat_netbsd32_20 compat_netbsd32_30 +SUBDIR+= compat_netbsd32_40 compat_netbsd32_50 +SUBDIR+= compat_netbsd32_60 compat_netbsd32_80 SUBDIR+= compat_netbsd32_43 SUBDIR+= compat_netbsd32_mqueue SUBDIR+= compat_netbsd32_nfssrv @@ -283,10 +283,10 @@ SUBDIR+= compat_netbsd32_sysvipc SUBDIR+= compat_linux32 SUBDIR+= compat_netbsd32 SUBDIR+= compat_netbsd32_09 compat
CVS commit: [pgoyette-compat] src/distrib/sets/lists/modules
Module Name:src Committed By: pgoyette Date: Wed Sep 12 01:28:32 UTC 2018 Modified Files: src/distrib/sets/lists/modules [pgoyette-compat]: ad.arm ad.mips md.amd64 Log Message: Add new compat_netbsd32_16 module to sets To generate a diff of this commit: cvs rdiff -u -r1.10.12.3 -r1.10.12.4 src/distrib/sets/lists/modules/ad.arm \ src/distrib/sets/lists/modules/ad.mips cvs rdiff -u -r1.75.2.5 -r1.75.2.6 src/distrib/sets/lists/modules/md.amd64 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/modules/ad.arm diff -u src/distrib/sets/lists/modules/ad.arm:1.10.12.3 src/distrib/sets/lists/modules/ad.arm:1.10.12.4 --- src/distrib/sets/lists/modules/ad.arm:1.10.12.3 Tue Sep 11 09:05:32 2018 +++ src/distrib/sets/lists/modules/ad.arm Wed Sep 12 01:28:32 2018 @@ -1,4 +1,4 @@ -# $NetBSD: ad.arm,v 1.10.12.3 2018/09/11 09:05:32 pgoyette Exp $ +# $NetBSD: ad.arm,v 1.10.12.4 2018/09/12 01:28:32 pgoyette Exp $ ./@MODULEDIR@/compat_netbsd32 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32/compat_netbsd32.kmod base-kernel-modules kmod @@ -12,10 +12,14 @@ ./@MODULEDIR@/compat_netbsd32_13/compat_netbsd32_13.kmod_base-kernel-modules kmod #./@MODULEDIR@/compat_netbsd32_14 base-kernel-modules kmod #./@MODULEDIR@/compat_netbsd32_14/compat_netbsd32_14.kmod base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_16 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_16/compat_netbsd32_16.kmod_base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_20 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_20/compat_netbsd32_20.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_30 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_30/compat_netbsd32_30.kmod base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_40 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_40/compat_netbsd32_40.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_50 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_50/compat_netbsd32_50.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_60 base-kernel-modules kmod Index: src/distrib/sets/lists/modules/ad.mips diff -u src/distrib/sets/lists/modules/ad.mips:1.10.12.3 src/distrib/sets/lists/modules/ad.mips:1.10.12.4 --- src/distrib/sets/lists/modules/ad.mips:1.10.12.3 Tue Sep 11 09:05:32 2018 +++ src/distrib/sets/lists/modules/ad.mips Wed Sep 12 01:28:32 2018 @@ -1,4 +1,4 @@ -# $NetBSD: ad.mips,v 1.10.12.3 2018/09/11 09:05:32 pgoyette Exp $ +# $NetBSD: ad.mips,v 1.10.12.4 2018/09/12 01:28:32 pgoyette Exp $ ./@MODULEDIR@/compat_netbsd32 base-kernel-modules kmod,arch64,nocompatmodules ./@MODULEDIR@/compat_netbsd32/compat_netbsd32.kmod base-kernel-modules kmod,arch64,nocompatmodules ./@MODULEDIR@/compat_netbsd32_09 base-kernel-modules kmod @@ -11,10 +11,14 @@ ./@MODULEDIR@/compat_netbsd32_13/compat_netbsd32_13.kmod base-kernel-modules kmod #./@MODULEDIR@/compat_netbsd32_14 base-kernel-modules kmod #./@MODULEDIR@/compat_netbsd32_14/compat_netbsd32_14.kmod base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_16 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_16/compat_netbsd32_16.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_20 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_20/compat_netbsd32_20.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_30 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_30/compat_netbsd32_30.kmod base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_40 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_40/compat_netbsd32_40.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_50 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_50/compat_netbsd32_50.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_60 base-kernel-modules kmod Index: src/distrib/sets/lists/modules/md.amd64 diff -u src/distrib/sets/lists/modules/md.amd64:1.75.2.5 src/distrib/sets/lists/modules/md.amd64:1.75.2.6 --- src/distrib/sets/lists/modules/md.amd64:1.75.2.5 Tue Sep 11 09:05:32 2018 +++ src/distrib/sets/lists/modules/md.amd64 Wed Sep 12 01:28:32 2018 @@ -1,4 +1,4 @@ -# $NetBSD: md.amd64,v 1.75.2.5 2018/09/11 09:05:32 pgoyette Exp $ +# $NetBSD: md.amd64,v 1.75.2.6 2018/09/12 01:28:32 pgoyette Exp $ # # NOTE that there are two sets of files here: # @MODULEDIR@ and amd64-xen @@ -65,10 +65,14 @@ ./@MODULEDIR@/compat_netbsd32_13/compat_netbsd32_13.kmod base-kernel-modules kmod #./@MODULEDIR@/compat_netbsd32_14 base-kernel-modules kmod #./@MODULEDIR@/compat_netbsd32_14/compat_netbsd32_14.kmod base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_16 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_16/compat_netbsd32_16.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_20 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_20/compat_netbsd32_20.kmod base-kernel-modules kmod ./
CVS commit: src/sys/compat/common
Module Name:src Committed By: msaitoh Date: Wed Sep 12 02:24:25 UTC 2018 Modified Files: src/sys/compat/common: uipc_syscalls_50.c Log Message: Fix a bug that SIOC[GZ]IFDATA returned old ifreq structure. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/compat/common/uipc_syscalls_50.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/common/uipc_syscalls_50.c diff -u src/sys/compat/common/uipc_syscalls_50.c:1.5 src/sys/compat/common/uipc_syscalls_50.c:1.6 --- src/sys/compat/common/uipc_syscalls_50.c:1.5 Thu Apr 26 08:11:18 2018 +++ src/sys/compat/common/uipc_syscalls_50.c Wed Sep 12 02:24:25 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: uipc_syscalls_50.c,v 1.5 2018/04/26 08:11:18 roy Exp $ */ +/* $NetBSD: uipc_syscalls_50.c,v 1.6 2018/09/12 02:24:25 msaitoh Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -37,7 +37,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: uipc_syscalls_50.c,v 1.5 2018/04/26 08:11:18 roy Exp $"); +__KERNEL_RCSID(0, "$NetBSD: uipc_syscalls_50.c,v 1.6 2018/09/12 02:24:25 msaitoh Exp $"); #include #include @@ -65,23 +65,24 @@ compat_ifdatareq(struct lwp *l, u_long c /* Validate arguments. */ switch (cmd) { - case SIOCGIFDATA: - case SIOCZIFDATA: - ifp = ifunit(ifdr->ifdr_name); - if (ifp == NULL) - return ENXIO; + case OSIOCGIFDATA: + case OSIOCZIFDATA: break; default: return ENOSYS; } + ifp = ifunit(ifdr->ifdr_name); + if (ifp == NULL) + return ENXIO; + /* Do work. */ switch (cmd) { - case SIOCGIFDATA: + case OSIOCGIFDATA: ifdatan2o(&ifdr->ifdr_data, &ifp->if_data); return 0; - case SIOCZIFDATA: + case OSIOCZIFDATA: if (l != NULL) { error = kauth_authorize_network(l->l_cred, KAUTH_NETWORK_INTERFACE,
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Wed Sep 12 03:21:14 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: syscalls.master Log Message: Prepare for splitting compat_netbsd32_sysvipc into version-specific modules To generate a diff of this commit: cvs rdiff -u -r1.120.2.12 -r1.120.2.13 \ src/sys/compat/netbsd32/syscalls.master Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/syscalls.master diff -u src/sys/compat/netbsd32/syscalls.master:1.120.2.12 src/sys/compat/netbsd32/syscalls.master:1.120.2.13 --- src/sys/compat/netbsd32/syscalls.master:1.120.2.12 Wed Sep 12 00:20:53 2018 +++ src/sys/compat/netbsd32/syscalls.master Wed Sep 12 03:21:14 2018 @@ -1,4 +1,4 @@ - $NetBSD: syscalls.master,v 1.120.2.12 2018/09/12 00:20:53 pgoyette Exp $ + $NetBSD: syscalls.master,v 1.120.2.13 2018/09/12 03:21:14 pgoyette Exp $ ; from: NetBSD: syscalls.master,v 1.81 1998/07/05 08:49:50 jonathan Exp ; @(#)syscalls.master 8.2 (Berkeley) 1/13/94 @@ -392,13 +392,13 @@ 166 UNIMPL 167 UNIMPL 168 UNIMPL -169 COMPAT_10 MODULAR compat_netbsd32_sysvipc \ +169 COMPAT_10 MODULAR compat_netbsd32_sysvipc_10 \ { int|netbsd32||semsys(int which, int a2, int a3, \ int a4, int a5); } osemsys -170 COMPAT_10 MODULAR compat_netbsd32_sysvipc \ +170 COMPAT_10 MODULAR compat_netbsd32_sysvipc_10 \ { int|netbsd32||msgsys(int which, int a2, int a3, \ int a4, int a5, int a6); } omsgsys -171 COMPAT_10 MODULAR compat_netbsd32_sysvipc \ +171 COMPAT_10 MODULAR compat_netbsd32_sysvipc_10 \ { int|netbsd32||shmsys(int which, int a2, int a3, \ int a4); } oshmsys 172 UNIMPL @@ -490,7 +490,7 @@ 218 UNIMPL 219 UNIMPL ; System calls 220-300 are reserved for use by NetBSD -220 COMPAT_14 MODULAR compat_netbsd32_sysvipc \ +220 COMPAT_14 MODULAR compat_netbsd32_sysvipc_14 \ { int|netbsd32||__semctl(int semid, int semnum, \ int cmd, netbsd32_semunu_t arg); } 221 STD MODULAR compat_netbsd32_sysvipc \ @@ -501,7 +501,7 @@ netbsd32_sembufp_t sops, netbsd32_size_t nsops); } 223 STD MODULAR compat_netbsd32_sysvipc \ { int|netbsd32||semconfig(int flag); } -224 COMPAT_14 MODULAR compat_netbsd32_sysvipc \ +224 COMPAT_14 MODULAR compat_netbsd32_sysvipc_14 \ { int|netbsd32||msgctl(int msqid, int cmd, \ netbsd32_msqid_ds14p_t buf); } 225 STD MODULAR compat_netbsd32_sysvipc \ @@ -516,7 +516,7 @@ 228 STD MODULAR compat_netbsd32_sysvipc \ { netbsd32_voidp|netbsd32||shmat(int shmid, \ netbsd32_voidp shmaddr, int shmflg); } -229 COMPAT_14 MODULAR compat_netbsd32_sysvipc \ +229 COMPAT_14 MODULAR compat_netbsd32_sysvipc_14 \ { int|netbsd32||shmctl(int shmid, int cmd, \ netbsd32_shmid_dsp_t buf); } 230 STD MODULAR compat_netbsd32_sysvipc \ @@ -693,13 +693,13 @@ 300 COMPAT_20 MODULAR compat_netbsd32_20 \ { int|netbsd32||fhstatfs(netbsd32_fhandlep_t fhp, \ netbsd32_stat50p_t buf); } -301 COMPAT_50 MODULAR compat_netbsd32_sysvipc \ +301 COMPAT_50 MODULAR compat_netbsd32_sysvipc_50 \ { int|netbsd32|14|semctl(int semid, int semnum, \ int cmd, ... netbsd32_semun50p_t arg); } -302 COMPAT_50 MODULAR compat_netbsd32_sysvipc \ +302 COMPAT_50 MODULAR compat_netbsd32_sysvipc_50 \ { int|netbsd32|13|msgctl(int msqid, int cmd, \ netbsd32_msqid_ds50p_t buf); } -303 COMPAT_50 MODULAR compat_netbsd32_sysvipc \ +303 COMPAT_50 MODULAR compat_netbsd32_sysvipc_50 \ { int|netbsd32|13|shmctl(int shmid, int cmd, \ netbsd32_shmid_ds50p_t buf); } 304 STD { int|netbsd32||lchflags(netbsd32_charp path, \
CVS commit: [pgoyette-compat] src/sys/compat/netbsd32
Module Name:src Committed By: pgoyette Date: Wed Sep 12 03:22:08 UTC 2018 Modified Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_syscall.h netbsd32_syscallargs.h netbsd32_syscalls.c netbsd32_syscalls_autoload.c netbsd32_sysent.c netbsd32_systrace_args.c Log Message: Regen To generate a diff of this commit: cvs rdiff -u -r1.134.2.9 -r1.134.2.10 \ src/sys/compat/netbsd32/netbsd32_syscall.h cvs rdiff -u -r1.134.2.8 -r1.134.2.9 \ src/sys/compat/netbsd32/netbsd32_syscallargs.h cvs rdiff -u -r1.132.2.9 -r1.132.2.10 \ src/sys/compat/netbsd32/netbsd32_syscalls.c cvs rdiff -u -r1.13.2.8 -r1.13.2.9 \ src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c cvs rdiff -u -r1.132.2.8 -r1.132.2.9 \ src/sys/compat/netbsd32/netbsd32_sysent.c cvs rdiff -u -r1.24.2.8 -r1.24.2.9 \ src/sys/compat/netbsd32/netbsd32_systrace_args.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/compat/netbsd32/netbsd32_syscall.h diff -u src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.9 src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.10 --- src/sys/compat/netbsd32/netbsd32_syscall.h:1.134.2.9 Wed Sep 12 00:22:26 2018 +++ src/sys/compat/netbsd32/netbsd32_syscall.h Wed Sep 12 03:22:07 2018 @@ -1,10 +1,10 @@ -/* $NetBSD: netbsd32_syscall.h,v 1.134.2.9 2018/09/12 00:22:26 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscall.h,v 1.134.2.10 2018/09/12 03:22:07 pgoyette Exp $ */ /* * System call numbers. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.12 2018/09/12 00:20:53 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.13 2018/09/12 03:21:14 pgoyette Exp */ #ifndef _NETBSD32_SYS_SYSCALL_H_ Index: src/sys/compat/netbsd32/netbsd32_syscallargs.h diff -u src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.8 src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.9 --- src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.134.2.8 Wed Sep 12 00:22:26 2018 +++ src/sys/compat/netbsd32/netbsd32_syscallargs.h Wed Sep 12 03:22:07 2018 @@ -1,10 +1,10 @@ -/* $NetBSD: netbsd32_syscallargs.h,v 1.134.2.8 2018/09/12 00:22:26 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscallargs.h,v 1.134.2.9 2018/09/12 03:22:07 pgoyette Exp $ */ /* * System call argument lists. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.12 2018/09/12 00:20:53 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.13 2018/09/12 03:21:14 pgoyette Exp */ #ifndef _NETBSD32_SYS_SYSCALLARGS_H_ Index: src/sys/compat/netbsd32/netbsd32_syscalls.c diff -u src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.9 src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.10 --- src/sys/compat/netbsd32/netbsd32_syscalls.c:1.132.2.9 Wed Sep 12 00:22:26 2018 +++ src/sys/compat/netbsd32/netbsd32_syscalls.c Wed Sep 12 03:22:07 2018 @@ -1,14 +1,14 @@ -/* $NetBSD: netbsd32_syscalls.c,v 1.132.2.9 2018/09/12 00:22:26 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscalls.c,v 1.132.2.10 2018/09/12 03:22:07 pgoyette Exp $ */ /* * System call names. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.12 2018/09/12 00:20:53 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.13 2018/09/12 03:21:14 pgoyette Exp */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.132.2.9 2018/09/12 00:22:26 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.132.2.10 2018/09/12 03:22:07 pgoyette Exp $"); #if defined(_KERNEL_OPT) #if defined(_KERNEL_OPT) Index: src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c diff -u src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c:1.13.2.8 src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c:1.13.2.9 --- src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c:1.13.2.8 Wed Sep 12 00:22:26 2018 +++ src/sys/compat/netbsd32/netbsd32_syscalls_autoload.c Wed Sep 12 03:22:07 2018 @@ -1,14 +1,14 @@ -/* $NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.8 2018/09/12 00:22:26 pgoyette Exp $ */ +/* $NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.9 2018/09/12 03:22:07 pgoyette Exp $ */ /* * System call autoload table. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.120.2.12 2018/09/12 00:20:53 pgoyette Exp + * created from NetBSD: syscalls.master,v 1.120.2.13 2018/09/12 03:21:14 pgoyette Exp */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.8 2018/09/12 00:22:26 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls_autoload.c,v 1.13.2.9 2018/09/12 03:22:07 pgoyette Exp $"); #include static struct sc_autoload netbsd32_syscalls_autoload[] = { @@ -67,24 +67,24 @@ static struct sc_autoload netbsd32_sysca { NETBSD32_SYS_compat_09_netbsd32_ogetdoma
CVS commit: src/sys/dev/pci
Module Name:src Committed By: mrg Date: Wed Sep 12 03:23:38 UTC 2018 Modified Files: src/sys/dev/pci: hdaudio_pci.c Log Message: use pci_mapreg_type() instead of assuming PCI_MAPREG_TYPE_MEM. suggested by riastradh@. fixes hdaudio on thinkpad P51 where the registers are mapped over 4GB range. probably fixes intel X10-based systems that map hdaudio high as well, but i was able to work around that in the BIOS. not so for the P51. XXX: pullup-7, pullup-8. To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/sys/dev/pci/hdaudio_pci.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/hdaudio_pci.c diff -u src/sys/dev/pci/hdaudio_pci.c:1.8 src/sys/dev/pci/hdaudio_pci.c:1.9 --- src/sys/dev/pci/hdaudio_pci.c:1.8 Sun Jun 4 23:34:55 2017 +++ src/sys/dev/pci/hdaudio_pci.c Wed Sep 12 03:23:38 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: hdaudio_pci.c,v 1.8 2017/06/04 23:34:55 pgoyette Exp $ */ +/* $NetBSD: hdaudio_pci.c,v 1.9 2018/09/12 03:23:38 mrg Exp $ */ /* * Copyright (c) 2009 Precedence Technologies Ltd @@ -34,7 +34,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: hdaudio_pci.c,v 1.8 2017/06/04 23:34:55 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: hdaudio_pci.c,v 1.9 2018/09/12 03:23:38 mrg Exp $"); #include #include @@ -107,8 +107,8 @@ hdaudio_pci_attach(device_t parent, devi struct hdaudio_pci_softc *sc = device_private(self); struct pci_attach_args *pa = opaque; const char *intrstr; - pcireg_t csr; - int err; + pcireg_t csr, maptype; + int err, reg; char intrbuf[PCI_INTRSTR_LEN]; aprint_naive("\n"); @@ -127,7 +127,9 @@ hdaudio_pci_attach(device_t parent, devi pci_conf_write(sc->sc_pc, sc->sc_tag, PCI_COMMAND_STATUS_REG, csr); /* Map MMIO registers */ - err = pci_mapreg_map(pa, HDAUDIO_PCI_AZBARL, PCI_MAPREG_TYPE_MEM, 0, + reg = HDAUDIO_PCI_AZBARL; + maptype = pci_mapreg_type(sc->sc_pc, sc->sc_tag, reg); + err = pci_mapreg_map(pa, reg, maptype, 0, &sc->sc_hdaudio.sc_memt, &sc->sc_hdaudio.sc_memh, &sc->sc_hdaudio.sc_membase,
CVS commit: [pgoyette-compat] src
Module Name:src Committed By: pgoyette Date: Wed Sep 12 04:35:22 UTC 2018 Modified Files: src/distrib/sets/lists/modules [pgoyette-compat]: ad.arm ad.mips md.amd64 src/sys/compat/netbsd32 [pgoyette-compat]: files.netbsd32 netbsd32_compat_50_sysv.c netbsd32_ipc.c src/sys/modules [pgoyette-compat]: Makefile src/sys/modules/compat_netbsd32 [pgoyette-compat]: Makefile src/sys/modules/compat_netbsd32_sysvipc [pgoyette-compat]: Makefile Added Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_compat_10_sysv.c netbsd32_compat_14_sysv.c Removed Files: src/sys/compat/netbsd32 [pgoyette-compat]: netbsd32_compat_10.c netbsd32_compat_14.c Log Message: Split compat_netbsd32_sysvipc into version-specific modules To generate a diff of this commit: cvs rdiff -u -r1.10.12.4 -r1.10.12.5 src/distrib/sets/lists/modules/ad.arm \ src/distrib/sets/lists/modules/ad.mips cvs rdiff -u -r1.75.2.6 -r1.75.2.7 src/distrib/sets/lists/modules/md.amd64 cvs rdiff -u -r1.39.14.3 -r1.39.14.4 src/sys/compat/netbsd32/files.netbsd32 cvs rdiff -u -r1.25.16.2 -r0 src/sys/compat/netbsd32/netbsd32_compat_10.c cvs rdiff -u -r0 -r1.1.2.1 src/sys/compat/netbsd32/netbsd32_compat_10_sysv.c \ src/sys/compat/netbsd32/netbsd32_compat_14_sysv.c cvs rdiff -u -r1.26 -r0 src/sys/compat/netbsd32/netbsd32_compat_14.c cvs rdiff -u -r1.1 -r1.1.20.1 \ src/sys/compat/netbsd32/netbsd32_compat_50_sysv.c cvs rdiff -u -r1.18.16.3 -r1.18.16.4 src/sys/compat/netbsd32/netbsd32_ipc.c cvs rdiff -u -r1.202.2.31 -r1.202.2.32 src/sys/modules/Makefile cvs rdiff -u -r1.20.12.8 -r1.20.12.9 src/sys/modules/compat_netbsd32/Makefile cvs rdiff -u -r1.1 -r1.1.20.1 \ src/sys/modules/compat_netbsd32_sysvipc/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/modules/ad.arm diff -u src/distrib/sets/lists/modules/ad.arm:1.10.12.4 src/distrib/sets/lists/modules/ad.arm:1.10.12.5 --- src/distrib/sets/lists/modules/ad.arm:1.10.12.4 Wed Sep 12 01:28:32 2018 +++ src/distrib/sets/lists/modules/ad.arm Wed Sep 12 04:35:22 2018 @@ -1,4 +1,4 @@ -# $NetBSD: ad.arm,v 1.10.12.4 2018/09/12 01:28:32 pgoyette Exp $ +# $NetBSD: ad.arm,v 1.10.12.5 2018/09/12 04:35:22 pgoyette Exp $ ./@MODULEDIR@/compat_netbsd32 base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32/compat_netbsd32.kmod base-kernel-modules kmod @@ -36,5 +36,11 @@ ./@MODULEDIR@/compat_netbsd32_ptrace/compat_netbsd32_ptrace.kmod base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_sysvipc base-kernel-modules kmod ./@MODULEDIR@/compat_netbsd32_sysvipc/compat_netbsd32_sysvipc.kmod base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_sysvipc_10 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_sysvipc_10/compat_netbsd32_sysvipc_10.kmod base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_sysvipc_14 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_sysvipc_14/compat_netbsd32_sysvipc_14.kmod base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_sysvipc_50 base-kernel-modules kmod +./@MODULEDIR@/compat_netbsd32_sysvipc_50/compat_netbsd32_sysvipc_50.kmod base-kernel-modules kmod ./@MODULEDIR@/exec_elf32 base-kernel-modules kmod ./@MODULEDIR@/exec_elf32/exec_elf32.kmod base-kernel-modules kmod Index: src/distrib/sets/lists/modules/ad.mips diff -u src/distrib/sets/lists/modules/ad.mips:1.10.12.4 src/distrib/sets/lists/modules/ad.mips:1.10.12.5 --- src/distrib/sets/lists/modules/ad.mips:1.10.12.4 Wed Sep 12 01:28:32 2018 +++ src/distrib/sets/lists/modules/ad.mips Wed Sep 12 04:35:22 2018 @@ -1,4 +1,4 @@ -# $NetBSD: ad.mips,v 1.10.12.4 2018/09/12 01:28:32 pgoyette Exp $ +# $NetBSD: ad.mips,v 1.10.12.5 2018/09/12 04:35:22 pgoyette Exp $ ./@MODULEDIR@/compat_netbsd32 base-kernel-modules kmod,arch64,nocompatmodules ./@MODULEDIR@/compat_netbsd32/compat_netbsd32.kmod base-kernel-modules kmod,arch64,nocompatmodules ./@MODULEDIR@/compat_netbsd32_09 base-kernel-modules kmod @@ -35,5 +35,11 @@ ./@MODULEDIR@/compat_netbsd32_ptrace/compat_netbsd32_ptrace.kmod base-kernel-modules kmod,arch64,nocompatmodules ./@MODULEDIR@/compat_netbsd32_sysvipc base-kernel-modules kmod,arch64,nocompatmodules ./@MODULEDIR@/compat_netbsd32_sysvipc/compat_netbsd32_sysvipc.kmod base-kernel-modules kmod,arch64,nocompatmodules +./@MODULEDIR@/compat_netbsd32_sysvipc_10 base-kernel-modules kmod,arch64,nocompatmodules +./@MODULEDIR@/compat_netbsd32_sysvipc_10/compat_netbsd32_sysvipc_10.kmod base-kernel-modules kmod,arch64,nocompatmodules +./@MODULEDIR@/compat_netbsd32_sysvipc_14 base-kernel-modules kmod,arch64,nocompatmodules +./@MODULEDIR@/compat_netbsd32_sysvipc_14/compat_netbsd32_sysvipc_14.kmod base-kernel-modules kmod,arch64,nocompatmodules +./@MODULEDIR@/compat_netbsd32_sysvipc_50 base-kernel-modules kmod,arch64,nocompatmodules +./@MODULEDIR@/compat_netbsd32_sysvipc_50/compat_n
CVS commit: src/sys/dev/pci
Module Name:src Committed By: msaitoh Date: Wed Sep 12 04:37:18 UTC 2018 Modified Files: src/sys/dev/pci: if_wm.c Log Message: - Split txdrop evcnt into pcqdrop and descdrop. - Simplify evcnt name by removing duplicated "tx" or "rx". - s/tu/underrun/ To generate a diff of this commit: cvs rdiff -u -r1.585 -r1.586 src/sys/dev/pci/if_wm.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/if_wm.c diff -u src/sys/dev/pci/if_wm.c:1.585 src/sys/dev/pci/if_wm.c:1.586 --- src/sys/dev/pci/if_wm.c:1.585 Mon Sep 3 16:29:32 2018 +++ src/sys/dev/pci/if_wm.c Wed Sep 12 04:37:18 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: if_wm.c,v 1.585 2018/09/03 16:29:32 riastradh Exp $ */ +/* $NetBSD: if_wm.c,v 1.586 2018/09/12 04:37:18 msaitoh Exp $ */ /* * Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc. @@ -83,7 +83,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.585 2018/09/03 16:29:32 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.586 2018/09/12 04:37:18 msaitoh Exp $"); #ifdef _KERNEL_OPT #include "opt_net_mpsafe.h" @@ -376,23 +376,24 @@ struct wm_txqueue { uint32_t txq_packets; /* for AIM */ uint32_t txq_bytes; /* for AIM */ #ifdef WM_EVENT_COUNTERS - WM_Q_EVCNT_DEFINE(txq, txsstall) /* Tx stalled due to no txs */ - WM_Q_EVCNT_DEFINE(txq, txdstall) /* Tx stalled due to no txd */ - WM_Q_EVCNT_DEFINE(txq, txfifo_stall) /* Tx FIFO stalls (82547) */ - WM_Q_EVCNT_DEFINE(txq, txdw) /* Tx descriptor interrupts */ - WM_Q_EVCNT_DEFINE(txq, txqe) /* Tx queue empty interrupts */ - /* XXX not used? */ - - WM_Q_EVCNT_DEFINE(txq, txipsum) /* IP checksums comp. out-bound */ - WM_Q_EVCNT_DEFINE(txq, txtusum) /* TCP/UDP cksums comp. out-bound */ - WM_Q_EVCNT_DEFINE(txq, txtusum6) /* TCP/UDP v6 cksums comp. out-bound */ - WM_Q_EVCNT_DEFINE(txq, txtso) /* TCP seg offload out-bound (IPv4) */ - WM_Q_EVCNT_DEFINE(txq, txtso6) /* TCP seg offload out-bound (IPv6) */ - WM_Q_EVCNT_DEFINE(txq, txtsopain) /* painful header manip. for TSO */ + /* TX event counters */ + WM_Q_EVCNT_DEFINE(txq, txsstall)/* Stalled due to no txs */ + WM_Q_EVCNT_DEFINE(txq, txdstall)/* Stalled due to no txd */ + WM_Q_EVCNT_DEFINE(txq, fifo_stall) /* FIFO stalls (82547) */ + WM_Q_EVCNT_DEFINE(txq, txdw) /* Tx descriptor interrupts */ + WM_Q_EVCNT_DEFINE(txq, txqe) /* Tx queue empty interrupts */ + /* XXX not used? */ + + WM_Q_EVCNT_DEFINE(txq, ipsum) /* IP checksums comp. */ + WM_Q_EVCNT_DEFINE(txq, tusum) /* TCP/UDP cksums comp. */ + WM_Q_EVCNT_DEFINE(txq, tusum6) /* TCP/UDP v6 cksums comp. */ + WM_Q_EVCNT_DEFINE(txq, tso) /* TCP seg offload (IPv4) */ + WM_Q_EVCNT_DEFINE(txq, tso6) /* TCP seg offload (IPv6) */ + WM_Q_EVCNT_DEFINE(txq, tsopain) /* Painful header manip. for TSO */ + WM_Q_EVCNT_DEFINE(txq, pcqdrop) /* Pkt dropped in pcq */ + WM_Q_EVCNT_DEFINE(txq, descdrop)/* Pkt dropped in MAC desc ring */ - WM_Q_EVCNT_DEFINE(txq, txdrop) /* Tx packets dropped(too many segs) */ - - WM_Q_EVCNT_DEFINE(txq, tu) /* Tx underrun */ + WM_Q_EVCNT_DEFINE(txq, underrun)/* Tx underrun */ char txq_txseg_evcnt_names[WM_NTXSEGS][sizeof("txqXXtxsegXXX")]; struct evcnt txq_ev_txseg[WM_NTXSEGS]; /* Tx packets w/ N segments */ @@ -433,11 +434,12 @@ struct wm_rxqueue { uint32_t rxq_packets; /* for AIM */ uint32_t rxq_bytes; /* for AIM */ #ifdef WM_EVENT_COUNTERS - WM_Q_EVCNT_DEFINE(rxq, rxintr); /* Rx interrupts */ - WM_Q_EVCNT_DEFINE(rxq, rxdefer); /* Rx deferred processing */ + /* RX event counters */ + WM_Q_EVCNT_DEFINE(rxq, intr); /* Interrupts */ + WM_Q_EVCNT_DEFINE(rxq, defer); /* Rx deferred processing */ - WM_Q_EVCNT_DEFINE(rxq, rxipsum); /* IP checksums checked in-bound */ - WM_Q_EVCNT_DEFINE(rxq, rxtusum); /* TCP/UDP cksums checked in-bound */ + WM_Q_EVCNT_DEFINE(rxq, ipsum); /* IP checksums checked */ + WM_Q_EVCNT_DEFINE(rxq, tusum); /* TCP/UDP cksums checked */ #endif }; @@ -6451,16 +6453,15 @@ wm_alloc_txrx_queues(struct wm_softc *sc WM_Q_MISC_EVCNT_ATTACH(txq, txsstall, txq, i, xname); WM_Q_MISC_EVCNT_ATTACH(txq, txdstall, txq, i, xname); - WM_Q_MISC_EVCNT_ATTACH(txq, txfifo_stall, txq, i, xname); + WM_Q_MISC_EVCNT_ATTACH(txq, fifo_stall, txq, i, xname); WM_Q_INTR_EVCNT_ATTACH(txq, txdw, txq, i, xname); WM_Q_INTR_EVCNT_ATTACH(txq, txqe, txq, i, xname); - - WM_Q_MISC_EVCNT_ATTACH(txq, txipsum, txq, i, xname); - WM_Q_MISC_EVCNT_ATTACH(txq, txtusum, txq, i, xname); - WM_Q_MISC_EVCNT_ATTACH(txq, txtusum6, txq, i, xname); - WM_Q_MISC_EVCNT_ATTACH(txq, txtso, txq, i, xname); - WM_Q_MISC_EVCNT_ATTACH(txq, txtso6, txq, i, xname); - WM_Q_MISC_EVCNT_ATTACH(txq, txtsopain, txq, i, xname); + WM_Q_MISC_EVCNT_ATTACH(txq, ipsum, txq, i, xname); + WM_Q_MISC_EVCNT_ATTACH(txq, tusum, txq, i, xname); + WM_Q_MISC_EVCNT_ATTACH(txq, tusum6, txq, i, xname); + WM_Q_MISC_EVCNT_ATTACH(txq, tso, txq, i, xname); + WM_
CVS commit: src/sys/dev/pci
Module Name:src Committed By: msaitoh Date: Wed Sep 12 04:59:26 UTC 2018 Modified Files: src/sys/dev/pci: if_wm.c Log Message: - Try m_defrag() to reduce the number of DMA segment if bus_dmamap_load_mbuf() returned EFBIG. When m_defrag() is called, txqNNdefrag event counter is incremented. If the 2nd try of bus_dmamap_load_mbuf() failed, txqNNtoomanyseg event counter is incremented. - Reduce the max number of DMA segemts from 256 to 64 (it's the same valuse as other BSD's (EM_MAX_SCATTER) and more than before if_wm.c rev. 1.75's value (40)) because we do m_defrag() now. To generate a diff of this commit: cvs rdiff -u -r1.586 -r1.587 src/sys/dev/pci/if_wm.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/if_wm.c diff -u src/sys/dev/pci/if_wm.c:1.586 src/sys/dev/pci/if_wm.c:1.587 --- src/sys/dev/pci/if_wm.c:1.586 Wed Sep 12 04:37:18 2018 +++ src/sys/dev/pci/if_wm.c Wed Sep 12 04:59:26 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: if_wm.c,v 1.586 2018/09/12 04:37:18 msaitoh Exp $ */ +/* $NetBSD: if_wm.c,v 1.587 2018/09/12 04:59:26 msaitoh Exp $ */ /* * Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc. @@ -83,7 +83,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.586 2018/09/12 04:37:18 msaitoh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.587 2018/09/12 04:59:26 msaitoh Exp $"); #ifdef _KERNEL_OPT #include "opt_net_mpsafe.h" @@ -197,11 +197,12 @@ static int wm_watchdog_timeout = WM_WATC * of packets, and we go ahead and manage up to 64 (16 for the i82547) * of them at a time. * - * We allow up to 256 (!) DMA segments per packet. Pathological packet + * We allow up to 64 DMA segments per packet. Pathological packet * chains containing many small mbufs have been observed in zero-copy - * situations with jumbo frames. + * situations with jumbo frames. If a mbuf chain has more than 40 DMA segments, + * m_defrag() is called to reduce it. */ -#define WM_NTXSEGS 256 +#define WM_NTXSEGS 64 #define WM_IFQUEUELEN 256 #define WM_TXQUEUELEN_MAX 64 #define WM_TXQUEUELEN_MAX_82547 16 @@ -392,7 +393,10 @@ struct wm_txqueue { WM_Q_EVCNT_DEFINE(txq, tsopain) /* Painful header manip. for TSO */ WM_Q_EVCNT_DEFINE(txq, pcqdrop) /* Pkt dropped in pcq */ WM_Q_EVCNT_DEFINE(txq, descdrop)/* Pkt dropped in MAC desc ring */ + /* other than toomanyseg */ + WM_Q_EVCNT_DEFINE(txq, toomanyseg) /* Pkt dropped(toomany DMA segs) */ + WM_Q_EVCNT_DEFINE(txq, defrag) /* m_defrag() */ WM_Q_EVCNT_DEFINE(txq, underrun)/* Tx underrun */ char txq_txseg_evcnt_names[WM_NTXSEGS][sizeof("txqXXtxsegXXX")]; @@ -6472,6 +6476,8 @@ wm_alloc_txrx_queues(struct wm_softc *sc WM_Q_MISC_EVCNT_ATTACH(txq, pcqdrop, txq, i, xname); WM_Q_MISC_EVCNT_ATTACH(txq, descdrop, txq, i, xname); + WM_Q_MISC_EVCNT_ATTACH(txq, toomanyseg, txq, i, xname); + WM_Q_MISC_EVCNT_ATTACH(txq, defrag, txq, i, xname); WM_Q_MISC_EVCNT_ATTACH(txq, underrun, txq, i, xname); #endif /* WM_EVENT_COUNTERS */ @@ -6592,6 +6598,8 @@ wm_free_txrx_queues(struct wm_softc *sc) WM_Q_EVCNT_DETACH(txq, pcqdrop, txq, i); WM_Q_EVCNT_DETACH(txq, descdrop, txq, i); + WM_Q_EVCNT_DETACH(txq, toomanyseg, txq, i); + WM_Q_EVCNT_DETACH(txq, defrag, txq, i); WM_Q_EVCNT_DETACH(txq, underrun, txq, i); #endif /* WM_EVENT_COUNTERS */ @@ -7173,6 +7181,7 @@ wm_send_common_locked(struct ifnet *ifp, bus_size_t seglen, curlen; uint32_t cksumcmd; uint8_t cksumfields; + bool remap = true; KASSERT(mutex_owned(txq->txq_lock)); @@ -7246,11 +7255,23 @@ wm_send_common_locked(struct ifnet *ifp, * since we can't sanely copy a jumbo packet to a single * buffer. */ +retry: error = bus_dmamap_load_mbuf(sc->sc_dmat, dmamap, m0, BUS_DMA_WRITE | BUS_DMA_NOWAIT); - if (error) { + if (__predict_false(error)) { if (error == EFBIG) { -WM_Q_EVCNT_INCR(txq, descdrop); +if (remap == true) { + struct mbuf *m; + + remap = false; + m = m_defrag(m0, M_NOWAIT); + if (m != NULL) { + WM_Q_EVCNT_INCR(txq, defrag); + m0 = m; + goto retry; + } +} +WM_Q_EVCNT_INCR(txq, toomanyseg); log(LOG_ERR, "%s: Tx packet consumes too many " "DMA segments, dropping...\n", device_xname(sc->sc_dev)); @@ -7775,6 +7796,7 @@ wm_nq_send_common_locked(struct ifnet *i bus_dmamap_t dmamap; int error, nexttx, lasttx = -1, seg, segs_needed; bool do_csum, sent; + bool remap = true; KASSERT(mutex_owned(txq->txq_lock)); @@ -7830,11 +7852,23 @@ wm_nq_send_common_locked(struct ifnet *i * since we can't sanely copy a jumbo packet to a single * buffer. */ +retry: error = bus_dmamap_load_mbuf(sc->sc_dmat, dmamap, m0, BUS_DMA_WRITE | BUS_DMA_NOWAIT); - if (error) { + if (__predict_false(error)) { if (error == EFBIG) { -WM_Q_EVCNT_INCR(txq, descdrop); +if (remap == true) { +
CVS commit: src/sys/dev/pci
Module Name:src Committed By: msaitoh Date: Wed Sep 12 05:03:05 UTC 2018 Modified Files: src/sys/dev/pci: if_wm.c Log Message: Fix comment. To generate a diff of this commit: cvs rdiff -u -r1.587 -r1.588 src/sys/dev/pci/if_wm.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/if_wm.c diff -u src/sys/dev/pci/if_wm.c:1.587 src/sys/dev/pci/if_wm.c:1.588 --- src/sys/dev/pci/if_wm.c:1.587 Wed Sep 12 04:59:26 2018 +++ src/sys/dev/pci/if_wm.c Wed Sep 12 05:03:05 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: if_wm.c,v 1.587 2018/09/12 04:59:26 msaitoh Exp $ */ +/* $NetBSD: if_wm.c,v 1.588 2018/09/12 05:03:05 msaitoh Exp $ */ /* * Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc. @@ -83,7 +83,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.587 2018/09/12 04:59:26 msaitoh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.588 2018/09/12 05:03:05 msaitoh Exp $"); #ifdef _KERNEL_OPT #include "opt_net_mpsafe.h" @@ -199,7 +199,7 @@ static int wm_watchdog_timeout = WM_WATC * * We allow up to 64 DMA segments per packet. Pathological packet * chains containing many small mbufs have been observed in zero-copy - * situations with jumbo frames. If a mbuf chain has more than 40 DMA segments, + * situations with jumbo frames. If a mbuf chain has more than 64 DMA segments, * m_defrag() is called to reduce it. */ #define WM_NTXSEGS 64