Re: [PATCH] x86/tdx: Fix data leak in mmio_read()
From: Dave Hansen
Date: Mon Aug 26 2024 - 12:42:52 EST
On 8/26/24 05:53, Kirill A. Shutemov wrote:
> The mmio_read() function makes a TDVMCALL to retrieve MMIO data for an
> address from the VMM.
>
> Sean noticed that mmio_read() unintentionally exposes the value of an
> initialized variable on the stack to the VMM.
>
> Do not send the original value of *val to the VMM.
The key to this is that 'val' is only used for the _return_ value, right?