MPC5200 RTC

bennett78 bennett78 at digis.net
Wed Dec 14 05:10:35 EST 2005


 *  The /dev/rtc interface will block on reads until an interrupt
 *  has been received. If a RTC interrupt has already happened,
 *  it will output an unsigned long and then block.

Paul Gortmaker's  rtctest (included below) works really well on my x86
machine  (driver/char/rtc.c) as a nice way for a user process to wait on 
ticks
of a programable frequency (via ioctl).

Under Denx linuxppc_2_4_devel MPC5200 I've tried:
    driver/char/rtc.c - kernel panics
       seems to need a RTC_IRQ to be defined
       include/linux/mc14681rtc.h mentions #define RTC_IRQ 8 ?
    CONFIG_PPC_RTC also panics
    driver/char/genrtc.c (with #define CONFIG_GEN_RTC_X)
       sort of works but I get the following:
       gen_rtc_interrupt: system delaying clock ticks?

The internal MPC5200 RTC doesn't seem supported.
I see a lot of references to external RTCs, probably because
the standby power for the 5200 is high. I would like to
use a timer as the RTC interrupt and add an external RTC
later as a time reference (none on Lite5200 dev brd).
How best can I assign a GPTx as an interrupt? other than re-write
genrtc.c?

thanks,
Frank Bennett




*//*

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://ozlabs.org/pipermail/linuxppc-embedded/attachments/20051213/4c1afe6e/attachment.htm 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rtctest.c
Type: text/x-c
Size: 4562 bytes
Desc: not available
Url : http://ozlabs.org/pipermail/linuxppc-embedded/attachments/20051213/4c1afe6e/attachment.bin 


More information about the Linuxppc-embedded mailing list