Re: [PATCH 1/2] x86/efi: Unmap efi boot services code/data regions from efi_pgd

From: Dave Hansen
Date: Mon Oct 22 2018 - 10:12:29 EST


On 10/21/2018 06:57 PM, Ingo Molnar wrote:
> Does the CPU _ever_ look look at the PFN if the page is !_PAGE_PRESENT,
> for example speculatively? If yes then what is the recommended value for
> the pfn - zero perhaps?

I'll never say never. :)

For L1TF[1], we know the CPU did exactly this; it ignored the
_PAGE_PRESENT bit when fetching data from the L1. That's what is worked
around with the gunk in arch/x86/include/asm/pgtable-invert.h.

I think Andi plugged the code in here at a low enough level in the page
table manipulation that pageattr.c should inherit it without doing
anything explicit. But, Sai, you might want to double-check this.

1.
https://www.intel.com/content/www/us/en/architecture-and-technology/l1tf.html