linux.h (a7ac45761335b1d514804cd0bfe44bdb2c3a3e0c) linux.h (4ab7403bbd76f466d482cd69035091c04e409c09)
1/*-
2 * Copyright (c) 1994-1996 Søren Schmidt
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

--- 19 unchanged lines hidden (view full) ---

28 * $FreeBSD$
29 */
30
31#ifndef _I386_LINUX_H_
32#define _I386_LINUX_H_
33
34#include <sys/signal.h> /* for sigval union */
35
1/*-
2 * Copyright (c) 1994-1996 Søren Schmidt
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

--- 19 unchanged lines hidden (view full) ---

28 * $FreeBSD$
29 */
30
31#ifndef _I386_LINUX_H_
32#define _I386_LINUX_H_
33
34#include <sys/signal.h> /* for sigval union */
35
36#include <compat/linux/linux.h>
36#include <i386/linux/linux_syscall.h>
37
38/*
39 * debugging support
40 */
41extern u_char linux_debug_map[];
42#define ldebug(name) isclr(linux_debug_map, LINUX_SYS_linux_ ## name)
43#define ARGS(nm, fmt) "linux(%ld/%ld): "#nm"("fmt")\n", \

--- 185 unchanged lines hidden (view full) ---

229 uint64_t f_bavail;
230 uint64_t f_files;
231 uint64_t f_ffree;
232 l_fsid_t f_fsid;
233 l_int f_namelen;
234 l_int f_spare[6];
235};
236
37#include <i386/linux/linux_syscall.h>
38
39/*
40 * debugging support
41 */
42extern u_char linux_debug_map[];
43#define ldebug(name) isclr(linux_debug_map, LINUX_SYS_linux_ ## name)
44#define ARGS(nm, fmt) "linux(%ld/%ld): "#nm"("fmt")\n", \

--- 185 unchanged lines hidden (view full) ---

230 uint64_t f_bavail;
231 uint64_t f_files;
232 uint64_t f_ffree;
233 l_fsid_t f_fsid;
234 l_int f_namelen;
235 l_int f_spare[6];
236};
237
237/*
238 * Signalling
239 */
240#define LINUX_SIGHUP 1
241#define LINUX_SIGINT 2
242#define LINUX_SIGQUIT 3
243#define LINUX_SIGILL 4
244#define LINUX_SIGTRAP 5
245#define LINUX_SIGABRT 6
246#define LINUX_SIGIOT LINUX_SIGABRT
247#define LINUX_SIGBUS 7
248#define LINUX_SIGFPE 8
249#define LINUX_SIGKILL 9
250#define LINUX_SIGUSR1 10
251#define LINUX_SIGSEGV 11
252#define LINUX_SIGUSR2 12
253#define LINUX_SIGPIPE 13
254#define LINUX_SIGALRM 14
255#define LINUX_SIGTERM 15
256#define LINUX_SIGSTKFLT 16
257#define LINUX_SIGCHLD 17
258#define LINUX_SIGCONT 18
259#define LINUX_SIGSTOP 19
260#define LINUX_SIGTSTP 20
261#define LINUX_SIGTTIN 21
262#define LINUX_SIGTTOU 22
263#define LINUX_SIGURG 23
264#define LINUX_SIGXCPU 24
265#define LINUX_SIGXFSZ 25
266#define LINUX_SIGVTALRM 26
267#define LINUX_SIGPROF 27
268#define LINUX_SIGWINCH 28
269#define LINUX_SIGIO 29
270#define LINUX_SIGPOLL LINUX_SIGIO
271#define LINUX_SIGPWR 30
272#define LINUX_SIGSYS 31
273#define LINUX_SIGRTMIN 32
274
275#define LINUX_SIGTBLSZ 31
276#define LINUX_NSIG_WORDS 2
238#define LINUX_NSIG_WORDS 2
277#define LINUX_NBPW 32
278#define LINUX_NSIG (LINUX_NBPW * LINUX_NSIG_WORDS)
279
280/* sigaction flags */
281#define LINUX_SA_NOCLDSTOP 0x00000001
282#define LINUX_SA_NOCLDWAIT 0x00000002
283#define LINUX_SA_SIGINFO 0x00000004
284#define LINUX_SA_RESTORER 0x04000000
285#define LINUX_SA_ONSTACK 0x08000000
286#define LINUX_SA_RESTART 0x10000000
287#define LINUX_SA_INTERRUPT 0x20000000
288#define LINUX_SA_NOMASK 0x40000000
289#define LINUX_SA_ONESHOT 0x80000000
290
291/* sigprocmask actions */
292#define LINUX_SIG_BLOCK 0
293#define LINUX_SIG_UNBLOCK 1
294#define LINUX_SIG_SETMASK 2
295
239
240/* sigaction flags */
241#define LINUX_SA_NOCLDSTOP 0x00000001
242#define LINUX_SA_NOCLDWAIT 0x00000002
243#define LINUX_SA_SIGINFO 0x00000004
244#define LINUX_SA_RESTORER 0x04000000
245#define LINUX_SA_ONSTACK 0x08000000
246#define LINUX_SA_RESTART 0x10000000
247#define LINUX_SA_INTERRUPT 0x20000000
248#define LINUX_SA_NOMASK 0x40000000
249#define LINUX_SA_ONESHOT 0x80000000
250
251/* sigprocmask actions */
252#define LINUX_SIG_BLOCK 0
253#define LINUX_SIG_UNBLOCK 1
254#define LINUX_SIG_SETMASK 2
255
296/* sigset_t macros */
297#define LINUX_SIGEMPTYSET(set) (set).__bits[0] = (set).__bits[1] = 0
298#define LINUX_SIGISMEMBER(set, sig) SIGISMEMBER(set, sig)
299#define LINUX_SIGADDSET(set, sig) SIGADDSET(set, sig)
300
301/* sigaltstack */
302#define LINUX_MINSIGSTKSZ 2048
256/* sigaltstack */
257#define LINUX_MINSIGSTKSZ 2048
303#define LINUX_SS_ONSTACK 1
304#define LINUX_SS_DISABLE 2
305
306typedef void (*l_handler_t)(l_int);
307typedef l_ulong l_osigset_t;
308
309typedef struct {
258
259typedef void (*l_handler_t)(l_int);
260typedef l_ulong l_osigset_t;
261
262typedef struct {
310 l_uint __bits[LINUX_NSIG_WORDS];
311} l_sigset_t;
312
313typedef struct {
314 l_handler_t lsa_handler;
315 l_osigset_t lsa_mask;
316 l_ulong lsa_flags;
317 void (*lsa_restorer)(void);
318} l_osigaction_t;
319
320typedef struct {
321 l_handler_t lsa_handler;

--- 404 unchanged lines hidden ---
263 l_handler_t lsa_handler;
264 l_osigset_t lsa_mask;
265 l_ulong lsa_flags;
266 void (*lsa_restorer)(void);
267} l_osigaction_t;
268
269typedef struct {
270 l_handler_t lsa_handler;

--- 404 unchanged lines hidden ---