[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190530103536.GA56046@lakrids.cambridge.arm.com>
Date: Thu, 30 May 2019 11:35:36 +0100
From: Mark Rutland <mark.rutland@....com>
To: Peter Zijlstra <peterz@...radead.org>
Cc: Will Deacon <will.deacon@....com>,
Young Xiao <92siuyang@...il.com>, linux@...linux.org.uk,
mingo@...hat.com, bp@...en8.de, hpa@...or.com, x86@...nel.org,
kan.liang@...ux.intel.com, linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org, ravi.bangoria@...ux.vnet.ibm.com,
mpe@...erman.id.au, acme@...hat.com, eranian@...gle.com,
fweisbec@...il.com, jolsa@...hat.com
Subject: Re: [PATCH] perf: Fix oops when kthread execs user process
On Wed, May 29, 2019 at 07:03:13PM +0200, Peter Zijlstra wrote:
> On Wed, May 29, 2019 at 05:38:54PM +0100, Mark Rutland wrote:
> > Generally speaking though, if we ever task task_pt_regs() of an idle
> > task we'll get junk, and user_mode() could be true.
>
> Agreed, but we're not doing that.
Sure.
I just think that might be an argument for having task_pt_regs() return
NULL for kthreads, or having a WARN_ON_ONCE(t->flags & PF_KTHREAD) to
catch missing checks elsewhere.
Thanks,
Mark.
Powered by blists - more mailing lists