clock_[get|set]time timespec conversions

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

clock_[get|set]time timespec conversions

Brian Ford
It's late and I haven't had time to test this, but I thought it deserved a
look.  There appears to be some confusion (at least in my head) about the
units of gtod.resolution() and minperiod.

2006-02-10  Brian Ford  <[hidden email]>

        * times.cc (clock_gettime): Properly convert ms period to struct
        timespec.
        (clock_settime): Likewise reverse convert.

Let me know if I'm just crazy ;-).  Thanks.

--
Brian Ford
Lead Realtime Software Engineer
VITAL - Visual Simulation Systems
FlightSafety International
the best safety device in any aircraft is a well-trained pilot...

times.cc.patch (1K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: clock_[get|set]res timespec conversions

Brian Ford
I said it was late.  Oh, well.

Make that clock_[get|set]RES...

On Fri, 10 Feb 2006, Brian Ford wrote:

> It's late and I haven't had time to test this, but I thought it deserved a
> look.  There appears to be some confusion (at least in my head) about the
> units of gtod.resolution() and minperiod.
>
> 2006-02-10  Brian Ford  <[hidden email]>
>
> * times.cc (clock_getres): Properly convert ms period to struct
> timespec.
> (clock_setres): Likewise reverse convert.
>
> Let me know if I'm just crazy ;-).  Thanks.

--
Brian Ford
Lead Realtime Software Engineer
VITAL - Visual Simulation Systems
FlightSafety International
the best safety device in any aircraft is a well-trained pilot...
Reply | Threaded
Open this post in threaded view
|

Re: clock_[get|set]time timespec conversions

Christopher Faylor-2
In reply to this post by Brian Ford
On Fri, Feb 10, 2006 at 05:53:45PM -0600, Brian Ford wrote:
>2006-02-10  Brian Ford  <[hidden email]>
>
> * times.cc (clock_gettime): Properly convert ms period to struct
> timespec.
> (clock_settime): Likewise reverse convert.
>

Applied.  I changed the ChangeLog entery to be, IMO, slightly more
informative, however.

cgf
Reply | Threaded
Open this post in threaded view
|

Re: clock_[get|set]time timespec conversions

Christopher Faylor-2
On Fri, Feb 10, 2006 at 07:09:10PM -0500, Christopher Faylor wrote:

>On Fri, Feb 10, 2006 at 05:53:45PM -0600, Brian Ford wrote:
>>2006-02-10  Brian Ford  <[hidden email]>
>>
>> * times.cc (clock_gettime): Properly convert ms period to struct
>> timespec.
>> (clock_settime): Likewise reverse convert.
>>
>
>Applied.  I changed the ChangeLog entery to be, IMO, slightly more
>informative, however.

Oops.

Thanks for the patch.

cgf