blob: 8874f681b056751fa9be3bee4d1a12b86f8fd1b5 [file] [log] [blame]
Greg Kroah-Hartmanb2441312017-11-01 15:07:57 +01001/* SPDX-License-Identifier: GPL-2.0 */
Linus Torvalds1da177e2005-04-16 15:20:36 -07002#ifndef _ASM_GENERIC_RESOURCE_H
3#define _ASM_GENERIC_RESOURCE_H
4
David Howells8a1ab312012-10-04 18:20:15 +01005#include <uapi/asm-generic/resource.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -07006
Linus Torvalds1da177e2005-04-16 15:20:36 -07007
8/*
9 * boot-time rlimit defaults for the init task:
10 */
11#define INIT_RLIMITS \
12{ \
13 [RLIMIT_CPU] = { RLIM_INFINITY, RLIM_INFINITY }, \
14 [RLIMIT_FSIZE] = { RLIM_INFINITY, RLIM_INFINITY }, \
15 [RLIMIT_DATA] = { RLIM_INFINITY, RLIM_INFINITY }, \
James Hoganffe69022014-05-01 15:05:07 +010016 [RLIMIT_STACK] = { _STK_LIM, RLIM_INFINITY }, \
Linus Torvalds1da177e2005-04-16 15:20:36 -070017 [RLIMIT_CORE] = { 0, RLIM_INFINITY }, \
18 [RLIMIT_RSS] = { RLIM_INFINITY, RLIM_INFINITY }, \
19 [RLIMIT_NPROC] = { 0, 0 }, \
Tim Gardner0ac1ee02011-05-24 17:13:05 -070020 [RLIMIT_NOFILE] = { INR_OPEN_CUR, INR_OPEN_MAX }, \
Linus Torvalds1da177e2005-04-16 15:20:36 -070021 [RLIMIT_MEMLOCK] = { MLOCK_LIMIT, MLOCK_LIMIT }, \
22 [RLIMIT_AS] = { RLIM_INFINITY, RLIM_INFINITY }, \
23 [RLIMIT_LOCKS] = { RLIM_INFINITY, RLIM_INFINITY }, \
24 [RLIMIT_SIGPENDING] = { 0, 0 }, \
25 [RLIMIT_MSGQUEUE] = { MQ_BYTES_MAX, MQ_BYTES_MAX }, \
Matt Mackalle43379f2005-05-01 08:59:00 -070026 [RLIMIT_NICE] = { 0, 0 }, \
27 [RLIMIT_RTPRIO] = { 0, 0 }, \
Peter Zijlstra78f2c7d2008-01-25 21:08:27 +010028 [RLIMIT_RTTIME] = { RLIM_INFINITY, RLIM_INFINITY }, \
Linus Torvalds1da177e2005-04-16 15:20:36 -070029}
30
Linus Torvalds1da177e2005-04-16 15:20:36 -070031#endif