1 2004-10-01 Oyvind Harboe <oyvind.harboe@zylin.com>
3 * src/signal.cxx: place the CYGBLD_ATTRIB_INIT_PRI such that it
4 compiles for gcc 3.4.2 which is more picky about its placement.
6 2003-12-02 Sandeep <sandeep@codito.com>
8 * src/mqueue.cxx (new): define a placement new instead of using <new>
10 2003-11-19 Rickard Westman <rickard.westman@27m.se>
12 * src/mqueue.cxx: Fix problem with mq_timedsend() and
13 mq_timedreceive() timing out with zero timeouts even when there is
16 2003-11-17 Dan Jakubiec <djakubiec@yahoo.com>
18 * src/pthread.cxx (pthread_exit): Added code to disable cancellation
19 requests during thread exit. This allows thread cleanup handlers
20 to issue system calls when cleaning up thread resources.
22 2003-06-18 Jonathan Larmour <jifl@eCosCentric.com>
24 * src/pthread.cxx (pthread_self_info): Just add some comments so
25 no-one's tempted to uncomment assert.
26 (pthread_create): Verify that self is a valid POSIX thread when
29 2003-03-20 Mark Salter <msalter@redhat.com>
31 * include/pthread.h: Avoid conflict with recently introduced gcc
34 2003-03-13 Bart Veer <bartv@ecoscentric.com>
36 * include/export.h: Only export signal-related functions if
37 CYGPKG_POSIX_SIGNALS is enabled.
39 2003-03-04 Gary Thomas <gary@mlbassoc.com>
41 * include/pthread.h: Rework prototypes to minimize namespace problems.
43 2003-03-03 Jonathan Larmour <jifl@eCosCentric.com>
45 * tests/signal2.c (cause_illegal_access): PowerPC only generates
46 alignment exceptions in little-endian mode, so make that a special
49 * tests/mutex3.c: Include POSIX headers before feature tests to
50 prevent spurious CYG_TEST_NA.
52 2003-02-24 Jonathan Larmour <jifl@eCosCentric.com>
54 * doc/posix.sgml: Expunge EL/IX. Dead standard.
55 * cdl/posix.cdl: Add doc link.
57 2003-02-13 Jonathan Larmour <jifl@eCosCentric.com>
59 * src/mutex.cxx: Include sched.hxx for scheduler lock/unlock primitives.
60 Reported by Jani Monoses.
62 2003-02-10 Gary Thomas <gary@mlbassoc.com>
64 * tests/signal3.c (main): Reorg code so it builds with older GCC.
66 2003-01-31 Nick Garnett <nickg@calivar.com>
68 * src/time.cxx (alarm_action): Added call to
69 cyg_posix_signal_sigwait() to wake up any sigwait()ing threads.
71 * src/signal.cxx (cyg_posix_signal_sigwait): Added this function
72 to export access to signal_sigwait conditional variable.
73 (sigtimedwait): Added call to cyg_posix_timer_asr() to allow timer
74 signals to be delivered here.
76 * src/pprivate.h: Added prototype for cyg_posix_signal_sigwait().
79 * tests/signal3.c: Added this program to test interaction of
80 timers and signals, particularly sigwait(). Based on a test
81 program from N.Suresh <nsuresh@cdotb.ernet.in>.
83 2003-01-20 Jonathan Larmour <jifl@eCosCentric.com>
85 * src/signal.cxx (cyg_posix_deliver_signals): silence warning.
87 * src/time.cxx (cyg_timespec_to_ticks): Remove use of default arg in
90 2003-01-18 Jonathan Larmour <jifl@eCosCentric.com>
92 * src/mqueue.cxx: Fix multi-line string literal warning.
94 2003-01-13 Jonathan Larmour <jifl@eCosCentric.com>
96 * doc/posix.sgml: Document them.
98 * src/mqueue.cxx (mq_timedreceive): Make fully compliant by dealing
100 (mq_timedsend): Ditto.
102 2003-01-13 Dmitriy Korovkin <dkorovkin@rambler.ru>
104 * src/mqueue.cxx (mq_timedsend): New function. Implementing POSIX
105 1003.1d draft definition.
106 (mq_timedreceive): Ditto.
108 2002-12-10 Wade Jensen <waj4news@cox.net>
109 2002-12-10 Jonathan Larmour <jifl@eCosCentric.com>
111 * src/mutex.cxx (pthread_cond_timedwait): Initialize clock converters
114 2002-11-26 Nick Garnett <nickg@ecoscentric.com>
116 * src/signal.cxx: Changed the three routines added in the last
117 change so that they can be called safely from non-POSIX threads.
119 2002-11-10 Nick Garnett <nickg@ecoscentric.com>
121 * src/signal.cxx: Added three exportable routines that may be used
122 by other packages to manipulate the signal mask, test for
123 deliverable signals, and have signals delivered at controlled
126 * include/export.h: Added macros to export signal mask management,
127 detection and delivery to other packages.
129 2002-11-05 Jonathan Larmour <jifl@eCosCentric.com>
131 * tests/tm_basic.cxx: Use <cyg/infra/diag.h> for diag_printf
134 2002-05-23 Jesper Skov <jskov@redhat.com>
136 * cdl/posix.cdl: Don't build tests using signals when posix
137 signals are disabled.
139 2002-05-21 Jesper Skov <jskov@redhat.com>
141 * tests/mutex3.c: Added an NA check.
143 2002-04-09 Jonathan Larmour <jlarmour@redhat.com>
145 * src/signal.cxx (cyg_deliver_signals): Don't assert here for an
146 unhandled signal (unless there's no _exit). Trace it though.
148 2002-04-08 Jonathan Larmour <jlarmour@redhat.com>
150 * src/sem.cxx (sem_getvalue): return 0, and put value in *sval.
152 2002-04-03 Jonathan Larmour <jlarmour@redhat.com>
154 * cdl/posix.cdl: Allow clocks to be configured again.
156 2002-03-05 Jesper Skov <jskov@redhat.com>
158 * src/pprivate.h: Correct conditional declaration of timespec
161 * src/sched.cxx (sched_rr_get_interval): Return ENOSYS when
162 CYGPKG_POSIX_CLOCKS disabled.
164 2002-02-27 Robin Farine <robin.farine@terminus.org>
166 * src/pthread.cxx (pthread_exit): While running thread static
167 storage destructors, set the thread's value associated with the
168 current key to NULL before invoking the destructor.
170 2002-02-14 Nick Garnett <nickg@redhat.com>
172 * doc/posix.sgml: Generally fixed up and reformatted to make this
173 file readable by mere humans. Some omissions and outdated
174 information fixed, but not substantially changed from the
177 * cdl/posix.cdl: Changed some definitions and dependencies so that
178 disabling the timers does not disable threads too. This was
179 largely a consequence of trying to document the behaviour of these
182 2002-02-14 Jonathan Larmour <jlarmour@redhat.com>
184 * doc/posix.sgml: New file, originally accompanied by this ChangeLog:
185 2001-12-22 Jonathan Larmour <jlarmour@redhat.com>
187 * ecos-elix.sgml: Do a minor cleanup of the function prototype
189 Should be done better than this, but this is at least not
190 _completely_ wrong any more.
191 Also several more layout problems due to incorrect tags fixed.
193 2001-12-07 Jonathan Larmour <jlarmour@redhat.com>
195 * ecos-elix.sgml: Add getcwd as supported now.
197 2001-12-06 Jonathan Larmour <jlarmour@redhat.com>
199 * ecos-elix.sgml: Created from old framemaker version.
201 2002-01-21 Jonathan Larmour <jlarmour@redhat.com>
203 * src/sched.cxx (sched_get_priority_min): Don't allow idle thread
204 priority as a valid priority.
207 2001-12-11 Nick Garnett <nickg@redhat.com>
209 * tests/mqueue2.c (cyg_user_start): Added CYG_TEST_INIT() to
210 NOTAPPLICABLE variant, otherwise the order of breakpoints are all
211 wrong and the testfarm registers a failure.
213 2001-11-06 Gary Thomas <gthomas@redhat.com>
215 * include/muttypes.h: Need <pkgconf/kernel.h> configuration info,
216 otherwise structures defined here could have the wrong size.
218 2001-10-25 I-Jui Sung <ijsung@csie.nctu.edu.tw>
220 * src/mqueue.cxx (do_mq_unlink): Nullify table entries' mq as this
221 is used by mq_open to see if the entry is used.
223 2001-10-11 Jesper Skov <jskov@redhat.com>
225 * tests/mutex3.c: Fixed warning.
226 (new_thread): Fixed allocation: increase counter
227 before starting threads which have been allocated resources.
229 * tests/signal2.c (cause_illegal_access): Fix warning.
231 2001-10-10 Jesper Skov <jskov@redhat.com>
233 * cdl/posix.cdl: Only build sem.cxx when the semaphores component
236 2001-10-09 Jonathan Larmour <jlarmour@redhat.com>
238 * src/pprivate.h (pthread_info): Conditionalize signal specific
239 members. Conditionalize declaration of
240 cyg_posix_pthread_release_thread().
242 * cdl/posix.cdl (CYGPKG_POSIX_CLOCKS): new option to separately
243 configure posix clocks from timers.
244 (CYGPKG_POSIX_TIMERS): require clocks and signals.
246 * include/time.h: Make proper ISO C. Conditionalize on
247 CYGPKG_POSIX_TIMERS correctly wrt the above change.
249 * src/pthread.cxx (posix_asr): Call signal and timer subsystems
252 * src/pthread.cxx (pthread_reap): Don't destroy signal handling
253 fields if there is no signal handling subsystem.
254 (cyg_posix_pthread_release_thread): Conditionalize on signals.
255 (pthread_create): Init signal subsys conditionally.
257 * src/signal.cxx (sleep): Move to...
259 * src/time.cxx: ...here.
260 Conditionalize throughout depending on whether it's POSIX clocks
261 or more specifically POSIX timers.
262 (nanosleep): Use PTHREAD_TESTCANCEL() not pthread_testcancel().
263 Get current thread from kernel not pthreads to remove pthread
266 2001-10-09 Jesper Skov <jskov@redhat.com>
268 * tests/signal2.c: Also do NA check for signals.
270 2001-10-01 Jonathan Larmour <jlarmour@redhat.com>
272 * src/mqueue.cxx (mq_open): Conditionalize use of sigev correctly.
273 (mq_close): Similarly.
275 2001-09-28 Jonathan Larmour <jlarmour@redhat.com>
277 * cdl/pthread.cdl (CYGNUM_POSIX_MAIN_DEFAULT_PRIORITY): Clarify
278 POSIX thread priority description.
280 2001-09-28 Jesper Skov <jskov@redhat.com>
282 * cdl/pthread.cdl: Changed default priority of POSIX main to
283 16. This allows service threads (such as DHCP thread) to run when
286 2001-09-10 Jonathan Larmour <jlarmour@redhat.com>
288 * include/pthread.h: Separate mutex and condvar API into separate
289 header file to fix configury problems.
290 * include/mutex.h: New file for the above.
291 * cdl/posix.cdl: provide the correct configury for the isoinfra
292 package to include the above file.
293 * cdl/pthread.cdl: Move _POSIX_PTHREAD_PRIO_INHERIT and
294 _POSIX_THREAD_PRIO_PROTECT to cdl/posix.cdl.
296 2001-09-07 Jonathan Larmour <jlarmour@redhat.com>
298 * src/sem.cxx (sem_trywait): Actually use the return value.
300 * src/sched.cxx (sched_get_priority_max): Use MAX not MIN
301 (sched_get_priority_min): Use MIN not MAX.
303 2001-09-06 Jesper Skov <jskov@redhat.com>
305 * cdl/posix.cdl: Moved signal implements statements to the
306 CYGPKG_POSIX_SIGNALS component.
308 2001-08-06 Jonathan Larmour <jlarmour@redhat.com>
310 * cdl/posix.cdl: Reorganize dependencies so that signals, timers
311 and pthreads really can be disabled, and the relevant files don't
313 Build new mutex.cxx file.
314 Remove duplicate CYGPKG_POSIX_SCHED dependency for pthreads.
316 * include/limits.h: Don't include irrelevant header dependencies.
318 * include/muttypes.h: New type defining mutex/cond var types separately
319 from other pthread types.
321 * include/types.h: Remove mutex/cond var types.
323 * include/signal.h: Conditionalize on CYGPKG_POSIX_SIGNALS
325 * include/sigsetjmp.h: Don't include irrelevant header dependencies.
326 Rewrite sigsetjmp in a much more compiler friendly (and readable)
327 way with less type punning.
329 * src/misc.cxx: Don't include sysconf cases when pthreads or
330 CYGPKG_POSIX_TIMERS not enabled.
332 * src/mutex.cxx: New file, broken out of pthreads.cxx, as most
333 of it is not fixed to the pthreads implementation, and I've fixed
334 the bits that were too tied to it.
336 * src/pprivate.h: Conditionalize definitions that are specific
337 to CYGPKG_POSIX_PTHREAD. Ditto for prototypes for CYGPKG_POSIX_SIGNALS
338 and CYGPKG_POSIX_TIMERS. Move PTHREAD_ENTRY/RETURN etc. macros
339 here so they can be used throughout the package.
341 * src/pthread.cxx: Remove mutex/cond var implementation, and
342 entry/return macros, as per above.
344 * src/signal.cxx (cyg_sigqueue): Don't just set non-queueable signals
345 pending - also forcibly wake up any blocked threads.
346 (siglongjmp): Use new layout of sigjmp_buf.
355 * tests/tm_basic.cxx:
356 Correct configuration dependencies, and do NA appropriately.
358 2001-08-03 Nick Garnett <nickg@cygnus.co.uk>
360 Imported from a development branch:
362 2001-06-27 Nick Garnett <nickg@cygnus.co.uk>
365 Modified the loop that waits for the threads to get going so that
366 it will function correctly in an SMP system, where the threads
367 will run in parallel.
369 * tests/mutex3.c: Disabled this test for SMP systems. It depends
370 too much on predicting the priority-driven execution order of the
371 threads. In an SMP system, some threads will run in parallel and
372 falsify the assumptions.
374 2001-05-25 Nick Garnett <nickg@cygnus.co.uk>
376 * src/signal.cxx (siglongjmp): Minor change to satisfy latest C++
379 2001-06-14 Jonathan Larmour <jlarmour@redhat.com>
381 * src/pthread.cxx (pthread_attr_setstacksize): Correct stack
384 2001-06-12 Jonathan Larmour <jlarmour@redhat.com>
386 * src/pthread.cxx (MAIN_DEFAULT_STACK_SIZE): Define to use at
387 least PTHREAD_STACK_MIN for main_stack.
389 2001-05-01 Nick Garnett <nickg@cygnus.co.uk>
392 * tests/signal2.c (cause_illegal_access): Added code for I386
393 architecture to provoke General Protection Fault.
395 * src/except.cxx: Removed some extraneous diag_printf()s.
397 2001-04-25 Bart Veer <bartv@redhat.com>
399 * tests/tm_basic.cxx:
400 This test is now functional on the synthetic target.
402 2001-04-20 Jonathan Larmour <jlarmour@redhat.com>
404 * src/time.cxx (cyg_ticks_to_timespec): Actually don't bother
405 with working out seconds using convertors. Instead just divide
406 down ns from a long long.
408 2001-04-19 Jonathan Larmour <jlarmour@redhat.com>
410 * src/time.cxx (cyg_ticks_to_timespec): Clock convertors round off,
411 so adjust timespec accordingly.
413 2001-02-14 Jonathan Larmour <jlarmour@redhat.com>
415 * include/pthread.h: Remove pthread_canceled() and
416 pthread_testcancel_unlock().
418 * src/pthread.cxx: Ditto.
419 (pthread_join): Restructure to have function exit only at function end
420 (pthread_cond_timedwait): Check for timeouts and return ETIMEDOUT
422 * src/signal.cxx (sigtimedwait): Restructure cancellation testing
424 * src/time.cxx (nanosleep): test for cancellation at the end of the
425 function to keep Nick happy ;).
427 2001-02-11 Jonathan Larmour <jlarmour@redhat.com>
429 * include/pthread.h: Add new pthread_testcancel_unlock and
430 pthread_canceled functions as eCos extensions.
431 Rename existing pthread_canceled variable to pthread_cancelled_dummy_var
433 * src/pthread.cxx (pthread_canceled): New function to interrogate if
434 current thread has deferred cancel pending
435 (pthread_testcancel_unlock): New function. Like testcancel, but unlocks
436 a mutex before exitting the thread.
437 (checkforcancel): New internal function
438 (pthread_join): Add thread cancellation checks.
439 (pthread_cond_wait): Ditto.
440 (pthread_cond_timedwait): Ditto.
441 (pthread_testcancel): Use checkforcancel()
443 * src/sem.cxx (sem_wait): Add thread cancellation checks
444 * src/signal.cxx (sigtimedwait): Ditto.
445 Also make compilation of this file conditional on CYGPKG_POSIX_SIGNALS
446 * src/time.cxx (nanosleep): Ditto.
447 Also make compilation of this file conditional on CYGPKG_POSIX_TIMERS
449 * cdl/posix.cdl (CYGPKG_POSIX_TIMERS): Implements POSIX timer ops.
450 Add explicit kernel and pthread dependencies.
452 * tests/sigsetjmp.c (pthread_entry1): Fix incorrect thread no. output
454 * tests/pthread3.c: Add deferred cancellation test.
456 2001-01-11 Nick Garnett <nickg@cygnus.co.uk>
458 * src/pthread.cxx (pthread_testcancel): Added test for self !=
459 NULL in case this gets called from a non-pthread.
461 2000-12-22 Jonathan Larmour <jlarmour@redhat.com>
463 * src/pthread.cxx (pthread_measure_stack_usage): New function
464 to measure stack usage.
466 * include/pthread.h: Prototype it.
468 * cdl/pthread.cdl: remove CYGNUM_POSIX_MAIN_DEFAULT_STACK_SIZE and
469 instead implement CYGINT_LIBC_STARTUP_EXTERNAL_INVOKE_MAIN_POSSIBLE
471 * src/pthread.cxx: Use stack size for main from libc_startup package
473 (cyg_posix_pthread_start): Likewise
475 2000-12-06 Jonathan Larmour <jlarmour@redhat.com>
477 * src/signal.cxx: include unistd.h for _exit
479 2000-11-20 Nick Garnett <nickg@cygnus.co.uk>
481 * src/signal.cxx (cyg_deliver_signals): Added else in code to
482 handle SIG_DFL. Otherwise if the SA_SIGINFO bit is set we call the
483 signal handler twice!
485 2000-11-07 Jonathan Larmour <jlarmour@redhat.com>
487 * src/signal.cxx (cyg_posix_thread_siginit): Add extra thread
488 argument so that threads can inherit parent's sigmask.
490 * src/pthread.cxx (pthread_create): Call with parent thread
492 * src/pprivate.h: Change cyg_posix_thread_siginit prototype to take
493 parent thread argument
495 * tests/signal1.c: Add more checking of sigwaits, and fix so that it's
496 only called when the signal is masked. Check errno values too
499 2000-11-02 Jonathan Larmour <jlarmour@redhat.com>
501 * src/signal.cxx (sigtimedwait): return signal number on success,
503 (SIGNAL_RETURN_VALUE): New macro for returning from functions with
504 valid non-zero returns
505 (sigwaitinfo): Pass on sigtimedwait result with SIGNAL_RETURN_VALUE
506 macro as it may return the signal number.
508 2000-11-01 Jonathan Larmour <jlarmour@redhat.com>
510 * src/signal.cxx (sigtimedwait): Check for SIGALRMs as a special
511 case when looping as it won't have been set pending if it was
513 (check_sigalarm): New function extracted from the posix signal ASR
514 (sigalrm_action): Unconditionally wake up threads waiting in sigwait
515 so that they can check for pending SIGALRMs even if they were
517 (cyg_deliver_signals): Handle SIG_DFL signals properly, and check
518 for bad signal handlers.
519 (cyg_posix_signal_start): Initialize default signal actions to SIG_DFL
521 2000-10-27 Jesper Skov <jskov@redhat.com>
523 * tests/signal2.c (cause_illegal_access): Don't loop forever.
525 2000-10-16 Jonathan Larmour <jlarmour@redhat.com>
527 * include/sigsetjmp.h (sigsetjmp): Various fixes to make portable
528 across all HALs (by avoiding CYGARC_JMP_BUF_SIZE) and remove warnings.
529 * src/signal.cxx (siglongjmp): Likewise
531 2000-10-12 Nick Garnett <nickg@cygnus.co.uk>
533 * include/sigsetjmp.h: Added this header to define
534 sigjmp_buf,sigsetjmp() and siglongjmp().
537 Added support for providing sigsetjmp implementation and header.
538 Added sigsetjmp test.
540 * src/signal.cxx: Added siglongjmp().
542 * tests/sigsetjmp.c: Added this test for sigsetjmp(), siglongjmp()
543 functionality. This is also a test for longjmping out of signal
547 Ifdeffed around cause_* functions to avoid compiler warnings when
549 Changed CYG_TEST_NA() calls to CYG_TEST_INFO() and changed
550 CYG_TEST_FINISH() to CYG_TEST_PASS_FINISH(). With the _NA's there,
551 the first unsupported exception just terminates the program, and
552 does not give any subsequent supported ones a chance to run.
554 2000-10-12 Jesper Skov <jskov@redhat.com>
556 * tests/timer1.c (main): Fix exit check.
558 2000-10-11 Nick Garnett <nickg@cygnus.co.uk>
560 * src/pthread.cxx: Fixed cyg_posix_pthread_release_thread() to
561 work for _DETACHED threads as well as for _RUNNING ones. Also
562 fixed a bug in test to decrement counter in this routine.
564 * src/pprivate.h: Added note about retaining numerical order of
565 PTHREAD_STATE_* defines.
567 * tests/timer1.c: Fixed some bugs of the how-did-it-ever-work
570 2000-10-05 Nick Garnett <nickg@cygnus.co.uk>
573 Added a set of compatibility functions to aid portability and
574 improve standards compliance.
575 Added cyg_posix_function_[start|finish] to set up and terminate
576 POSIX API functionality wrt signal and cancellation behaviour.
577 (Lots more to do here).
580 Added this file to contain definitions that can be exported from
581 the POSIX package to others.
583 * src/pprivate.h: Added include of export.h
585 2000-09-11 Jonathan Larmour <jlarmour@redhat.com>
587 * include/limits.h (OPEN_MAX): Don't define here - let FS infra do
593 2000-09-04 Nick Garnett <nickg@cygnus.co.uk>
597 Fixed bug in calculation of thread stack addresses.
599 * src/misc.cxx (sysconf): Change zero returns to -1 when a feature
602 2000-08-08 Jonathan Larmour <jlarmour@redhat.co.uk>
604 * include/limits.h: Don't define SSIZE_MAX here, leave it to the
607 2000-07-27 Jonathan Larmour <jlarmour@redhat.co.uk>
609 * tests/signal2.c: NA if no setjmp/longjmp
611 2000-07-26 Nick Garnett <nickg@cygnus.co.uk>
614 * src/pthread.cxx (pthread_testcancel): Reversed addition of cyg_
617 2000-07-25 Jonathan Larmour <jlarmour@redhat.co.uk>
619 * src/pthread.cxx: Define main_stack and main_thread as static
620 Rename pthread_canceled -> cyg_pthread_canceled - pthread_ may be
621 a reserved name space but this makes explicit it is implementation-
622 and not standard-defined
623 (PTHREAD_ENTRY_VOID): Define for funcs that take no args
624 (pthread_testcancel): Call PTHREAD_ENTRY_VOID()
626 * include/pthread.h: Rename pthread_canceled -> cyg_pthread_canceled
628 2000-07-20 Jonathan Larmour <jlarmour@redhat.co.uk>
630 * src/pthread.cxx: Use isoinfra to determine presence of malloc()
631 Define pthread_malloc() and pthread_free() as inlines
633 * cdl/posix.cdl: Shouldn't define _POSIX_MESSAGE_PASSING at all - that
636 2000-07-20 Nick Garnett <nickg@cygnus.co.uk>
638 * cdl/posix.cdl: Added misc.cxx to compile list. Added option to
639 define _POSIX_MESSAGE_PASSING. Added configury for utsname
642 * include/utsname.h: Added this file to define struct utsname and
643 uname() function prototype.
645 * include/mqueue.h: Moved definition of _POSIX_MESSAGE_PASSING to
648 * include/limits.h: Added NGROUPS_MAX definition.
651 Added support for malloced() thread stacks.
652 Added implementations of pthread_mutex_setprioceiling() and
653 pthread_mutex_getprioceiling().
654 Changed implementations of pthread_mutex_destroy(),
655 pthread_mutex_lock() and pthread_mutex_trylock() to conform more
656 closely to the standard.
657 Changed pthread_key_create() to assign NULL to all valid thread
658 slots that correspond to a newly allocated key.
660 * src/pprivate.h: Added freestack and stackmem members to manage
661 malloced thread stacks.
663 * src/misc.cxx: Added this file to contain functions that do not
664 belong in any other files. Currently contains uname() and
667 2000-07-19 Jonathan Larmour <jlarmour@redhat.co.uk>
669 * src/startup.cxx: Remove unnecessary includes
670 Use dummy object constructor to do initialization
673 Don't need main.cxx any more
674 Build startup.cxx into extras.o (via libextras.a)
676 * cdl/pthread.cdl (CYGPKG_POSIX_MAIN_THREAD):
677 Integrate with CYGPKG_LIBC_STARTUP - tell CYGPKG_LIBC_STARTUP to
678 let pthreads set up main thread
680 * src/pthread.cxx: Integrate with CYGPKG_LIBC_STARTUP rather than
681 calling main() directly.
682 Track number of threads waiting to be joined, so we can tell in
683 pthread_exit() if this is the last thread, and therefore whether
686 * src/main.cxx: obsolete, removed
688 2000-07-13 Nick Garnett <nickg@cygnus.co.uk>
690 * src/signal.cxx: Added ISO C compatibility functions signal() and
693 2000-06-21 Nick Garnett <nickg@cygnus.co.uk>
695 * src/pthread.cxx: Added for(;;) loop to end of pthread_exit().
696 pthread_exit() is marked with the noreturn attribute, and without
697 this some compilers generate a call to abort() here in case
698 Cyg_Thread::exit() returns. The loop avoids this.
700 2000-06-06 Jonathan Larmour <jlarmour@redhat.co.uk>
702 * src/mqueue.cxx (mq_receive): Fix non-portable treatment of mode flags
704 * tests/mqueue2.c (main): Ditto
706 2000-05-24 Nick Garnett <nickg@cygnus.co.uk>
708 * tests/pthread2.c: Added this program to test per-thread data
711 * tests/pthread3.c: Added this program to test execution of
712 cancellation handler.
714 * src/pthread.cxx: Fixed some bugs revealed by new test programs.
716 * cdl/posix.cdl: Added two new pthread tests.
718 2000-05-22 Jonathan Larmour <jlarmour@redhat.co.uk>
720 * cdl/posix.cdl (CYGPKG_POSIX): Require
721 CYGIMP_KERNEL_SCHED_SORTED_QUEUES
723 2000-05-20 Jonathan Larmour <jlarmour@redhat.co.uk>
725 * tests/mqueue1.c (cyg_user_start): Define correctly
726 * tests/mqueue2.c (cyg_user_start): Likewise
728 * src/pprivate.h (cyg_sigqueue): Make struct sigevent * arg const since
729 it is, and it prevents warnings elsewhere
730 * src/signal.cxx (cyg_sigqueue): ditto
732 * tests/signal2.c: Use CYG_TEST_NA, not CYG_TEST_INFO (otherwise
733 the test farm may fail the tests because there are no PASSes or NAs)
735 * cdl/posix.cdl (CYGPKG_POSIX): We need errno and error codes, so
737 Move some of the package implements into the components
738 Add message queue configuration, build mqueue.cxx and the mqueue1 and
740 Move some calculated options into isoinfra, implemented as interfaces
741 so that unistd.h and limits.h can get the values
743 * include/limits.h: Move _POSIX_* macros into isoinfra limits.h
744 since they are implementation independent
746 * src/mqueue.cxx: Add POSIX message queue implementation
747 * tests/mqueue1.c, tests/mqueue2.c: and tests
749 2000-05-18 Nick Garnett <nickg@cygnus.co.uk>
755 Added prioritization of static kernel objects.
757 2000-05-17 Nick Garnett <nickg@cygnus.co.uk>
760 To reduce the static memory required by this code, the
761 pthread_info structure for a pthread is now allocated in the stack
762 memory for that thread, and not in a static table. The table is
763 now just an array of pointers. The per-thread data array is now
764 also allocated onto the stack only when first required.
766 * include/pthread.h: Removed some redundant code.
768 * include/limits.h: Added PTHREAD_STACK_OVERHEAD to record
769 management overhead imposed on POSIX threads stacks. This is added
770 to the HAL minimum requirement to generate PTHREAD_STACK_MIN.
772 * src/pprivate.h (pthread_info):
773 * include/types.h (pthread_attr_t): Converted a number of integer
774 state and boolean fields to bitfields.
777 Added requirement for CYGFUN_KERNEL_THREADS_STACK_LIMIT.
779 2000-05-16 Nick Garnett <nickg@cygnus.co.uk>
781 * include/types.h: Added stacksize_valid to pthread_attr_t
785 Added SI_EXCEPT to mark any signals that were caused by an
786 exception. Removed conditions around SIGBUS.
788 * src/startup.cxx (cyg_posix_start):
789 Added call to cyg_posix_exception_start().
792 Rearranged cyg_deliver_signals() so that it is possible to
793 longjmp() out of a signal handler without leaving signal handling
794 code in an inconsistent state.
795 Added handling of SIG_IGN in sigaction().
797 * src/pthread.cxx: Added setting and checking of stacksize_valid.
799 * src/pprivate.h: Added cyg_deliver_signals() as an export of
800 signal system. Added exports from except.cxx.
802 * src/except.cxx: Added this file to handle delivery of exceptions
803 into the POSIX signal mechanism.
805 * cdl/posix.cdl: Added except.cxx to compile list, added signal2
806 to tests. Added requirement on kernel exception processing.
808 * tests/tm_basic.cxx: Tidied up a compilation warning.
810 * tests/signal2.c: Added this test for exception signal generation.
812 * tests/mutex3.c: Fixed stupid bug.
814 2000-05-10 Nick Garnett <nickg@cygnus.co.uk>
816 * src/pprivate.h: Added cyg_posix_clock_start() prototype.
818 * src/startup.cxx: Added call to cyg_posix_clock_start().
820 * src/time.cxx: Added startup routine to initialize
821 converters. Fixed error result bug in timer_delete().
823 * include/signal.h: Removed some configuration tests which are now
826 * cdl/posix.cdl: Added configury for the signals component. Added
829 * tests/tm_basic.cxx:
830 Added this POSIXized version of the tm_basic test. Note that this
831 has not been entirely converted. While the code being tested is
832 POSIX, the timing infrastructure remains a mish-mash of kernel,
835 2000-05-04 Nick Garnett <nickg@cygnus.co.uk>
838 Many changes to implement the delivery of signals on timer expiry.
839 Also added timer_delete().
842 cyg_sigqueue() and cyg_deliver_signals() may now only be called
843 from within the context of a POSIX thread, either from an API call
845 cyg_deliver_signals() can now cope with a signal that has
846 SA_SIGINFO set but no signals queued. It also determines
847 dynamically whether to lock the signal_mutex.
848 cyg_deliver_signals() is no longer called implicitly from
849 cyg_sigqueue() - so a number of expicit calls have been added.
852 Added this file to implement scheduling API.
855 Moved priority translation macros to pprivate.h.
856 Removed errno handling, now done in isoinfra package.
857 Added iterative calls to per-thread data destructors.
860 Removed error field from pthread_info structure.
861 Moved priority translation macros here.
862 Removed prototype for cyg_deliver_signals().
863 Added prototype for cyg_posix_timer_asr().
865 * include/time.h: Added timer_delete() which was mysteriously
868 * cdl/posix.cdl: Added sched.cxx to compile list and timer1.c to
873 Fixed bug in use of stack sizes.
876 Added test for use of timers.
878 2000-05-02 Jonathan Larmour <jlarmour@redhat.co.uk>
880 * include/sched.h: No longer needed - just use the default definition
883 * include/errno.h: No longer needed - errno provision now comes from
886 * include/sys/types.h: Moved to include/types.h
888 * cdl/posix.cdl, cdl/pthread.cdl: Put include files in cyg/posix, and
889 configure CYGPKG_ISOINFRA to include the appropriate headers
891 * include/semaphore.h: Don't need to check kernel - including
892 pkgconf/kernel.h would already fail
893 Give SEM_FAILED a type so casting behaves in C++
895 * include/signal.h: This uses pid_t etc., so include <sys/types.h>
896 Add signal() and raise() prototypes (to allow libc compilation, even
897 though they aren't implemented yet)
899 * include/time.h: Remove unnecessary includes. Move clockid_t and
900 timer_t definitions here from sys/types.h since this is where the
901 standard says they must live.
903 * src/pprivate.h: Include signal.h and limits.h since their contents
904 are used later in the file.
906 2000-04-28 Nick Garnett <nickg@cygnus.co.uk>
909 Added implementations of alarm(), pause() and sleep().
910 Modified cyg_sigqueue() so that it could be called from an ASR.
911 Added cyg_posix_signal_asr() to do signal processing in ASRs.
912 Miscellaneous bug fixes.
915 Added pthread_count to count number of threads created.
916 Added call to signal ASR function in main ASR.
917 Added cyg_posix_pthread_release_thread() to seek out and kick a
918 thread to which a given set of signals may be delivered.
921 Added some more functions that are shared between POSIX
925 Added alarm(), pause() and sleep() prototypes.
927 * tests/signal1.c: Added this test for various aspects of signal
930 * cdl/posix.cdl: Added signal1 test.
932 2000-04-20 Nick Garnett <nickg@cygnus.co.uk>
934 * src/signal.cxx: Added this file to contain signal handling code.
936 * src/time.cxx: Made tick<->timespec converters exported to
937 rest of POSIX subsystem. Enabled interface to signal mechanism for
938 notifying timer expiration.
941 Made pthread_mutex exported to rest of POSIX subsystem.
942 Exported pthread_info_id().
943 Added thread init and destroy functions for signal subsystem.
945 * src/startup.cxx: Added call to cyg_posix_signal_start().
947 * src/pprivate.h: Added signal handling fields support to
948 pthread_info structure. Added extra internal interfaces to support
949 signal handling code.
951 * include/signal.h: Added _how_ argument values for the sigmask
954 * cdl/posix.cdl: Added signal.cxx to compile list.
956 2000-04-13 Nick Garnett <nickg@cygnus.co.uk>
960 Added implementation of clock and timer functions. These are
961 currently untested since they need working signals.
963 2000-04-12 Nick Garnett <nickg@cygnus.co.uk>
965 * src/pprivate.h: Added cancellation support fields to
966 pthread_info structure. Made pthread_self_info() exported.
968 * include/semaphore.h: Added SEM_FAILED plus misc. tidies.
970 * include/pthread.h: Added PTHREAD_CANCELED.
972 * include/errno.h: Fixed cyg_pthread_errno_p() return type.
975 Added pthread_reap() to clean up exited threads.
976 Added support for cancellation.
977 Added cyg_posix_errno_p().
980 Added this file to implement time functionality. At present only
981 nanosleep() is actually implemented.
984 Added this file to implement semaphore functionality.
987 Added some extra configuration requirements.
990 Added some more files to compile.
991 Added semaphore configuration.
994 Added this test program. This is actually a POSIXized version of
995 Hugo's splendid kernel test of the same name. It exercises quite a
996 lot of the pthread infrastructure and is thus a good test to run.
999 Added proper comment headers and added full testing stuff.
1001 2000-04-10 Nick Garnett <nickg@cygnus.co.uk>
1005 Added per-thread data support.
1007 2000-04-06 Nick Garnett <nickg@cygnus.co.uk>
1010 Filled in implementations of lots of functions.
1013 Added this file to contain a default main. This is currenly just a
1014 duplicate of the same file from the C library. Work is needed to
1017 * include/sys/types.h:
1018 Modified pthread_mutex_t to conform to kernel structure.
1021 Added support for main thread.
1024 Added main.cxx to compile list.
1026 2000-03-31 Nick Garnett <nickg@cygnus.co.uk>
1030 Added CDL files to configure POSIX subsystem.
1035 Added these files to begin implementation of POSIX package.
1037 * include/pthread.h:
1041 * include/sys/types.h:
1042 Many changes needed by implementation work.
1046 Added these header files.
1048 2000-03-24 Nick Garnett <nickg@cygnus.co.uk>
1050 * include/sys/types.h:
1053 * include/pthread.h:
1055 * include/semaphore.h:
1057 Roughed out (most of) the set of POSIX headers for the
1058 functionality we are currently going to support. These files are
1059 currently neither fully standard conformant nor implementation
1060 ready. Much work is still needed to make them so. Watch this
1063 #####ECOSGPLCOPYRIGHTBEGIN####
1064 ## -------------------------------------------
1065 ## This file is part of eCos, the Embedded Configurable Operating System.
1066 ## Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
1068 ## eCos is free software; you can redistribute it and/or modify it under
1069 ## the terms of the GNU General Public License as published by the Free
1070 ## Software Foundation; either version 2 or (at your option) any later version.
1072 ## eCos is distributed in the hope that it will be useful, but WITHOUT ANY
1073 ## WARRANTY; without even the implied warranty of MERCHANTABILITY or
1074 ## FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
1075 ## for more details.
1077 ## You should have received a copy of the GNU General Public License along
1078 ## with eCos; if not, write to the Free Software Foundation, Inc.,
1079 ## 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
1081 ## As a special exception, if other files instantiate templates or use macros
1082 ## or inline functions from this file, or you compile this file and link it
1083 ## with other works to produce a work based on this file, this file does not
1084 ## by itself cause the resulting work to be covered by the GNU General Public
1085 ## License. However the source code for this file must still be made available
1086 ## in accordance with section (3) of the GNU General Public License.
1088 ## This exception does not invalidate any other reasons why a work based on
1089 ## this file might be covered by the GNU General Public License.
1091 ## Alternative licenses for eCos may be arranged by contacting Red Hat, Inc.
1092 ## at http://sources.redhat.com/ecos/ecos-license/
1093 ## -------------------------------------------
1094 #####ECOSGPLCOPYRIGHTEND####