added correct use of _Thread_queue_Enter_critical_section

This commit is contained in:
Joel Sherrill
1995-12-08 21:06:15 +00:00
parent 7826883b16
commit 67d224af9e
12 changed files with 12 additions and 10 deletions

View File

@@ -350,6 +350,7 @@ int _POSIX_Condition_variables_Wait_support(
the_cond->Mutex = *mutex;
/* XXX .. enter critical section .. */
_Thread_queue_Enqueue( &the_cond->Wait_queue, 0 );
_Thread_Enable_dispatch();

View File

@@ -355,7 +355,7 @@ rtems_status_code rtems_region_get_segment(
executing->Wait.count = size;
executing->Wait.return_argument = (unsigned32 *) segment;
the_region->Wait_queue.sync = TRUE;
_Thread_queue_Enter_critical_section( &the_region->Wait_queue );
_Thread_queue_Enqueue( &the_region->Wait_queue, timeout );

View File

@@ -284,7 +284,7 @@ void _CORE_message_queue_Seize(
return;
}
the_message_queue->Wait_queue.sync = TRUE;
_Thread_queue_Enter_critical_section( &the_message_queue->Wait_queue );
executing->Wait.queue = &the_message_queue->Wait_queue;
executing->Wait.id = id;
executing->Wait.return_argument = (void *)buffer;

View File

@@ -139,7 +139,7 @@ void _CORE_mutex_Seize(
return;
}
the_mutex->Wait_queue.sync = TRUE;
_Thread_queue_Enter_critical_section( &the_mutex->Wait_queue );
executing->Wait.queue = &the_mutex->Wait_queue;
executing->Wait.id = id;
_ISR_Enable( level );

View File

@@ -146,7 +146,7 @@ void _CORE_semaphore_Seize(
return;
}
the_semaphore->Wait_queue.sync = TRUE;
_Thread_queue_Enter_critical_section( &the_semaphore->Wait_queue );
executing->Wait.queue = &the_semaphore->Wait_queue;
executing->Wait.id = id;
_ISR_Enable( level );

View File

@@ -195,7 +195,7 @@ unsigned32 _MPCI_Send_request_packet (
(*_MPCI_table->send_packet)( destination, the_packet );
_MPCI_Remote_blocked_threads.sync = TRUE;
_Thread_queue_Enter_critical_section( &_MPCI_Remote_blocked_threads );
/*
* See if we need a default timeout

View File

@@ -350,6 +350,7 @@ int _POSIX_Condition_variables_Wait_support(
the_cond->Mutex = *mutex;
/* XXX .. enter critical section .. */
_Thread_queue_Enqueue( &the_cond->Wait_queue, 0 );
_Thread_Enable_dispatch();

View File

@@ -355,7 +355,7 @@ rtems_status_code rtems_region_get_segment(
executing->Wait.count = size;
executing->Wait.return_argument = (unsigned32 *) segment;
the_region->Wait_queue.sync = TRUE;
_Thread_queue_Enter_critical_section( &the_region->Wait_queue );
_Thread_queue_Enqueue( &the_region->Wait_queue, timeout );

View File

@@ -284,7 +284,7 @@ void _CORE_message_queue_Seize(
return;
}
the_message_queue->Wait_queue.sync = TRUE;
_Thread_queue_Enter_critical_section( &the_message_queue->Wait_queue );
executing->Wait.queue = &the_message_queue->Wait_queue;
executing->Wait.id = id;
executing->Wait.return_argument = (void *)buffer;

View File

@@ -139,7 +139,7 @@ void _CORE_mutex_Seize(
return;
}
the_mutex->Wait_queue.sync = TRUE;
_Thread_queue_Enter_critical_section( &the_mutex->Wait_queue );
executing->Wait.queue = &the_mutex->Wait_queue;
executing->Wait.id = id;
_ISR_Enable( level );

View File

@@ -146,7 +146,7 @@ void _CORE_semaphore_Seize(
return;
}
the_semaphore->Wait_queue.sync = TRUE;
_Thread_queue_Enter_critical_section( &the_semaphore->Wait_queue );
executing->Wait.queue = &the_semaphore->Wait_queue;
executing->Wait.id = id;
_ISR_Enable( level );

View File

@@ -195,7 +195,7 @@ unsigned32 _MPCI_Send_request_packet (
(*_MPCI_table->send_packet)( destination, the_packet );
_MPCI_Remote_blocked_threads.sync = TRUE;
_Thread_queue_Enter_critical_section( &_MPCI_Remote_blocked_threads );
/*
* See if we need a default timeout