Module Name: src
Committed By: martin
Date: Fri Nov 30 10:28:46 UTC 2018
Modified Files:
src/sys/compat/linux/common [netbsd-8]: linux_misc_notalpha.c
src/sys/kern [netbsd-8]: kern_time.c
Log Message:
Additionally pull up following revision(s) (requested by maxv in ticket #1110):
sys/compat/linux/common/linux_misc_notalpha.c: revision 1.110
sys/kern/kern_time.c: revision 1.193
Improve my kern_time.c::rev1.192, systematically clear the buffers we get
from 'ptimer_pool' to prevent more leaks.
To generate a diff of this commit:
cvs rdiff -u -r1.109 -r1.109.12.1 \
src/sys/compat/linux/common/linux_misc_notalpha.c
cvs rdiff -u -r1.189.8.1 -r1.189.8.2 src/sys/kern/kern_time.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/linux/common/linux_misc_notalpha.c
diff -u src/sys/compat/linux/common/linux_misc_notalpha.c:1.109 src/sys/compat/linux/common/linux_misc_notalpha.c:1.109.12.1
--- src/sys/compat/linux/common/linux_misc_notalpha.c:1.109 Sun Nov 9 17:48:08 2014
+++ src/sys/compat/linux/common/linux_misc_notalpha.c Fri Nov 30 10:28:46 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: linux_misc_notalpha.c,v 1.109 2014/11/09 17:48:08 maxv Exp $ */
+/* $NetBSD: linux_misc_notalpha.c,v 1.109.12.1 2018/11/30 10:28:46 martin Exp $ */
/*-
* Copyright (c) 1995, 1998, 2008 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_misc_notalpha.c,v 1.109 2014/11/09 17:48:08 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_misc_notalpha.c,v 1.109.12.1 2018/11/30 10:28:46 martin Exp $");
/*
* Note that we must NOT include "opt_compat_linux32.h" here,
@@ -161,6 +161,7 @@ linux_sys_alarm(struct lwp *l, const str
if (spare == NULL) {
mutex_spin_exit(&timer_lock);
spare = pool_get(&ptimer_pool, PR_WAITOK);
+ memset(spare, 0, sizeof(*spare));
goto retry;
}
ptp = spare;
Index: src/sys/kern/kern_time.c
diff -u src/sys/kern/kern_time.c:1.189.8.1 src/sys/kern/kern_time.c:1.189.8.2
--- src/sys/kern/kern_time.c:1.189.8.1 Thu Nov 29 08:48:38 2018
+++ src/sys/kern/kern_time.c Fri Nov 30 10:28:46 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: kern_time.c,v 1.189.8.1 2018/11/29 08:48:38 martin Exp $ */
+/* $NetBSD: kern_time.c,v 1.189.8.2 2018/11/30 10:28:46 martin Exp $ */
/*-
* Copyright (c) 2000, 2004, 2005, 2007, 2008, 2009 The NetBSD Foundation, Inc.
@@ -61,7 +61,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_time.c,v 1.189.8.1 2018/11/29 08:48:38 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_time.c,v 1.189.8.2 2018/11/30 10:28:46 martin Exp $");
#include <sys/param.h>
#include <sys/resourcevar.h>
@@ -1164,6 +1164,7 @@ dosetitimer(struct proc *p, int which, s
if (spare == NULL) {
mutex_spin_exit(&timer_lock);
spare = pool_get(&ptimer_pool, PR_WAITOK);
+ memset(spare, 0, sizeof(*spare));
goto retry;
}
pt = spare;