From f23d4706169d68d3c4e90b297650f89c272716f4 Mon Sep 17 00:00:00 2001 From: Gedare Bloom Date: Thu, 9 Jun 2016 11:33:15 -0400 Subject: cpukit: Add and use Watchdog_Discipline. Clock disciplines may be WATCHDOG_RELATIVE, WATCHDOG_ABSOLUTE, or WATCHDOG_NO_TIMEOUT. A discipline of WATCHDOG_RELATIVE with a timeout of WATCHDOG_NO_TIMEOUT is equivalent to a discipline of WATCHDOG_NO_TIMEOUT. updates #2732 --- cpukit/rtems/src/semobtain.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'cpukit/rtems/src/semobtain.c') diff --git a/cpukit/rtems/src/semobtain.c b/cpukit/rtems/src/semobtain.c index 0e5330af41..9afef54917 100644 --- a/cpukit/rtems/src/semobtain.c +++ b/cpukit/rtems/src/semobtain.c @@ -69,13 +69,14 @@ rtems_status_code rtems_semaphore_obtain( executing = _Thread_Executing; wait = !_Options_Is_no_wait( option_set ); + _Thread_queue_Context_set_relative_timeout( &queue_context, timeout ); + switch ( the_semaphore->variant ) { case SEMAPHORE_VARIANT_MUTEX_INHERIT_PRIORITY: status = _CORE_recursive_mutex_Seize( &the_semaphore->Core_control.Mutex.Recursive, executing, wait, - timeout, _CORE_recursive_mutex_Seize_nested, &queue_context ); @@ -85,7 +86,6 @@ rtems_status_code rtems_semaphore_obtain( &the_semaphore->Core_control.Mutex, executing, wait, - timeout, _CORE_recursive_mutex_Seize_nested, &queue_context ); @@ -96,7 +96,6 @@ rtems_status_code rtems_semaphore_obtain( _Semaphore_Get_operations( the_semaphore ), executing, wait, - timeout, _CORE_recursive_mutex_Seize_nested, &queue_context ); @@ -107,7 +106,6 @@ rtems_status_code rtems_semaphore_obtain( &the_semaphore->Core_control.MRSP, executing, wait, - timeout, &queue_context ); break; @@ -122,7 +120,6 @@ rtems_status_code rtems_semaphore_obtain( _Semaphore_Get_operations( the_semaphore ), executing, wait, - timeout, &queue_context ); break; -- cgit v1.2.3