Module Name: src Committed By: reinoud Date: Sun Aug 28 19:37:16 UTC 2011
Modified Files: src/sys/arch/usermode/include: thunk.h src/sys/arch/usermode/usermode: thunk.c Log Message: Add thunk_makecontext_trapframe2go() To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 src/sys/arch/usermode/include/thunk.h cvs rdiff -u -r1.20 -r1.21 src/sys/arch/usermode/usermode/thunk.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/include/thunk.h diff -u src/sys/arch/usermode/include/thunk.h:1.18 src/sys/arch/usermode/include/thunk.h:1.19 --- src/sys/arch/usermode/include/thunk.h:1.18 Sat Aug 27 21:14:15 2011 +++ src/sys/arch/usermode/include/thunk.h Sun Aug 28 19:37:15 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: thunk.h,v 1.18 2011/08/27 21:14:15 reinoud Exp $ */ +/* $NetBSD: thunk.h,v 1.19 2011/08/28 19:37:15 reinoud Exp $ */ /*- * Copyright (c) 2011 Jared D. McNeill <jmcne...@invisible.ca> @@ -60,6 +60,7 @@ int thunk_getcontext(ucontext_t *); int thunk_setcontext(const ucontext_t *); void thunk_makecontext(ucontext_t *, void (*)(void), int, void (*)(void *), void *); +void thunk_makecontext_trapframe2go(ucontext_t *, void *func, void *trapframe); int thunk_swapcontext(ucontext_t *, ucontext_t *); int thunk_getchar(void); Index: src/sys/arch/usermode/usermode/thunk.c diff -u src/sys/arch/usermode/usermode/thunk.c:1.20 src/sys/arch/usermode/usermode/thunk.c:1.21 --- src/sys/arch/usermode/usermode/thunk.c:1.20 Sat Aug 27 21:14:15 2011 +++ src/sys/arch/usermode/usermode/thunk.c Sun Aug 28 19:37:16 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: thunk.c,v 1.20 2011/08/27 21:14:15 reinoud Exp $ */ +/* $NetBSD: thunk.c,v 1.21 2011/08/28 19:37:16 reinoud Exp $ */ /*- * Copyright (c) 2011 Jared D. McNeill <jmcne...@invisible.ca> @@ -27,7 +27,7 @@ */ #include <sys/cdefs.h> -__RCSID("$NetBSD: thunk.c,v 1.20 2011/08/27 21:14:15 reinoud Exp $"); +__RCSID("$NetBSD: thunk.c,v 1.21 2011/08/28 19:37:16 reinoud Exp $"); #include <sys/types.h> #include <sys/ansi.h> @@ -173,6 +173,12 @@ makecontext(ucp, func, argc, arg1, arg2); } +void +thunk_makecontext_trapframe2go(ucontext_t *ucp, void *func, void *trapframe) +{ + makecontext(ucp, func, 1, trapframe); +} + int thunk_swapcontext(ucontext_t *oucp, ucontext_t *ucp) {