Interrupts Disabled After First Context Switch

Kirspel, Kevin {Engineering - Osmetech CCD} kevin.kirspel at osmetech.com
Thu Jan 5 15:00:06 UTC 2006


Upon entering a task, the interrupts at the hardware level are enabled.
After a call to rtems_task_wake_after() the interrupts are disabled and
remain disabled while the task is running.  What part of the code should
I look at to diagnose this issue? It seems that interrupts get disabled
before the task switch is performed.

The code sample below illustrates what I am doing. At the first
printf(), the interrupts are enabled.  After the second printf(), the
interrupts are disabled.

rtems_task GUITask ( rtems_task_argument ignored )
{
  //Local Varaibles
  rtems_interrupt_level level;

  /* Wait 100ms til everyone is up and running */
  rtems_interrupt_disable(level);
  rtems_interrupt_enable(level);
  printf( "\r\nINT BEFORE: %08lX", level );
  rtems_task_wake_after( 10 );
  rtems_interrupt_disable(level);
  rtems_interrupt_enable(level);
  printf ( "\r\nINT AFTER: %08lX", level );
}

Kevin Kirspel
Osmetech 
235 Hembree Park Drive
Roswell GA, 30076
770-510-4444 x4568





More information about the users mailing list