Re: [PATCH 2/6] Add a global synchronization point for pvclock

From: Jeremy Fitzhardinge
Date: Tue Apr 27 2010 - 14:00:46 EST


On 04/27/2010 06:28 AM, Marcelo Tosatti wrote:
>> + last = atomic64_read(&last_value);
>> + do {
>> + if (ret < last)
>> + return last;
>> + last = atomic64_cmpxchg(&last_value, last, ret);
>> + } while (unlikely(last != ret));
>>
> Wraparound?
>

If the units nanoseconds, it's good for ~500,000 years of uptime.

J

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/