sd: remove 'ssd' driver support
[unleashed/tickless.git] / usr / src / lib / libshell / common / data / limits.c
blob3bea9cc9e58fcb01397f32c14f3816f037a99b8f
1 /***********************************************************************
2 * *
3 * This software is part of the ast package *
4 * Copyright (c) 1982-2010 AT&T Intellectual Property *
5 * and is licensed under the *
6 * Common Public License, Version 1.0 *
7 * by AT&T Intellectual Property *
8 * *
9 * A copy of the License is available at *
10 * http://www.opensource.org/licenses/cpl1.0.txt *
11 * (with md5 checksum 059e8cd6165cb4c31e351f2b69388fd9) *
12 * *
13 * Information and Software Systems Research *
14 * AT&T Research *
15 * Florham Park NJ *
16 * *
17 * David Korn <dgk@research.att.com> *
18 * *
19 ***********************************************************************/
20 #pragma prototyped
22 #include <ast.h>
23 #include "ulimit.h"
26 * This is the list of resouce limits controlled by ulimit
27 * This command requires getrlimit(), vlimit(), or ulimit()
30 #ifndef _no_ulimit
32 const char e_unlimited[] = "unlimited";
33 const char* e_units[] = { 0, "block", "byte", "kbyte", "second" };
35 const int shtab_units[] = { 1, 512, 1, 1024, 1 };
37 const Limit_t shtab_limits[] =
39 "as", "address space limit", RLIMIT_AS, 0, 'M', LIM_KBYTE,
40 "core", "core file size", RLIMIT_CORE, 0, 'c', LIM_BLOCK,
41 "cpu", "cpu time", RLIMIT_CPU, 0, 't', LIM_SECOND,
42 "data", "data size", RLIMIT_DATA, 0, 'd', LIM_KBYTE,
43 "fsize", "file size", RLIMIT_FSIZE, 0, 'f', LIM_BLOCK,
44 "locks", "number of file locks", RLIMIT_LOCKS, 0, 'L', LIM_COUNT,
45 "memlock", "locked address space", RLIMIT_MEMLOCK, 0, 'l', LIM_KBYTE,
46 "nofile", "number of open files", RLIMIT_NOFILE, "OPEN_MAX", 'n', LIM_COUNT,
47 "nproc", "number of processes", RLIMIT_NPROC, "CHILD_MAX", 'u', LIM_COUNT,
48 "pipe", "pipe buffer size", RLIMIT_PIPE, "PIPE_BUF", 'p', LIM_BYTE,
49 "rss", "resident set size", RLIMIT_RSS, 0, 'm', LIM_KBYTE,
50 "sbsize", "socket buffer size", RLIMIT_SBSIZE, "PIPE_BUF", 'b', LIM_BYTE,
51 "stack", "stack size", RLIMIT_STACK, 0, 's', LIM_KBYTE,
52 "threads", "number of threads", RLIMIT_PTHREAD, "THREADS_MAX", 'T', LIM_COUNT,
53 "vmem", "process size", RLIMIT_VMEM, 0, 'v', LIM_KBYTE,
54 { 0 }
57 #endif