[PATCH V4] powerpc/85xx: Add machine check handler to fix PCIe erratum on mpc85xx
Scott Wood
scottwood at freescale.com
Sat Mar 16 03:34:52 EST 2013
On 03/14/2013 09:47:58 PM, Jia Hongtao-B38951 wrote:
>
> > -----Original Message-----
> > From: Wood Scott-B07421
> > Sent: Thursday, March 14, 2013 12:38 AM
> > To: David Laight
> > Cc: Jia Hongtao-B38951; Wood Scott-B07421;
> linuxppc-dev at lists.ozlabs.org;
> > Stuart Yoder
> > Subject: Re: [PATCH V4] powerpc/85xx: Add machine check handler to
> fix
> > PCIe erratum on mpc85xx
> >
> > On 03/13/2013 04:40:40 AM, David Laight wrote:
> > > > Hmm, seems there's no probe_user_address() -- for userspace we
> > > > basically want the same thing minus the KERNEL_DS. See
> > > > arch/powerpc/perf/callchain.c for an example.
> > >
> > > Isn't that just copy_from_user() ?
> >
> > Plus pagefault_disable/enable().
> >
> > -Scott
>
> pagefault_disable() is identical to preempt_disable(). So I think this
> could not avoid other cpu to swap out the instruction we want to read
> back.
> probe_kernel_address() also have the same issue.
That's not the point -- the point is to let the page fault handler know
that it should go directly to bad_page_fault(). Do not pass
handle_mm_fault(). Do not collect a page from disk.
Granted, we're already in atomic context which will have that effect
due to being in the machine check handler, but it's better to be
explicit about it and not depend on how pagefault_diasble() is
implemented.
-Scott
More information about the Linuxppc-dev
mailing list