summaryrefslogtreecommitdiffstats
path: root/testsuites/sptests
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2016-05-17 14:54:48 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2016-05-20 07:49:40 +0200
commit5eac967651866b0501593dcfea458452ef9e9128 (patch)
tree318c199360e7f6eef5f78412e4c6b037aba7ea6f /testsuites/sptests
parentsptests/spintrcritical22: Avoid _Objects_Get() (diff)
downloadrtems-5eac967651866b0501593dcfea458452ef9e9128.tar.bz2
testsuites: Replace _Thread_Get()
Replace _Thread_Get() with _Thread_Get_interrupt_disable() to avoid the Giant lock. Update #2555.
Diffstat (limited to 'testsuites/sptests')
-rw-r--r--testsuites/sptests/spintrcritical23/init.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/testsuites/sptests/spintrcritical23/init.c b/testsuites/sptests/spintrcritical23/init.c
index 89fea25a12..4857d99585 100644
--- a/testsuites/sptests/spintrcritical23/init.c
+++ b/testsuites/sptests/spintrcritical23/init.c
@@ -42,13 +42,12 @@ static test_context ctx_instance;
static Thread_Control *get_tcb(rtems_id id)
{
- Objects_Locations location;
+ ISR_lock_Context lock_context;
Thread_Control *tcb;
- tcb = _Thread_Get(id, &location);
- _Objects_Put(&tcb->Object);
-
- rtems_test_assert(tcb != NULL && location == OBJECTS_LOCAL);
+ tcb = _Thread_Get_interrupt_disable(id, &lock_context);
+ rtems_test_assert(tcb != NULL);
+ _ISR_lock_ISR_enable(&lock_context);
return tcb;
}