From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8448 invoked by alias); 15 Jun 2012 19:21:23 -0000 Received: (qmail 8058 invoked by uid 22791); 15 Jun 2012 19:21:12 -0000 X-SWARE-Spam-Status: No, hits=-4.9 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,KHOP_RCVD_TRUST,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE,SARE_SUB_ENC_UTF8,TW_FN X-Spam-Check-By: sourceware.org Received: from mail-pb0-f41.google.com (HELO mail-pb0-f41.google.com) (209.85.160.41) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 15 Jun 2012 19:20:46 +0000 Received: by pbbrp2 with SMTP id rp2so6186857pbb.0 for ; Fri, 15 Jun 2012 12:20:45 -0700 (PDT) Received: by 10.68.226.226 with SMTP id rv2mr23326655pbc.101.1339788045431; Fri, 15 Jun 2012 12:20:45 -0700 (PDT) Received: from anchor.twiddle.home ([173.160.232.49]) by mx.google.com with ESMTPS id tm2sm14126864pbc.69.2012.06.15.12.20.44 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 15 Jun 2012 12:20:45 -0700 (PDT) From: Richard Henderson To: libc-ports@sourceware.org Subject: =?UTF-8?q?=5BPATCH=203/7=5D=20alpha=3A=20Add=20missing=20definitions=20in=20resource=2Eh=2C=20shm=2Eh?= Date: Fri, 15 Jun 2012 19:21:00 -0000 Message-Id: <1339788037-29519-4-git-send-email-rth@twiddle.net> In-Reply-To: <1339788037-29519-1-git-send-email-rth@twiddle.net> References: <1339788037-29519-1-git-send-email-rth@twiddle.net> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-IsSubscribed: yes Mailing-List: contact libc-ports-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: libc-ports-owner@sourceware.org X-SW-Source: 2012-06/txt/msg00062.txt.bz2 --- sysdeps/unix/sysv/linux/alpha/bits/resource.h | 42 ++++++++++++++++++++++-- sysdeps/unix/sysv/linux/alpha/bits/shm.h | 4 +- 2 files changed, 40 insertions(+), 6 deletions(-) diff --git a/sysdeps/unix/sysv/linux/alpha/bits/resource.h b/sysdeps/unix/sysv/linux/alpha/bits/resource.h index da7b5a4..4df082c 100644 --- a/sysdeps/unix/sysv/linux/alpha/bits/resource.h +++ b/sysdeps/unix/sysv/linux/alpha/bits/resource.h @@ -1,6 +1,5 @@ /* Bit values & structures for resource limits. Alpha/Linux version. - Copyright (C) 1994, 1996, 1997, 1998, 1999, 2000, 2004, 2005 - Free Software Foundation, Inc. + Copyright (C) 1994-2012 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 @@ -99,7 +98,13 @@ enum __rlimit_resource __RLIMIT_RTPRIO = 14, #define RLIMIT_RTPRIO __RLIMIT_RTPRIO - __RLIMIT_NLIMITS = 15, + /* Maximum CPU time in µs that a process scheduled under a real-time + scheduling policy may consume without making a blocking system + call before being forcibly descheduled. */ + __RLIMIT_RTTIME = 15, +#define RLIMIT_RTTIME __RLIMIT_RTTIME + + __RLIMIT_NLIMITS = 16, __RLIM_NLIMITS = __RLIMIT_NLIMITS #define RLIMIT_NLIMITS __RLIMIT_NLIMITS #define RLIM_NLIMITS __RLIM_NLIMITS @@ -157,10 +162,11 @@ enum __rusage_who #define RUSAGE_SELF RUSAGE_SELF /* All of its terminated child processes. */ - RUSAGE_CHILDREN = -1, + RUSAGE_CHILDREN = -1 #define RUSAGE_CHILDREN RUSAGE_CHILDREN #ifdef __USE_GNU + , /* The calling thread. */ RUSAGE_THREAD = 1 # define RUSAGE_THREAD RUSAGE_THREAD @@ -230,3 +236,31 @@ enum __priority_which PRIO_USER = 2 /* WHO is a user ID. */ #define PRIO_USER PRIO_USER }; + + +__BEGIN_DECLS + +#ifdef __USE_GNU +/* Modify and return resource limits of a process atomically. */ +# ifndef __USE_FILE_OFFSET64 +extern int prlimit (__pid_t __pid, enum __rlimit_resource __resource, + const struct rlimit *__new_limit, + struct rlimit *__old_limit) __THROW; +# else +# ifdef __REDIRECT_NTH +extern int __REDIRECT_NTH (prlimit, (__pid_t __pid, + enum __rlimit_resource __resource, + const struct rlimit *__new_limit, + struct rlimit *__old_limit), prlimit64); +# else +# define prlimit prlimit64 +# endif +# endif +# ifdef __USE_LARGEFILE64 +extern int prlimit64 (__pid_t __pid, enum __rlimit_resource __resource, + const struct rlimit64 *__new_limit, + struct rlimit64 *__old_limit) __THROW; +# endif +#endif + +__END_DECLS diff --git a/sysdeps/unix/sysv/linux/alpha/bits/shm.h b/sysdeps/unix/sysv/linux/alpha/bits/shm.h index a52a266..48f4cb9 100644 --- a/sysdeps/unix/sysv/linux/alpha/bits/shm.h +++ b/sysdeps/unix/sysv/linux/alpha/bits/shm.h @@ -1,5 +1,4 @@ -/* Copyright (C) 1995, 1996, 1997, 2000, 2002, 2004 - Free Software Foundation, Inc. +/* Copyright (C) 1995-2012 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 @@ -30,6 +29,7 @@ #define SHM_RDONLY 010000 /* attach read-only else read-write */ #define SHM_RND 020000 /* round attach address to SHMLBA */ #define SHM_REMAP 040000 /* take-over region on attach */ +#define SHM_EXEC 0100000 /* execution access */ /* Commands for `shmctl'. */ #define SHM_LOCK 11 /* lock segment (root only) */ -- 1.7.7.6