<html><body>
<p><tt>Linas Vepstas <linasvepstas@gmail.com> wrote on 07/24/2009 05:30:09 PM:<br>
<br>
> 2009/7/24 Richard Lary <rlary@us.ibm.com>:<br>
> > Linas Vepstas <linasvepstas@gmail.com> wrote on 07/23/2009 07:44:33 AM:<br>
> ><br>
> >> 2009/7/15 Mike Mason <mmlnx@us.ibm.com>:<br>
> >> > By default, EEH does what's known as a "hot reset" during error recovery<br>
> >> > of<br>
> >> > a PCI Express device. We've found a case where the device needs a<br>
> >> > "fundamental reset" to recover properly. The current PCI error recovery<br>
> >> > and<br>
> >> > EEH frameworks do not support this distinction.<br>
> >> ><br>
> >> > The attached patch (courtesy of Richard Lary) adds a bit field to<br>
> >> > pci_dev<br>
> >> > that indicates whether the device requires a fundamental reset during<br>
> >> > error<br>
> >> > recovery. This bit can be checked by EEH to determine which reset type<br>
> >> > is<br>
> >> > required.<br>
> >> ><br>
> >> > This patch supersedes the previously submitted patch that implemented a<br>
> >> > reset type callback.<br>
> >> ><br>
> >> > Please review and let me know of any concerns.<br>
> >><br>
> >> I like this patch a *lot* better .. it is vastly simpler, more direct.<br>
> >><br>
> >><br>
> >> > diff -uNrp a/include/linux/pci.h b/include/linux/pci.h<br>
> >> > --- a/include/linux/pci.h 2009-07-13 14:25:37.000000000 -0700<br>
> >> > +++ b/include/linux/pci.h 2009-07-15 10:25:37.000000000 -0700<br>
> >> > @@ -273,6 +273,7 @@ struct pci_dev {<br>
> >> > unsigned int ari_enabled:1; /* ARI forwarding */<br>
> >> > unsigned int is_managed:1;<br>
> >> > unsigned int is_pcie:1;<br>
> >> > + unsigned int fndmntl_rst_rqd:1; /* Dev requires fundamental<br>
> >> > reset<br>
> >> > */<br>
> >> > unsigned int state_saved:1;<br>
> >> > unsigned int is_physfn:1;<br>
> >> > unsigned int is_virtfn:1;<br>
> >><br>
> >> As Ben points out, the name is awkward. How about needs_freset ?<br>
> ><br>
> > I am OK with name change.<br>
> ><br>
> ><br>
> >> Since this affects the entire pci subsystem, it should be documented<br>
> >> properly. The "pci error recovery" subsystem was designed to be<br>
> >> usable in other architectures, and so the error recovery docs should<br>
> >> take at least a paragraph to describe what this flag means, and when<br>
> >> its supposed to be used.<br>
> ><br>
> > I will update the documentation, are you referring to<br>
> > Documentation/powerpc/eeh-pci-error-recovery.txt<br>
> > or some other documentation?<br>
> <br>
> No, I'm thinking<br>
> Documentation/PCI/pci-error-recovery.txt<br>
> <br>
> because the flag is not powerpc-specific.<br>
</tt><br>
<tt>Got it, glad I asked...</tt><br>
<br>
<tt>-rich</tt><br>
<tt><br>
> ><br>
> >> Providing the docs patch together with the pci.h patch *only* would<br>
> >> probably simplify acceptance by the PCI community.<br>
> >><br>
> >> --linas<br>
> ><br>
</tt></body></html>