[okl4-developer] rtc: using return value in device_interrupt to hide hw interrupts

Geoffrey Lee glee at ok-labs.com
Fri Nov 21 15:34:56 EST 2008


On Thu, Nov 20, 2008 at 08:06:55AM -0800, Gabi Voiculescu wrote:
> Hello.
> 
> My goal is to simulate a 64bit rtc timer instead of the hardware available 32bit one.
> 
> I just want to verify I understood correctly the interaction between vrtc server and a rtc driver in OKL4 2.1.
> 
> First, I want to be sure that the RTC timer counts time in seconds (not microseconds)!  
> 
> Second, I want to make sure I got the return values from device_interrupt_impl right to correctly hide HW interrupts from threads:
> 

Gabi - that rtc functionality has been disabled because we used it for 
something specific - my understanding is the alarm implementation
is incomplete and hence it was disabled.

	-gl


> 
> As I understand it, in vrtc_server.c, vrtc_async_handler(L4_Word_t notify) if device_interrupt returns with:
>  non zero, alarm_callback() will notify whatever thread has set the alarm using L4_notify, zero, the thread that set the alarm won't be notified, in essence hiding the hardware interrupt from the thread that commanded the alarm.
> So, to a thread that has set an alarm and now waits for it  to be set:
> returning zero hides the hardware interrupt
> returning non zero shows the hardware interrupt
> The reason I ask is that in pxa250_rtc driver, the driver's device_interrupt_impl always returns 0, in essence hiding any hw alarms from other threads, which looks weird and might explain why I see alarm stuff being commented out in the iguana "driver_example".
> 
> Thank you,
> Gabi Voiculescu
> 
> 
> 
> 
> 
>       
> _______________________________________________
> Developer mailing list
> Developer at okl4.org
> https://lists.okl4.org/mailman/listinfo/developer


-- 




More information about the Developer mailing list