clone.c (976e3645923bdd2fe7893aae33fd7a21098bfb28) | clone.c (33def8498fdde180023444b08e12b72a9efed41d) |
---|---|
1// SPDX-License-Identifier: GPL-2.0 2/* 3 * Copyright (C) 2015 Thomas Meyer (thomas@m3y3r.de) 4 * Copyright (C) 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com) 5 */ 6 7#include <signal.h> 8#include <sched.h> --- 7 unchanged lines hidden (view full) --- 16/* 17 * This is in a separate file because it needs to be compiled with any 18 * extraneous gcc flags (-pg, -fprofile-arcs, -ftest-coverage) disabled 19 * 20 * Use UM_KERN_PAGE_SIZE instead of PAGE_SIZE because that calls getpagesize 21 * on some systems. 22 */ 23 | 1// SPDX-License-Identifier: GPL-2.0 2/* 3 * Copyright (C) 2015 Thomas Meyer (thomas@m3y3r.de) 4 * Copyright (C) 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com) 5 */ 6 7#include <signal.h> 8#include <sched.h> --- 7 unchanged lines hidden (view full) --- 16/* 17 * This is in a separate file because it needs to be compiled with any 18 * extraneous gcc flags (-pg, -fprofile-arcs, -ftest-coverage) disabled 19 * 20 * Use UM_KERN_PAGE_SIZE instead of PAGE_SIZE because that calls getpagesize 21 * on some systems. 22 */ 23 |
24void __attribute__ ((__section__ (".__syscall_stub"))) | 24void __section(".__syscall_stub") |
25stub_clone_handler(void) 26{ 27 struct stub_data *data = (struct stub_data *) STUB_DATA; 28 long err; 29 30 err = stub_syscall2(__NR_clone, CLONE_PARENT | CLONE_FILES | SIGCHLD, 31 STUB_DATA + UM_KERN_PAGE_SIZE / 2 - sizeof(void *)); 32 if (err != 0) --- 20 unchanged lines hidden --- | 25stub_clone_handler(void) 26{ 27 struct stub_data *data = (struct stub_data *) STUB_DATA; 28 long err; 29 30 err = stub_syscall2(__NR_clone, CLONE_PARENT | CLONE_FILES | SIGCHLD, 31 STUB_DATA + UM_KERN_PAGE_SIZE / 2 - sizeof(void *)); 32 if (err != 0) --- 20 unchanged lines hidden --- |