about summary refs log tree commit diff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2000-03-15 07:50:48 +0000
committerUlrich Drepper <drepper@redhat.com>2000-03-15 07:50:48 +0000
commit5d1415976fb392aac199c42a47bf453a86286da5 (patch)
tree1a962b9171aed5571400290ab7a4c7ae4d455634
parent30b416ea87471a739763966fddc37f6273be58e0 (diff)
downloadglibc-5d1415976fb392aac199c42a47bf453a86286da5.tar.gz
glibc-5d1415976fb392aac199c42a47bf453a86286da5.tar.xz
glibc-5d1415976fb392aac199c42a47bf453a86286da5.zip
Update.
2000-03-08  Andreas Jaeger  <aj@suse.de>

	* sysdeps/unix/sysv/linux/scsi/sg.h: Sync with Linux 2.3.50.

	* timezone/africa: Update from tzdata2000d.
	* timezone/asia: Likewise.
	* timezone/australasia: Likewise.
	* timezone/europe: Likewise.
	* timezone/northamerica: Likewise.
	* timezone/southamerica: Likewise.

	* po/fr.po: Update from translation team.
	* po/de.po: Likewise.

	* sysdeps/i386/fpu/bits/mathinline.h: Fix union definition error
	in __sgn1l, otherwise g++ fails to parse this.
	Reported by Sean Chen <sean.chen@turbolinux.com>.
-rw-r--r--ChangeLog20
-rw-r--r--linuxthreads/ChangeLog4
-rw-r--r--linuxthreads/condvar.c8
-rw-r--r--sysdeps/unix/sysv/linux/alpha/ioperm.c3
-rw-r--r--sysdeps/unix/sysv/linux/scsi/sg.h17
5 files changed, 42 insertions, 10 deletions
diff --git a/ChangeLog b/ChangeLog
index 0d362cbf4f..9277e73853 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,19 @@
+2000-03-08  Andreas Jaeger  <aj@suse.de>
+
+	* sysdeps/unix/sysv/linux/scsi/sg.h: Sync with Linux 2.3.50.
+
 2000-03-14  Ulrich Drepper  <drepper@redhat.com>
 
+	* timezone/africa: Update from tzdata2000d.
+	* timezone/asia: Likewise.
+	* timezone/australasia: Likewise.
+	* timezone/europe: Likewise.
+	* timezone/northamerica: Likewise.
+	* timezone/southamerica: Likewise.
+
+	* po/fr.po: Update from translation team.
+	* po/de.po: Likewise.
+
 	* elf/dl-deps.c (_dl_map_object_deps): Change return type and remove
 	last parameter.  Move code to add map to global scope from here...
 	* elf/dl-open.c (dl_open_worker): ...here.
@@ -151,9 +165,9 @@
 
 2000-03-06  Andreas Jaeger  <aj@suse.de>
 
- 	* sysdeps/i386/fpu/bits/mathinline.h: Fix union definition error
- 	in __sgn1l, otherwise g++ fails to parse this.
- 	Reported by Sean Chen <sean.chen@turbolinux.com>.
+	* sysdeps/i386/fpu/bits/mathinline.h: Fix union definition error
+	in __sgn1l, otherwise g++ fails to parse this.
+	Reported by Sean Chen <sean.chen@turbolinux.com>.
 
 2000-03-03  Geoff Keating  <geoffk@cygnus.com>
 
diff --git a/linuxthreads/ChangeLog b/linuxthreads/ChangeLog
index 2a7bcb9e60..725653b02c 100644
--- a/linuxthreads/ChangeLog
+++ b/linuxthreads/ChangeLog
@@ -1,5 +1,9 @@
 2000-03-14  Ulrich Drepper  <drepper@redhat.com>
 
+	* condvar.c (pthread_cond_wait): Check whether mutex is owned by
+	current thread and return error if not.
+	(pthread_cond_timedwait): Likewise.
+
 	* mutex.c (__pthread_once): Handle cancelled init function correctly.
 	(pthread_once_cancelhandler): New function.
 	Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
diff --git a/linuxthreads/condvar.c b/linuxthreads/condvar.c
index 410ca65af0..d1e91d228c 100644
--- a/linuxthreads/condvar.c
+++ b/linuxthreads/condvar.c
@@ -77,6 +77,10 @@ int pthread_cond_wait(pthread_cond_t *cond, pthread_mutex_t *mutex)
   pthread_extricate_if extr;
   int already_canceled = 0;
 
+  /* Check whether the mutex is locked and owned by this thread.  */
+  if (mutex->__m_owner != self)
+    return EINVAL;
+
   /* Set up extrication interface */
   extr.pu_object = cond;
   extr.pu_extricate_func = cond_extricate_func;
@@ -380,6 +384,10 @@ pthread_cond_timedwait_relative_new(pthread_cond_t *cond,
 int pthread_cond_timedwait(pthread_cond_t *cond, pthread_mutex_t *mutex,
                            const struct timespec * abstime)
 {
+  /* Check whether the mutex is locked and owned by this thread.  */
+  if (mutex->__m_owner != self)
+    return EINVAL;
+
   /* Indirect call through pointer! */
   return pthread_cond_tw_rel(cond, mutex, abstime);
 }
diff --git a/sysdeps/unix/sysv/linux/alpha/ioperm.c b/sysdeps/unix/sysv/linux/alpha/ioperm.c
index 7b38fcceea..65bab818d9 100644
--- a/sysdeps/unix/sysv/linux/alpha/ioperm.c
+++ b/sysdeps/unix/sysv/linux/alpha/ioperm.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992, 1996, 1997, 1998, 1999 Free Software Foundation, Inc.
+/* Copyright (C) 1992, 1996-1999, 2000 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by David Mosberger.
 
@@ -139,6 +139,7 @@ static struct platform {
   {"Sable",	IOSYS_CPUDEP},
   {"Miata",	IOSYS_CIA},
   {"Tsunami",	IOSYS_TSUNAMI},
+  {"Nautilus",	IOSYS_TSUNAMI},
   {"Rawhide",	IOSYS_MCPCIA},
   {"Ruffian",	IOSYS_CIA},
   {"Takara",	IOSYS_CIA},
diff --git a/sysdeps/unix/sysv/linux/scsi/sg.h b/sysdeps/unix/sysv/linux/scsi/sg.h
index 077ccd338d..246f56f5b9 100644
--- a/sysdeps/unix/sysv/linux/scsi/sg.h
+++ b/sysdeps/unix/sysv/linux/scsi/sg.h
@@ -34,7 +34,7 @@
 /* Same structure as used by readv() Linux system call. It defines one
    scatter-gather element. */
 typedef struct sg_iovec
-{                      
+{
   void * iov_base;            /* Starting address  */
   size_t iov_len;             /* Length in bytes  */
 } sg_iovec_t;
@@ -42,11 +42,12 @@ typedef struct sg_iovec
 
 typedef struct sg_io_hdr
 {
-  char interface_id;          /* [i] 'S' for SCSI generic (required) */
+  int interface_id;           /* [i] 'S' for SCSI generic (required) */
+  int dxfer_direction;        /* [i] data transfer direction  */
   unsigned char cmd_len;      /* [i] SCSI command length ( <= 16 bytes) */
-  unsigned char iovec_count;  /* [i] 0 implies no scatter gather */
   unsigned char mx_sb_len;    /* [i] max length to write to sbp */
   int dxfer_direction;        /* [i] data transfer direction  */
+  unsigned short int iovec_count; /* [i] 0 implies no scatter gather */
   unsigned int dxfer_len;     /* [i] byte count of data transfer */
   void * dxferp;              /* [i], [*io] points to data transfer memory
 				 or scatter gather list */
@@ -166,9 +167,13 @@ typedef struct sg_req_info {
 
 #define SG_GET_VERSION_NUM 0x2282 /* Example: version 2.1.34 yields 20134 */
 
-/* Returns -EBUSY if occupied else takes as input: 0 -> do nothing,
-   1 -> device reset or  2 -> bus reset (may not be activated yet) */
+/* Returns -EBUSY if occupied. 3rd argument pointer to int (see next) */
 #define SG_SCSI_RESET 0x2284
+/* Associated values that can be given to SG_SCSI_RESET follow */
+#define SG_SCSI_RESET_NOTHING	0
+#define SG_SCSI_RESET_DEVICE	1
+#define SG_SCSI_RESET_BUS	2
+#define SG_SCSI_RESET_HOST	3
 
 /* synchronous SCSI command ioctl, (only in version 3 interface) */
 #define SG_IO 0x2285   /* similar effect as write() followed by read() */
@@ -243,7 +248,7 @@ struct sg_header
 
 
 /* IOCTLs: The following are not required (or ignored) when the sg_io_hdr_t
-	   interface is used. That are kept for backward compatibility with
+	   interface is used. They are kept for backward compatibility with
 	   the original and version 2 drivers. */
 
 #define SG_SET_TIMEOUT		0x2201	/* Set timeout; *(int *)arg==timeout.  */