diff options
| author | Andrea Parri <[email protected]> | 2020-01-09 16:06:49 +0000 |
|---|---|---|
| committer | Daniel Lezcano <[email protected]> | 2020-01-16 18:09:02 +0000 |
| commit | 0af3e137c144377fbaf5025ba784ff5ba7ad40c9 (patch) | |
| tree | e7061dcf97329e37ca4a45d5882a6582765da744 /include/clocksource/hyperv_timer.h | |
| parent | clocksource/drivers/timer-microchip-pit64b: Fix sparse warning (diff) | |
| download | kernel-0af3e137c144377fbaf5025ba784ff5ba7ad40c9.tar.gz kernel-0af3e137c144377fbaf5025ba784ff5ba7ad40c9.zip | |
clocksource/drivers/hyper-v: Untangle stimers and timesync from clocksources
hyperv_timer.c exports hyperv_cs, which is used by stimers and the
timesync mechanism. However, the clocksource dependency is not
needed: these mechanisms only depend on the partition reference
counter (which can be read via a MSR or via the TSC Reference Page).
Introduce the (function) pointer hv_read_reference_counter, as an
embodiment of the partition reference counter read, and export it
in place of the hyperv_cs pointer. The latter can be removed.
This should clarify that there's no relationship between Hyper-V
stimers & timesync and the Linux clocksource abstractions. No
functional or semantic change.
Suggested-by: Michael Kelley <[email protected]>
Signed-off-by: Andrea Parri <[email protected]>
Reviewed-by: Michael Kelley <[email protected]>
Signed-off-by: Daniel Lezcano <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'include/clocksource/hyperv_timer.h')
| -rw-r--r-- | include/clocksource/hyperv_timer.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/clocksource/hyperv_timer.h b/include/clocksource/hyperv_timer.h index 553e539469f0..34eef083c988 100644 --- a/include/clocksource/hyperv_timer.h +++ b/include/clocksource/hyperv_timer.h @@ -30,7 +30,7 @@ extern void hv_stimer_global_cleanup(void); extern void hv_stimer0_isr(void); #ifdef CONFIG_HYPERV_TIMER -extern struct clocksource *hyperv_cs; +extern u64 (*hv_read_reference_counter)(void); extern void hv_init_clocksource(void); extern struct ms_hyperv_tsc_page *hv_get_tsc_page(void); |
