cloudabi32_sysvec.c (316570) | cloudabi32_sysvec.c (316574) |
---|---|
1/*- 2 * Copyright (c) 2015-2016 Nuxi, https://nuxi.nl/ 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 1. Redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer. --- 10 unchanged lines hidden (view full) --- 19 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 20 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 21 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 22 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 23 * SUCH DAMAGE. 24 */ 25 26#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2015-2016 Nuxi, https://nuxi.nl/ 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 1. Redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer. --- 10 unchanged lines hidden (view full) --- 19 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 20 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 21 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 22 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 23 * SUCH DAMAGE. 24 */ 25 26#include <sys/cdefs.h> |
27__FBSDID("$FreeBSD: stable/11/sys/i386/cloudabi32/cloudabi32_sysvec.c 316570 2017-04-06 13:51:54Z ed $"); | 27__FBSDID("$FreeBSD: stable/11/sys/i386/cloudabi32/cloudabi32_sysvec.c 316574 2017-04-06 15:10:36Z ed $"); |
28 29#include <sys/param.h> 30#include <sys/imgact.h> 31#include <sys/kernel.h> 32#include <sys/proc.h> 33#include <sys/sysent.h> 34 35#include <vm/vm.h> --- 115 unchanged lines hidden (view full) --- 151{ 152 stack_t stack; 153 uint32_t args[3]; 154 void *frameptr; 155 int error; 156 157 /* Perform standard register initialization. */ 158 stack.ss_sp = TO_PTR(attr->stack); | 28 29#include <sys/param.h> 30#include <sys/imgact.h> 31#include <sys/kernel.h> 32#include <sys/proc.h> 33#include <sys/sysent.h> 34 35#include <vm/vm.h> --- 115 unchanged lines hidden (view full) --- 151{ 152 stack_t stack; 153 uint32_t args[3]; 154 void *frameptr; 155 int error; 156 157 /* Perform standard register initialization. */ 158 stack.ss_sp = TO_PTR(attr->stack); |
159 stack.ss_size = attr->stack_size - sizeof(args); | 159 stack.ss_size = attr->stack_len - sizeof(args); |
160 cpu_set_upcall(td, TO_PTR(attr->entry_point), NULL, &stack); 161 162 /* 163 * Copy the arguments for the thread entry point onto the stack 164 * (args[1] and args[2]). Similar to process startup, use the 165 * otherwise unused return address (args[0]) for TLS. 166 */ 167 args[0] = tcb; --- 36 unchanged lines hidden --- | 160 cpu_set_upcall(td, TO_PTR(attr->entry_point), NULL, &stack); 161 162 /* 163 * Copy the arguments for the thread entry point onto the stack 164 * (args[1] and args[2]). Similar to process startup, use the 165 * otherwise unused return address (args[0]) for TLS. 166 */ 167 args[0] = tcb; --- 36 unchanged lines hidden --- |