Hi all,
This patch series picks up the LPT pvtime feature originally developed
by Steven Price: https://patchwork.kernel.org/cover/10726499/
Backgroud:
There is demand for cross-platform migration, which means we have to
solve different CPU features and arch counter frequency between hosts.
This patch series can solve the latter problem.
About LPT:
This implements support for Live Physical Time (LPT) which provides the
guest with a method to derive a stable counter of time during which the
guest is executing even when the guest is being migrated between hosts
with different physical counter frequencies.
Changes on Steven Price's work:
1. LPT structure: use symmatical semantics of scale multiplier, and use
fraction bits instead of "shift" to make everything clear.
2. Structure allocation: host kernel does not allocates the LPT structure,
instead it is allocated by userspace through VM attributes. The save/restore
functionality can be removed.
3. Since LPT structure just need update once for each guest run, add a flag to
indicate the update status. This has two benifits: 1) avoid multiple update
by each vCPUs. 2) If the update flag is not set, then return NOT SUPPORT for
coressponding guest HVC call.
4. Add VM device attributes interface for userspace configuration.
5. Add a base LPT read/write layer to reduce code.
6. Support ptimer scaling.
7. Support timer event stream translation.
Things need concern:
1. https://developer.arm.com/docs/den0057/a needs update.