Commit Graph

90 Commits

Author SHA1 Message Date
Sebastian Huber
18657d189d 2010-12-16 Sebastian Huber <sebastian.huber@embedded-brains.de>
* score/src/watchdognanoseconds.c: New file.
	* score/Makefile.am: Reflect change above.
	* score/include/rtems/score/watchdog.h, score/src/coretodget.c,
	score/src/coretodgetuptime.c: Do not allow NULL as nanoseconds since
	last tick handler pointer.
2010-12-16 14:50:12 +00:00
Joel Sherrill
0faa9dad07 2010-11-24 Gedare Bloom <giddyup44@yahoo.com>
PR 1647/cpukit
	* posix/src/nanosleep.c, posix/src/sched_yield.c,
	rtems/src/taskwakeafter.c, sapi/include/confdefs.h,
	sapi/include/rtems/config.h, sapi/src/exinit.c, score/Makefile.am,
	score/preinstall.am, score/include/rtems/score/prioritybitmap.h,
	score/include/rtems/score/thread.h,
	score/inline/rtems/score/thread.inl, score/src/thread.c,
	score/src/threadchangepriority.c, score/src/threadclearstate.c,
	score/src/threadclose.c, score/src/threadinitialize.c,
	score/src/threadready.c, score/src/threadresume.c,
	score/src/threadsetpriority.c, score/src/threadsetstate.c,
	score/src/threadsettransient.c,	score/src/threadsuspend.c,
	score/src/threadtickletimeslice.c: Refactor scheduler out of thread
	handler to facilitate alternate scheduler implementations.
	* score/src/threadyieldprocessor.c: Removed.
	* score/src/schedulerprioritythreadschedulerupdate.c,
	score/src/schedulerprioritythreadschedulerfree.c,
	score/src/schedulerpriorityblock.c, score/src/scheduler.c,
	score/src/schedulerprioritythreadschedulerallocate.c,
	score/src/schedulerpriorityunblock.c,
	score/src/schedulerpriority.c, score/src/schedulerpriorityyield.c,
	score/include/rtems/score/schedulerpriority.h,
	score/include/rtems/score/scheduler.h,
	score/inline/rtems/score/scheduler.inl,
	score/inline/rtems/score/schedulerpriority.inl: New files.
2010-11-24 15:51:28 +00:00
Sebastian Huber
a19ae9ec60 2010-08-23 Sebastian Huber <sebastian.huber@embedded-brains.de>
PR 1673/cpukit
	* score/src/chainappendempty.c, score/src/chaingetempty.c,
	score/src/chainprependempty.c: New files.
	* score/Makefile.am: Reflect changes above.
	* score/include/rtems/score/chain.h: Declare
	_Chain_Append_with_empty_check(), _Chain_Prepend_with_empty_check(),
	and _Chain_Get_with_empty_check().
	* score/inline/rtems/score/chain.inl: Define
	_Chain_Append_with_empty_check_unprotected(),
	_Chain_Prepend_with_empty_check_unprotected(), and
	_Chain_Get_with_empty_check_unprotected().
2010-08-23 16:10:53 +00:00
Joel Sherrill
a55e305ed3 2010-07-29 Gedare Bloom <giddyup44@yahoo.com>
PR 1635/cpukit
	* sapi/src/exinit.c, score/Makefile.am, score/preinstall.am,
	score/include/rtems/score/bitfield.h,
	score/include/rtems/score/priority.h,
	score/include/rtems/score/thread.h,
	score/inline/rtems/score/priority.inl,
	score/inline/rtems/score/thread.inl,
	score/src/threadchangepriority.c, score/src/threadclearstate.c,
	score/src/threadready.c, score/src/threadresume.c,
	score/src/threadsetpriority.c, score/src/threadsetstate.c,
	score/src/threadsettransient.c, score/src/threadsuspend.c:
	Refactoring of priority handling, to isolate the bitmap
	implementation of priorities in the supercore so that priority
	management is a little more modular. This change is in anticipation
	of scheduler implementations that can select how they manage tracking
	priority levels / finding the highest priority ready task. Note that
	most of the changes here are simple renaming, to clarify the use of
	the bitmap-based priority management.
	* score/include/rtems/score/prioritybitmap.h,
	score/inline/rtems/score/prioritybitmap.inl: New files.
2010-07-29 17:52:10 +00:00
Sebastian Huber
9f9a82bdce 2010-07-16 Sebastian Huber <sebastian.huber@embedded-brains.de>
* score/include/rtems/score/basedefs.h: New file.
	* score/Makefile.am, score/preinstall.am: Reflect change above.
	* score/include/rtems/score/percpu.h: Include <rtems/score/cpu.h>.
	* score/include/rtems/system.h: Moved definition of SCORE_EXTERN,
	SAPI_EXTERN, RTEMS_EXTERN, POSIX_EXTERN, RTEMS_INLINE_ROUTINE,
	RTEMS_COMPILER_MEMORY_BARRIER, RTEMS_COMPILER_NO_RETURN_ATTRIBUTE,
	RTEMS_COMPILER_DEPRECATED_ATTRIBUTE, TRUE, and FALSE to
	<rtems/score/basedefs.h>.
	Removed include of <rtems/score/cpu.h>, <stdint.h> and <stddef.h>.
2010-07-16 08:31:34 +00:00
Sebastian Huber
32d5196d70 2010-07-06 Sebastian Huber <sebastian.huber@embedded-brains.de>
* score/src/isrthreaddispatch.c: Removed file.
	* score/Makefile.am: Reflect change above.
	* score/include/rtems/score/isr.h: Removed _ISR_Thread_dispatch()
	declaration.
2010-07-06 07:56:15 +00:00
Joel Sherrill
11e8bc5f0f 2010-06-28 Joel Sherrill <joel.sherrill@oarcorp.com>
PR 1573/cpukit
	* configure.ac, posix/src/killinfo.c,
	posix/src/psignalclearprocesssignals.c,
	posix/src/psignalsetprocesssignals.c,
	posix/src/psignalunblockthread.c, posix/src/pthreadcreate.c,
	posix/src/pthreadkill.c, posix/src/pthreadsigmask.c,
	rtems/src/signalsend.c, rtems/src/taskmode.c, score/Makefile.am,
	score/preinstall.am, score/include/rtems/system.h,
	score/include/rtems/score/context.h, score/include/rtems/score/isr.h,
	score/include/rtems/score/thread.h, score/src/isr.c,
	score/src/isrthreaddispatch.c, score/src/thread.c,
	score/src/threaddispatch.c, score/src/threadloadenv.c: Add a per cpu
	data structure which contains the information required by RTEMS for
	each CPU core. This encapsulates information such as thread
	executing, heir, idle and dispatch needed.
	* score/include/rtems/score/percpu.h, score/src/percpu.c: New files.
2010-06-29 00:34:12 +00:00
Joel Sherrill
569b3f4141 2010-06-24 Gedare Bloom <giddyup44@yahoo.com>
PR 1589/cpukit
	* score/Makefile.am, score/include/rtems/score/thread.h,
	score/inline/rtems/score/thread.inl: Make _Thread_Evaluate_mode() an
	inline method. It is only used in one place and relatively simple.
	* score/src/threadevaluatemode.c: Removed.
2010-06-24 22:40:32 +00:00
Joel Sherrill
8bef4ccfb0 2010-06-24 Gedare Bloom <giddyup44@yahoo.com>
PR 1590/cpukit
	* score/Makefile.am, score/include/rtems/score/thread.h,
	score/src/threadtickletimeslice.c: Remove _Thread_Reset_timeslice and
	replaces its single use with a call to the functionally equivalent
	_Thread_Yield_processor().
	* score/src/threadresettimeslice.c: Removed.
2010-06-24 21:27:30 +00:00
Ralf Corsepius
3fb8e9782f Remove LIBITRON. 2010-06-17 15:29:44 +00:00
Thomas Doerfler
b7de5ded7e User extension API: add const to some params, inline _User_extensions_Add_API_set 2010-01-26 15:01:56 +00:00
Thomas Doerfler
9224a751b1 Changed base implementation of protected heap allocations to use _Heap_Allocate_aligned_with_boundary(). 2009-11-30 13:06:21 +00:00
Ralf Corsepius
e447c7d242 Whitespace removal. 2009-11-28 06:15:55 +00:00
Joel Sherrill
081c475fe3 2009-09-25 Joel Sherrill <joel.sherrill@OARcorp.com>
* score/Makefile.am: Re-add file accidentally deleted by Sebastian.
2009-09-25 18:30:11 +00:00
Joel Sherrill
c42d1a459b 2009-09-25 Sebastian Huber <Sebastian.Huber@embedded-brains.de>
* sapi/include/rtems/extension.h, sapi/src/extensiondelete.c,
	sapi/src/extensionident.c, sapi/src/extensioncreate.c,
	sapi/inline/rtems/extension.inl, score/include/rtems/score/userext.h,
	score/src/userextthreaddelete.c, score/src/userext.c,
	score/src/userextthreadcreate.c, score/src/userextremoveset.c,
	score/src/userextthreadbegin.c, score/src/userextaddset.c,
	score/src/userextthreadstart.c, score/src/userextthreadswitch.c,
	score/src/userextthreadrestart.c: Documentation. The types
	User_extensions_routine and rtems_extension are now deprecated.
	Removed unused types User_extensions_thread_post_switch_extension and
	rtems_task_post_switch_extension. Renamed _User_extensions_Add_API_set()
	in _User_extensions_Add_set(). Renamed _User_extensions_Add_set() in
	_User_extensions_Add_set_with_table().
	* score/src/userextaddapiset.c: Removed file.
	* score/Makefile.am: Update.
2009-09-25 17:51:46 +00:00
Joel Sherrill
0881ed02fd 2009-09-14 Sebastian Huber <Sebastian.Huber@embedded-brains.de>
* score/src/heapalignupuptr.c, score/src/heapallocatealigned.c:
	Removed files.
	* score/Makefile.am: Update.
2009-09-14 15:32:02 +00:00
Joel Sherrill
93f7ea15e5 2009-08-19 Joel Sherrill <joel.sherrill@OARcorp.com>
* sapi/include/confdefs.h, score/Makefile.am,
	score/include/rtems/score/thread.h: Only instantiate
	_Thread_Idle_body() if it is going ot be used.
	* score/src/threadidlebody.c: Removed.
2009-08-19 16:40:03 +00:00
Joel Sherrill
3390ba8832 2009-08-12 Joel Sherrill <joel.sherrill@OARcorp.com>
* libcsupport/Makefile.am, libcsupport/preinstall.am,
	posix/Makefile.am, posix/preinstall.am, rtems/Makefile.am,
	rtems/preinstall.am, score/Makefile.am, score/preinstall.am: Revert
	modifications accidentally committed.
2009-08-12 14:20:20 +00:00
Joel Sherrill
235aaf0c10 2009-08-09 Xi Yang <hiyangxi@gmail.com>
* libcsupport/Makefile.am, posix/Makefile.am, rtems/Makefile.am,
	sapi/Makefile.am, score/Makefile.am,
	score/include/rtems/score/heap.h: HEAP_BLOCK_USED_OVERHEAD was under
	by one uint32_t. This showed up in the unlimited and heapwalk tests
	on ARM targets.
2009-08-09 15:23:10 +00:00
Joel Sherrill
684e243dd0 Revert. 2009-08-06 20:39:27 +00:00
Joel Sherrill
88157a76de 2009-08-05 Joel Sherrill <joel.sherrill@OARcorp.com>
* libcsupport/Makefile.am, rtems/Makefile.am, rtems/preinstall.am,
	sapi/Makefile.am, sapi/preinstall.am, score/Makefile.am,
	score/preinstall.am, score/include/rtems/score/heap.h,
	score/inline/rtems/score/heap.inl: Remove inline version now that it
	is in a C file.
	* libcsupport/src/end_profile.c: New file.
2009-08-05 21:18:29 +00:00
Joel Sherrill
e6faab6503 2009-08-05 Joel Sherrill <joel.sherrill@OARcorp.com>
* score/Makefile.am: Move from inline to body to avoid path explosion
	from inlining this. Makes coverage analysis easier.
	* score/src/heapalignupuptr.c: New file.
2009-08-05 21:16:49 +00:00
Joel Sherrill
0df035b6e5 2009-07-26 Joel Sherrill <joel.sherrill@oarcorp.com>
* score/Makefile.am, score/preinstall.am: SuperCore Spinlock is only
	used by POSIX API. Do not build it when POSIX is not enabled.
2009-07-27 00:00:53 +00:00
Thomas Doerfler
915bb51b90 make thread dispatching in ISRs generic code 2009-07-17 09:08:22 +00:00
Joel Sherrill
7246c8e997 2009-03-02 Joel Sherrill <joel.sherrill@oarcorp.com>
* libcsupport/src/malloc_initialize.c, score/Makefile.am,
	score/include/rtems/score/protectedheap.h,
	score/inline/rtems/score/heap.inl: Get total heap size correct when
	using unified C Program Heap and RTEMS Workspace.
	* score/src/pheapgetsize.c: New file.
2009-03-02 18:10:34 +00:00
Joel Sherrill
584ab9e16e 2008-12-18 Joel Sherrill <joel.sherrill@oarcorp.com>
* rtems/include/rtems/rtems/regionmp.h, sapi/include/rtems/config.h,
	sapi/src/exinit.c, score/Makefile.am,
	score/include/rtems/score/object.h,
	score/include/rtems/score/objectmp.h, score/src/objectmp.c: Eliminate
	Object Handler Initialization routine since it was all for MP
	configurations.
	* score/src/object.c: Removed.
2008-12-18 17:15:13 +00:00
Joel Sherrill
26fb4aadcd 2008-12-16 Joel Sherrill <joel.sherrill@oarcorp.com>
* libblock/src/bdbuf.c, libmisc/capture/capture-cli.c,
	libmisc/capture/capture.c, libmisc/mw-fb/mw_uid.c,
	rtems/include/rtems/rtems/support.h, score/Makefile.am,
	score/include/rtems/score/tod.h, score/src/coretod.c,
	score/src/coretodtickle.c: Eliminate all public use of TOD conversion
	routines. Eliminate _TOD_Microseconds_per_tick and let every place
	use the field directly from the Configuration Table. This required
	moving some methods from macros to bodies.
	* score/src/coretodmsecstoticks.c, score/src/coretodtickspersec.c,
	score/src/coretodusectoticks.c: New files.
2008-12-16 20:53:34 +00:00
Joel Sherrill
e57cb3c9df 2008-12-09 Joel Sherrill <joel.sherrill@oarcorp.com>
* score/Makefile.am, score/preinstall.am,
	score/include/rtems/score/timespec.h,
	score/include/rtems/score/timestamp.h: Add 64-bit implementation of
	SuperCore Timestamps. Tested on PowerPC/psim and SPARC/sis.
	* score/include/rtems/score/timestamp64.h, score/src/ts64addto.c,
	score/src/ts64divide.c, score/src/ts64dividebyinteger.c,
	score/src/ts64equalto.c, score/src/ts64getnanoseconds.c,
	score/src/ts64getseconds.c, score/src/ts64greaterthan.c,
	score/src/ts64lessthan.c, score/src/ts64set.c,
	score/src/ts64settozero.c, score/src/ts64subtract.c,
	score/src/ts64toticks.c, score/src/ts64totimespec.c: New files.
2008-12-09 21:27:35 +00:00
Joel Sherrill
c16bcc009b 2008-12-08 Joel Sherrill <joel.sherrill@oarcorp.com>
* libcsupport/src/__times.c, libmisc/cpuuse/cpuusagereport.c,
	libmisc/cpuuse/cpuusagereset.c, posix/src/clockgettime.c,
	posix/src/pthread.c, posix/src/timersettime.c,
	rtems/include/rtems/rtems/ratemon.h,
	rtems/src/clockgetsecondssinceepoch.c, rtems/src/clockgetuptime.c,
	rtems/src/ratemongetstatus.c, rtems/src/ratemonperiod.c,
	rtems/src/ratemonreportstatistics.c, rtems/src/taskwakewhen.c,
	rtems/src/timerfirewhen.c, rtems/src/timerserver.c,
	rtems/src/timerserverfirewhen.c, score/Makefile.am,
	score/preinstall.am, score/include/rtems/score/thread.h,
	score/include/rtems/score/tod.h, score/src/coretod.c,
	score/src/coretodget.c, score/src/coretodgetuptime.c,
	score/src/coretodset.c, score/src/coretodtickle.c,
	score/src/threaddispatch.c, score/src/threadinitialize.c: Add
	SuperCore handler Timestamp to provide an opaque class for the
	representation and manipulation of uptime, time of day, and the
	difference between two timestamps. By using SuperCore Timestamp, it
	is clear which methods and APIs really have to be struct timespec and
	which can be in an optimized native format.
	* score/include/rtems/score/timestamp.h,
	score/src/coretodgetuptimetimespec.c: New files.
2008-12-08 19:41:31 +00:00
Joel Sherrill
109ace3a1f 2008-12-03 Joel Sherrill <joel.sherrill@OARcorp.com>
PR 1347/cpukit
	* rtems/include/rtems/rtems/timer.h, rtems/src/rtemstimer.c,
	rtems/src/timerreset.c, rtems/src/timerserver.c,
	rtems/src/timerserverfireafter.c, rtems/src/timerserverfirewhen.c,
	score/Makefile.am, score/include/rtems/score/watchdog.h: Rework Timer
	Server to ensure that the context allows for blocking, allocating
	memory, and acquiring semaphores and mutexes.
	* score/src/watchdogadjusttochain.c: New file.
2008-12-03 20:58:29 +00:00
Joel Sherrill
c8f7b4e6ca 2008-11-26 Joel Sherrill <joel.sherrill@oarcorp.com>
* score/Makefile.am, score/include/rtems/score/watchdog.h: Add
	_Watchdog_Report and _Watchdog_Report_chain as debug assist routines.
	They are NOT to be used in directives.
	* score/src/watchdogreport.c, score/src/watchdogreportchain.c:
	New files.
2008-11-26 16:38:06 +00:00
Joel Sherrill
9184270ac4 2008-02-06 Joel Sherrill <joel.sherrill@oarcorp.com>
* posix/src/mqueueunlink.c, score/Makefile.am,
	score/include/rtems/score/object.h,
	score/inline/rtems/score/object.inl: Enhance
	_Objects_Namespace_remove() to handle freeing object names which are
	strings. All changed _Objects_Close() to call
	_Objects_Namespace_remove(). The resulting code was then moved from
	inline routines to function calls.
	* score/src/objectclose.c, score/src/objectnamespaceremove.c: New files.
2008-02-06 23:54:55 +00:00
Joel Sherrill
c57f26bd07 2008-01-30 Joel Sherrill <joel.sherrill@OARcorp.com>
* score/Makefile.am, score/include/rtems/score/threadq.h,
	score/inline/rtems/score/threadq.inl: _Thread_queue_Process_timeout
	was really too complex to be inlined.
	* score/src/threadqprocesstimeout.c: New file.
2008-01-30 14:56:57 +00:00
Joel Sherrill
6c06288f64 2008-01-29 Joel Sherrill <joel.sherrill@oarcorp.com>
* itron/src/exd_tsk.c, itron/src/task.c, libmisc/capture/capture.c,
	libmisc/monitor/mon-config.c, libmisc/monitor/mon-driver.c,
	libmisc/monitor/mon-itask.c, libmisc/monitor/mon-monitor.c,
	libmisc/monitor/mon-mpci.c, libmisc/monitor/mon-object.c,
	libmisc/monitor/mon-symbols.c, posix/src/cancelrun.c,
	posix/src/pthreadexit.c, rtems/Makefile.am, rtems/preinstall.am,
	rtems/include/rtems.h, rtems/include/rtems/rtems/support.h,
	rtems/inline/rtems/rtems/tasks.inl, rtems/src/eventmp.c,
	rtems/src/msgmp.c, rtems/src/partmp.c, rtems/src/regionmp.c,
	rtems/src/rtemsobjectgetname.c, rtems/src/semmp.c,
	rtems/src/signalmp.c, rtems/src/taskdelete.c, rtems/src/taskmp.c,
	rtems/src/timerserver.c, score/Makefile.am,
	score/include/rtems/score/object.h,
	score/inline/rtems/score/object.inl, score/src/Unlimited.txt,
	score/src/objectgetnameasstring.c,
	score/src/threadqextractwithproxy.c: Add new Object Services
	collection. This changed the name of a few previously public but
	undocumented services and added a some new services.
	* rtems/include/rtems/rtems/object.h, rtems/src/rtemsbuildid.c,
	rtems/src/rtemsbuildname.c, rtems/src/rtemsobjectapimaximumclass.c,
	rtems/src/rtemsobjectapiminimumclass.c,
	rtems/src/rtemsobjectgetapiclassname.c,
	rtems/src/rtemsobjectgetapiname.c,
	rtems/src/rtemsobjectgetclassicname.c,
	rtems/src/rtemsobjectgetclassinfo.c,
	rtems/src/rtemsobjectidapimaximum.c,
	rtems/src/rtemsobjectidapiminimum.c, rtems/src/rtemsobjectidgetapi.c,
	rtems/src/rtemsobjectidgetclass.c, rtems/src/rtemsobjectidgetindex.c,
	rtems/src/rtemsobjectidgetnode.c, rtems/src/rtemsobjectsetname.c,
	score/src/objectapimaximumclass.c, score/src/objectgetinfo.c,
	score/src/objectgetinfoid.c, score/src/objectsetname.c: New files.
	* rtems/src/rtemsidtoname.c: Removed.
2008-01-29 21:52:21 +00:00
Joel Sherrill
ce19f1fa3b 2008-01-23 Joel Sherrill <joel.sherrill@oarcorp.com>
* itron/include/rtems/itron/object.h, itron/src/cre_tsk.c,
	libblock/src/show_bdbuf.c, libmisc/capture/capture-cli.c,
	libmisc/capture/capture.c, libmisc/monitor/mon-manager.c,
	libmisc/stackchk/check.c, posix/src/condinit.c,
	posix/src/keycreate.c, posix/src/mqueuecreatesupp.c,
	posix/src/mqueuedeletesupp.c, posix/src/mqueuenametoid.c,
	posix/src/mqueueopen.c, posix/src/mqueueunlink.c,
	posix/src/mutexinit.c, posix/src/pbarrierinit.c,
	posix/src/prwlockinit.c, posix/src/pspininit.c,
	posix/src/pthreadcreate.c, posix/src/pthreadexit.c,
	posix/src/semaphorecreatesupp.c, posix/src/semaphorenametoid.c,
	posix/src/timercreate.c, rtems/src/barrierident.c,
	rtems/src/dpmemident.c, rtems/src/msgqident.c, rtems/src/partident.c,
	rtems/src/ratemonident.c, rtems/src/regionident.c,
	rtems/src/semident.c, rtems/src/taskident.c, rtems/src/timerident.c,
	sapi/src/extensionident.c, score/Makefile.am,
	score/include/rtems/score/object.h,
	score/inline/rtems/score/object.inl, score/src/apimutexallocate.c,
	score/src/objectextendinformation.c,
	score/src/objectgetnameasstring.c, score/src/objectmp.c,
	score/src/objectnametoid.c: Convert the Objects_Name type from a
	simple type to a union of an unsigned 32 bit integer and a pointer.
	This should help eliminate weird casts between u32 and pointers in
	various places. The APIs now have to explicitly call _u32 or _string
	versions of helper routines. This should also simplify things and
	eliminate the need for ugly casts in some cases.
	* score/src/objectclearname.c, score/src/objectcomparenameraw.c,
	score/src/objectcomparenamestring.c, score/src/objectcopynameraw.c,
	score/src/objectcopynamestring.c: Removed.
2008-01-23 22:57:43 +00:00
Joel Sherrill
3168deaa10 2008-01-22 Joel Sherrill <joel.sherrill@oarcorp.com>
* rtems/include/rtems/rtems/event.h,
	rtems/inline/rtems/rtems/eventset.inl, rtems/src/event.c,
	rtems/src/eventseize.c, rtems/src/eventsurrender.c,
	rtems/src/eventtimeout.c, score/Makefile.am, score/preinstall.am,
	score/include/rtems/score/interr.h,
	score/include/rtems/score/thread.h,
	score/include/rtems/score/threadq.h,
	score/include/rtems/score/tqdata.h,
	score/inline/rtems/score/threadq.inl,
	score/inline/rtems/score/tqdata.inl, score/src/threadq.c,
	score/src/threadqdequeue.c, score/src/threadqdequeuefifo.c,
	score/src/threadqdequeuepriority.c, score/src/threadqenqueue.c,
	score/src/threadqenqueuefifo.c, score/src/threadqenqueuepriority.c,
	score/src/threadqextract.c, score/src/threadqextractfifo.c,
	score/src/threadqextractpriority.c,
	score/src/threadqextractwithproxy.c, score/src/threadqfirst.c,
	score/src/threadqfirstfifo.c, score/src/threadqfirstpriority.c,
	score/src/threadqflush.c, score/src/threadqrequeue.c,
	score/src/threadqtimeout.c: Refactor thread queue enqueue and event
	blocking synchronization critical sections. This resulted in three
	copies of essentially the same hard to test critical section code
	becoming the one shared routine _Thread_blocking_operation_Cancel. In
	addition, the thread queue and event code now share a common
	synchronization enumerated type. Along the way, switches were
	reworked to eliminate dead code generated by gcc and comments and
	copyrights were updated.
	* score/include/rtems/score/threadsync.h,
	score/src/threadblockingoperationcancel.c: New files.
2008-01-22 18:28:53 +00:00
Joel Sherrill
bc2b8df658 2008-01-08 Joel Sherrill <joel.sherrill@OARcorp.com>
* score/Makefile.am: Add missing file.
2008-01-08 17:33:00 +00:00
Chris Johns
1ff9922df0 2007-12-22 Chris Johns <chrisj@rtems.org>
* configure.ac: fixed bug that always enabled strict order
	mutexes.
	* score/inline/rtems/score/coremutex.inl: Fixed coding standard.
	* score/src/coremutex.c: Add the holder's thread to the lock_mutex
	list if the mutex is initialised locked.
	* libnetworking/rtems/rtems_glue.c: Changed semaphore error
	message to show the error is an rtems-net error.
	* libmisc/monitor/mon-network.c: Removed warnings.
	* telnetd/icmds.c: Changed shell_* to rtems_shell_*.
	* score/Makefile.am: Fixed typo that stopped 'make tags' working.
	* libmisc/shell/err.c, libmisc/shell/err.h, libmisc/shell/errx.c,
	libmisc/shell/extern-cp.h, libmisc/shell/fts.c,
	libmisc/shell/fts.h, libmisc/shell/main_cp.c,
	libmisc/shell/utils-cp.c, libmisc/shell/verr.c,
	libmisc/shell/verrx.c, libmisc/shell/vwarn.c,
	libmisc/shell/vwarnx.c, libmisc/shell/warn.c,
	libmisc/shell/warnx.c: New. Ported from BSD.
	* libmisc/shell/shellconfig.h: Add the cp command.
	* libmisc/Makefile.am: Add the new files to the shell.
	* libmisc/shell/shell.c, libmisc/shell/shell.h: Add scripting
	support.
	* libblock/src/flashdisk.c: Fixed disk drive count size setting
	bug.
2007-12-22 08:27:18 +00:00
Joel Sherrill
c933967b9d 2007-12-14 Joel Sherrill <joel.sherrill@OARcorp.com>
* score/Makefile.am: _Thread_Rotate_ready_queue is only used by ITRON
	API.
2007-12-14 19:18:34 +00:00
Joel Sherrill
bcf4cbb589 2007-12-13 Joel Sherrill <joel.sherrill@OARcorp.com>
* libcsupport/preinstall.am, posix/preinstall.am, rtems/Makefile.am,
	rtems/preinstall.am, sapi/Makefile.am, sapi/preinstall.am,
	score/Makefile.am, score/preinstall.am: Revert testing patch.
2007-12-13 17:00:38 +00:00
Joel Sherrill
8d8daef461 2007-12-13 Joel Sherrill <joel.sherrill@OARcorp.com>
* libcsupport/preinstall.am, posix/preinstall.am, posix/src/aio.c,
	posix/src/clockgetcpuclockid.c, posix/src/clockgetenableattr.c,
	posix/src/clockgettime.c, posix/src/clocksetenableattr.c,
	posix/src/clocksettime.c, posix/src/devctl.c,
	posix/src/pthreadcreate.c, posix/src/pthreadgetcpuclockid.c,
	posix/src/types.c, rtems/preinstall.am, sapi/Makefile.am,
	sapi/preinstall.am, score/Makefile.am, score/preinstall.am: Eliminate
	POSIX_NOT_IMPLEMENTED(). Return ENOSYS instead.
2007-12-13 15:45:43 +00:00
Joel Sherrill
55289c7d53 2007-12-12 Joel Sherrill <joel.sherrill@OARcorp.com>
* score/Makefile.am: Only used by ITRON so do not build if ITRON is
	disabled.
2007-12-12 14:22:08 +00:00
Joel Sherrill
8fd28d8302 2007-11-09 Joel Sherrill <joel.sherrill@OARcorp.com>
* sapi/src/exinit.c, score/Makefile.am,
	score/include/rtems/score/apimutex.h: API Mutex calls should never
	have been inlined. Inlining them lead to many inlined copies of core
	mutex lock. This lead to over 2K savings in the SPARC/ERC32
	minimum.exe.
	* score/src/apimutex.c, score/src/apimutexallocate.c,
	score/src/apimutexlock.c, score/src/apimutexunlock.c: New files.
2007-11-09 15:21:20 +00:00
Joel Sherrill
78dabb697c 2007-10-26 Joel Sherrill <joel.sherrill@OARcorp.com>
* score/Makefile.am, score/include/rtems/score/thread.h,
	score/inline/rtems/score/thread.inl: No longer inline _Thread_Get. It
	resulted in unnessary code explosion, many uncovered paths when
	looking at binary executable coverage, and only optimized getting
	self. Id translations were still getting pushed to a subroutine call
	to _Objects_Get. Later the non-inlined version can be further
	optimized to get Ids in range for the current API, then self, then
	look at other APIs.
	* score/src/threadget.c: New file.
2007-10-26 19:44:10 +00:00
Joel Sherrill
c3330a88ee 2007-05-17 Joel Sherrill <joel.sherrill@oarcorp.com>
* ChangeLog, configure.ac, libcsupport/src/__times.c,
	libmisc/cpuuse/cpuuse.c, libmisc/stackchk/check.c,
	rtems/include/rtems/rtems/ratemon.h, rtems/src/ratemongetstatus.c,
	rtems/src/ratemonperiod.c, rtems/src/ratemonreportstatistics.c,
	rtems/src/ratemonresetall.c, rtems/src/ratemontimeout.c,
	score/Makefile.am, score/include/rtems/score/thread.h,
	score/include/rtems/score/timespec.h, score/src/threaddispatch.c,
	score/src/threadinitialize.c, score/src/threadtickletimeslice.c,
	score/src/timespecdivide.c: Add nanoseconds granularity to the rate
	monotonic period statistics and CPU usage statistics. This capability
	is enabled by default although may be conditionally disabled by the
	user. It could be too much overhead on small targets but it does not
	appear to be bad in early testing. Its impact on code size has not
	been evaluated either. It is possible that both forms of statistics
	gathering could be disabled with further tweaking of the conditional
	compilation.
	* score/src/timespecdividebyinteger.c: New file.
2007-05-17 22:46:45 +00:00
Joel Sherrill
f919582d8f 2007-05-16 Joel Sherrill <joel.sherrill@oarcorp.com>
* score/Makefile.am, score/include/rtems/score/timespec.h: Add division
	and greater than operations for timespecs.
	* score/src/timespecdivide.c, score/src/timespecgreaterthan.c:
	New files.
2007-05-16 15:04:25 +00:00
Joel Sherrill
e1bce866cf 2007-05-15 Joel Sherrill <joel.sherrill@oarcorp.com>
* Makefile.am, preinstall.am, libmisc/Makefile.am, rtems/Makefile.am,
	rtems/include/rtems.h, rtems/include/rtems/rtems/ratemon.h,
	rtems/inline/rtems/rtems/ratemon.inl, rtems/src/ratemoncancel.c,
	rtems/src/ratemoncreate.c, rtems/src/ratemondelete.c,
	rtems/src/ratemongetstatus.c, rtems/src/ratemonident.c,
	rtems/src/ratemonperiod.c, rtems/src/ratemontimeout.c,
	score/Makefile.am, score/include/rtems/score/object.h,
	score/src/threadhandler.c, wrapup/Makefile.am: Integrate Rate
	Monotonic Statistics and Period Usage into Rate Monotonic Manager.
	Added the following directives: rtems_rate_monotonic_get_statistics,
	rtems_rate_monotonic_reset_statistics,
	rtems_rate_montonic_reset_all_statistics,
	rtems_rate_montonic_report_statistics, and rtems_object_get_name.
	Obsoleted the rtems/rtmonuse.h file as a public interface.
	* rtems/src/ratemongetstatistics.c,
	rtems/src/ratemonreportstatistics.c, rtems/src/ratemonresetall.c,
	rtems/src/ratemonresetstatistics.c, rtems/src/rtemsobjectgetname.c,
	score/src/objectgetnameasstring.c: New files.
	* libmisc/rtmonuse/rtmonuse.c, libmisc/rtmonuse/rtmonuse.h: Removed.
2007-05-15 20:16:16 +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
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
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