[Bug 2180] New: _TOD_Get_with_nanoseconds() is broken on SMP

Joel Sherrill joel.sherrill at oarcorp.com
Thu Aug 21 20:49:06 UTC 2014


On 8/21/2014 3:47 PM, Chris Johns wrote:
> On 21/08/2014 11:51 pm, Gedare Bloom wrote:
>> On Thu, Aug 21, 2014 at 3:03 AM, Sebastian Huber
>> <sebastian.huber at embedded-brains.de> wrote:
>>> On 20/08/14 16:05, Joel Sherrill wrote:
>>> The clock handling is entirely broken on SMP and not scalable.  Our clock
>>> infrastructure is only good enough for uni-processor systems, but even here
>>> the usage of nanosecond timestamps is suboptimal.  I would rather use
>>> something like the FreeBSD time hands:
>>>
>>> http://phk.freebsd.dk/pubs/timecounter.pdf
>>>
>> Nice.  It looks like it would take:
>> 1) Convert the 64-bit timestamps into bintime: a split time_t
>> 'seconds' + uint64_t 'frac' format. The math is shown in the paper.
>> 2) A lock-free ring buffer for the timehands.
>> 3) The timecounter structure that describes the hw clock source, and a
>> way to register timecounters from BSPs.
>> 4) Rewrite tick handling to do the refresh operation.
>>
>> Did I miss anything?
>>
> If we implement this it would be nice to get NTP working cleanly with 
> RTEMS. The RSB is now building NTP.
PHK has bounced some email with myself, Harlan Stenn, and Chris. He may
be willing to help review.
> Chris
> _______________________________________________
> devel mailing list
> devel at rtems.org
> http://lists.rtems.org/mailman/listinfo/devel

-- 
Joel Sherrill, Ph.D.             Director of Research & Development
joel.sherrill at OARcorp.com        On-Line Applications Research
Ask me about RTEMS: a free RTOS  Huntsville AL 35805
Support Available                (256) 722-9985



More information about the devel mailing list