Re: [PATCH 2/2] rtems: Add more clock tick functions

2014-08-24 Thread Sebastian Huber
On 24/08/14 11:42, Pavel Pisa wrote: Hello Sebastian, On Sunday 24 of August 2014 10:54:15 Sebastian Huber wrote: On 08/22/2014 10:14 PM, Pavel Pisa wrote: +RTEMS_INLINE_ROUTINE bool rtems_clock_ticks_before( + rtems_interval ticks +) +{ + return ( (int32_t) ticks - (int32_t) _Watchdog_Tic

Re: [PATCH 2/2] rtems: Add more clock tick functions

2014-08-24 Thread Joel Sherrill
On August 24, 2014 7:28:32 AM EDT, Chris Johns wrote: >On 24/08/2014 6:57 pm, Sebastian Huber wrote: >> On 08/24/2014 05:02 AM, Chris Johns wrote: >>> >>> The calls names make sense from a programming point of view but from >a >>> user point of view they are sort of forwards and backwards. For >

Re: [PATCH 2/2] rtems: Add more clock tick functions

2014-08-24 Thread Chris Johns
On 24/08/2014 6:57 pm, Sebastian Huber wrote: On 08/24/2014 05:02 AM, Chris Johns wrote: The calls names make sense from a programming point of view but from a user point of view they are sort of forwards and backwards. For example rtems_clock_ticks_later_us is the "the clock tick so many micro

Re: [PATCH 2/2] rtems: Add more clock tick functions

2014-08-24 Thread Pavel Pisa
Hello Sebastian, On Sunday 24 of August 2014 10:54:15 Sebastian Huber wrote: > On 08/22/2014 10:14 PM, Pavel Pisa wrote: > >>> +RTEMS_INLINE_ROUTINE bool rtems_clock_ticks_before( > >>> > >>> > >+ rtems_interval ticks > >>> > >+) > >>> > >+{ > >>> > >+ return ( (int32_t) ticks - (int32_t) _Watch

Re: [PATCH 2/2] rtems: Add more clock tick functions

2014-08-24 Thread Sebastian Huber
On 08/24/2014 05:02 AM, Chris Johns wrote: On 23/08/2014 1:12 am, Sebastian Huber wrote: Add rtems_clock_ticks_later(), rtems_clock_ticks_later_us() and rtems_clock_ticks_later_us(). FIXME: Patch is incomplete. Documentation and tests are missing. Just for API review. --- cpukit/rtems/inclu

Re: [PATCH 2/2] rtems: Add more clock tick functions

2014-08-24 Thread Sebastian Huber
On 08/22/2014 10:14 PM, Pavel Pisa wrote: +RTEMS_INLINE_ROUTINE bool rtems_clock_ticks_before( > >+ rtems_interval ticks > >+) > >+{ > >+ return ( (int32_t) ticks - (int32_t) _Watchdog_Ticks_since_boot ) > 0; > >Why not just return _Watchdog_Ticks_since_boot < ticks; Yes, this doesn't work i

Re: [PATCH 2/2] rtems: Add more clock tick functions

2014-08-23 Thread Chris Johns
On 23/08/2014 1:12 am, Sebastian Huber wrote: Add rtems_clock_ticks_later(), rtems_clock_ticks_later_us() and rtems_clock_ticks_later_us(). FIXME: Patch is incomplete. Documentation and tests are missing. Just for API review. --- cpukit/rtems/include/rtems/rtems/clock.h | 66

Re: [PATCH 2/2] rtems: Add more clock tick functions

2014-08-22 Thread Pavel Pisa
On Friday 22 of August 2014 17:24:41 Gedare Bloom wrote: > On Fri, Aug 22, 2014 at 11:12 AM, Sebastian Huber > > wrote: > > Add rtems_clock_ticks_later(), rtems_clock_ticks_later_us() and > > rtems_clock_ticks_later_us(). > > > > FIXME: Patch is incomplete. Documentation and tests are missing. J

Re: [PATCH 2/2] rtems: Add more clock tick functions

2014-08-22 Thread Gedare Bloom
On Fri, Aug 22, 2014 at 11:12 AM, Sebastian Huber wrote: > Add rtems_clock_ticks_later(), rtems_clock_ticks_later_us() and > rtems_clock_ticks_later_us(). > > FIXME: Patch is incomplete. Documentation and tests are missing. Just > for API review. > --- > cpukit/rtems/include/rtems/rtems/clock.h

Re: [PATCH 2/2] rtems: Add more clock tick functions

2014-08-22 Thread Gedare Bloom
These also would go into the clockimpl.h On Fri, Aug 22, 2014 at 11:12 AM, Sebastian Huber wrote: > Add rtems_clock_ticks_later(), rtems_clock_ticks_later_us() and > rtems_clock_ticks_later_us(). > > FIXME: Patch is incomplete. Documentation and tests are missing. Just > for API review. > --- >

[PATCH 2/2] rtems: Add more clock tick functions

2014-08-22 Thread Sebastian Huber
Add rtems_clock_ticks_later(), rtems_clock_ticks_later_us() and rtems_clock_ticks_later_us(). FIXME: Patch is incomplete. Documentation and tests are missing. Just for API review. --- cpukit/rtems/include/rtems/rtems/clock.h | 66 1 file changed, 66 insertions(+