[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CALCETrVd8i9xmGT9GPXU6tuvte+M9e3otYa8YNLEgPE+W81E2w@mail.gmail.com>
Date: Thu, 21 Mar 2019 11:28:50 -0700
From: Andy Lutomirski <luto@...nel.org>
To: Peter Zijlstra <peterz@...radead.org>
Cc: Steven Rostedt <rostedt@...dmis.org>,
Juergen Gross <jgross@...e.com>,
LKML <linux-kernel@...r.kernel.org>,
"H. Peter Anvin" <hpa@...or.com>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...nel.org>, Borislav Petkov <bp@...en8.de>,
Joel Fernandes <joel@...lfernandes.org>,
He Zhe <zhe.he@...driver.com>,
Linus Torvalds <torvalds@...ux-foundation.org>
Subject: Re: [RFC][PATCH] tracing/x86: Save CR2 before tracing irqsoff on error_entry
On Thu, Mar 21, 2019 at 11:27 AM Peter Zijlstra <peterz@...radead.org> wrote:
>
> On Thu, Mar 21, 2019 at 11:05:06AM -0700, Andy Lutomirski wrote:
>
> > Ugh.
> >
> > I certainly agree in principle that sticking the CR2 read into the asm
> > is the right solution. But this patch makes the spaghetti even more
> > tangled. Maybe we can rearrange the code a bit so that the entry
> > sequence saves at least one register before calling error_entry, so we
> > can do it the obvious way.
>
> What is the obvious way? Note that with all the Xen/paravirt-me-harder
> bits on, we need to clobber at least RAX to get CR2.
>
> And most of the patch was munging the paravirt bits to make that happen.
>
> Another thing I did notices is that CLAC and CLD are not next to one
> another in these paths.
The thing I really don't like is all the EBX crud to try to get
everything in to the right order.
Powered by blists - more mailing lists