Re: [PATCH v2 5/7] x86/mm, tracing: Fix CR2 corruption
From: Linus Torvalds
Date: Thu Jul 04 2019 - 22:19:19 EST
On Fri, Jul 5, 2019 at 5:03 AM Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:
>
> Despire the current efforts to read CR2 before tracing happens there
> still exist a number of possible holes:
So this whole series disturbs me for the simple reason that I thought
tracing was supposed to save/restore cr2 and make it unnecessary to
worry about this in non-tracing code.
That is very much what the NMI code explicitly does. Why shouldn't all
the other tracing code do the same thing in case they can take page
faults?
So I don't think the patches are wrong per se, but this seems to solve
it at the wrong level.
Linus