This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

posix time functions


We discovered a (perhaps) un-documented feature in the eCos posix clock_settime and clock_gettime functions. Setting the time, changes the system clock (number of ticks). The system clock should only be changeable by the interrupt routine which is incrementing it. All other code should really only have read access. Is there a chance this could be changed? That is, if we fix it in the kernel, would that type of patch be accepted. I would think that setting the clock and possibly losing alarms would be something that other people have noticed before. For now we have implemented our own time off-set and never call settime and call our own gettime which adds our offset to the time that the OS is returning. But this seems like the hard way of doing it.

David Brennan

--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]