This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Sync with Linux 3.5


I've reviewed the header changes for Linux 3.5 and suggest the following
changes. Tested on x86-64. Ok to commit?


Andreas

2012-07-25  Andreas Jaeger  <aj@suse.de>

	* sysdeps/unix/sysv/linux/s390/sys/ptrace.h: Add __THROW for
	ptrace.

	* sysdeps/unix/sysv/linux/sys/ptrace.h (__ptrace_eventcodes): Add
	new value PTRACE_EVENT_SECCOMP from Linux 3.5.
	(__ptrace_setoptions): Add new value PTRACE_O_TRACESECCOMP, adjust
	PTRACE_O_MASK.
	* sysdeps/unix/sysv/linux/s390/bits/ptrace.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/bits/ptrace.h: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/bits/ptrace.h: Likewise.

	* sysdeps/unix/sysv/linux/sys/epoll.h (EPOLLWAKEUP): Add new
	value.

	* sysdeps/unix/sysv/linux/bits/siginfo.h (siginfo_t): Add
	_sigsys.
	(si_call_addr, si_syscall, si_arch): Define new macro.
	* sysdeps/unix/sysv/linux/s390/bits/siginfo.h (siginfo_t): Add
	_sigsys.
	(si_call_addr, si_syscall, si_arch): Define new marcro.
	* sysdeps/unix/sysv/linux/sparc/bits/siginfo.h (siginfo_t): Add
	_sigsys.
	(si_call_addr, si_syscall, si_arch): Define new macro.
	* sysdeps/unix/sysv/linux/x86/bits/siginfo.h (struct): Add
	_sigsys.
	(si_call_addr, si_syscall, si_arch): Define new macro.

diff --git a/sysdeps/unix/sysv/linux/bits/siginfo.h b/sysdeps/unix/sysv/linux/bits/siginfo.h
index d68a493..81b91e6 100644
--- a/sysdeps/unix/sysv/linux/bits/siginfo.h
+++ b/sysdeps/unix/sysv/linux/bits/siginfo.h
@@ -1,5 +1,5 @@
 /* siginfo_t, sigevent and constants.  Linux version.
-   Copyright (C) 1997-2002, 2003, 2011, 2012 Free Software Foundation, Inc.
+   Copyright (C) 1997-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
@@ -103,6 +103,14 @@ typedef struct
 	    long int si_band;	/* Band event for SIGPOLL.  */
 	    int si_fd;
 	  } _sigpoll;
+
+	/* SIGSYS.  */
+	struct
+	  {
+	    void *_call_addr;	/* Calling user insn.  */
+	    int _syscall;	/* Triggering system call number.  */
+	    unsigned int _arch; /* AUDIT_ARCH_* of syscall.  */
+	} _sigsys;
       } _sifields;
   } siginfo_t;
 
@@ -121,6 +129,9 @@ typedef struct
 # define si_addr	_sifields._sigfault.si_addr
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
+# define si_call_addr 	_sifields._sigsys._call_addr
+# define si_syscall	_sifields._sigsys._syscall
+# define si_arch	_sifields._sigsys._arch
 
 
 /* Values for `si_code'.  Positive values are reserved for kernel-generated
diff --git a/sysdeps/unix/sysv/linux/powerpc/sys/ptrace.h b/sysdeps/unix/sysv/linux/powerpc/sys/ptrace.h
index d43a135..16f9cf7 100644
--- a/sysdeps/unix/sysv/linux/powerpc/sys/ptrace.h
+++ b/sysdeps/unix/sysv/linux/powerpc/sys/ptrace.h
@@ -1,5 +1,5 @@
 /* `ptrace' debugger support interface.  Linux version.
-   Copyright (C) 2001, 2006, 2007, 2011 Free Software Foundation, Inc.
+   Copyright (C) 2001-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
@@ -134,17 +134,20 @@ enum __ptrace_setoptions {
   PTRACE_O_TRACEEXEC	= 0x00000010,
   PTRACE_O_TRACEVFORKDONE = 0x00000020,
   PTRACE_O_TRACEEXIT	= 0x00000040,
-  PTRACE_O_MASK		= 0x0000007f
+  PTRACE_O_TRACESECCOMP = 0x00000080,
+  PTRACE_O_MASK		= 0x000000ff
 };
 
 /* Wait extended result codes for the above trace options.  */
-enum __ptrace_eventcodes {
+enum __ptrace_eventcodes
+{
   PTRACE_EVENT_FORK	= 1,
   PTRACE_EVENT_VFORK	= 2,
   PTRACE_EVENT_CLONE	= 3,
   PTRACE_EVENT_EXEC	= 4,
   PTRACE_EVENT_VFORK_DONE = 5,
-  PTRACE_EVENT_EXIT	= 6
+  PTRACE_EVENT_EXIT	= 6,
+  PTRAVE_EVENT_SECCOMP  = 7
 };
 
 /* Perform process tracing functions.  REQUEST is one of the values
diff --git a/sysdeps/unix/sysv/linux/s390/bits/siginfo.h b/sysdeps/unix/sysv/linux/s390/bits/siginfo.h
index baa9891..1477082 100644
--- a/sysdeps/unix/sysv/linux/s390/bits/siginfo.h
+++ b/sysdeps/unix/sysv/linux/s390/bits/siginfo.h
@@ -1,5 +1,5 @@
 /* siginfo_t, sigevent and constants.  S/390 version.
-   Copyright (C) 2001, 2002, 2003, 2009, 2011, 2012 Free Software Foundation, Inc.
+   Copyright (C) 2001-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
@@ -104,6 +104,14 @@ typedef struct
 	    long int si_band;	/* Band event for SIGPOLL.  */
 	    int si_fd;
 	  } _sigpoll;
+
+	/* SIGSYS.  */
+	struct
+	  {
+	    void *_call_addr;	/* Calling user insn.  */
+	    int _syscall;	/* Triggering system call number.  */
+	    unsigned int _arch; /* AUDIT_ARCH_* of syscall.  */
+	} _sigsys;
       } _sifields;
   } siginfo_t;
 
@@ -123,6 +131,9 @@ typedef struct
 # define si_trapno	_sifields._sigfault.si_trapno
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
+# define si_call_addr 	_sifields._sigsys._call_addr
+# define si_syscall	_sifields._sigsys._syscall
+# define si_arch	_sifields._sigsys._arch
 
 
 /* Values for `si_code'.  Positive values are reserved for kernel-generated
diff --git a/sysdeps/unix/sysv/linux/s390/sys/ptrace.h b/sysdeps/unix/sysv/linux/s390/sys/ptrace.h
index 4bc7768..266a749 100644
--- a/sysdeps/unix/sysv/linux/s390/sys/ptrace.h
+++ b/sysdeps/unix/sysv/linux/s390/sys/ptrace.h
@@ -1,5 +1,5 @@
 /* `ptrace' debugger support interface.  Linux version.
-   Copyright (C) 2000, 2006, 2007, 2011 Free Software Foundation, Inc.
+   Copyright (C) 2000-2012 Free Software Foundation, Inc.
    Contributed by Denis Joseph Barrow (djbarrow@de.ibm.com).
    This file is part of the GNU C Library.
 
@@ -165,7 +165,8 @@ enum __ptrace_flags
 };
 
 /* Options set using PTRACE_SETOPTIONS.  */
-enum __ptrace_setoptions {
+enum __ptrace_setoptions 
+{
   PTRACE_O_TRACESYSGOOD	= 0x00000001,
   PTRACE_O_TRACEFORK	= 0x00000002,
   PTRACE_O_TRACEVFORK   = 0x00000004,
@@ -173,17 +174,20 @@ enum __ptrace_setoptions {
   PTRACE_O_TRACEEXEC	= 0x00000010,
   PTRACE_O_TRACEVFORKDONE = 0x00000020,
   PTRACE_O_TRACEEXIT	= 0x00000040,
-  PTRACE_O_MASK		= 0x0000007f
+  PTRACE_O_TRACESECCOMP = 0x00000080,
+  PTRACE_O_MASK		= 0x000000ff
 };
 
 /* Wait extended result codes for the above trace options.  */
-enum __ptrace_eventcodes {
+enum __ptrace_eventcodes
+{
   PTRACE_EVENT_FORK	= 1,
   PTRACE_EVENT_VFORK	= 2,
   PTRACE_EVENT_CLONE	= 3,
   PTRACE_EVENT_EXEC	= 4,
   PTRACE_EVENT_VFORK_DONE = 5,
-  PTRACE_EVENT_EXIT	= 6
+  PTRACE_EVENT_EXIT	= 6,
+  PTRAVE_EVENT_SECCOMP  = 7
 };
 
 /* Perform process tracing functions.  REQUEST is one of the values
@@ -195,7 +199,7 @@ enum __ptrace_eventcodes {
    appear (those that are used for the particular request) as:
      pid_t PID, void *ADDR, int DATA, void *ADDR2
    after REQUEST.  */
-extern long int ptrace (enum __ptrace_request __request, ...);
+extern long int ptrace (enum __ptrace_request __request, ...) __THROW;
 
 __END_DECLS
 
diff --git a/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h b/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h
index 4ce1bbf..bd01dc5 100644
--- a/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h
+++ b/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h
@@ -1,5 +1,5 @@
 /* siginfo_t, sigevent and constants.  Linux/SPARC version.
-   Copyright (C) 1997-2002, 2003, 2011, 2012 Free Software Foundation, Inc.
+   Copyright (C) 1997-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
@@ -104,6 +104,14 @@ typedef struct
 	    int si_band;	/* Band event for SIGPOLL.  */
 	    int si_fd;
 	  } _sigpoll;
+
+	/* SIGSYS.  */
+	struct
+	  {
+	    void *_call_addr;	/* Calling user insn.  */
+	    int _syscall;	/* Triggering system call number.  */
+	    unsigned int _arch; /* AUDIT_ARCH_* of syscall.  */
+	} _sigsys;
       } _sifields;
   } siginfo_t;
 
@@ -123,6 +131,9 @@ typedef struct
 # define si_trapno	_sifields._sigfault.si_trapno
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
+# define si_call_addr 	_sifields._sigsys._call_addr
+# define si_syscall	_sifields._sigsys._syscall
+# define si_arch	_sifields._sigsys._arch
 
 
 /* Values for `si_code'.  Positive values are reserved for kernel-generated
diff --git a/sysdeps/unix/sysv/linux/sparc/sys/ptrace.h b/sysdeps/unix/sysv/linux/sparc/sys/ptrace.h
index e335362..0d76f42 100644
--- a/sysdeps/unix/sysv/linux/sparc/sys/ptrace.h
+++ b/sysdeps/unix/sysv/linux/sparc/sys/ptrace.h
@@ -1,6 +1,5 @@
 /* `ptrace' debugger support interface.  Linux/SPARC version.
-   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2006, 2007, 2011
-   Free Software Foundation, Inc.
+   Copyright (C) 1996-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
@@ -210,7 +209,8 @@ enum __ptrace_flags
 };
 
 /* Options set using PTRACE_SETOPTIONS.  */
-enum __ptrace_setoptions {
+enum __ptrace_setoptions
+{
   PTRACE_O_TRACESYSGOOD	= 0x00000001,
   PTRACE_O_TRACEFORK	= 0x00000002,
   PTRACE_O_TRACEVFORK   = 0x00000004,
@@ -218,17 +218,20 @@ enum __ptrace_setoptions {
   PTRACE_O_TRACEEXEC	= 0x00000010,
   PTRACE_O_TRACEVFORKDONE = 0x00000020,
   PTRACE_O_TRACEEXIT	= 0x00000040,
-  PTRACE_O_MASK		= 0x0000007f
+  PTRACE_O_TRACESECCOMP = 0x00000080,
+  PTRACE_O_MASK		= 0x000000ff
 };
 
 /* Wait extended result codes for the above trace options.  */
-enum __ptrace_eventcodes {
+enum __ptrace_eventcodes
+{
   PTRACE_EVENT_FORK	= 1,
   PTRACE_EVENT_VFORK	= 2,
   PTRACE_EVENT_CLONE	= 3,
   PTRACE_EVENT_EXEC	= 4,
   PTRACE_EVENT_VFORK_DONE = 5,
-  PTRACE_EVENT_EXIT	= 6
+  PTRACE_EVENT_EXIT	= 6,
+  PTRAVE_EVENT_SECCOMP  = 7
 };
 
 /* Perform process tracing functions.  REQUEST is one of the values
diff --git a/sysdeps/unix/sysv/linux/sys/epoll.h b/sysdeps/unix/sysv/linux/sys/epoll.h
index a55ebad..6c2f10a 100644
--- a/sysdeps/unix/sysv/linux/sys/epoll.h
+++ b/sysdeps/unix/sysv/linux/sys/epoll.h
@@ -61,6 +61,8 @@ enum EPOLL_EVENTS
 #define EPOLLHUP EPOLLHUP
     EPOLLRDHUP = 0x2000,
 #define EPOLLRDHUP EPOLLRDHUP
+    EPOLLWAKEUP = 1u << 29,
+#define EPOLLWAKEUP EPOLLWAKEUP
     EPOLLONESHOT = 1u << 30,
 #define EPOLLONESHOT EPOLLONESHOT
     EPOLLET = 1u << 31
diff --git a/sysdeps/unix/sysv/linux/sys/ptrace.h b/sysdeps/unix/sysv/linux/sys/ptrace.h
index eadb4d0..7a7998a 100644
--- a/sysdeps/unix/sysv/linux/sys/ptrace.h
+++ b/sysdeps/unix/sysv/linux/sys/ptrace.h
@@ -1,5 +1,5 @@
 /* `ptrace' debugger support interface.  Linux version.
-   Copyright (C) 1996-1999,2000,2006,2007,2011 Free Software Foundation, Inc.
+   Copyright (C) 1996-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
@@ -165,7 +165,8 @@ enum __ptrace_setoptions
   PTRACE_O_TRACEEXEC	= 0x00000010,
   PTRACE_O_TRACEVFORKDONE = 0x00000020,
   PTRACE_O_TRACEEXIT	= 0x00000040,
-  PTRACE_O_MASK		= 0x0000007f
+  PTRACE_O_TRACESECCOMP = 0x00000080,
+  PTRACE_O_MASK		= 0x000000ff
 };
 
 /* Wait extended result codes for the above trace options.  */
@@ -176,7 +177,8 @@ enum __ptrace_eventcodes
   PTRACE_EVENT_CLONE	= 3,
   PTRACE_EVENT_EXEC	= 4,
   PTRACE_EVENT_VFORK_DONE = 5,
-  PTRACE_EVENT_EXIT	= 6
+  PTRACE_EVENT_EXIT	= 6,
+  PTRAVE_EVENT_SECCOMP  = 7
 };
 
 /* Perform process tracing functions.  REQUEST is one of the values
diff --git a/sysdeps/unix/sysv/linux/x86/bits/siginfo.h b/sysdeps/unix/sysv/linux/x86/bits/siginfo.h
index 2e05e65..b679352 100644
--- a/sysdeps/unix/sysv/linux/x86/bits/siginfo.h
+++ b/sysdeps/unix/sysv/linux/x86/bits/siginfo.h
@@ -115,6 +115,15 @@ typedef struct
 	    long int si_band;	/* Band event for SIGPOLL.  */
 	    int si_fd;
 	  } _sigpoll;
+
+	/* SIGSYS.  */
+	struct
+	  {
+	    void *_call_addr;	/* Calling user insn.  */
+	    int _syscall;	/* Triggering system call number.  */
+	    unsigned int _arch; /* AUDIT_ARCH_* of syscall.  */
+	} _sigsys;
+
       } _sifields;
   } siginfo_t __SI_ALIGNMENT;
 
@@ -133,6 +142,9 @@ typedef struct
 # define si_addr	_sifields._sigfault.si_addr
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
+# define si_call_addr 	_sifields._sigsys._call_addr
+# define si_syscall	_sifields._sigsys._syscall
+# define si_arch	_sifields._sigsys._arch
 
 
 /* Values for `si_code'.  Positive values are reserved for kernel-generated

-- 
 Andreas Jaeger aj@{suse.com,opensuse.org} Twitter/Identica: jaegerandi
  SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 NÃrnberg, Germany
   GF: Jeff Hawn,Jennifer Guild,Felix ImendÃrffer,HRB16746 (AG NÃrnberg)
    GPG fingerprint = 93A3 365E CE47 B889 DF7F  FED1 389A 563C C272 A126


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]