Re: Smatch check for Spectre stuff
From: Dan Carpenter
Date: Wed Jun 13 2018 - 09:59:47 EST
On Wed, Jun 13, 2018 at 04:10:49PM +0300, Dan Carpenter wrote:
> Also it turns out that mem_section[] is declared in mm/sparse.c and
> Smatch is supposed to be able to figure out the size of it but
> apparently there is a bug... :( I'll take a look at that.
Oh. I have CONFIG_SPARSEMEM_EXTREME enabled so the size ends up
depending on cpu_feature_enabled(X86_FEATURE_LA57) which is tricky.
Meaning that I can detect that everything higher than 127 is masked off
but it doesn't help me since I don't know that the array has 128
elements.
regards,
dan carpenter