Subject: Re: [PATCH 06/17] sky2: advanced error reporting

From: Stephen Hemminger <[email-masked]>
Date: Wed, 9 May 2007 15:35:32 -0700

On Wed, 9 May 2007 12:05:51 -0500
[email-masked] (Linas Vepstas) wrote:

> On Tue, May 08, 2007 at 08:49:55PM -0700, Stephen Hemminger wrote:
> > Use the kernel interfaces for advanced error reporting.
> > This should be cleaner and clear up errors on boot.
> 
> Hmm. I thought that the AER functions would eventually 
> be handled by the struct pci_error_handlers callbacks,
> so that dev drivers wouldn't actually have code such as

No, it doesn't seem to work that way. Those callback seems to
be for bus reported errors, not device reported errors.

> > +		pci_read_config_dword(pdev, pos + PCI_ERR_UNCOR_STATUS, &status);
> > +		pci_read_config_dword(pdev, pos + PCI_ERR_UNCOR_SEVER, &mask);
> 
> in them. But perhaps I haven't studed what this drivr is trying to 
> do; nor have I really kept track of the aer code.
> 

On boot up it clears errors because power on seems to leave a bogus
error report.

When error is detected, it gets an IRQ and than has to decode it as PCI
error.

Earlier versions of the driver (pre AER) were doing the same thing but
with only minimal handling of errors. Now at least it uses common code.