Module Name:    src
Committed By:   reinoud
Date:           Fri Jun  1 07:26:15 UTC 2018

Modified Files:
        src/sys/arch/usermode/dev: cpu.c

Log Message:
Pass the address of the array, this fixes issues with i386 compilation


To generate a diff of this commit:
cvs rdiff -u -r1.79 -r1.80 src/sys/arch/usermode/dev/cpu.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/usermode/dev/cpu.c
diff -u src/sys/arch/usermode/dev/cpu.c:1.79 src/sys/arch/usermode/dev/cpu.c:1.80
--- src/sys/arch/usermode/dev/cpu.c:1.79	Tue May 29 09:25:01 2018
+++ src/sys/arch/usermode/dev/cpu.c	Fri Jun  1 07:26:15 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: cpu.c,v 1.79 2018/05/29 09:25:01 reinoud Exp $ */
+/* $NetBSD: cpu.c,v 1.80 2018/06/01 07:26:15 reinoud Exp $ */
 
 /*-
  * Copyright (c) 2007 Jared D. McNeill <[email protected]>
@@ -30,7 +30,7 @@
 #include "opt_hz.h"
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.79 2018/05/29 09:25:01 reinoud Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.80 2018/06/01 07:26:15 reinoud Exp $");
 
 #include <sys/param.h>
 #include <sys/conf.h>
@@ -353,9 +353,9 @@ cpu_setmcontext(struct lwp *l, const mco
 	thunk_printf_debug("cpu_setmcontext\n");
 #endif
 	if ((flags & _UC_CPU) != 0)
-		memcpy(&ucp->uc_mcontext.__gregs, mcp->__gregs, sizeof(__gregset_t));
+		memcpy(&ucp->uc_mcontext.__gregs, &mcp->__gregs, sizeof(__gregset_t));
 	if ((flags & _UC_FPU) != 0)
-		memcpy(&ucp->uc_mcontext.__fpregs, mcp->__fpregs, sizeof(__fpregset_t));
+		memcpy(&ucp->uc_mcontext.__fpregs, &mcp->__fpregs, sizeof(__fpregset_t));
 	if ((flags & _UC_TLSBASE) != 0)
 		lwp_setprivate(l, (void *) (uintptr_t) mcp->_mc_tlsbase);
 

Reply via email to