Commit Graph

1138 Commits

Author SHA1 Message Date
Joel Sherrill
45d406f8e9 2007-05-10 Joel Sherrill <joel.sherrill@OARcorp.com>
PR 1241/rtems
	* score/src/threadchangepriority.c, score/src/threadqrequeue.c: Close
	critical section window added with requeueing support.
2007-05-10 18:47:35 +00:00
Joel Sherrill
a32835a34a 2007-05-10 Joel Sherrill <joel.sherrill@OARcorp.com>
PR 1237/rtems
	* cpu.c, cpu_asm.S, rtems/score/cpu.h: Add logic to prevent stack creep
	when interrupts occur at a sufficient rate that the interrupted
	thread never gets to clean its stack. This patch ensures that an
	interrupted thread will not nest ISR dispatches on its stack.
2007-05-10 18:40:49 +00:00
Joel Sherrill
c3db01d0f3 2007-05-09 Joel Sherrill <joel.sherrill@OARcorp.com>
* libcsupport/include/rtems/libcsupport.h, libcsupport/src/newlibc.c,
	sapi/Makefile.am, sapi/include/confdefs.h, sapi/src/exinit.c,
	score/Makefile.am, score/preinstall.am,
	score/include/rtems/score/userext.h, score/src/chain.c,
	score/src/userext.c: Switch to newlib reentrancy extension being
	installed in the initial set instead of using rtems_extension_create.
	While implementing this, noticed that user extensions and chain code
	had multiple functions in a single file which is not desirable in the
	SuperCore and API portions of RTEMS, so split these into multiple
	files with one function per file. Also noticed that some of user
	extension code was inlined for no particular reason so moved that to
	C bodies.  Split executive shutdown from initialization since not
	every application shuts down.  Moved __fini call to executive shutdown
	to be more symmetrical with where it is called at startup.
	* sapi/src/exshutdown.c, score/src/chainappend.c,
	score/src/chainextract.c, score/src/chainget.c,
	score/src/chaininsert.c, score/src/userextaddapiset.c,
	score/src/userextaddset.c, score/src/userextremoveset.c,
	score/src/userextthreadbegin.c, score/src/userextthreadcreate.c,
	score/src/userextthreaddelete.c, score/src/userextthreadrestart.c,
	score/src/userextthreadstart.c, score/src/userextthreadswitch.c: New
	files.
	* score/inline/rtems/score/userext.inl: Removed.
2007-05-09 18:27:26 +00:00
Ralf Corsepius
203ed7ff8c Include <rtems/stdint.h> instead of <stdint.h>. 2007-05-09 15:56:13 +00:00
Ralf Corsepius
8b56aa3dea 2007-05-09 Ralf Corsépius <ralf.corsepius@rtems.org>
* rtems/score/cpu.h: Remove CPU_HAS_OWN_HOST_TO_NETWORK_ROUTINES.
2007-05-09 15:28:52 +00:00
Ralf Corsepius
2ff7d009a0 Add HAVE_CONFIG_H magic. 2007-05-08 15:34:14 +00:00
Ralf Corsepius
728a0bd3aa Use size_t for stacksizes. 2007-05-08 10:43:06 +00:00
Joel Sherrill
e746a88b22 2007-05-03 Joel Sherrill <joel@OARcorp.com>
* ChangeLog, libcsupport/src/malloc.c,
	libcsupport/src/mallocfreespace.c, sapi/include/confdefs.h,
	score/Makefile.am, score/preinstall.am: malloc never blocks so the
	Region Manager is quite heavy for implementing this. This patch
	implements the C Program Heap directly in terms of the new Protected
	Heap handler. This handler is a direct use of a SuperCore Heap in
	conjunction with the Allocator Mutex used internally by RTEMS. This
	saves 3184 bytes on most SPARC test executables.
	* score/include/rtems/score/protectedheap.h, score/src/pheapallocate.c,
	score/src/pheapallocatealigned.c, score/src/pheapextend.c,
	score/src/pheapfree.c, score/src/pheapgetblocksize.c,
	score/src/pheapgetfreeinfo.c, score/src/pheapgetinfo.c,
	score/src/pheapinit.c, score/src/pheapresizeblock.c,
	score/src/pheapwalk.c: New files.
2007-05-03 21:33:39 +00:00
Joel Sherrill
ddb1867f82 2007-04-17 Joel Sherrill <joel@OARcorp.com>
* rtems/bfin/bf533.h: Fix warnings about constants being too large.
2007-04-17 17:10:24 +00:00
Ralf Corsepius
8ea0d7dabd 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* rtems/score/cpu.h:
	  Use Context_Control_fp* instead of void* for fp_contexts.
	  Eliminate evil casts.
2007-04-17 05:58:04 +00:00
Ralf Corsepius
b60dc89330 Use Context_Control_fp* instead of void* for fp_contexts.
Eliminate evil casts.
2007-04-17 05:57:57 +00:00
Ralf Corsepius
e08e6c4c21 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* cpu.c, rtems/score/cpu.h:
	  Use Context_Control_fp* instead of void* for fp_contexts.
2007-04-17 05:50:50 +00:00
Ralf Corsepius
14865ec7b9 Use Context_Control_fp* instead of void* for fp_contexts. 2007-04-17 05:50:27 +00:00
Ralf Corsepius
c1fb67b686 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* cpu.c:
	  Use Context_Control_fp* instead of void* for fp_contexts.
2007-04-17 05:46:16 +00:00
Ralf Corsepius
f2c2caa5e9 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* rtems/score/cpu.h:
	  Use Context_Control_fp* instead of void* for fp_contexts.
	  Eliminate evil casts.
2007-04-17 05:43:02 +00:00
Ralf Corsepius
0edd196e46 Use Context_Control_fp* instead of void* for fp_contexts.
Eliminate evil casts.
2007-04-17 05:42:54 +00:00
Ralf Corsepius
476838bf7a 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* rtems/score/cpu.h:
	  Use Context_Control_fp* instead of void* for fp_contexts.
	  Eliminate evil casts.
2007-04-17 05:31:35 +00:00
Ralf Corsepius
ce1093e07c Use Context_Control_fp* instead of void* for fp_contexts.
Eliminate evil casts.
2007-04-17 05:31:27 +00:00
Ralf Corsepius
231aac4fc1 Use Context_Control_fp* instead of void* for fp_contexts.
Eliminate evil casts.
2007-04-17 05:18:49 +00:00
Ralf Corsepius
c4881ddb67 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* rtems/score/cpu.h:
	  Use Context_Control_fp* instead of void* for fp_contexts.
	  Eliminate evil casts.
2007-04-17 05:18:43 +00:00
Ralf Corsepius
3ca0bfe030 Use Context_Control_fp* instead of void* for fp_contexts.
Eliminate evil casts.
2007-04-17 05:11:53 +00:00
Ralf Corsepius
9374ed491f 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* rtems/score/cpu.h:
	  Use Context_Control_fp* instead of void* for fp_contexts.
	  Eliminate evil casts.
2007-04-17 05:11:31 +00:00
Ralf Corsepius
4ec2f4f6f8 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* cpu_asm.c:
	  Use Context_Control_fp* instead of void* for fp_contexts.
	* rtems/score/cpu.h:
	  Use Context_Control_fp* instead of void* for fp_contexts.
	  Eliminate evil casts.
2007-04-17 05:05:59 +00:00
Ralf Corsepius
39308e008b Use Context_Control_fp* instead of void* for fp_contexts. 2007-04-17 05:05:54 +00:00
Ralf Corsepius
9e0abe51a1 Use Context_Control_fp* instead of void* for fp_contexts.
Eliminate evil casts.
2007-04-17 05:05:39 +00:00
Ralf Corsepius
3c577510c8 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* rtems/score/cpu.h:
	  Use Context_Control_fp* instead of void* for fp_contexts.
2007-04-17 05:03:24 +00:00
Ralf Corsepius
50650ed3ea 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* rtems/score/cpu.h:
	  Use Context_Control_fp* instead of void* for fp_contexts.
	  Eliminate evil casts.
2007-04-17 05:02:29 +00:00
Ralf Corsepius
0aa0ef63c5 2007-04-17 Ralf Corsépius <ralf.corsepius@rtems.org>
* cpu.c:
	  Use Context_Control_fp* instead of void* for fp_contexts.
	* rtems/score/cpu.h:
	  Use Context_Control_fp* instead of void* for fp_contexts.
	  Eliminate evil casts.
2007-04-17 05:01:15 +00:00
Ralf Corsepius
3c86f88536 Use Context_Control_fp* instead of void* for fp_contexts. 2007-04-17 04:55:44 +00:00
Ralf Corsepius
ada7b9e142 Use Context_Control_fp* instead of void* for fp_contexts. Eliminate evil casts. 2007-04-17 04:49:05 +00:00
Ralf Corsepius
ccb09f6b86 Use Context_Control_fp* instead of void* for fp_contexts. Eliminate evil casts. 2007-04-17 04:42:37 +00:00
Ralf Corsepius
63c23d3272 Include <sys/time.h>. 2007-04-13 05:14:46 +00:00
Ralf Corsepius
7a5e8fb6ce 2007-04-13 Ralf Corsépius <ralf.corsepius@rtems.org>
* score/include/rtems/score/object.h: Use size_t for byte sizes.
2007-04-13 03:10:03 +00:00
Joel Sherrill
63f786e7c8 2007-04-05 Joel Sherrill <joel@OARcorp.com>
* itron/src/itrontime.c: Fix typo.
	* score/include/rtems/score/tod.h: Add TOD_TICKS_PER_SECOND macro.
	* score/src/iterateoverthreads.c: Safely take NULL as argument.
	* score/src/threaddispatch.c: Formatting.
2007-04-05 22:13:08 +00:00
Joel Sherrill
412dbff629 2007-04-05 Joel Sherrill <joel@OARcorp.com>
* posix/Makefile.am, posix/include/rtems/posix/time.h,
	posix/src/adjtime.c, posix/src/alarm.c, posix/src/clockgetres.c,
	posix/src/condtimedwait.c, posix/src/mqueuetimedreceive.c,
	posix/src/mqueuetimedsend.c, posix/src/mutextimedlock.c,
	posix/src/nanosleep.c, posix/src/posixtimespecabsolutetimeout.c,
	posix/src/pthread.c, posix/src/pthreadcreate.c,
	posix/src/pthreadsetschedparam.c, posix/src/ptimer1.c,
	posix/src/sched.c, posix/src/semtimedwait.c,
	posix/src/sigtimedwait.c, posix/src/ualarm.c,
	rtems/src/clocktodtoseconds.c, score/Makefile.am,
	score/preinstall.am, score/include/rtems/score/tod.h,
	score/inline/rtems/score/tod.inl, score/src/coretod.c,
	score/src/coretodget.c, score/src/coretodgetuptime.c,
	score/src/coretodset.c, score/src/coretodtickle.c: Provide timespec
	manipulation routines in the SuperCore. Use them everywhere possible.
	This lead to significant cleanup in the API routines and eliminated
	some of the same code from the POSIX API. At this point, the
	SuperCore keeps time in POSIX timespec format properly from 1970. You
	just cannot set it before 1988 in keeping with RTEMS traditional
	behavior.
	* score/include/rtems/score/timespec.h, score/src/timespecaddto.c,
	score/src/timespecfromticks.c, score/src/timespecisvalid.c,
	score/src/timespeclessthan.c, score/src/timespecsubtract.c,
	score/src/timespectoticks.c: New files.
	* posix/src/posixintervaltotimespec.c,
	posix/src/posixtimespecsubtract.c,
	posix/src/posixtimespectointerval.c: Removed.
2007-04-05 21:17:27 +00:00
Joel Sherrill
fc054cabb5 2007-04-04 Joel Sherrill <joel@OARcorp.com>
* score/Makefile.am, score/include/rtems/score/tod.h,
	score/inline/rtems/score/tod.inl: Make _TOD_Tickle_ticks a real
	non-inlined routine. It should only be used once so there is little
	advantage to inlining it.
	* score/src/coretodtickle.c: New file.
2007-04-04 13:54:10 +00:00
Joel Sherrill
551db24a70 2007-04-02 Joel Sherrill <joel@OARcorp.com>
* posix/Makefile.am, score/src/objectgetnoprotection.c: Eliminate some
	dead code.
	* posix/src/time.c: Removed.
2007-04-02 22:06:18 +00:00
Joel Sherrill
f6e09342ee 2007-04-02 Joel Sherrill <joel@OARcorp.com>
* posix/include/rtems/posix/timer.h, posix/src/alarm.c,
	posix/src/posixtimespectointerval.c, posix/src/ptimer1.c,
	posix/src/sysconf.c, posix/src/ualarm.c, rtems/src/clockget.c,
	rtems/src/clocktodvalidate.c, score/include/rtems/score/tod.h,
	score/inline/rtems/score/tod.inl, score/src/coretod.c: Eliminate
	TOD_Ticks_per_second variable.
2007-04-02 21:51:52 +00:00
Joel Sherrill
812da54688 2007-04-02 Joel Sherrill <joel@OARcorp.com>
* itron/src/itrontime.c, libcsupport/src/__gettod.c,
	posix/include/rtems/posix/time.h, posix/include/rtems/posix/timer.h,
	posix/src/clockgettime.c, posix/src/clocksettime.c,
	posix/src/nanosleep.c, posix/src/posixtimespecsubtract.c,
	posix/src/posixtimespectointerval.c, posix/src/ptimer1.c,
	posix/src/sleep.c, rtems/Makefile.am,
	rtems/include/rtems/rtems/clock.h, rtems/include/rtems/rtems/timer.h,
	rtems/include/rtems/rtems/types.h, rtems/src/clockget.c,
	rtems/src/clockset.c, rtems/src/clocktodtoseconds.c,
	rtems/src/clocktodvalidate.c, rtems/src/taskwakewhen.c,
	score/Makefile.am, score/include/rtems/score/tod.h,
	score/inline/rtems/score/tod.inl, score/src/coretod.c,
	score/src/coretodset.c: Convert from Classic API style TOD_Control as
	fundamental time structure to POSIX struct timespec. Add
	clock_get_uptime().
	* rtems/src/clockgetuptime.c, score/src/coretodget.c,
	score/src/coretodgetuptime.c: New files.
	* score/src/coretodtickle.c, score/src/coretodtoseconds.c,
	score/src/coretodvalidate.c: Removed.
2007-04-02 18:23:59 +00:00
Joel Sherrill
4b6546f0bb 2007-03-28 Chris Johns <chrisj@rtems.org>
* rtems/Makefile.am, rtems/include/rtems/rtems/clock.h,
	score/include/rtems/score/watchdog.h: Add support for a handler to
	obtain the number of nanoseconds since the last clock tick. The
	primary interface for this is rtems_clock_set_nanoseconds_extension.
	Subsequent commits from Joel will redo the TOD support to use this
	capability.
	* rtems/src/clocksetnsecshandler.c: New file.
2007-03-28 19:56:14 +00:00
Ralf Corsepius
77b1020ad7 2007-03-18 Ralf Corsépius <ralf.corsepius@rtems.org>
* score/src/heapwalk.c: include stdlib.h.
2007-03-18 07:34:25 +00:00
Ralf Corsepius
37c7bfcbd2 Change _Workspace_Handler_initialization and _Workspace_Allocate_or_fatal_error to using size_t. 2007-03-16 07:19:24 +00:00
Ralf Corsepius
83d01d54d7 2007-03-13 Ralf Corsépius <ralf.corsepius@rtems.org>
* score/include/rtems/score/stack.h: Use size_t for stack sizes.
2007-03-13 05:38:21 +00:00
Ralf Corsepius
d38ac0e614 2007-03-13 Ralf Corsépius <ralf.corsepius@rtems.org>
* score/include/rtems/score/chain.h, score/src/chain.c:
	Change _Chain_Initialize to using size_t.
2007-03-13 05:17:12 +00:00
Joel Sherrill
1fb90ec740 2007-03-12 Joel Sherrill <joel@OARcorp.com>
* score/src/heapallocatealigned.c, score/src/threadqrequeue.c: Correct
	license URL and/or fix mistake in copyright notice. Both of these
	mistakes appear to be from code submitted after these changes were
	made previously.
2007-03-12 11:16:02 +00:00
Joel Sherrill
96d0b64c62 2007-03-05 Joel Sherrill <joel@OARcorp.com>
PR 1222/cpukit
	* score/Makefile.am, score/include/rtems/score/coremutex.h,
	score/include/rtems/score/threadq.h,
	score/inline/rtems/score/coremutex.inl, score/src/coremsgsubmit.c,
	score/src/coremutexsurrender.c, score/src/threadchangepriority.c,
	score/src/threadclearstate.c, score/src/threadhandler.c,
	score/src/threadinitialize.c, score/src/threadqdequeuefifo.c,
	score/src/threadqdequeuepriority.c, score/src/threadqenqueue.c,
	score/src/threadqenqueuefifo.c, score/src/threadqenqueuepriority.c,
	score/src/threadqextractfifo.c, score/src/threadqextractpriority.c,
	score/src/threadsetstate.c: Enhance so that when the prioirity of a
	thread that is blocked on a priority based thread queue is changed,
	that its placement in the queue is reevaluated based upon the new
	priority. This enhancement includes modifications to the SuperCore as
	well as new test cases.
	* score/src/threadqrequeue.c: New file.
2007-03-05 21:01:40 +00:00
Ralf Corsepius
4768a2742b 2007-02-16 Ralf Corsepius <ralf.corsepius@rtems.org>
* score/Makefile.am: Remove macros/README.
2007-02-16 01:55:47 +00:00
Ralf Corsepius
59c44c6b95 More size_t for heap-sizes. 2007-02-11 08:35:15 +00:00
Ralf Corsepius
8022a681a3 Use size_t for heap-sizes. 2007-02-11 04:52:37 +00:00
Ralf Corsepius
f0bc38351c 2007-02-06 Ralf Corsépius <ralf.corsepius@rtems.org>
* score/inline/rtems/score/coremsg.inl: More size_t and consts.
2007-02-06 13:40:57 +00:00