[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CALCETrXOTPwU75uBTfUYD+vLeUSP1sAaoS1UrJwQyji9ZugHVw@mail.gmail.com>
Date: Thu, 14 Apr 2016 12:29:53 -0700
From: Andy Lutomirski <luto@...capital.net>
To: Dmitry Safonov <dsafonov@...tuozzo.com>
Cc: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>,
"H. Peter Anvin" <hpa@...or.com>, X86 ML <x86@...nel.org>,
Robert Richter <rric@...nel.org>, oprofile-list@...ts.sf.net,
Dmitry Safonov <0x7f454c46@...il.com>
Subject: Re: [PATCH 4/4] x86/oprofile: down with test_thread_flag(TIF_IA32)
On Thu, Apr 14, 2016 at 11:10 AM, Dmitry Safonov <dsafonov@...tuozzo.com> wrote:
> As we have here full register set - just use user_64bit_mode
> on it.
>
> Signed-off-by: Dmitry Safonov <dsafonov@...tuozzo.com>
> ---
> arch/x86/oprofile/backtrace.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/x86/oprofile/backtrace.c b/arch/x86/oprofile/backtrace.c
> index cb31a4440e58..405dadaee74a 100644
> --- a/arch/x86/oprofile/backtrace.c
> +++ b/arch/x86/oprofile/backtrace.c
> @@ -69,7 +69,7 @@ x86_backtrace_32(struct pt_regs * const regs, unsigned int depth)
> struct stack_frame_ia32 *head;
>
> /* User process is IA32 */
> - if (!current || !test_thread_flag(TIF_IA32))
> + if (!current || user_64bit_mode(regs))
This is presumably okay, but I know nothing about oprofile.
> return 0;
>
> head = (struct stack_frame_ia32 *) regs->bp;
> --
> 2.8.0
>
--
Andy Lutomirski
AMA Capital Management, LLC
Powered by blists - more mailing lists