1f2f4bf5aSAlex Dewar /* SPDX-License-Identifier: GPL-2.0 */ 28569c914SAl Viro /* 38569c914SAl Viro * Copyright (C) 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com) 48569c914SAl Viro */ 58569c914SAl Viro 68569c914SAl Viro #ifndef __START_H__ 78569c914SAl Viro #define __START_H__ 88569c914SAl Viro 99e636452SAl Viro #include <generated/asm-offsets.h> 108569c914SAl Viro 118569c914SAl Viro /* 128569c914SAl Viro * Stolen from linux/const.h, which can't be directly included since 138569c914SAl Viro * this is used in userspace code, which has no access to the kernel 148569c914SAl Viro * headers. Changed to be suitable for adding casts to the start, 158569c914SAl Viro * rather than "UL" to the end. 168569c914SAl Viro */ 178569c914SAl Viro 188569c914SAl Viro /* Some constant macros are used in both assembler and 198569c914SAl Viro * C code. Therefore we cannot annotate them always with 208569c914SAl Viro * 'UL' and other type specifiers unilaterally. We 218569c914SAl Viro * use the following macros to deal with this. 228569c914SAl Viro */ 23bfc58e2bSJohannes Berg #define STUB_START stub_start 249f0b4807SJohannes Berg #define STUB_CODE STUB_START 259f0b4807SJohannes Berg #define STUB_DATA (STUB_CODE + UM_KERN_PAGE_SIZE) 26*6032aca0SJohannes Berg #define STUB_DATA_PAGES 1 /* must be a power of two */ 27*6032aca0SJohannes Berg #define STUB_END (STUB_DATA + STUB_DATA_PAGES * UM_KERN_PAGE_SIZE) 288569c914SAl Viro 298569c914SAl Viro #ifndef __ASSEMBLY__ 308569c914SAl Viro 3137185b33SAl Viro #include <sysdep/ptrace.h> 328569c914SAl Viro 338569c914SAl Viro struct cpu_task { 348569c914SAl Viro int pid; 358569c914SAl Viro void *task; 368569c914SAl Viro }; 378569c914SAl Viro 388569c914SAl Viro extern struct cpu_task cpu_tasks[]; 398569c914SAl Viro 408569c914SAl Viro extern unsigned long high_physmem; 418569c914SAl Viro extern unsigned long uml_physmem; 428569c914SAl Viro extern unsigned long uml_reserved; 438569c914SAl Viro extern unsigned long end_vm; 448569c914SAl Viro extern unsigned long start_vm; 458569c914SAl Viro extern unsigned long long highmem; 468569c914SAl Viro 478569c914SAl Viro extern unsigned long brk_start; 488569c914SAl Viro 498569c914SAl Viro extern unsigned long host_task_size; 50bfc58e2bSJohannes Berg extern unsigned long stub_start; 518569c914SAl Viro 528569c914SAl Viro extern int linux_main(int argc, char **argv); 5333bbc306SThomas Meyer extern void uml_finishsetup(void); 548569c914SAl Viro 55d3c1cfcdSMartin Pärtel struct siginfo; 56d3c1cfcdSMartin Pärtel extern void (*sig_info[])(int, struct siginfo *si, struct uml_pt_regs *); 578569c914SAl Viro 588569c914SAl Viro #endif 598569c914SAl Viro 608569c914SAl Viro #endif 61