linux_machdep.c (164033) | linux_machdep.c (165867) |
---|---|
1/*- 2 * Copyright (c) 2000 Marcel Moolenaar 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 13 unchanged lines hidden (view full) --- 22 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 23 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 24 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 */ 28 29#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2000 Marcel Moolenaar 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 13 unchanged lines hidden (view full) --- 22 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 23 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 24 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 */ 28 29#include <sys/cdefs.h> |
30__FBSDID("$FreeBSD: head/sys/i386/linux/linux_machdep.c 164033 2006-11-06 13:42:10Z rwatson $"); | 30__FBSDID("$FreeBSD: head/sys/i386/linux/linux_machdep.c 165867 2007-01-07 19:00:38Z netchild $"); |
31 32#include <sys/param.h> 33#include <sys/systm.h> 34#include <sys/file.h> 35#include <sys/fcntl.h> 36#include <sys/imgact.h> 37#include <sys/lock.h> 38#include <sys/malloc.h> --- 364 unchanged lines hidden (view full) --- 403 404 error = fork1(td, ff, 0, &p2); 405 if (error) 406 return (error); 407 408 /* create the emuldata */ 409 error = linux_proc_init(td, p2->p_pid, args->flags); 410 /* reference it - no need to check this */ | 31 32#include <sys/param.h> 33#include <sys/systm.h> 34#include <sys/file.h> 35#include <sys/fcntl.h> 36#include <sys/imgact.h> 37#include <sys/lock.h> 38#include <sys/malloc.h> --- 364 unchanged lines hidden (view full) --- 403 404 error = fork1(td, ff, 0, &p2); 405 if (error) 406 return (error); 407 408 /* create the emuldata */ 409 error = linux_proc_init(td, p2->p_pid, args->flags); 410 /* reference it - no need to check this */ |
411 em = em_find(p2, EMUL_UNLOCKED); | 411 em = em_find(p2, EMUL_DOLOCK); |
412 KASSERT(em != NULL, ("clone: emuldata not found.\n")); 413 /* and adjust it */ 414 if (args->flags & CLONE_PARENT_SETTID) { 415 if (args->parent_tidptr == NULL) { 416 EMUL_UNLOCK(&emul_lock); 417 return (EINVAL); 418 } 419 error = copyout(&p2->p_pid, args->parent_tidptr, sizeof(p2->p_pid)); --- 854 unchanged lines hidden --- | 412 KASSERT(em != NULL, ("clone: emuldata not found.\n")); 413 /* and adjust it */ 414 if (args->flags & CLONE_PARENT_SETTID) { 415 if (args->parent_tidptr == NULL) { 416 EMUL_UNLOCK(&emul_lock); 417 return (EINVAL); 418 } 419 error = copyout(&p2->p_pid, args->parent_tidptr, sizeof(p2->p_pid)); --- 854 unchanged lines hidden --- |