smptests: Use priority ceiling for locked print

In case the printf() blocks on a semaphore it was possible to end up in
a livelock.
This commit is contained in:
Sebastian Huber
2013-05-31 13:56:56 +02:00
parent e071c18322
commit ac2bb464a5
2 changed files with 3 additions and 2 deletions

View File

@@ -78,7 +78,7 @@ rtems_task Init(
sprintf(ch, "%02" PRId32, i );
status = rtems_task_create(
rtems_build_name( 'T', 'A', ch[0], ch[1] ),
1,
2,
RTEMS_MINIMUM_STACK_SIZE,
RTEMS_DEFAULT_MODES,
RTEMS_DEFAULT_ATTRIBUTES,

View File

@@ -36,7 +36,8 @@ void locked_print_initialize(void)
rtems_build_name ('S', 'E', 'M', '1'),
1,
RTEMS_LOCAL |
RTEMS_SIMPLE_BINARY_SEMAPHORE |
RTEMS_BINARY_SEMAPHORE |
RTEMS_PRIORITY_CEILING |
RTEMS_PRIORITY,
1,
&locked_print_semaphore