Changeset f22af606 in rtems


Ignore:
Timestamp:
Jun 19, 2015, 7:17:55 PM (4 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, master
Children:
f9090ac
Parents:
1cfe012
git-author:
Sebastian Huber <sebastian.huber@…> (06/19/15 19:17:55)
git-committer:
Sebastian Huber <sebastian.huber@…> (06/19/15 19:21:27)
Message:

sptests/sp37: Fix type and simplify

File:
1 edited

Legend:

Unmodified
Added
Removed
  • testsuites/sptests/sp37/init.c

    r1cfe012 rf22af606  
    334334void check_isr_in_progress_inline(void)
    335335{
    336   bool in_isr;
    337 
    338   in_isr = rtems_interrupt_is_in_progress();
    339   isr_in_progress_inline = ( in_isr ) ? 1 : 2;
     336  isr_in_progress_inline = rtems_interrupt_is_in_progress() ? 1 : 2;
    340337}
    341338
     
    354351)
    355352{
    356   bool in_isr;
    357 
    358353  check_isr_in_progress_inline();
    359354
    360   in_isr = rtems_interrupt_is_in_progress();
    361   isr_in_progress_body = ( in_isr ) ? 1 : 2;
     355  isr_in_progress_body = rtems_interrupt_is_in_progress() ? 1 : 2;
    362356}
    363357
     
    368362{
    369363  switch (result) {
    370     case -1:
     364    case 0:
    371365      printf( "isr_in_progress(%s) timer did not fire\n", s );
     366      rtems_test_exit(0);
    372367      break;
    373368    case 1:
    374369      printf( "isr_in_progress(%s) from ISR -- OK\n", s );
    375370      break;
    376     case 2:
     371    default:
    377372      printf( "isr_in_progress(%s) from ISR -- returned bad value\n", s);
    378373      rtems_test_exit(0);
     
    574569   * Test ISR in progress from actual ISR
    575570   */
    576   isr_in_progress_body   = -1;
    577   isr_in_progress_inline = -1;
    578 
    579571  status = rtems_timer_fire_after( timer, 10, test_isr_in_progress, NULL );
    580572  directive_failed( status, "timer_fire_after failed" );
    581573
    582   status = rtems_task_wake_after( 100 );
     574  status = rtems_task_wake_after( 11 );
    583575  directive_failed( status, "wake_after failed" );
    584576
    585   check_isr_worked( "inline", isr_in_progress_body );
     577  check_isr_worked( "inline", isr_in_progress_inline );
    586578
    587579  check_isr_worked( "body", isr_in_progress_body );
Note: See TracChangeset for help on using the changeset viewer.