[T106][ZXW-22]7520V3SCV2.01.01.02P42U09_VEC_V0.8_AP_VEC origin source commit
Change-Id: Ic6e05d89ecd62fc34f82b23dcf306c93764aec4b
diff --git a/ap/libc/glibc/glibc-2.22/resource/sys/resource.h b/ap/libc/glibc/glibc-2.22/resource/sys/resource.h
new file mode 100644
index 0000000..f2e617a
--- /dev/null
+++ b/ap/libc/glibc/glibc-2.22/resource/sys/resource.h
@@ -0,0 +1,102 @@
+/* Copyright (C) 1992-2015 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+
+ The GNU C Library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, see
+ <http://www.gnu.org/licenses/>. */
+
+#ifndef _SYS_RESOURCE_H
+#define _SYS_RESOURCE_H 1
+
+#include <features.h>
+
+/* Get the system-dependent definitions of structures and bit values. */
+#include <bits/resource.h>
+
+#ifndef __id_t_defined
+typedef __id_t id_t;
+# define __id_t_defined
+#endif
+
+__BEGIN_DECLS
+
+/* The X/Open standard defines that all the functions below must use
+ `int' as the type for the first argument. When we are compiling with
+ GNU extensions we change this slightly to provide better error
+ checking. */
+#if defined __USE_GNU && !defined __cplusplus
+typedef enum __rlimit_resource __rlimit_resource_t;
+typedef enum __rusage_who __rusage_who_t;
+typedef enum __priority_which __priority_which_t;
+#else
+typedef int __rlimit_resource_t;
+typedef int __rusage_who_t;
+typedef int __priority_which_t;
+#endif
+
+/* Put the soft and hard limits for RESOURCE in *RLIMITS.
+ Returns 0 if successful, -1 if not (and sets errno). */
+#ifndef __USE_FILE_OFFSET64
+extern int getrlimit (__rlimit_resource_t __resource,
+ struct rlimit *__rlimits) __THROW;
+#else
+# ifdef __REDIRECT_NTH
+extern int __REDIRECT_NTH (getrlimit, (__rlimit_resource_t __resource,
+ struct rlimit *__rlimits), getrlimit64);
+# else
+# define getrlimit getrlimit64
+# endif
+#endif
+#ifdef __USE_LARGEFILE64
+extern int getrlimit64 (__rlimit_resource_t __resource,
+ struct rlimit64 *__rlimits) __THROW;
+#endif
+
+/* Set the soft and hard limits for RESOURCE to *RLIMITS.
+ Only the super-user can increase hard limits.
+ Return 0 if successful, -1 if not (and sets errno). */
+#ifndef __USE_FILE_OFFSET64
+extern int setrlimit (__rlimit_resource_t __resource,
+ const struct rlimit *__rlimits) __THROW;
+#else
+# ifdef __REDIRECT_NTH
+extern int __REDIRECT_NTH (setrlimit, (__rlimit_resource_t __resource,
+ const struct rlimit *__rlimits),
+ setrlimit64);
+# else
+# define setrlimit setrlimit64
+# endif
+#endif
+#ifdef __USE_LARGEFILE64
+extern int setrlimit64 (__rlimit_resource_t __resource,
+ const struct rlimit64 *__rlimits) __THROW;
+#endif
+
+/* Return resource usage information on process indicated by WHO
+ and put it in *USAGE. Returns 0 for success, -1 for failure. */
+extern int getrusage (__rusage_who_t __who, struct rusage *__usage) __THROW;
+
+/* Return the highest priority of any process specified by WHICH and WHO
+ (see above); if WHO is zero, the current process, process group, or user
+ (as specified by WHO) is used. A lower priority number means higher
+ priority. Priorities range from PRIO_MIN to PRIO_MAX (above). */
+extern int getpriority (__priority_which_t __which, id_t __who) __THROW;
+
+/* Set the priority of all processes specified by WHICH and WHO (see above)
+ to PRIO. Returns 0 on success, -1 on errors. */
+extern int setpriority (__priority_which_t __which, id_t __who, int __prio)
+ __THROW;
+
+__END_DECLS
+
+#endif /* sys/resource.h */
diff --git a/ap/libc/glibc/glibc-2.22/resource/sys/vlimit.h b/ap/libc/glibc/glibc-2.22/resource/sys/vlimit.h
new file mode 100644
index 0000000..a344a07
--- /dev/null
+++ b/ap/libc/glibc/glibc-2.22/resource/sys/vlimit.h
@@ -0,0 +1,67 @@
+/* Copyright (C) 1991-2015 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+
+ The GNU C Library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, see
+ <http://www.gnu.org/licenses/>. */
+
+#ifndef _SYS_VLIMIT_H
+#define _SYS_VLIMIT_H 1
+
+#include <features.h>
+
+__BEGIN_DECLS
+
+/* This interface is obsolete, and is superseded by <sys/resource.h>. */
+
+/* Kinds of resource limit. */
+enum __vlimit_resource
+{
+ /* Setting this non-zero makes it impossible to raise limits.
+ Only the super-use can set it to zero.
+
+ This is not implemented in recent versions of BSD, nor by
+ the GNU C library. */
+ LIM_NORAISE,
+
+ /* CPU time available for each process (seconds). */
+ LIM_CPU,
+
+ /* Largest file which can be created (bytes). */
+ LIM_FSIZE,
+
+ /* Maximum size of the data segment (bytes). */
+ LIM_DATA,
+
+ /* Maximum size of the stack segment (bytes). */
+ LIM_STACK,
+
+ /* Largest core file that will be created (bytes). */
+ LIM_CORE,
+
+ /* Resident set size (bytes). */
+ LIM_MAXRSS
+};
+
+/* This means no limit. */
+#define INFINITY 0x7fffffff
+
+
+/* Set the soft limit for RESOURCE to be VALUE.
+ Returns 0 for success, -1 for failure. */
+extern int vlimit (enum __vlimit_resource __resource, int __value) __THROW;
+
+
+__END_DECLS
+
+#endif /* sys/vlimit.h */
diff --git a/ap/libc/glibc/glibc-2.22/resource/sys/vtimes.h b/ap/libc/glibc/glibc-2.22/resource/sys/vtimes.h
new file mode 100644
index 0000000..2ac31d9
--- /dev/null
+++ b/ap/libc/glibc/glibc-2.22/resource/sys/vtimes.h
@@ -0,0 +1,68 @@
+/* Copyright (C) 1991-2015 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+
+ The GNU C Library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, see
+ <http://www.gnu.org/licenses/>. */
+
+#ifndef _SYS_VTIMES_H
+#define _SYS_VTIMES_H 1
+
+#include <features.h>
+
+__BEGIN_DECLS
+
+/* This interface is obsolete; use `getrusage' instead. */
+
+/* Granularity of the `vm_utime' and `vm_stime' fields of a `struct vtimes'.
+ (This is the frequency of the machine's power supply, in Hz.) */
+#define VTIMES_UNITS_PER_SECOND 60
+
+struct vtimes
+{
+ /* User time used in units of 1/VTIMES_UNITS_PER_SECOND seconds. */
+ int vm_utime;
+ /* System time used in units of 1/VTIMES_UNITS_PER_SECOND seconds. */
+ int vm_stime;
+
+ /* Amount of data and stack memory used (kilobyte-seconds). */
+ unsigned int vm_idsrss;
+ /* Amount of text memory used (kilobyte-seconds). */
+ unsigned int vm_ixrss;
+ /* Maximum resident set size (text, data, and stack) (kilobytes). */
+ int vm_maxrss;
+
+ /* Number of hard page faults (i.e. those that required I/O). */
+ int vm_majflt;
+ /* Number of soft page faults (i.e. those serviced by reclaiming
+ a page from the list of pages awaiting reallocation. */
+ int vm_minflt;
+
+ /* Number of times a process was swapped out of physical memory. */
+ int vm_nswap;
+
+ /* Number of input operations via the file system. Note: This
+ and `ru_oublock' do not include operations with the cache. */
+ int vm_inblk;
+ /* Number of output operations via the file system. */
+ int vm_oublk;
+};
+
+/* If CURRENT is not NULL, write statistics for the current process into
+ *CURRENT. If CHILD is not NULL, write statistics for all terminated child
+ processes into *CHILD. Returns 0 for success, -1 for failure. */
+extern int vtimes (struct vtimes * __current, struct vtimes * __child) __THROW;
+
+__END_DECLS
+
+#endif /* sys/vtimes.h */