Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1702318
| From | Paolo Bonzini <pbonzini@redhat.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v4 01/10] timekeeper: introduce extended clocksource reading callback |
| Date | 2017-08-02 19:30 +0200 |
| Message-ID | <ua5D5-4rG-27@gated-at.bofh.it> (permalink) |
| References | <ua3hT-2KU-5@gated-at.bofh.it> <ua3hT-2KU-15@gated-at.bofh.it> <ua5to-4lS-13@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 02/08/2017 19:08, John Stultz wrote: >> + bool (*read_with_stamp)(struct clocksource *cs, >> + u64 *cycles, u64 *cycles_stamp); >> u64 mask; > I'm not really fan of an interface that leaks magic data to users that > know enough. > > And its not clear from this if the magic data is standardized or > different clocksources export different data? > > What exactly are the attributes you're trying to pull from the > lower-level hardware that you can't get otherwise (without using the > update_pvclock_gtod() since, if I'm understanding that apparently > gives you too much detail to deal with)? We need the exact TSC value that was used to compute the ktime. This is different between TSC and kvmclock because TSC's read() callback returns cycles (of course), while kvmclock's read() callback returns nanoseconds. In turn, kvmclock's read() callback returns nanoseconds because it has to check the read against the host-provided seqlock, so this cannot be changed. Paolo
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH v4 01/10] timekeeper: introduce extended clocksource reading callback Denis Plotnikov <dplotnikov@virtuozzo.com> - 2017-08-02 17:00 +0200
Re: [PATCH v4 01/10] timekeeper: introduce extended clocksource reading callback John Stultz <john.stultz@linaro.org> - 2017-08-02 19:20 +0200
Re: [PATCH v4 01/10] timekeeper: introduce extended clocksource reading callback Paolo Bonzini <pbonzini@redhat.com> - 2017-08-02 19:30 +0200
csiph-web