forked from Imagelibrary/rtems
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:
@@ -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,
|
||||
|
||||
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user