<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>change log for rtems (2011-07-31)</title>
</head>
<body text='#000000' bgcolor='#ffffff'>
<a name='cs1'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
PR 1867/cpukit
* Makefile.am, configure.ac, psx12/task.c, psxkey03/init.c,
psxrwlock01/test.c: Correct implementation of pthread_exit() and
pthread_join() to support the case where a thread is joinable but
calls pthread_exit() before a thread has attempted to join.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/ChangeLog.diff?r1=text&tr1=1.347&r2=text&tr2=1.348&diff_format=h">M</a></td><td width='1%'>1.348</td><td width='100%'>testsuites/psxtests/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/Makefile.am.diff?r1=text&tr1=1.75&r2=text&tr2=1.76&diff_format=h">M</a></td><td width='1%'>1.76</td><td width='100%'>testsuites/psxtests/Makefile.am</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/configure.ac.diff?r1=text&tr1=1.83&r2=text&tr2=1.84&diff_format=h">M</a></td><td width='1%'>1.84</td><td width='100%'>testsuites/psxtests/configure.ac</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx12/task.c.diff?r1=text&tr1=1.7&r2=text&tr2=1.8&diff_format=h">M</a></td><td width='1%'>1.8</td><td width='100%'>testsuites/psxtests/psx12/task.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psxkey03/init.c.diff?r1=text&tr1=1.7&r2=text&tr2=1.8&diff_format=h">M</a></td><td width='1%'>1.8</td><td width='100%'>testsuites/psxtests/psxkey03/init.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psxrwlock01/test.c.diff?r1=text&tr1=1.16&r2=text&tr2=1.17&diff_format=h">M</a></td><td width='1%'>1.17</td><td width='100%'>testsuites/psxtests/psxrwlock01/test.c</td></tr>
</table>
<pre>
<font color='#006600'>diff -u rtems/testsuites/psxtests/ChangeLog:1.347 rtems/testsuites/psxtests/ChangeLog:1.348
--- rtems/testsuites/psxtests/ChangeLog:1.347 Fri Jul 22 15:23:20 2011
+++ rtems/testsuites/psxtests/ChangeLog Sun Jul 31 11:16:17 2011
</font><font color='#997700'>@@ -1,3 +1,11 @@
</font><font color='#000088'>+2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
+
+ PR 1867/cpukit
+ * Makefile.am, configure.ac, psx12/task.c, psxkey03/init.c,
+ psxrwlock01/test.c: Correct implementation of pthread_exit() and
+ pthread_join() to support the case where a thread is joinable but
+ calls pthread_exit() before a thread has attempted to join.
+
</font> 2011-07-22 Joel Sherrill <joel.sherrill@oarcorp.com>
PR 1839/filesystem
<font color='#006600'>diff -u rtems/testsuites/psxtests/Makefile.am:1.75 rtems/testsuites/psxtests/Makefile.am:1.76
--- rtems/testsuites/psxtests/Makefile.am:1.75 Mon Jun 20 00:37:02 2011
+++ rtems/testsuites/psxtests/Makefile.am Sun Jul 31 11:16:17 2011
</font><font color='#997700'>@@ -7,7 +7,8 @@
</font> SUBDIRS = psxclock
if HAS_POSIX
SUBDIRS += psxhdrs psx01 psx02 psx03 psx04 psx05 psx06 psx07 psx08 psx09 \
<font color='#880000'>- psx10 psx11 psx12 psx13 psx14 psx15 psxaio01 psxaio02 psxaio03 \
</font><font color='#000088'>+ psx10 psx11 psx12 psx13 psx14 psx15 psx16 \
+ psxaio01 psxaio02 psxaio03 \
</font> psxalarm01 psxautoinit01 psxautoinit02 psxbarrier01 \
psxcancel psxcancel01 psxclassic01 psxcleanup psxcleanup01 \
psxcond01 psxenosys psxkey01 psxkey02 psxkey03 \
<font color='#006600'>diff -u rtems/testsuites/psxtests/configure.ac:1.83 rtems/testsuites/psxtests/configure.ac:1.84
--- rtems/testsuites/psxtests/configure.ac:1.83 Tue Mar 8 16:10:38 2011
+++ rtems/testsuites/psxtests/configure.ac Sun Jul 31 11:16:17 2011
</font><font color='#997700'>@@ -96,6 +96,7 @@
</font> psx13/Makefile
psx14/Makefile
psx15/Makefile
<font color='#000088'>+psx16/Makefile
</font> psxaio01/Makefile
psxaio02/Makefile
psxaio03/Makefile
<font color='#006600'>diff -u rtems/testsuites/psxtests/psx12/task.c:1.7 rtems/testsuites/psxtests/psx12/task.c:1.8
--- rtems/testsuites/psxtests/psx12/task.c:1.7 Tue Feb 22 03:47:31 2011
+++ rtems/testsuites/psxtests/psx12/task.c Sun Jul 31 11:16:17 2011
</font><font color='#997700'>@@ -30,6 +30,11 @@
</font> void *argument
)
{
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "Task_1: exitting" );
pthread_exit( NULL );
<font color='#006600'>diff -u rtems/testsuites/psxtests/psxkey03/init.c:1.7 rtems/testsuites/psxtests/psxkey03/init.c:1.8
--- rtems/testsuites/psxtests/psxkey03/init.c:1.7 Tue Feb 22 03:47:34 2011
+++ rtems/testsuites/psxtests/psxkey03/init.c Sun Jul 31 11:16:17 2011
</font><font color='#997700'>@@ -32,6 +32,11 @@
</font> {
int sc;
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "Test_Thread - pthread_setspecific - OK" );
sc = pthread_setspecific( Key, key_value );
rtems_test_assert( !sc );
<font color='#006600'>diff -u rtems/testsuites/psxtests/psxrwlock01/test.c:1.16 rtems/testsuites/psxtests/psxrwlock01/test.c:1.17
--- rtems/testsuites/psxtests/psxrwlock01/test.c:1.16 Tue Feb 22 03:47:35 2011
+++ rtems/testsuites/psxtests/psxrwlock01/test.c Sun Jul 31 11:16:17 2011
</font><font color='#997700'>@@ -39,6 +39,11 @@
</font> {
int status;
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "ReadThread - pthread_rwlock_rdlock(RWLock) blocking -- OK" );
status = pthread_rwlock_rdlock(&RWLock);
rtems_test_assert( !status );
<font color='#997700'>@@ -56,6 +61,11 @@
</font> {
int status;
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "WriteThread - pthread_rwlock_wrlock(RWLock) blocking -- OK" );
status = pthread_rwlock_wrlock(&RWLock);
rtems_test_assert( !status );
</pre>
<p> </p>
<a name='cs2'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>branches: 1.1.2; 1.1.4;
file Makefile.am was initially added on branch rtems-4-10-branch.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/Makefile.am?rev=NONE&content-type=text/vnd.viewcvs-markup">A</a></td><td width='1%'><font color="#000088">NONE</font></td><td width='100%'><font color="#000088">testsuites/psxtests/psx16/Makefile.am</font></td></tr>
</table>
<p> </p>
<a name='cs3'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>branches: 1.1.2; 1.1.4;
file .cvsignore was initially added on branch rtems-4-10-branch.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/.cvsignore?rev=NONE&content-type=text/vnd.viewcvs-markup">A</a></td><td width='1%'><font color="#000088">NONE</font></td><td width='100%'><font color="#000088">testsuites/psxtests/psx16/.cvsignore</font></td></tr>
</table>
<p> </p>
<a name='cs4'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
<font color='#225522'><em>(on branch rtems-4-10-branch)</em></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
PR 1867/cpukit
* Makefile.am, configure.ac, psx12/task.c, psxkey03/init.c,
psxrwlock01/test.c: Correct implementation of pthread_exit() and
pthread_join() to support the case where a thread is joinable but
calls pthread_exit() before a thread has attempted to join.
* psx16/.cvsignore, psx16/Makefile.am, psx16/init.c, psx16/psx16.doc,
psx16/psx16.scn: New files.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/ChangeLog.diff?r1=text&tr1=1.264.2.3&r2=text&tr2=1.264.2.4&diff_format=h">M</a></td><td width='1%'>1.264.2.4</td><td width='100%'>testsuites/psxtests/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/Makefile.am.diff?r1=text&tr1=1.58&r2=text&tr2=1.58.2.1&diff_format=h">M</a></td><td width='1%'>1.58.2.1</td><td width='100%'>testsuites/psxtests/Makefile.am</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/configure.ac.diff?r1=text&tr1=1.61.2.3&r2=text&tr2=1.61.2.4&diff_format=h">M</a></td><td width='1%'>1.61.2.4</td><td width='100%'>testsuites/psxtests/configure.ac</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx12/task.c.diff?r1=text&tr1=1.6&r2=text&tr2=1.6.8.1&diff_format=h">M</a></td><td width='1%'>1.6.8.1</td><td width='100%'>testsuites/psxtests/psx12/task.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/.cvsignore.diff?r1=text&tr1=1.1&r2=text&tr2=1.1.2.1&diff_format=h">M</a></td><td width='1%'>1.1.2.1</td><td width='100%'>testsuites/psxtests/psx16/.cvsignore</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/Makefile.am.diff?r1=text&tr1=1.1&r2=text&tr2=1.1.2.1&diff_format=h">M</a></td><td width='1%'>1.1.2.1</td><td width='100%'>testsuites/psxtests/psx16/Makefile.am</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/init.c.diff?r1=text&tr1=1.1&r2=text&tr2=1.1.2.1&diff_format=h">M</a></td><td width='1%'>1.1.2.1</td><td width='100%'>testsuites/psxtests/psx16/init.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/psx16.doc.diff?r1=text&tr1=1.1&r2=text&tr2=1.1.2.1&diff_format=h">M</a></td><td width='1%'>1.1.2.1</td><td width='100%'>testsuites/psxtests/psx16/psx16.doc</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/psx16.scn.diff?r1=text&tr1=1.1&r2=text&tr2=1.1.2.1&diff_format=h">M</a></td><td width='1%'>1.1.2.1</td><td width='100%'>testsuites/psxtests/psx16/psx16.scn</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psxkey03/init.c.diff?r1=text&tr1=1.5&r2=text&tr2=1.5.2.1&diff_format=h">M</a></td><td width='1%'>1.5.2.1</td><td width='100%'>testsuites/psxtests/psxkey03/init.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psxrwlock01/test.c.diff?r1=text&tr1=1.13&r2=text&tr2=1.13.2.1&diff_format=h">M</a></td><td width='1%'>1.13.2.1</td><td width='100%'>testsuites/psxtests/psxrwlock01/test.c</td></tr>
</table>
<pre>
<font color='#006600'>diff -u rtems/testsuites/psxtests/ChangeLog:1.264.2.3 rtems/testsuites/psxtests/ChangeLog:1.264.2.4
--- rtems/testsuites/psxtests/ChangeLog:1.264.2.3 Tue Feb 8 00:38:03 2011
+++ rtems/testsuites/psxtests/ChangeLog Sun Jul 31 11:16:42 2011
</font><font color='#997700'>@@ -1,14 +1,24 @@
</font><font color='#880000'>-2011-02-08 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
+
+ PR 1867/cpukit
+ * Makefile.am, configure.ac, psx12/task.c, psxkey03/init.c,
+ psxrwlock01/test.c: Correct implementation of pthread_exit() and
+ pthread_join() to support the case where a thread is joinable but
+ calls pthread_exit() before a thread has attempted to join.
+ * psx16/.cvsignore, psx16/Makefile.am, psx16/init.c, psx16/psx16.doc,
+ psx16/psx16.scn: New files.
+
+2011-02-08 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* include/pmacros.h: Add PRIxblksize_t, PRIxblkcnt_t.
* configure.ac: Add AC_CHECK_SIZEOF([blksize_t]),
AC_CHECK_SIZEOF([blkcnt_t]).
<font color='#880000'>-2011-02-02 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2011-02-02 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: Require autoconf-2.68, automake-1.11.1.
<font color='#880000'>-2010-10-01 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2010-10-01 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: Check for pthread_attr_{get,set}cputime instead of<span style="background-color: #FF0000"> </span>
pthread_pthread_attr_{get,set}cputime (Typo).
<font color='#997700'>@@ -18,7 +28,7 @@
</font> * psxfile01/test.c, psxmount/test.c, psxreaddir/test.c,
psxstat/test.c: Update to the new mount API.
<font color='#880000'>-2010-05-29 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2010-05-29 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: Add AC_CHECK_SIZEOF(off_t).
* include/pmacros.h: Add PRIdoff_t.
<font color='#997700'>@@ -55,7 +65,7 @@
</font> psxhdrs/pthread22.c, psxhdrs/sched01.c, psxhdrs/sched03.c:
Reflect POSIX changes to sched_param.
<font color='#880000'>-2010-04-02 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2010-04-02 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxhdrs/proc01.c, psxhdrs/proc02.c, psxhdrs/proc07.c,
psxhdrs/proc08.c, psxhdrs/proc09.c, psxhdrs/proc10.c,
<font color='#997700'>@@ -136,28 +146,28 @@
</font> * psxenosys/Makefile.am: Add documentation file.
* psxenosys/psxenosys.doc: New file.
<font color='#880000'>-2009-01-02 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-01-02 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxsignal03/init.c:<span style="background-color: #FF0000"> </span>
Print sigval.sival_ptr instead of "union sigval".
<font color='#880000'>-2009-01-01 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-01-01 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxstat/test.c: Apply PRI* macros to print struct stat fields.
* psxreaddir/test.c: Apply PRI* macros to print struct stat fields.
* psxfile01/test.c: Remove obsure #ifdef's.
Apply PRI* macros to print struct stat fields.
<font color='#880000'>-2009-10-31 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-31 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* include/pmacros.h: Change TM_OCTOBER to 9, TM_NOVEMBER to 10,
TM_DECEMBER to 11 (tm_mon months start with JAN = 0).
<font color='#880000'>-2009-10-31 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-31 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* include/pmacros.h: November is the 11th month.
<font color='#880000'>-2009-10-30 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-30 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxstat/test.c: Remove #ifdef's.
* psxmount/test.c, psxreaddir/test.c: Remove __P (unused anachronism).
<font color='#997700'>@@ -169,7 +179,7 @@
</font> rtems_object_api_minimum_class, rtems_object_api_maximum_class.
Reflect the prototypes having been missing to printf's.
<font color='#880000'>-2009-10-29 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-29 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxsysconf/init.c:<span style="background-color: #FF0000"> </span>
Comment out sysconf(LONG_MAX) check (not useful).
<font color='#997700'>@@ -179,11 +189,11 @@
</font> * psx10/init.c: Pass 0x7FFF instead of 0xFFFFFF as invalid pshared
attribute to pthread_condattr_setpshared for 16bit target compliance.
<font color='#880000'>-2009-10-28 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-28 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxbarrier01/test.c: Include <tmacros.h>
<font color='#880000'>-2009-10-27 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-27 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psx01/init.c, psx01/task.c, psx02/init.c, psx03/init.c,
psx04/init.c, psx05/init.c, psx06/init.c, psx07/init.c,
<font color='#997700'>@@ -193,7 +203,7 @@
</font> psxmsgq02/init.c, psxsignal01/init.c, psxualarm/init.c:
Use PRIxpthread_t to print pthread_t's.
<font color='#880000'>-2009-10-27 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-27 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxmsgq02/init.c:
Remove cast in call to fatal_posix_service_status_errno.
<font color='#997700'>@@ -206,14 +216,14 @@
</font> * configure.ac:
Add AC_CHECK_DECLS pthread_attr_getcputime, pthread_attr_setcputime.
<font color='#880000'>-2009-10-27 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-27 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxtimer01/psxtimer.c: Use %ld to print *.tv_nsec.
* psxsysconf/init.c: Use %ld to print *.tv_nsec.
* psxclock/init.c: Use %ld to print *.tv_nsec.
* psx06/init.c, psx06/system.h: Misc. warning fixes.
<font color='#880000'>-2009-10-26 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-26 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxsignal03/init.c: Add missing argument to printf.
* psxfile01/test.c: Use %zu instead of %d to print size_t's.
<font color='#997700'>@@ -222,7 +232,7 @@
</font> * configure.ac: Add AC_CHECK_HEADERS sys/mman.h.
Add AC_CHECK_DECLS pthread_atfork, adjtime, mprotect.
<font color='#880000'>-2009-10-25 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-25 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxtime/test.c: Include <sys/time.h>.
Conditionally add local prototype for adjtime()
<font color='#997700'>@@ -236,27 +246,27 @@
</font> if pthread.h doesn't supply it.
* psxkey01/init.c: Include "test_support.h".
<font color='#880000'>-2009-10-25 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-25 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: Check for pthread_atfork in pthread.h.
* psxrwlock01/test.c: Conditionally add local prototype for
pthread_atfork() if pthread.h doesn't supply it.
Include <pthread.h>.
<font color='#880000'>-2009-10-25 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-25 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: Check for sys/mman.h.
Check for mprotect in sys/mman.h.
* psxenosys/init.c: Conditionally add local prototype for
mprotect() if sys/mman.h doesn't supply it.
<font color='#880000'>-2009-10-25 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-25 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: Check for pthread_rwlock_unlock in pthread.h.
* psxrwlock01/test.c: Conditionally add local prototype for
pthread_rwlock_unlock() if pthread.h doesn't supply it.
<font color='#880000'>-2009-10-25 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-25 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psx01/init.c, psxalarm01/init.c, psxbarrier01/test.c,
psxclock/init.c, psxfatal01/testcase.h, psxfatal02/testcase.h,
<font color='#997700'>@@ -273,7 +283,7 @@
</font> * Makefile.am: Build file IO related tests even with POSIX threading is
disabled.
<font color='#880000'>-2009-10-20 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-10-20 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: Don't add -ansi -fasm to CFLAGS.
<font color='#997700'>@@ -768,7 +778,7 @@
</font>
* psxfile01/test.c: Change from int to size_t.
<font color='#880000'>-2009-04-03 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2009-04-03 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psx01/Makefile.am, psx02/Makefile.am, psx03/Makefile.am,
psx04/Makefile.am, psx05/Makefile.am, psx06/Makefile.am,
<font color='#997700'>@@ -816,7 +826,7 @@
</font>
* psx01/psx01.scn: Bump version to 4.9.99.0
<font color='#880000'>-2008-09-06 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2008-09-06 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxcleanup/psxcleanup.c, psxfatal_support/init.c,
psxfatal_support/system.h: Convert to "bool".
<font color='#997700'>@@ -1044,7 +1054,7 @@
</font> * psxrwlock01/main.c, psxrwlock01/test.c: Improve rwlock test to
include normal blocking and unblocking on timeout.
<font color='#880000'>-2006-12-02 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2006-12-02 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: New BUG-REPORT address.
<font color='#997700'>@@ -1078,11 +1088,11 @@
</font> * psxsem01/init.c: Make sem_timedwait more conformant to Open Group
specification.
<font color='#880000'>-2006-10-17 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2006-10-17 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: Require autoconf-2.60. Require automake-1.10.
<font color='#880000'>-2006-07-11 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2006-07-11 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psx01/Makefile.am, psx02/Makefile.am, psx03/Makefile.am,
psx04/Makefile.am, psx05/Makefile.am, psx06/Makefile.am,
<font color='#997700'>@@ -1268,7 +1278,7 @@
</font> * psxfile01/test.c, psxmsgq01/init.c, psxstat/test.c,
psxtimer/psxtimer.c: Eliminate warnings and typos.
<font color='#880000'>-2004-02-26 Sébastien Barré <sbarre@sdelcc.com>
</font><font color='#000088'>+2004-02-26 Sébastien Barré <sbarre@sdelcc.com>
</font>
PR 582/core
* psxmsgq01/init.c, psxmsgq01/psxmsgq01.scn: Fix the POSIX message
<font color='#006600'>diff -u rtems/testsuites/psxtests/Makefile.am:1.58 rtems/testsuites/psxtests/Makefile.am:1.58.2.1
--- rtems/testsuites/psxtests/Makefile.am:1.58 Mon Dec 28 10:43:10 2009
+++ rtems/testsuites/psxtests/Makefile.am Sun Jul 31 11:16:43 2011
</font><font color='#997700'>@@ -7,7 +7,7 @@
</font> SUBDIRS = psxclock
if HAS_POSIX
SUBDIRS += psxhdrs psx01 psx02 psx03 psx04 psx05 psx06 psx07 psx08 psx09 \
<font color='#880000'>- psx10 psx11 psx12 psx13 psx14 psxalarm01 \
</font><font color='#000088'>+ psx10 psx11 psx12 psx13 psx14 psx16 psxalarm01 \
</font> psxautoinit01 psxautoinit02 psxbarrier01 \
psxcancel psxcancel01 psxcleanup psxcleanup01 \
psxcond01 psxenosys psxkey01 psxkey02 \
<font color='#006600'>diff -u rtems/testsuites/psxtests/configure.ac:1.61.2.3 rtems/testsuites/psxtests/configure.ac:1.61.2.4
--- rtems/testsuites/psxtests/configure.ac:1.61.2.3 Tue Feb 8 00:38:03 2011
+++ rtems/testsuites/psxtests/configure.ac Sun Jul 31 11:16:43 2011
</font><font color='#997700'>@@ -74,6 +74,7 @@
</font> psx12/Makefile
psx13/Makefile
psx14/Makefile
<font color='#000088'>+psx16/Makefile
</font> psxalarm01/Makefile
psxautoinit01/Makefile
psxautoinit02/Makefile
<font color='#006600'>diff -u rtems/testsuites/psxtests/psx12/task.c:1.6 rtems/testsuites/psxtests/psx12/task.c:1.6.8.1
--- rtems/testsuites/psxtests/psx12/task.c:1.6 Thu Sep 4 13:53:38 2003
+++ rtems/testsuites/psxtests/psx12/task.c Sun Jul 31 11:16:43 2011
</font><font color='#997700'>@@ -26,6 +26,11 @@
</font> void *argument
)
{
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "Task_1: exitting" );
pthread_exit( NULL );
<font color='#006600'>diff -u /dev/null rtems/testsuites/psxtests/psx16/.cvsignore:1.1.2.1
--- /dev/null Sun Jul 31 12:11:27 2011
+++ rtems/testsuites/psxtests/psx16/.cvsignore Sun Jul 31 11:16:43 2011
</font><font color='#997700'>@@ -0,0 +1,2 @@
</font><font color='#000088'>+Makefile
+Makefile.in
</font>
<font color='#006600'>diff -u /dev/null rtems/testsuites/psxtests/psx16/Makefile.am:1.1.2.1
--- /dev/null Sun Jul 31 12:11:27 2011
+++ rtems/testsuites/psxtests/psx16/Makefile.am Sun Jul 31 11:16:43 2011
</font><font color='#997700'>@@ -0,0 +1,25 @@
</font><font color='#000088'>+##
+## $Id$
+##
+
+rtems_tests_PROGRAMS = psx16
+psx16_SOURCES = init.c
+
+dist_rtems_tests_DATA = psx16.scn
+dist_rtems_tests_DATA += psx16.doc
+
+include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg
+include $(top_srcdir)/../automake/compile.am
+include $(top_srcdir)/../automake/leaf.am
+
+AM_CPPFLAGS += -I$(top_srcdir)/include
+AM_CPPFLAGS += -I$(top_srcdir)/../support/include
+
+LINK_OBJS = $(psx16_OBJECTS) $(psx16_LDADD)
+LINK_LIBS = $(psx16_LDLIBS)
+
+psx16$(EXEEXT): $(psx16_OBJECTS) $(psx16_DEPENDENCIES)
+ @rm -f psx16$(EXEEXT)
+ $(make-exe)
+
+include $(top_srcdir)/../automake/local.am
</font>
<font color='#006600'>diff -u /dev/null rtems/testsuites/psxtests/psx16/init.c:1.1.2.1
--- /dev/null Sun Jul 31 12:11:27 2011
+++ rtems/testsuites/psxtests/psx16/init.c Sun Jul 31 11:16:43 2011
</font><font color='#997700'>@@ -0,0 +1,78 @@
</font><font color='#000088'>+/*
+ * COPYRIGHT (c) 1989-2011.
+ * On-Line Applications Research Corporation (OAR).
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.rtems.com/license/LICENSE.
+ *
+ * $Id$
+ */
+
+#include <tmacros.h>
+#include "test_support.h"
+#include <pthread.h>
+
+int Index;
+
+void *TestThread(
+ void *argument
+)
+{
+ int *index = (int *)argument;
+
+ *index = 7;<span style="background-color: #FF0000"> </span>
+
+ puts( "TestThread exiting" );
+ return argument;
+}
+
+void *POSIX_Init(
+ rtems_task_argument argument
+)
+{
+ int status;
+ pthread_t id;
+ pthread_attr_t attr;
+ void *join_return;
+
+ puts( "\n\n*** POSIX TEST PSX16 ***" );
+
+ Index = 5;
+
+ /* Initialize and set thread detached attribute */
+ pthread_attr_init(&attr);
+ pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_JOINABLE);
+
+ puts( "Creating TestThread" );
+ status = pthread_create( &id, &attr, TestThread, (void *)&Index );
+ rtems_test_assert( status == 0 );
+
+ /* let test thread run and exit */
+ puts( "Let TestThread run and exit before we attempt to join" );
+ sleep( 2 );
+
+ join_return = NULL;
+ status = pthread_join( id, &join_return );
+ rtems_test_assert( status == 0 );
+ rtems_test_assert( join_return == &Index );
+ rtems_test_assert( *(int *)join_return == 7 );
+ puts( "Successfully joined with TestThread" );
+
+ puts( "*** END OF POSIX TEST PSX16 ***" );
+
+ rtems_test_exit(0);
+}
+
+/* configuration information */
+
+#define CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER
+#define CONFIGURE_APPLICATION_NEEDS_CLOCK_DRIVER
+
+#define CONFIGURE_MAXIMUM_POSIX_THREADS 2
+
+#define CONFIGURE_POSIX_INIT_THREAD_TABLE
+
+#define CONFIGURE_INIT
+#include <rtems/confdefs.h>
+/* end of file */
</font>
<font color='#006600'>diff -u /dev/null rtems/testsuites/psxtests/psx16/psx16.doc:1.1.2.1
--- /dev/null Sun Jul 31 12:11:27 2011
+++ rtems/testsuites/psxtests/psx16/psx16.doc Sun Jul 31 11:16:43 2011
</font><font color='#997700'>@@ -0,0 +1,24 @@
</font><font color='#000088'>+#
+# $Id$
+#
+# COPYRIGHT (c) 1989-2011.
+# On-Line Applications Research Corporation (OAR).
+#
+# The license and distribution terms for this file may be
+# found in the file LICENSE in this distribution or at
+# http://www.rtems.com/license/LICENSE.
+#
+
+This file describes the directives and concepts tested by this test set.
+
+test set name: psx16
+
+directives:
+
+ pthread_join
+ pthread_exit
+
+concepts:
+
++ Ensure that if a joinable thread exits before it has been joined,
+that it waits for a thread to call pthread_join.
</font>
<font color='#006600'>diff -u /dev/null rtems/testsuites/psxtests/psx16/psx16.scn:1.1.2.1
--- /dev/null Sun Jul 31 12:11:27 2011
+++ rtems/testsuites/psxtests/psx16/psx16.scn Sun Jul 31 11:16:43 2011
</font><font color='#997700'>@@ -0,0 +1,6 @@
</font><font color='#000088'>+*** POSIX TEST PSX16 ***
+Creating TestThread
+Let TestThread run and exit before we attempt to join
+TestThread exiting
+Successfully joined with TestThread
+*** END OF POSIX TEST PSX16 ***
</font>
<font color='#006600'>diff -u rtems/testsuites/psxtests/psxkey03/init.c:1.5 rtems/testsuites/psxtests/psxkey03/init.c:1.5.2.1
--- rtems/testsuites/psxtests/psxkey03/init.c:1.5 Tue Dec 8 11:52:53 2009
+++ rtems/testsuites/psxtests/psxkey03/init.c Sun Jul 31 11:16:43 2011
</font><font color='#997700'>@@ -28,6 +28,11 @@
</font> {
int sc;
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "Test_Thread - pthread_setspecific - OK" );
sc = pthread_setspecific( Key, key_value );
rtems_test_assert( !sc );
<font color='#006600'>diff -u rtems/testsuites/psxtests/psxrwlock01/test.c:1.13 rtems/testsuites/psxtests/psxrwlock01/test.c:1.13.2.1
--- rtems/testsuites/psxtests/psxrwlock01/test.c:1.13 Tue Dec 8 15:16:02 2009
+++ rtems/testsuites/psxtests/psxrwlock01/test.c Sun Jul 31 11:16:43 2011
</font><font color='#997700'>@@ -35,6 +35,11 @@
</font> {
int status;
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "ReadThread - pthread_rwlock_rdlock(RWLock) blocking -- OK" );
status = pthread_rwlock_rdlock(&RWLock);
rtems_test_assert( !status );
<font color='#997700'>@@ -52,6 +57,11 @@
</font> {
int status;
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "WriteThread - pthread_rwlock_wrlock(RWLock) blocking -- OK" );
status = pthread_rwlock_wrlock(&RWLock);
rtems_test_assert( !status );
</pre>
<p> </p>
<a name='cs5'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>file psx16.scn was added on branch rtems-4-9-branch on 2011-07-31 16:17:02 +0000
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/psx16.scn?rev=1.1&content-type=text/vnd.viewcvs-markup">R</a></td><td width='1%'><font color="#880000">1.1</font></td><td width='100%'><font color="#880000">testsuites/psxtests/psx16/psx16.scn</font></td></tr>
</table>
<p> </p>
<a name='cs6'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>file init.c was added on branch rtems-4-9-branch on 2011-07-31 16:17:02 +0000
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/init.c?rev=1.1&content-type=text/vnd.viewcvs-markup">R</a></td><td width='1%'><font color="#880000">1.1</font></td><td width='100%'><font color="#880000">testsuites/psxtests/psx16/init.c</font></td></tr>
</table>
<p> </p>
<a name='cs7'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>file Makefile.am was added on branch rtems-4-9-branch on 2011-07-31 16:17:02 +0000
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/Makefile.am?rev=1.1&content-type=text/vnd.viewcvs-markup">R</a></td><td width='1%'><font color="#880000">1.1</font></td><td width='100%'><font color="#880000">testsuites/psxtests/psx16/Makefile.am</font></td></tr>
</table>
<p> </p>
<a name='cs8'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>branches: 1.1.2; 1.1.4;
file init.c was initially added on branch rtems-4-10-branch.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/init.c?rev=NONE&content-type=text/vnd.viewcvs-markup">A</a></td><td width='1%'><font color="#000088">NONE</font></td><td width='100%'><font color="#000088">testsuites/psxtests/psx16/init.c</font></td></tr>
</table>
<p> </p>
<a name='cs9'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>file .cvsignore was added on branch rtems-4-9-branch on 2011-07-31 16:17:02 +0000
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/.cvsignore?rev=1.1&content-type=text/vnd.viewcvs-markup">R</a></td><td width='1%'><font color="#880000">1.1</font></td><td width='100%'><font color="#880000">testsuites/psxtests/psx16/.cvsignore</font></td></tr>
</table>
<p> </p>
<a name='cs10'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>branches: 1.1.2; 1.1.4;
file psx16.doc was initially added on branch rtems-4-10-branch.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/psx16.doc?rev=NONE&content-type=text/vnd.viewcvs-markup">A</a></td><td width='1%'><font color="#000088">NONE</font></td><td width='100%'><font color="#000088">testsuites/psxtests/psx16/psx16.doc</font></td></tr>
</table>
<p> </p>
<a name='cs11'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>branches: 1.1.2; 1.1.4;
file psx16.scn was initially added on branch rtems-4-10-branch.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/psx16.scn?rev=NONE&content-type=text/vnd.viewcvs-markup">A</a></td><td width='1%'><font color="#000088">NONE</font></td><td width='100%'><font color="#000088">testsuites/psxtests/psx16/psx16.scn</font></td></tr>
</table>
<p> </p>
<a name='cs12'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>file psx16.doc was added on branch rtems-4-9-branch on 2011-07-31 16:17:02 +0000
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/psx16.doc?rev=1.1&content-type=text/vnd.viewcvs-markup">R</a></td><td width='1%'><font color="#880000">1.1</font></td><td width='100%'><font color="#880000">testsuites/psxtests/psx16/psx16.doc</font></td></tr>
</table>
<p> </p>
<a name='cs13'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
<font color='#225522'><em>(on branch rtems-4-9-branch)</em></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
PR 1867/cpukit
* posix/src/pthreadexit.c, posix/src/pthreadjoin.c: Correct
implementation of pthread_exit() and pthread_join() to support the
case where a thread is joinable but calls pthread_exit() before a
thread has attempted to join.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/ChangeLog.diff?r1=text&tr1=1.2891&r2=text&tr2=1.2892&diff_format=h">M</a></td><td width='1%'>1.2892</td><td width='100%'>cpukit/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/ChangeLog.diff?r1=text&tr1=1.1539.2.78&r2=text&tr2=1.1539.2.79&diff_format=h">M</a></td><td width='1%'>1.1539.2.79</td><td width='100%'>cpukit/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/ChangeLog.diff?r1=text&tr1=1.2346.2.99&r2=text&tr2=1.2346.2.100&diff_format=h">M</a></td><td width='1%'>1.2346.2.100</td><td width='100%'>cpukit/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/posix/src/pthreadexit.c.diff?r1=text&tr1=1.12&r2=text&tr2=1.13&diff_format=h">M</a></td><td width='1%'>1.13</td><td width='100%'>cpukit/posix/src/pthreadexit.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/posix/src/pthreadexit.c.diff?r1=text&tr1=1.10&r2=text&tr2=1.10.2.1&diff_format=h">M</a></td><td width='1%'>1.10.2.1</td><td width='100%'>cpukit/posix/src/pthreadexit.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/posix/src/pthreadexit.c.diff?r1=text&tr1=1.12&r2=text&tr2=1.12.2.1&diff_format=h">M</a></td><td width='1%'>1.12.2.1</td><td width='100%'>cpukit/posix/src/pthreadexit.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/posix/src/pthreadjoin.c.diff?r1=text&tr1=1.11&r2=text&tr2=1.12&diff_format=h">M</a></td><td width='1%'>1.12</td><td width='100%'>cpukit/posix/src/pthreadjoin.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/posix/src/pthreadjoin.c.diff?r1=text&tr1=1.8.4.1&r2=text&tr2=1.8.4.2&diff_format=h">M</a></td><td width='1%'>1.8.4.2</td><td width='100%'>cpukit/posix/src/pthreadjoin.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/posix/src/pthreadjoin.c.diff?r1=text&tr1=1.8.2.1&r2=text&tr2=1.8.2.2&diff_format=h">M</a></td><td width='1%'>1.8.2.2</td><td width='100%'>cpukit/posix/src/pthreadjoin.c</td></tr>
</table>
<pre>
<font color='#006600'>diff -u rtems/cpukit/ChangeLog:1.2891 rtems/cpukit/ChangeLog:1.2892
--- rtems/cpukit/ChangeLog:1.2891 Wed Jul 27 12:17:49 2011
+++ rtems/cpukit/ChangeLog Sun Jul 31 11:15:59 2011
</font><font color='#997700'>@@ -1,3 +1,11 @@
</font><font color='#000088'>+2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
+
+ PR 1867/cpukit
+ * posix/src/pthreadexit.c, posix/src/pthreadjoin.c: Correct
+ implementation of pthread_exit() and pthread_join() to support the
+ case where a thread is joinable but calls pthread_exit() before a
+ thread has attempted to join.
+
</font> 2011-07-27 Joel Sherrill <joel.sherrilL@OARcorp.com>
* posix/src/pthread.c, posix/src/pthreadjoin.c: Revert accidental
<font color='#006600'>diff -u rtems/cpukit/ChangeLog:1.1539.2.78 rtems/cpukit/ChangeLog:1.1539.2.79
--- rtems/cpukit/ChangeLog:1.1539.2.78 Sun Jul 24 15:26:12 2011
+++ rtems/cpukit/ChangeLog Sun Jul 31 11:16:53 2011
</font><font color='#997700'>@@ -1,3 +1,11 @@
</font><font color='#000088'>+2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
+
+ PR 1867/cpukit
+ * posix/src/pthreadexit.c, posix/src/pthreadjoin.c: Correct
+ implementation of pthread_exit() and pthread_join() to support the
+ case where a thread is joinable but calls pthread_exit() before a
+ thread has attempted to join.
+
</font> 2011-07-24 Joel Sherrill <joel.sherrilL@OARcorp.com>
PR 1839/filesystem
<font color='#006600'>diff -u rtems/cpukit/ChangeLog:1.2346.2.99 rtems/cpukit/ChangeLog:1.2346.2.100
--- rtems/cpukit/ChangeLog:1.2346.2.99 Sun Jul 31 09:12:27 2011
+++ rtems/cpukit/ChangeLog Sun Jul 31 11:16:28 2011
</font><font color='#997700'>@@ -1,5 +1,13 @@
</font> 2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
<font color='#000088'>+ PR 1867/cpukit
+ * posix/src/pthreadexit.c, posix/src/pthreadjoin.c: Correct
+ implementation of pthread_exit() and pthread_join() to support the
+ case where a thread is joinable but calls pthread_exit() before a
+ thread has attempted to join.
+
+2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
+
</font> PR 1839/filesystem
* libcsupport/include/rtems/libio_.h, libcsupport/src/fchdir.c,
libcsupport/src/fdatasync.c, libcsupport/src/fpathconf.c,
<font color='#006600'>diff -u rtems/cpukit/posix/src/pthreadexit.c:1.12 rtems/cpukit/posix/src/pthreadexit.c:1.13
--- rtems/cpukit/posix/src/pthreadexit.c:1.12 Mon Nov 30 09:44:21 2009
+++ rtems/cpukit/posix/src/pthreadexit.c Sun Jul 31 11:16:00 2011
</font><font color='#997700'>@@ -3,7 +3,7 @@
</font> *
* NOTE: Key destructors are executed in the POSIX api delete extension.
*
<font color='#880000'>- * COPYRIGHT (c) 1989-2008.
</font><font color='#000088'>+ * COPYRIGHT (c) 1989-2011.
</font> * On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
<font color='#997700'>@@ -25,15 +25,21 @@
</font> #include <rtems/score/thread.h>
#include <rtems/posix/pthread.h>
<font color='#000088'>+
</font> void _POSIX_Thread_Exit(
Thread_Control *the_thread,
void *value_ptr
)
{
<font color='#880000'>- Objects_Information *the_information;
</font><font color='#000088'>+ Objects_Information *the_information;
+ Thread_Control *unblocked;
+ POSIX_API_Control *api;
</font>
the_information = _Objects_Get_information_id( the_thread->Object.id );
<font color='#000088'>+ api = the_thread->API_Extensions[ THREAD_API_POSIX ];
+
+
</font> /*
* The_information has to be non-NULL. Otherwise, we couldn't be
* running in a thread of this API and class.
<font color='#997700'>@@ -51,6 +57,31 @@
</font>
the_thread->Wait.return_argument = value_ptr;
<font color='#000088'>+ /*
+ * Process join
+ */
+ if ( api->detachstate == PTHREAD_CREATE_JOINABLE ) {
+ unblocked = _Thread_queue_Dequeue( &api->Join_List );
+ if ( unblocked ) {
+ do {
+ *(void **)unblocked->Wait.return_argument = value_ptr;
+ } while ( (unblocked = _Thread_queue_Dequeue( &api->Join_List )) );
+ } else {
+ _Thread_Set_state(
+ the_thread,
+ STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT
+ );
+ _RTEMS_Unlock_allocator();
+ _Thread_Enable_dispatch();
+ /* now waiting for thread to arrive */
+ _RTEMS_Lock_allocator();
+ _Thread_Disable_dispatch();
+ }
+ }
+
+ /*
+ * Now shut down the thread
+ */
</font> _Thread_Close( the_information, the_thread );
_POSIX_Threads_Free( the_thread );
<font color='#006600'>diff -u rtems/cpukit/posix/src/pthreadexit.c:1.10 rtems/cpukit/posix/src/pthreadexit.c:1.10.2.1
--- rtems/cpukit/posix/src/pthreadexit.c:1.10 Thu May 22 15:38:03 2008
+++ rtems/cpukit/posix/src/pthreadexit.c Sun Jul 31 11:16:55 2011
</font><font color='#997700'>@@ -3,7 +3,7 @@
</font> *
* NOTE: Key destructors are executed in the POSIX api delete extension.
*
<font color='#880000'>- * COPYRIGHT (c) 1989-2008.
</font><font color='#000088'>+ * COPYRIGHT (c) 1989-2011.
</font> * On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
<font color='#997700'>@@ -26,15 +26,21 @@
</font> #include <rtems/score/thread.h>
#include <rtems/posix/pthread.h>
<font color='#000088'>+
</font> void _POSIX_Thread_Exit(
Thread_Control *the_thread,
void *value_ptr
)
{
<font color='#880000'>- Objects_Information *the_information;
</font><font color='#000088'>+ Objects_Information *the_information;
+ Thread_Control *unblocked;
+ POSIX_API_Control *api;
</font>
the_information = _Objects_Get_information_id( the_thread->Object.id );
<font color='#000088'>+ api = the_thread->API_Extensions[ THREAD_API_POSIX ];
+
+
</font> /*
* The_information has to be non-NULL. Otherwise, we couldn't be<span style="background-color: #FF0000"> </span>
* running in a thread of this API and class.
<font color='#997700'>@@ -52,6 +58,31 @@
</font>
the_thread->Wait.return_argument = value_ptr;
<font color='#000088'>+ /*
+ * Process join
+ */
+ if ( api->detachstate == PTHREAD_CREATE_JOINABLE ) {
+ unblocked = _Thread_queue_Dequeue( &api->Join_List );
+ if ( unblocked ) {
+ do {
+ *(void **)unblocked->Wait.return_argument = value_ptr;
+ } while ( (unblocked = _Thread_queue_Dequeue( &api->Join_List )) );
+ } else {
+ _Thread_Set_state(
+ the_thread,
+ STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT
+ );
+ _RTEMS_Unlock_allocator();
+ _Thread_Enable_dispatch();
+ /* now waiting for thread to arrive */
+ _RTEMS_Lock_allocator();
+ _Thread_Disable_dispatch();
+ }
+ }
+
+ /*
+ * Now shut down the thread
+ */
</font> _Thread_Close( the_information, the_thread );
_POSIX_Threads_Free( the_thread );
<font color='#006600'>diff -u rtems/cpukit/posix/src/pthreadexit.c:1.12 rtems/cpukit/posix/src/pthreadexit.c:1.12.2.1
--- rtems/cpukit/posix/src/pthreadexit.c:1.12 Mon Nov 30 09:44:21 2009
+++ rtems/cpukit/posix/src/pthreadexit.c Sun Jul 31 11:16:30 2011
</font><font color='#997700'>@@ -3,7 +3,7 @@
</font> *
* NOTE: Key destructors are executed in the POSIX api delete extension.
*
<font color='#880000'>- * COPYRIGHT (c) 1989-2008.
</font><font color='#000088'>+ * COPYRIGHT (c) 1989-2011.
</font> * On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
<font color='#997700'>@@ -25,15 +25,21 @@
</font> #include <rtems/score/thread.h>
#include <rtems/posix/pthread.h>
<font color='#000088'>+
</font> void _POSIX_Thread_Exit(
Thread_Control *the_thread,
void *value_ptr
)
{
<font color='#880000'>- Objects_Information *the_information;
</font><font color='#000088'>+ Objects_Information *the_information;
+ Thread_Control *unblocked;
+ POSIX_API_Control *api;
</font>
the_information = _Objects_Get_information_id( the_thread->Object.id );
<font color='#000088'>+ api = the_thread->API_Extensions[ THREAD_API_POSIX ];
+
+
</font> /*
* The_information has to be non-NULL. Otherwise, we couldn't be
* running in a thread of this API and class.
<font color='#997700'>@@ -51,6 +57,31 @@
</font>
the_thread->Wait.return_argument = value_ptr;
<font color='#000088'>+ /*
+ * Process join
+ */
+ if ( api->detachstate == PTHREAD_CREATE_JOINABLE ) {
+ unblocked = _Thread_queue_Dequeue( &api->Join_List );
+ if ( unblocked ) {
+ do {
+ *(void **)unblocked->Wait.return_argument = value_ptr;
+ } while ( (unblocked = _Thread_queue_Dequeue( &api->Join_List )) );
+ } else {
+ _Thread_Set_state(
+ the_thread,
+ STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT
+ );
+ _RTEMS_Unlock_allocator();
+ _Thread_Enable_dispatch();
+ /* now waiting for thread to arrive */
+ _RTEMS_Lock_allocator();
+ _Thread_Disable_dispatch();
+ }
+ }
+
+ /*
+ * Now shut down the thread
+ */
</font> _Thread_Close( the_information, the_thread );
_POSIX_Threads_Free( the_thread );
<font color='#006600'>diff -u rtems/cpukit/posix/src/pthreadjoin.c:1.11 rtems/cpukit/posix/src/pthreadjoin.c:1.12
--- rtems/cpukit/posix/src/pthreadjoin.c:1.11 Wed Jul 27 12:17:49 2011
+++ rtems/cpukit/posix/src/pthreadjoin.c Sun Jul 31 11:16:00 2011
</font><font color='#997700'>@@ -52,12 +52,18 @@
</font> * Put ourself on the threads join list
*/
<font color='#880000'>- _Thread_Executing->Wait.return_argument = &return_pointer;
-
- _Thread_queue_Enter_critical_section( &api->Join_List );
-
- _Thread_queue_Enqueue( &api->Join_List, WATCHDOG_NO_TIMEOUT );
-
</font><font color='#000088'>+ if ( the_thread->current_state ==
+ (STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT) ) {
+ return_pointer = the_thread->Wait.return_argument;
+ _Thread_Clear_state(
+ the_thread,
+ (STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT)
+ );
+ } else {
+ _Thread_Executing->Wait.return_argument = &return_pointer;
+ _Thread_queue_Enter_critical_section( &api->Join_List );
+ _Thread_queue_Enqueue( &api->Join_List, WATCHDOG_NO_TIMEOUT );
+ }
</font> _Thread_Enable_dispatch();
if ( value_ptr )
<font color='#006600'>diff -u rtems/cpukit/posix/src/pthreadjoin.c:1.8.4.1 rtems/cpukit/posix/src/pthreadjoin.c:1.8.4.2
--- rtems/cpukit/posix/src/pthreadjoin.c:1.8.4.1 Tue Mar 8 16:14:56 2011
+++ rtems/cpukit/posix/src/pthreadjoin.c Sun Jul 31 11:16:30 2011
</font><font color='#997700'>@@ -52,12 +52,18 @@
</font> * Put ourself on the threads join list
*/
<font color='#880000'>- _Thread_Executing->Wait.return_argument = &return_pointer;
-
- _Thread_queue_Enter_critical_section( &api->Join_List );
-
- _Thread_queue_Enqueue( &api->Join_List, WATCHDOG_NO_TIMEOUT );
-
</font><font color='#000088'>+ if ( the_thread->current_state ==
+ (STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT) ) {
+ return_pointer = the_thread->Wait.return_argument;
+ _Thread_Clear_state(
+ the_thread,
+ (STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT)
+ );
+ } else {
+ _Thread_Executing->Wait.return_argument = &return_pointer;
+ _Thread_queue_Enter_critical_section( &api->Join_List );
+ _Thread_queue_Enqueue( &api->Join_List, WATCHDOG_NO_TIMEOUT );
+ }
</font> _Thread_Enable_dispatch();
if ( value_ptr )
<font color='#006600'>diff -u rtems/cpukit/posix/src/pthreadjoin.c:1.8.2.1 rtems/cpukit/posix/src/pthreadjoin.c:1.8.2.2
--- rtems/cpukit/posix/src/pthreadjoin.c:1.8.2.1 Tue Mar 8 16:15:07 2011
+++ rtems/cpukit/posix/src/pthreadjoin.c Sun Jul 31 11:16:55 2011
</font><font color='#997700'>@@ -52,12 +52,18 @@
</font> * Put ourself on the threads join list
*/
<font color='#880000'>- _Thread_Executing->Wait.return_argument = &return_pointer;
-
- _Thread_queue_Enter_critical_section( &api->Join_List );
-
- _Thread_queue_Enqueue( &api->Join_List, WATCHDOG_NO_TIMEOUT );
-
</font><font color='#000088'>+ if ( the_thread->current_state ==
+ (STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT) ) {
+ return_pointer = the_thread->Wait.return_argument;
+ _Thread_Clear_state(
+ the_thread,
+ (STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT)
+ );
+ } else {
+ _Thread_Executing->Wait.return_argument = &return_pointer;
+ _Thread_queue_Enter_critical_section( &api->Join_List );
+ _Thread_queue_Enqueue( &api->Join_List, WATCHDOG_NO_TIMEOUT );
+ }
</font> _Thread_Enable_dispatch();
if ( value_ptr )
</pre>
<p> </p>
<a name='cs14'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>joel</strong></font>
<font color='#225522'><em>(on branch rtems-4-9-branch)</em></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
PR 1867/cpukit
* Makefile.am, configure.ac, psx12/task.c, psxrwlock01/test.c: Correct
implementation of pthread_exit() and pthread_join() to support the
case where a thread is joinable but calls pthread_exit() before a
thread has attempted to join.
* psx16/.cvsignore, psx16/Makefile.am, psx16/init.c, psx16/psx16.doc,
psx16/psx16.scn: New files.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/ChangeLog.diff?r1=text&tr1=1.125&r2=text&tr2=1.125.2.1&diff_format=h">M</a></td><td width='1%'>1.125.2.1</td><td width='100%'>testsuites/psxtests/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/Makefile.am.diff?r1=text&tr1=1.32&r2=text&tr2=1.32.2.1&diff_format=h">M</a></td><td width='1%'>1.32.2.1</td><td width='100%'>testsuites/psxtests/Makefile.am</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/configure.ac.diff?r1=text&tr1=1.31&r2=text&tr2=1.31.2.1&diff_format=h">M</a></td><td width='1%'>1.31.2.1</td><td width='100%'>testsuites/psxtests/configure.ac</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx12/task.c.diff?r1=text&tr1=1.6&r2=text&tr2=1.6.6.1&diff_format=h">M</a></td><td width='1%'>1.6.6.1</td><td width='100%'>testsuites/psxtests/psx12/task.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/.cvsignore.diff?r1=text&tr1=1.1.4.1&r2=text&tr2=1.1.4.2&diff_format=h">M</a></td><td width='1%'>1.1.4.2</td><td width='100%'>testsuites/psxtests/psx16/.cvsignore</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/Makefile.am.diff?r1=text&tr1=1.1.4.1&r2=text&tr2=1.1.4.2&diff_format=h">M</a></td><td width='1%'>1.1.4.2</td><td width='100%'>testsuites/psxtests/psx16/Makefile.am</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/init.c.diff?r1=text&tr1=1.1.4.1&r2=text&tr2=1.1.4.2&diff_format=h">M</a></td><td width='1%'>1.1.4.2</td><td width='100%'>testsuites/psxtests/psx16/init.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/psx16.doc.diff?r1=text&tr1=1.1.4.1&r2=text&tr2=1.1.4.2&diff_format=h">M</a></td><td width='1%'>1.1.4.2</td><td width='100%'>testsuites/psxtests/psx16/psx16.doc</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psx16/psx16.scn.diff?r1=text&tr1=1.1.4.1&r2=text&tr2=1.1.4.2&diff_format=h">M</a></td><td width='1%'>1.1.4.2</td><td width='100%'>testsuites/psxtests/psx16/psx16.scn</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/testsuites/psxtests/psxrwlock01/test.c.diff?r1=text&tr1=1.4&r2=text&tr2=1.4.2.1&diff_format=h">M</a></td><td width='1%'>1.4.2.1</td><td width='100%'>testsuites/psxtests/psxrwlock01/test.c</td></tr>
</table>
<pre>
<font color='#006600'>diff -u rtems/testsuites/psxtests/ChangeLog:1.125 rtems/testsuites/psxtests/ChangeLog:1.125.2.1
--- rtems/testsuites/psxtests/ChangeLog:1.125 Fri Sep 5 22:33:27 2008
+++ rtems/testsuites/psxtests/ChangeLog Sun Jul 31 11:17:02 2011
</font><font color='#997700'>@@ -1,4 +1,14 @@
</font><font color='#880000'>-2008-09-06 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>
+
+ PR 1867/cpukit
+ * Makefile.am, configure.ac, psx12/task.c, psxrwlock01/test.c: Correct
+ implementation of pthread_exit() and pthread_join() to support the
+ case where a thread is joinable but calls pthread_exit() before a
+ thread has attempted to join.
+ * psx16/.cvsignore, psx16/Makefile.am, psx16/init.c, psx16/psx16.doc,
+ psx16/psx16.scn: New files.
+
+2008-09-06 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psxcleanup/psxcleanup.c, psxfatal_support/init.c,
psxfatal_support/system.h: Convert to "bool".
<font color='#997700'>@@ -226,7 +236,7 @@
</font> * psxrwlock01/main.c, psxrwlock01/test.c: Improve rwlock test to
include normal blocking and unblocking on timeout.
<font color='#880000'>-2006-12-02 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2006-12-02 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: New BUG-REPORT address.
<font color='#997700'>@@ -260,11 +270,11 @@
</font> * psxsem01/init.c: Make sem_timedwait more conformant to Open Group
specification.
<font color='#880000'>-2006-10-17 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2006-10-17 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* configure.ac: Require autoconf-2.60. Require automake-1.10.
<font color='#880000'>-2006-07-11 Ralf Corsépius <ralf.corsepius@rtems.org>
</font><font color='#000088'>+2006-07-11 Ralf Corsépius <ralf.corsepius@rtems.org>
</font>
* psx01/Makefile.am, psx02/Makefile.am, psx03/Makefile.am,
psx04/Makefile.am, psx05/Makefile.am, psx06/Makefile.am,
<font color='#997700'>@@ -450,7 +460,7 @@
</font> * psxfile01/test.c, psxmsgq01/init.c, psxstat/test.c,
psxtimer/psxtimer.c: Eliminate warnings and typos.
<font color='#880000'>-2004-02-26 Sébastien Barré <sbarre@sdelcc.com>
</font><font color='#000088'>+2004-02-26 Sébastien Barré <sbarre@sdelcc.com>
</font>
PR 582/core
* psxmsgq01/init.c, psxmsgq01/psxmsgq01.scn: Fix the POSIX message
<font color='#006600'>diff -u rtems/testsuites/psxtests/Makefile.am:1.32 rtems/testsuites/psxtests/Makefile.am:1.32.2.1
--- rtems/testsuites/psxtests/Makefile.am:1.32 Mon Feb 4 13:39:43 2008
+++ rtems/testsuites/psxtests/Makefile.am Sun Jul 31 11:17:02 2011
</font><font color='#997700'>@@ -5,9 +5,9 @@
</font> ACLOCAL_AMFLAGS = -I ../aclocal
SUBDIRS = psxhdrs psx01 psx02 psx03 psx04 psx05 psx06 psx07 psx08 psx09 \
<font color='#880000'>- psx10 psx11 psx12 psx13 psx14 psxcleanup psxtime psxtimer01 psxtimer02 \
- psxcancel psxbarrier01 psxmsgq01 psxmsgq02 psxrwlock01 psxsem01 \
- psxspin01 psxenosys psxsignal01 psxsysconf psxualarm psxkey01 \
</font><font color='#000088'>+ psx10 psx11 psx12 psx13 psx14 psx16 psxcleanup psxtime psxtimer01 \
+ psxtimer02 psxcancel psxbarrier01 psxmsgq01 psxmsgq02 psxrwlock01
+ psxsem01 psxspin01 psxenosys psxsignal01 psxsysconf psxualarm psxkey01 \
</font> psxfatal01 psxfatal02
## File IO tests
<font color='#006600'>diff -u rtems/testsuites/psxtests/configure.ac:1.31 rtems/testsuites/psxtests/configure.ac:1.31.2.1
--- rtems/testsuites/psxtests/configure.ac:1.31 Mon Feb 4 13:39:43 2008
+++ rtems/testsuites/psxtests/configure.ac Sun Jul 31 11:17:02 2011
</font><font color='#997700'>@@ -41,6 +41,7 @@
</font> psx12/Makefile
psx13/Makefile
psx14/Makefile
<font color='#000088'>+psx16/Makefile
</font> psxbarrier01/Makefile
psxcancel/Makefile
psxchroot01/Makefile
<font color='#006600'>diff -u rtems/testsuites/psxtests/psx12/task.c:1.6 rtems/testsuites/psxtests/psx12/task.c:1.6.6.1
--- rtems/testsuites/psxtests/psx12/task.c:1.6 Thu Sep 4 13:53:38 2003
+++ rtems/testsuites/psxtests/psx12/task.c Sun Jul 31 11:17:02 2011
</font><font color='#997700'>@@ -26,6 +26,11 @@
</font> void *argument
)
{
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "Task_1: exitting" );
pthread_exit( NULL );
<font color='#006600'>diff -u /dev/null rtems/testsuites/psxtests/psx16/.cvsignore:1.1.4.2
--- /dev/null Sun Jul 31 12:11:31 2011
+++ rtems/testsuites/psxtests/psx16/.cvsignore Sun Jul 31 11:17:02 2011
</font><font color='#997700'>@@ -0,0 +1,2 @@
</font><font color='#000088'>+Makefile
+Makefile.in
</font>
<font color='#006600'>diff -u /dev/null rtems/testsuites/psxtests/psx16/Makefile.am:1.1.4.2
--- /dev/null Sun Jul 31 12:11:31 2011
+++ rtems/testsuites/psxtests/psx16/Makefile.am Sun Jul 31 11:17:02 2011
</font><font color='#997700'>@@ -0,0 +1,25 @@
</font><font color='#000088'>+##
+## $Id$
+##
+
+rtems_tests_PROGRAMS = psx16
+psx16_SOURCES = init.c
+
+dist_rtems_tests_DATA = psx16.scn
+dist_rtems_tests_DATA += psx16.doc
+
+include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg
+include $(top_srcdir)/../automake/compile.am
+include $(top_srcdir)/../automake/leaf.am
+
+AM_CPPFLAGS += -I$(top_srcdir)/include
+AM_CPPFLAGS += -I$(top_srcdir)/../support/include
+
+LINK_OBJS = $(psx16_OBJECTS) $(psx16_LDADD)
+LINK_LIBS = $(psx16_LDLIBS)
+
+psx16$(EXEEXT): $(psx16_OBJECTS) $(psx16_DEPENDENCIES)
+ @rm -f psx16$(EXEEXT)
+ $(make-exe)
+
+include $(top_srcdir)/../automake/local.am
</font>
<font color='#006600'>diff -u /dev/null rtems/testsuites/psxtests/psx16/init.c:1.1.4.2
--- /dev/null Sun Jul 31 12:11:31 2011
+++ rtems/testsuites/psxtests/psx16/init.c Sun Jul 31 11:17:02 2011
</font><font color='#997700'>@@ -0,0 +1,78 @@
</font><font color='#000088'>+/*
+ * COPYRIGHT (c) 1989-2011.
+ * On-Line Applications Research Corporation (OAR).
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.rtems.com/license/LICENSE.
+ *
+ * $Id$
+ */
+
+#include <tmacros.h>
+#include "test_support.h"
+#include <pthread.h>
+
+int Index;
+
+void *TestThread(
+ void *argument
+)
+{
+ int *index = (int *)argument;
+
+ *index = 7;<span style="background-color: #FF0000"> </span>
+
+ puts( "TestThread exiting" );
+ return argument;
+}
+
+void *POSIX_Init(
+ rtems_task_argument argument
+)
+{
+ int status;
+ pthread_t id;
+ pthread_attr_t attr;
+ void *join_return;
+
+ puts( "\n\n*** POSIX TEST PSX16 ***" );
+
+ Index = 5;
+
+ /* Initialize and set thread detached attribute */
+ pthread_attr_init(&attr);
+ pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_JOINABLE);
+
+ puts( "Creating TestThread" );
+ status = pthread_create( &id, &attr, TestThread, (void *)&Index );
+ rtems_test_assert( status == 0 );
+
+ /* let test thread run and exit */
+ puts( "Let TestThread run and exit before we attempt to join" );
+ sleep( 2 );
+
+ join_return = NULL;
+ status = pthread_join( id, &join_return );
+ rtems_test_assert( status == 0 );
+ rtems_test_assert( join_return == &Index );
+ rtems_test_assert( *(int *)join_return == 7 );
+ puts( "Successfully joined with TestThread" );
+
+ puts( "*** END OF POSIX TEST PSX16 ***" );
+
+ rtems_test_exit(0);
+}
+
+/* configuration information */
+
+#define CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER
+#define CONFIGURE_APPLICATION_NEEDS_CLOCK_DRIVER
+
+#define CONFIGURE_MAXIMUM_POSIX_THREADS 2
+
+#define CONFIGURE_POSIX_INIT_THREAD_TABLE
+
+#define CONFIGURE_INIT
+#include <rtems/confdefs.h>
+/* end of file */
</font>
<font color='#006600'>diff -u /dev/null rtems/testsuites/psxtests/psx16/psx16.doc:1.1.4.2
--- /dev/null Sun Jul 31 12:11:31 2011
+++ rtems/testsuites/psxtests/psx16/psx16.doc Sun Jul 31 11:17:02 2011
</font><font color='#997700'>@@ -0,0 +1,24 @@
</font><font color='#000088'>+#
+# $Id$
+#
+# COPYRIGHT (c) 1989-2011.
+# On-Line Applications Research Corporation (OAR).
+#
+# The license and distribution terms for this file may be
+# found in the file LICENSE in this distribution or at
+# http://www.rtems.com/license/LICENSE.
+#
+
+This file describes the directives and concepts tested by this test set.
+
+test set name: psx16
+
+directives:
+
+ pthread_join
+ pthread_exit
+
+concepts:
+
++ Ensure that if a joinable thread exits before it has been joined,
+that it waits for a thread to call pthread_join.
</font>
<font color='#006600'>diff -u /dev/null rtems/testsuites/psxtests/psx16/psx16.scn:1.1.4.2
--- /dev/null Sun Jul 31 12:11:32 2011
+++ rtems/testsuites/psxtests/psx16/psx16.scn Sun Jul 31 11:17:02 2011
</font><font color='#997700'>@@ -0,0 +1,6 @@
</font><font color='#000088'>+*** POSIX TEST PSX16 ***
+Creating TestThread
+Let TestThread run and exit before we attempt to join
+TestThread exiting
+Successfully joined with TestThread
+*** END OF POSIX TEST PSX16 ***
</font>
<font color='#006600'>diff -u rtems/testsuites/psxtests/psxrwlock01/test.c:1.4 rtems/testsuites/psxtests/psxrwlock01/test.c:1.4.2.1
--- rtems/testsuites/psxtests/psxrwlock01/test.c:1.4 Fri Aug 15 11:30:01 2008
+++ rtems/testsuites/psxtests/psxrwlock01/test.c Sun Jul 31 11:17:02 2011
</font><font color='#997700'>@@ -30,6 +30,11 @@
</font> {
int status;
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "ReadThread - pthread_rwlock_rdlock(RWLock) blocking -- OK" );
status = pthread_rwlock_rdlock(&RWLock);
assert( !status );
<font color='#997700'>@@ -47,6 +52,11 @@
</font> {
int status;
<font color='#000088'>+ /*
+ * Detach ourselves so we don't wait for a join that won't happen.
+ */
+ pthread_detach( pthread_self() );
+
</font> puts( "WriteThread - pthread_rwlock_wrlock(RWLock) blocking -- OK" );
status = pthread_rwlock_wrlock(&RWLock);
assert( !status );
</pre>
<p> </p>
<p>--<br />
<small>Generated by <a href="http://www.codewiz.org/projects/index.html#loginfo">Deluxe Loginfo</a> 2.122 by Bernardo Innocenti <bernie@develer.com></small></p>
</body>
</html>