treewide: remove redundant IS_ERR() before error code check
[linux/fpc-iii.git] / arch / um / include / shared / as-layout.h
blob5f286ef2721b8f214f67c5514b0e6907cc65485a
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3 * Copyright (C) 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com)
4 */
6 #ifndef __START_H__
7 #define __START_H__
9 #include <generated/asm-offsets.h>
12 * Stolen from linux/const.h, which can't be directly included since
13 * this is used in userspace code, which has no access to the kernel
14 * headers. Changed to be suitable for adding casts to the start,
15 * rather than "UL" to the end.
18 /* Some constant macros are used in both assembler and
19 * C code. Therefore we cannot annotate them always with
20 * 'UL' and other type specifiers unilaterally. We
21 * use the following macros to deal with this.
24 #ifdef __ASSEMBLY__
25 #define _UML_AC(X, Y) (Y)
26 #else
27 #define __UML_AC(X, Y) (X(Y))
28 #define _UML_AC(X, Y) __UML_AC(X, Y)
29 #endif
31 #define STUB_START _UML_AC(, 0x100000)
32 #define STUB_CODE _UML_AC((unsigned long), STUB_START)
33 #define STUB_DATA _UML_AC((unsigned long), STUB_CODE + UM_KERN_PAGE_SIZE)
34 #define STUB_END _UML_AC((unsigned long), STUB_DATA + UM_KERN_PAGE_SIZE)
36 #ifndef __ASSEMBLY__
38 #include <sysdep/ptrace.h>
40 struct cpu_task {
41 int pid;
42 void *task;
45 extern struct cpu_task cpu_tasks[];
47 extern unsigned long high_physmem;
48 extern unsigned long uml_physmem;
49 extern unsigned long uml_reserved;
50 extern unsigned long end_vm;
51 extern unsigned long start_vm;
52 extern unsigned long long highmem;
54 extern unsigned long brk_start;
56 extern unsigned long host_task_size;
58 extern int linux_main(int argc, char **argv);
59 extern void uml_finishsetup(void);
61 struct siginfo;
62 extern void (*sig_info[])(int, struct siginfo *si, struct uml_pt_regs *);
64 #endif
66 #endif