Re: [PATCH] KVM: SVM: Update dump_ghcb() to use the GHCB snapshot fields

From: Tom Lendacky
Date: Fri May 02 2025 - 17:56:27 EST


On 5/2/25 16:50, Sean Christopherson wrote:
> On Mon, 28 Apr 2025 13:55:31 -0500, Tom Lendacky wrote:
>> Commit 4e15a0ddc3ff ("KVM: SEV: snapshot the GHCB before accessing it")
>> updated the SEV code to take a snapshot of the GHCB before using it. But
>> the dump_ghcb() function wasn't updated to use the snapshot locations.
>> This results in incorrect output from dump_ghcb() for the "is_valid" and
>> "valid_bitmap" fields.
>>
>> Update dump_ghcb() to use the proper locations.
>>
>> [...]
>
> Applied to kvm-x86 fixes.
>
> Tom, I tried to find a middle ground between capturing the "snapshot" behavior
> and not making it seem like the reported GPA is the GPA of the snapshot. Holler
> if you don't like the end result.

No hollerin' here. Looks good, Sean.

Thanks,
Tom

>
> [1/1] KVM: SVM: Update dump_ghcb() to use the GHCB snapshot fields
> https://github.com/kvm-x86/linux/commit/5fea0c6c0ebe
>
> --
> https://github.com/kvm-x86/linux/tree/next