mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2025-12-27 15:00:16 +00:00
2009-04-20 Santosh G Vattam <vattam.santosh@gmail.com>
* sp37/init.c, sp37/sp37.scn: Add test case for rtems_interrupt_level_attribute body.
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
2009-04-20 Santosh G Vattam <vattam.santosh@gmail.com>
|
||||
|
||||
* sp37/init.c, sp37/sp37.scn: Add test case for
|
||||
rtems_interrupt_level_attribute body.
|
||||
|
||||
2009-04-03 Ralf Corsépius <ralf.corsepius@rtems.org>
|
||||
|
||||
* sp01/Makefile.am, sp02/Makefile.am, sp03/Makefile.am,
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
void test_interrupt_inline(void)
|
||||
{
|
||||
rtems_interrupt_level level;
|
||||
rtems_attribute level_attribute, level_attribute_macro;
|
||||
bool in_isr;
|
||||
|
||||
puts( "interrupt is in progress (use body)" );
|
||||
@@ -36,6 +37,13 @@ void test_interrupt_inline(void)
|
||||
|
||||
puts( "interrupt enable (use inline)" );
|
||||
rtems_interrupt_enable( level );
|
||||
|
||||
puts( "interrupt level attribute (use inline)" );
|
||||
level_attribute = rtems_interrupt_level_attribute( level );
|
||||
level_attribute_macro = RTEMS_INTERRUPT_LEVEL(level);
|
||||
if ( level_attribute_macro == level_attribute ) {
|
||||
puts( "test case working.." );
|
||||
}
|
||||
}
|
||||
|
||||
volatile int isr_in_progress_body;
|
||||
@@ -147,6 +155,7 @@ rtems_task Init(
|
||||
rtems_time_of_day time;
|
||||
rtems_status_code status;
|
||||
rtems_interrupt_level level;
|
||||
rtems_attribute level_attribute,level_attribute_macro;
|
||||
bool in_isr;
|
||||
rtems_id timer;
|
||||
int i;
|
||||
@@ -250,6 +259,13 @@ rtems_task Init(
|
||||
|
||||
puts( "interrupt enable (use body)" );
|
||||
rtems_interrupt_enable( level );
|
||||
|
||||
puts( "interrupt level attribute (use body)" );
|
||||
level_attribute = rtems_interrupt_level_attribute( level );
|
||||
level_attribute_macro = RTEMS_INTERRUPT_LEVEL(level);
|
||||
if ( level_attribute_macro == level_attribute ) {
|
||||
puts("test seems to work");
|
||||
}
|
||||
|
||||
/*
|
||||
* Test ISR in progress from actual ISR
|
||||
|
||||
@@ -6,11 +6,15 @@ interrupt is in progress (use body)
|
||||
interrupt disable (use inline)
|
||||
interrupt flash (use inline)
|
||||
interrupt enable (use inline)
|
||||
interrupt level attribute (use inline)
|
||||
test case working..
|
||||
interrupt is in progress (use body)
|
||||
interrupt disable (use body)
|
||||
interrupt disable (use body)
|
||||
interrupt flash (use body)
|
||||
interrupt enable (use body)
|
||||
interrupt level attribute (use body)
|
||||
test seems to work
|
||||
isr_in_progress(inline) from ISR -- OK
|
||||
isr_in_progress(body) from ISR -- OK
|
||||
*** END OF TEST 37 ***
|
||||
|
||||
Reference in New Issue
Block a user