2009-12-18 14:43:44     IVTMR bit set in ILAT on "go" command execution

Document created by Aaronwu Employee on Sep 25, 2013
Version 1Show Document
  • View in full screen mode

2009-12-18 14:43:44     IVTMR bit set in ILAT on "go" command execution

Doug Bailey (UNITED STATES)

Message: 83712   

 

I am using u-boot (1.1.6) to boot a BF527 that loads an application via bootp

and uses the go command to pass execution the application.

 

When this application initializes itself, it throws an unexpected exception

which locks up the application.  Upon further review, the interrpt is being

thrown from the core timer.

 

I notice that before execution is passed from u-boot, the ILAT register has a

value of 0x40 i.e the Core Timer interrupt is ready to fire.  I notice that

interrupts.c has a timer_init function which enables the timer but does not

appear to be used in the u-boot code.

 

If I remove the code doing the TCNTL setup, ILAT stays at value 0 and my

application runs.

 

What am I losing by not initializing the Core Timer?

 

What would be a better approach to prevent the ILAT bit from causing the

interrupt to fire off?

 

 

 

Thanks,

 

Doug Bailey

QuoteReplyEditDelete

 

 

2009-12-18 15:49:55     Re: IVTMR bit set in ILAT on "go" command execution

Mike Frysinger (UNITED STATES)

Message: 83715   

 

u-boot uses the core timer for delays and timeouts.  if you disable it, dont expect the other pieces to work either.

 

if you dont want the timer interrupt firing, then dont enable that bit when enabling interrupts.  IVG6 is dedicated to the timer, so enabling it without using the core timer is pointless.

QuoteReplyEditDelete

 

 

2009-12-18 16:15:08     Re: IVTMR bit set in ILAT on "go" command execution

Doug Bailey (UNITED STATES)

Message: 83716   

 

More than likely, it is a problem in the application (RTEMS).  During the process of turning on their timer interrupts, the code does not take into account that the ILAT bit may already be active.  I guess I need to dig into their code base to see what is going on when they enable their core timer. 

QuoteReplyEditDelete

 

 

2009-12-18 16:30:31     Re: IVTMR bit set in ILAT on "go" command execution

Mike Frysinger (UNITED STATES)

Message: 83717   

 

an OS shouldnt enable any interrupts until it is fully ready to process them.  this is how linux works ... it initializes all vectors/states before enabling interrupts.

Attachments

    Outcomes