+23
−16
+6
−11
Loading
Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more
The version field in struct pvclock_vcpu_time_info basically implements
a seqcount. Wrap it with the usual read_begin and read_retry functions,
and use these APIs instead of peppering the code with smp_rmb()s.
While at it, change it to the more pedantically correct virt_rmb().
With this change, __pvclock_read_cycles can be simplified noticeably.
Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>