Quoting Dimitry Andric <d...@freebsd.org> (from Sun, 12 Jul 2020 15:36:25 +0200):

On 12 Jul 2020, at 11:51, Alexander Leidinger <netch...@freebsd.org> wrote:

Author: netchild
Date: Sun Jul 12 09:51:09 2020
New Revision: 363125
URL: https://svnweb.freebsd.org/changeset/base/363125

Log:
 Implement CLOCK_MONOTONIC_RAW (linux >= 2.6.28).

 It is documented as a raw hardware-based clock not subject to NTP or
 incremental adjustments. With this "not as precise as CLOCK_MONOTONIC"
 description in mind, map it to our CLOCK_MONOTNIC_FAST (the same
 mapping as for the linux CLOCK_MONOTONIC_COARSE).

Okay, but:

@@ -212,6 +212,7 @@ linux_to_native_clockid(clockid_t *n, clockid_t l)
                *n = CLOCK_THREAD_CPUTIME_ID;
                break;
        case LINUX_CLOCK_REALTIME_COARSE:
+       case LINUX_CLOCK_MONOTONIC_RAW:
                *n = CLOCK_REALTIME_FAST;
                break;
        case LINUX_CLOCK_MONOTONIC_COARSE:

this shows it is actually mapped to CLOCK_REALTIME_FAST, not
CLOCK_MONOTONIC_FAST. Is the code right, or the commit message? :)

The commit message and the code I have running are right, the code I committed from a "no other change than that"-svn-tree was not. :(
I think I should switch to "diff | patch" even for one-liners like that.

I commited the fix based upon another message I've seen before this one, but thanks for looking at the code.

Bye,
Alexander.

--
http://www.Leidinger.net alexan...@leidinger.net: PGP 0x8F31830F9F2772BF
http://www.FreeBSD.org    netch...@freebsd.org  : PGP 0x8F31830F9F2772BF

Attachment: pgpWt6J1gVLa9.pgp
Description: Digitale PGP-Signatur

Reply via email to