creating PCI-related sysfs entries
Linas Vepstas
linas at austin.ibm.com
Fri Feb 3 07:46:24 EST 2006
On Thu, Feb 02, 2006 at 12:39:02PM -0700, Grant Grundler was heard to remark:
>
> My guess is error handling/containment can abstract at the "bus" level
> since we can't always guarantee "one device per slot" (think
> multifunction devices).
:-) Yes, testing with multi-function cards exposed bugs, but the
code should work fine with them. In particular, the design allows
multi-function devices to "vote" how they want to be reset, with
the dumbest voter getting thier way.
The bus disconnect is reported to all functions on all affected
cards/slots. This allows all instances of a device driver to react
appropriately. However, for card setup/init, typically, you
want to have only one driver instance do that. You'll notice
in the sym53cxx2 patch I just sent, there's a
+ if (PCI_FUNC(pdev->devfn) == 0)
+ sym_reset_scsi_bus(np, 0);
so that the other instances don't fall over each other reseting.
There's similar code in the e100 e1000 and ixgb drivers; I tested
multi-function versions of these. (not sure about ixgb).
> Yes, I agree don't have a better idea other than what I already
> pointed out.
Hmm. well, I may have lost the thread of what that was.
--linas
More information about the Linuxppc64-dev
mailing list