public inbox for libc-ports@sourceware.org
 help / color / mirror / Atom feed
* [PATCH 1/4] Update Alpha O_SYNC.
  2010-01-12 21:25 Updates for Alpha Matt Turner
@ 2010-01-12 21:25 ` Matt Turner
  2010-01-12 21:25   ` [PATCH 2/4] Update Alpha bits/fcntl.h for XPG7 and allow bits/stat.h inclusion from fcntl.h Matt Turner
  2010-01-30  0:25 ` Updates for Alpha Joseph S. Myers
  1 sibling, 1 reply; 7+ messages in thread
From: Matt Turner @ 2010-01-12 21:25 UTC (permalink / raw)
  To: Joseph S. Myers; +Cc: libc-ports, Matt Turner

Signed-off-by: Matt Turner <mattst88@gmail.com>
---
 ChangeLog.alpha                            |    5 +++++
 sysdeps/unix/sysv/linux/alpha/bits/fcntl.h |    6 +++---
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/ChangeLog.alpha b/ChangeLog.alpha
index ed97e8b..812a9cf 100644
--- a/ChangeLog.alpha
+++ b/ChangeLog.alpha
@@ -1,3 +1,8 @@
+2010-01-12  Matt Turner  <mattst88@gmail.com>
+
+	* sysdeps/unix/sysv/linux/alpha/bits/fcntl.h: Redefine O_SYNC and
+	O_DSYNC to match 2.6.33+ kernels.
+
 2009-11-23  Matt Turner  <mattst88@gmail.com>
 
 	* sysdeps/unix/sysv/linux/alpha/bits/stat.h: Use struct timespec
diff --git a/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h b/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h
index 1e71643..a6ea1ca 100644
--- a/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h
+++ b/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h
@@ -1,5 +1,5 @@
 /* O_*, F_*, FD_* bit values for Linux.
-   Copyright (C) 1995-2000,2004,2005,2006,2007 Free Software Foundation, Inc.
+   Copyright (C) 1995-2000,2004,2005,2006,2007,2010 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
@@ -41,7 +41,7 @@
 #define O_NONBLOCK	 00004
 #define O_APPEND	 00010
 #define O_NDELAY	O_NONBLOCK
-#define O_SYNC		040000
+#define O_SYNC		020040000
 #define O_FSYNC		O_SYNC
 #define O_ASYNC		020000	/* fcntl, for BSD compatibility */
 
@@ -62,7 +62,7 @@
    We define the symbols here but let them do the same as O_SYNC since
    this is a superset.  */
 #if defined __USE_POSIX199309 || defined __USE_UNIX98
-# define O_DSYNC	O_SYNC	/* Synchronize data.  */
+# define O_DSYNC	040000	/* Synchronize data.  */
 # define O_RSYNC	O_SYNC	/* Synchronize read operations.  */
 #endif
 
-- 
1.6.4.4

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH 2/4] Update Alpha bits/fcntl.h for XPG7 and allow bits/stat.h inclusion from fcntl.h.
  2010-01-12 21:25 ` [PATCH 1/4] Update Alpha O_SYNC Matt Turner
@ 2010-01-12 21:25   ` Matt Turner
  2010-01-12 21:25     ` [PATCH 3/4] Update Alpha bits/sigaction.h for XPG7 Matt Turner
  0 siblings, 1 reply; 7+ messages in thread
From: Matt Turner @ 2010-01-12 21:25 UTC (permalink / raw)
  To: Joseph S. Myers; +Cc: libc-ports, Matt Turner

Signed-off-by: Matt Turner <mattst88@gmail.com>
---
 ChangeLog.alpha                            |    8 ++++++++
 sysdeps/unix/sysv/linux/alpha/bits/fcntl.h |   10 +++++++---
 sysdeps/unix/sysv/linux/alpha/bits/stat.h  |    4 ++--
 3 files changed, 17 insertions(+), 5 deletions(-)

diff --git a/ChangeLog.alpha b/ChangeLog.alpha
index 812a9cf..2f36660 100644
--- a/ChangeLog.alpha
+++ b/ChangeLog.alpha
@@ -1,5 +1,13 @@
 2010-01-12  Matt Turner  <mattst88@gmail.com>
 
+	* sysdeps/unix/sysv/linux/alpha/bits/fcntl.h: Define O_DIRECTORY,
+	O_NOFOLLOW, O_CLOEXEC, F_DUPFD_CLOEXEC, F_SETOWN, and F_GETOWN for
+	XPG7.
+	* sysdeps/unix/sysv/linux/alpha/bits/stat.h: Enable using from
+	fcntl.h.
+
+2010-01-12  Matt Turner  <mattst88@gmail.com>
+
 	* sysdeps/unix/sysv/linux/alpha/bits/fcntl.h: Redefine O_SYNC and
 	O_DSYNC to match 2.6.33+ kernels.
 
diff --git a/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h b/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h
index a6ea1ca..7a6a3fd 100644
--- a/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h
+++ b/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h
@@ -45,12 +45,14 @@
 #define O_FSYNC		O_SYNC
 #define O_ASYNC		020000	/* fcntl, for BSD compatibility */
 
-#ifdef __USE_GNU
+#ifdef __USE_XOPEN2K8
 # define O_DIRECTORY	0100000	/* Must be a directory.  */
 # define O_NOFOLLOW	0200000	/* Do not follow links.  */
+# define O_CLOEXEC	010000000 /* Set close_on_exec.  */
+#endif
+#ifdef __USE_GNU
 # define O_DIRECT	02000000 /* Direct disk access.  */
 # define O_NOATIME	04000000 /* Do not set atime.  */
-# define O_CLOEXEC      010000000 /* Set close_on_exec.  */
 #endif
 
 #ifdef __USE_LARGEFILE64
@@ -79,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
+#if defined __USE_BSD || defined __USE_UNIX98 || defiend __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
@@ -93,6 +95,8 @@
 # define F_SETLEASE	1024	/* Set a lease.	 */
 # define F_GETLEASE	1025	/* Enquire what lease is active.  */
 # define F_NOTIFY	1026	/* Request notfications on a directory.	 */
+#endif
+#ifdef __USE_XOPEN2K8
 # define F_DUPFD_CLOEXEC 1030	/* Duplicate file descriptor with
 				   close-on-exit set.  */
 #endif
diff --git a/sysdeps/unix/sysv/linux/alpha/bits/stat.h b/sysdeps/unix/sysv/linux/alpha/bits/stat.h
index 0aaabe2..4dbfebe 100644
--- a/sysdeps/unix/sysv/linux/alpha/bits/stat.h
+++ b/sysdeps/unix/sysv/linux/alpha/bits/stat.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996,1997,1998,1999,2000,2001,2004
+/* Copyright (C) 1996,1997,1998,1999,2000,2001,2004,2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -17,7 +17,7 @@
    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
    02111-1307 USA.  */
 
-#ifndef _SYS_STAT_H
+#if !defined _SYS_STAT_H && !defined _FCNTL_H
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
-- 
1.6.4.4

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH 3/4] Update Alpha bits/sigaction.h for XPG7.
  2010-01-12 21:25   ` [PATCH 2/4] Update Alpha bits/fcntl.h for XPG7 and allow bits/stat.h inclusion from fcntl.h Matt Turner
@ 2010-01-12 21:25     ` Matt Turner
  2010-01-12 21:25       ` [PATCH 4/4] Fix Alpha bits/stat.h double inclusion problem Matt Turner
  0 siblings, 1 reply; 7+ messages in thread
From: Matt Turner @ 2010-01-12 21:25 UTC (permalink / raw)
  To: Joseph S. Myers; +Cc: libc-ports, Matt Turner

Signed-off-by: Matt Turner <mattst88@gmail.com>
---
 ChangeLog.alpha                                |    5 +++++
 sysdeps/unix/sysv/linux/alpha/bits/sigaction.h |    4 +++-
 2 files changed, 8 insertions(+), 1 deletions(-)

diff --git a/ChangeLog.alpha b/ChangeLog.alpha
index 2f36660..d6cd01f 100644
--- a/ChangeLog.alpha
+++ b/ChangeLog.alpha
@@ -1,5 +1,10 @@
 2010-01-12  Matt Turner  <mattst88@gmail.com>
 
+	* sysdeps/unix/sysv/linux/alpha/bits/sigaction.h: Define
+	SA_RESTART, SA_NODEFER and SA_RESETHAND if __USE_XOPEN2K8.
+
+2010-01-12  Matt Turner  <mattst88@gmail.com>
+
 	* sysdeps/unix/sysv/linux/alpha/bits/fcntl.h: Define O_DIRECTORY,
 	O_NOFOLLOW, O_CLOEXEC, F_DUPFD_CLOEXEC, F_SETOWN, and F_GETOWN for
 	XPG7.
diff --git a/sysdeps/unix/sysv/linux/alpha/bits/sigaction.h b/sysdeps/unix/sysv/linux/alpha/bits/sigaction.h
index 80feb2f..cdf4758 100644
--- a/sysdeps/unix/sysv/linux/alpha/bits/sigaction.h
+++ b/sysdeps/unix/sysv/linux/alpha/bits/sigaction.h
@@ -1,5 +1,5 @@
 /* The proper definitions for Linux/Alpha sigaction.
-   Copyright (C) 1996, 1997, 1999, 2000 Free Software Foundation, Inc.
+   Copyright (C) 1996, 1997, 1999, 2000, 2010 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
@@ -54,6 +54,8 @@ struct sigaction
 				    three arguments instead of one.  */
 #if defined __USE_UNIX98 || defined __USE_MISC
 # define SA_ONSTACK   0x00000001 /* Use signal stack by using `sa_restorer'. */
+#endif
+#if defined __USE_UNIX98 || defined __USE_MISC || defined __USE_XOPEN2K8
 # define SA_RESTART   0x00000002 /* Restart syscall on signal return.  */
 # define SA_NODEFER   0x00000008 /* Don't automatically block the signal
 				    when its handler is being executed.  */
-- 
1.6.4.4

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Updates for Alpha
@ 2010-01-12 21:25 Matt Turner
  2010-01-12 21:25 ` [PATCH 1/4] Update Alpha O_SYNC Matt Turner
  2010-01-30  0:25 ` Updates for Alpha Joseph S. Myers
  0 siblings, 2 replies; 7+ messages in thread
From: Matt Turner @ 2010-01-12 21:25 UTC (permalink / raw)
  To: Joseph S. Myers; +Cc: libc-ports


Following this email are four patches with minor fixes pointed out
by Joseph Myers. (Thanks a ton for pointing them out!)

My GNU copyright assignment paperwork should be in order. I mailed
it back in mid-December.

Thanks,
Matt

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH 4/4] Fix Alpha bits/stat.h double inclusion problem.
  2010-01-12 21:25     ` [PATCH 3/4] Update Alpha bits/sigaction.h for XPG7 Matt Turner
@ 2010-01-12 21:25       ` Matt Turner
  0 siblings, 0 replies; 7+ messages in thread
From: Matt Turner @ 2010-01-12 21:25 UTC (permalink / raw)
  To: Joseph S. Myers; +Cc: libc-ports, Matt Turner

Signed-off-by: Matt Turner <mattst88@gmail.com>
---
 ChangeLog.alpha                           |    5 +++++
 sysdeps/unix/sysv/linux/alpha/bits/stat.h |    5 +++++
 2 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/ChangeLog.alpha b/ChangeLog.alpha
index d6cd01f..0abea04 100644
--- a/ChangeLog.alpha
+++ b/ChangeLog.alpha
@@ -1,5 +1,10 @@
 2010-01-12  Matt Turner  <mattst88@gmail.com>
 
+	* sysdeps/unix/sysv/linux/alpha/bits/stat.h: Fix double-inclusion
+	problem.
+
+2010-01-12  Matt Turner  <mattst88@gmail.com>
+
 	* sysdeps/unix/sysv/linux/alpha/bits/sigaction.h: Define
 	SA_RESTART, SA_NODEFER and SA_RESETHAND if __USE_XOPEN2K8.
 
diff --git a/sysdeps/unix/sysv/linux/alpha/bits/stat.h b/sysdeps/unix/sysv/linux/alpha/bits/stat.h
index 4dbfebe..d7241bd 100644
--- a/sysdeps/unix/sysv/linux/alpha/bits/stat.h
+++ b/sysdeps/unix/sysv/linux/alpha/bits/stat.h
@@ -21,6 +21,9 @@
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
+#ifndef _BITS_STAT_H
+#define _BITS_STAT_H	1
+
 /* Versions of the `struct stat' data structure.  */
 #define _STAT_VER_KERNEL	0
 #define _STAT_VER_GLIBC2	1
@@ -155,3 +158,5 @@ struct stat64
 # define UTIME_NOW	((1l << 30) - 1l)
 # define UTIME_OMIT	((1l << 30) - 2l)
 #endif
+
+#endif /* bits/stat.h */
-- 
1.6.4.4

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Updates for Alpha
  2010-01-12 21:25 Updates for Alpha Matt Turner
  2010-01-12 21:25 ` [PATCH 1/4] Update Alpha O_SYNC Matt Turner
@ 2010-01-30  0:25 ` Joseph S. Myers
  2010-01-30 18:54   ` Mike Frysinger
  1 sibling, 1 reply; 7+ messages in thread
From: Joseph S. Myers @ 2010-01-30  0:25 UTC (permalink / raw)
  To: Matt Turner; +Cc: libc-ports

I have verified the assignment, and reviewed and committed these patches.  
I remind you that an ____longjmp_chk implementation is still needed for 
Alpha for it to work, and that it will need to be reviewed by someone with 
actual Alpha knowledge; an actual maintainer for Alpha is also needed.

-- 
Joseph S. Myers
joseph@codesourcery.com

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Updates for Alpha
  2010-01-30  0:25 ` Updates for Alpha Joseph S. Myers
@ 2010-01-30 18:54   ` Mike Frysinger
  0 siblings, 0 replies; 7+ messages in thread
From: Mike Frysinger @ 2010-01-30 18:54 UTC (permalink / raw)
  To: libc-ports; +Cc: Joseph S. Myers, Matt Turner

[-- Attachment #1: Type: Text/Plain, Size: 722 bytes --]

On Friday 29 January 2010 19:24:54 Joseph S. Myers wrote:
> I have verified the assignment, and reviewed and committed these patches.
> I remind you that an ____longjmp_chk implementation is still needed for
> Alpha for it to work, and that it will need to be reviewed by someone with
> actual Alpha knowledge; an actual maintainer for Alpha is also needed.

while true, you can still get a working for all real intents and purposes with 
a common C stub (which is what we do in Gentoo):
/* Stub to make building happy -- no fortify checks, but
   it at least does the correct thing (longjmps).  */
#include <setjmp.h>
void ____longjmp_chk (__jmp_buf env, int val)
{
  return __longjmp (env, val);
}
-mike

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2010-01-30 18:54 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-01-12 21:25 Updates for Alpha Matt Turner
2010-01-12 21:25 ` [PATCH 1/4] Update Alpha O_SYNC Matt Turner
2010-01-12 21:25   ` [PATCH 2/4] Update Alpha bits/fcntl.h for XPG7 and allow bits/stat.h inclusion from fcntl.h Matt Turner
2010-01-12 21:25     ` [PATCH 3/4] Update Alpha bits/sigaction.h for XPG7 Matt Turner
2010-01-12 21:25       ` [PATCH 4/4] Fix Alpha bits/stat.h double inclusion problem Matt Turner
2010-01-30  0:25 ` Updates for Alpha Joseph S. Myers
2010-01-30 18:54   ` Mike Frysinger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).