Got it! thanks for your explanation!
On 01/19/2018 07:29 AM, QingFeng Hao wrote:
It ist similar to commit 0cb5b30698fd ("kvm: vmx: Scrub hardware GPRs at VM-exit").
在 2018/1/17 17:48, Martin Schwidefsky 写道:
Clear all user space registers on entry to the kernel and all KVM guestI am not sure if I understand this but it will be safer?
registers on KVM guest exit if the register does not contain either a
parameter or a result value.
The idea is to minimize potential payload channels.
nod, this makes sense!
And can we abstract the operations to be a macro like CLEAR_REG_7?No, please.
xgr %r7,%r7
is absolutely clear what it does, a MACRO often is not.