2020-01-18 11:38:21 +03:00
|
|
|
/*
|
2021-08-14 17:03:38 +03:00
|
|
|
* Copyright (c) 2018-2021, Andreas Kling <kling@serenityos.org>
|
2020-01-18 11:38:21 +03:00
|
|
|
*
|
2021-04-22 11:24:48 +03:00
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
2020-01-18 11:38:21 +03:00
|
|
|
*/
|
|
|
|
|
2018-10-14 23:57:41 +03:00
|
|
|
#pragma once
|
|
|
|
|
2020-08-08 18:32:34 +03:00
|
|
|
#include <AK/DistinctNumeric.h>
|
2019-04-06 15:29:29 +03:00
|
|
|
#include <AK/Types.h>
|
2021-08-14 19:52:14 +03:00
|
|
|
#include <Kernel/API/POSIX/dirent.h>
|
2021-08-14 16:36:26 +03:00
|
|
|
#include <Kernel/API/POSIX/fcntl.h>
|
2021-08-14 18:12:54 +03:00
|
|
|
#include <Kernel/API/POSIX/futex.h>
|
2021-08-14 19:06:44 +03:00
|
|
|
#include <Kernel/API/POSIX/net/if.h>
|
|
|
|
#include <Kernel/API/POSIX/net/if_arp.h>
|
|
|
|
#include <Kernel/API/POSIX/net/route.h>
|
2021-08-14 17:53:38 +03:00
|
|
|
#include <Kernel/API/POSIX/netinet/in.h>
|
2021-08-14 19:57:35 +03:00
|
|
|
#include <Kernel/API/POSIX/poll.h>
|
2021-08-14 19:28:05 +03:00
|
|
|
#include <Kernel/API/POSIX/serenity.h>
|
2021-08-14 18:05:53 +03:00
|
|
|
#include <Kernel/API/POSIX/signal.h>
|
2021-08-14 20:07:36 +03:00
|
|
|
#include <Kernel/API/POSIX/stdio.h>
|
2021-08-14 17:03:38 +03:00
|
|
|
#include <Kernel/API/POSIX/sys/mman.h>
|
2021-08-14 20:35:40 +03:00
|
|
|
#include <Kernel/API/POSIX/sys/ptrace.h>
|
2021-08-14 17:34:29 +03:00
|
|
|
#include <Kernel/API/POSIX/sys/socket.h>
|
2021-08-14 16:42:24 +03:00
|
|
|
#include <Kernel/API/POSIX/sys/stat.h>
|
2021-08-14 20:24:36 +03:00
|
|
|
#include <Kernel/API/POSIX/sys/time.h>
|
2021-08-14 20:17:32 +03:00
|
|
|
#include <Kernel/API/POSIX/sys/times.h>
|
2021-08-14 20:38:47 +03:00
|
|
|
#include <Kernel/API/POSIX/sys/uio.h>
|
2021-08-14 17:34:29 +03:00
|
|
|
#include <Kernel/API/POSIX/sys/un.h>
|
2021-08-14 19:55:39 +03:00
|
|
|
#include <Kernel/API/POSIX/sys/utsname.h>
|
2021-08-14 19:18:30 +03:00
|
|
|
#include <Kernel/API/POSIX/sys/wait.h>
|
2021-08-14 17:14:32 +03:00
|
|
|
#include <Kernel/API/POSIX/termios.h>
|
2021-08-14 16:42:24 +03:00
|
|
|
#include <Kernel/API/POSIX/time.h>
|
2021-08-14 20:03:23 +03:00
|
|
|
#include <Kernel/API/POSIX/unistd.h>
|
2020-05-28 17:52:02 +03:00
|
|
|
|
|
|
|
// Kernel internal options.
|
|
|
|
#define O_NOFOLLOW_NOERROR (1 << 29)
|
|
|
|
#define O_UNLINK_INTERNAL (1 << 30)
|
2020-08-08 18:32:34 +03:00
|
|
|
// Avoid interference with AK/Types.h and LibC/sys/types.h by defining *separate* names:
|
|
|
|
TYPEDEF_DISTINCT_ORDERED_ID(pid_t, ProcessID);
|
|
|
|
TYPEDEF_DISTINCT_ORDERED_ID(pid_t, ThreadID);
|
|
|
|
TYPEDEF_DISTINCT_ORDERED_ID(pid_t, SessionID);
|
|
|
|
TYPEDEF_DISTINCT_ORDERED_ID(pid_t, ProcessGroupID);
|
2018-12-03 03:12:26 +03:00
|
|
|
|
2019-07-03 22:17:35 +03:00
|
|
|
typedef u32 __u32;
|
|
|
|
typedef u16 __u16;
|
|
|
|
typedef u8 __u8;
|
2019-04-06 15:29:29 +03:00
|
|
|
typedef int __s32;
|
|
|
|
typedef short __s16;
|
|
|
|
|
2019-05-30 00:20:51 +03:00
|
|
|
struct sched_param {
|
|
|
|
int sched_priority;
|
|
|
|
};
|
2019-09-23 20:06:03 +03:00
|
|
|
|
2021-05-19 12:31:43 +03:00
|
|
|
#define ST_RDONLY 0x1
|
|
|
|
#define ST_NOSUID 0x2
|
|
|
|
|
|
|
|
struct statvfs {
|
|
|
|
unsigned long f_bsize;
|
|
|
|
unsigned long f_frsize;
|
|
|
|
fsblkcnt_t f_blocks;
|
|
|
|
fsblkcnt_t f_bfree;
|
|
|
|
fsblkcnt_t f_bavail;
|
|
|
|
|
|
|
|
fsfilcnt_t f_files;
|
|
|
|
fsfilcnt_t f_ffree;
|
|
|
|
fsfilcnt_t f_favail;
|
|
|
|
|
|
|
|
unsigned long f_fsid;
|
|
|
|
unsigned long f_flag;
|
|
|
|
unsigned long f_namemax;
|
|
|
|
};
|