diff options
Diffstat (limited to 'arch/um/include/os.h')
-rw-r--r-- | arch/um/include/os.h | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/arch/um/include/os.h b/arch/um/include/os.h index 2a1c64d8d0bf..d3d1bc6074ef 100644 --- a/arch/um/include/os.h +++ b/arch/um/include/os.h | |||
@@ -12,6 +12,7 @@ | |||
12 | #include "sysdep/ptrace.h" | 12 | #include "sysdep/ptrace.h" |
13 | #include "kern_util.h" | 13 | #include "kern_util.h" |
14 | #include "skas/mm_id.h" | 14 | #include "skas/mm_id.h" |
15 | #include "irq_user.h" | ||
15 | 16 | ||
16 | #define OS_TYPE_FILE 1 | 17 | #define OS_TYPE_FILE 1 |
17 | #define OS_TYPE_DIR 2 | 18 | #define OS_TYPE_DIR 2 |
@@ -121,6 +122,7 @@ static inline struct openflags of_cloexec(struct openflags flags) | |||
121 | return(flags); | 122 | return(flags); |
122 | } | 123 | } |
123 | 124 | ||
125 | /* file.c */ | ||
124 | extern int os_stat_file(const char *file_name, struct uml_stat *buf); | 126 | extern int os_stat_file(const char *file_name, struct uml_stat *buf); |
125 | extern int os_stat_fd(const int fd, struct uml_stat *buf); | 127 | extern int os_stat_fd(const int fd, struct uml_stat *buf); |
126 | extern int os_access(const char *file, int mode); | 128 | extern int os_access(const char *file, int mode); |
@@ -156,10 +158,20 @@ extern int os_connect_socket(char *name); | |||
156 | extern int os_file_type(char *file); | 158 | extern int os_file_type(char *file); |
157 | extern int os_file_mode(char *file, struct openflags *mode_out); | 159 | extern int os_file_mode(char *file, struct openflags *mode_out); |
158 | extern int os_lock_file(int fd, int excl); | 160 | extern int os_lock_file(int fd, int excl); |
161 | extern void os_flush_stdout(void); | ||
162 | extern int os_stat_filesystem(char *path, long *bsize_out, | ||
163 | long long *blocks_out, long long *bfree_out, | ||
164 | long long *bavail_out, long long *files_out, | ||
165 | long long *ffree_out, void *fsid_out, | ||
166 | int fsid_size, long *namelen_out, | ||
167 | long *spare_out); | ||
168 | extern int os_change_dir(char *dir); | ||
169 | extern int os_fchange_dir(int fd); | ||
159 | 170 | ||
160 | /* start_up.c */ | 171 | /* start_up.c */ |
161 | extern void os_early_checks(void); | 172 | extern void os_early_checks(void); |
162 | extern int can_do_skas(void); | 173 | extern int can_do_skas(void); |
174 | extern void os_check_bugs(void); | ||
163 | 175 | ||
164 | /* Make sure they are clear when running in TT mode. Required by | 176 | /* Make sure they are clear when running in TT mode. Required by |
165 | * SEGV_MAYBE_FIXABLE */ | 177 | * SEGV_MAYBE_FIXABLE */ |
@@ -198,6 +210,8 @@ extern void os_flush_stdout(void); | |||
198 | /* tt.c | 210 | /* tt.c |
199 | * for tt mode only (will be deleted in future...) | 211 | * for tt mode only (will be deleted in future...) |
200 | */ | 212 | */ |
213 | extern void forward_ipi(int fd, int pid); | ||
214 | extern void kill_child_dead(int pid); | ||
201 | extern void stop(void); | 215 | extern void stop(void); |
202 | extern int wait_for_stop(int pid, int sig, int cont_type, void *relay); | 216 | extern int wait_for_stop(int pid, int sig, int cont_type, void *relay); |
203 | extern int protect_memory(unsigned long addr, unsigned long len, | 217 | extern int protect_memory(unsigned long addr, unsigned long len, |
@@ -294,4 +308,26 @@ extern void initial_thread_cb_skas(void (*proc)(void *), | |||
294 | extern void halt_skas(void); | 308 | extern void halt_skas(void); |
295 | extern void reboot_skas(void); | 309 | extern void reboot_skas(void); |
296 | 310 | ||
311 | /* irq.c */ | ||
312 | extern int os_waiting_for_events(struct irq_fd *active_fds); | ||
313 | extern int os_isatty(int fd); | ||
314 | extern int os_create_pollfd(int fd, int events, void *tmp_pfd, int size_tmpfds); | ||
315 | extern void os_free_irq_by_cb(int (*test)(struct irq_fd *, void *), void *arg, | ||
316 | struct irq_fd *active_fds, struct irq_fd ***last_irq_ptr2); | ||
317 | extern void os_free_irq_later(struct irq_fd *active_fds, | ||
318 | int irq, void *dev_id); | ||
319 | extern int os_get_pollfd(int i); | ||
320 | extern void os_set_pollfd(int i, int fd); | ||
321 | extern void os_set_ioignore(void); | ||
322 | extern void init_irq_signals(int on_sigstack); | ||
323 | |||
324 | /* sigio.c */ | ||
325 | extern void write_sigio_workaround(void); | ||
326 | extern int add_sigio_fd(int fd, int read); | ||
327 | extern int ignore_sigio_fd(int fd); | ||
328 | |||
329 | /* skas/trap */ | ||
330 | extern void sig_handler_common_skas(int sig, void *sc_ptr); | ||
331 | extern void user_signal(int sig, union uml_pt_regs *regs, int pid); | ||
332 | |||
297 | #endif | 333 | #endif |