Re: [PATCH] x86: sgx: Don't track poisoned pages for reclaiming

From: Dave Hansen
Date: Tue Feb 11 2025 - 18:32:03 EST


On 2/11/25 13:18, Huang, Kai wrote:
>>> This requires low-level SGX implementation knowledge to fully
>>> understand. Both what "ETRACK, EBLOCK and EWB" are in the first place,
>>> how they are involved in reclaim and also why EREMOVE doesn't lead to
>>> the same fate.
>>
>> Does it? [I'll dig up Intel SDM to check this]
>>
> I just did. 🙂
>
> It seems EREMOVE only reads and updates the EPCM entry for the target
> EPC page but won't actually access that EPC page.

Actually, now that I think about it even more, why would ETRACK or
EBLOCK access the page itself? They seem superficially like they'd be
metadata-only too.