alpha: Update bits/fcntl.h for XPG7 and define f_owner_ex et al.
authorRichard Henderson <rth@twiddle.net>
Fri, 26 Mar 2010 17:38:14 +0000 (10:38 -0700)
committerRichard Henderson <rth@twiddle.net>
Fri, 26 Mar 2010 20:17:52 +0000 (13:17 -0700)
Signed-off-by: Richard Henderson <rth@twiddle.net>
ChangeLog.alpha
sysdeps/unix/sysv/linux/alpha/bits/fcntl.h

index 6cb84b8..84945a8 100644 (file)
@@ -1,5 +1,12 @@
 2010-03-26  Richard Henderson  <rth@redhat.com>
 
+       * sysdeps/unix/sysv/linux/alpha/bits/fcntl.h (F_SETOWN_EX,
+       F_GETOWN_EX, F_OWNER_TID, F_OWNER_PID, F_OWNER_PGRP,
+       F_OWNER_GID, struct f_owner_ex): Define.
+       (F_SETOWN, F_GETOWN): Define with XPG7.
+
+2010-03-26  Richard Henderson  <rth@redhat.com>
+
        * sysdeps/unix/alpha/sysdep.h (PTR_MANGLE): Define for !PIC too.
        (PTR_DEMANGLE): Likewise.
 
index 7a6a3fd..860e9ac 100644 (file)
@@ -81,7 +81,7 @@
 #define F_SETLK64      F_SETLK /* Set record locking info (non-blocking).  */
 #define F_SETLKW64     F_SETLKW /* Set record locking info (blocking).  */
 
-#if defined __USE_BSD || defined __USE_UNIX98 || defiend __USE_XOPEN2K8
+#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
 # define F_SETOWN      5       /* Get owner of socket (receiver of SIGIO).  */
 # define F_GETOWN      6       /* Set owner of socket (receiver of SIGIO).  */
 #endif
@@ -89,6 +89,8 @@
 #ifdef __USE_GNU
 # define F_SETSIG      10      /* Set number of signal to be sent.  */
 # define F_GETSIG      11      /* Get number of signal to be sent.  */
+# define F_SETOWN_EX   15      /* Get owner (thread receiving SIGIO).  */
+# define F_GETOWN_EX   16      /* Set owner (thread receiving SIGIO).  */
 #endif
 
 #ifdef __USE_GNU
@@ -161,6 +163,23 @@ struct flock64
   };
 #endif
 
+#ifdef __USE_GNU
+/* Owner types.  */
+enum __pid_type
+  {
+    F_OWNER_TID = 0,           /* Kernel thread.  */
+    F_OWNER_PID,               /* Process.  */
+    F_OWNER_PGRP,              /* Process group.  */
+    F_OWNER_GID = F_OWNER_PGRP /* Alternative, obsolete name.  */
+  };
+
+/* Structure to use with F_GETOWN_EX and F_SETOWN_EX.  */
+struct f_owner_ex
+  {
+    enum __pid_type type;      /* Owner type of ID.  */
+    __pid_t pid;               /* ID of owner.  */
+  };
+#endif
 
 /* Define some more compatibility macros to be backward compatible with
    BSD systems which did not managed to hide these kernel macros.  */