[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y7P7UKpmE8/LsmOn@unreal>
Date: Tue, 3 Jan 2023 11:54:24 +0200
From: Leon Romanovsky <leon@...nel.org>
To: Paul Menzel <pmenzel@...gen.mpg.de>
Cc: Rajat Khandelwal <rajat.khandelwal@...ux.intel.com>,
intel-wired-lan@...ts.osuosl.org, rajat.khandelwal@...el.com,
jesse.brandeburg@...el.com, linux-kernel@...r.kernel.org,
edumazet@...gle.com, anthony.l.nguyen@...el.com,
netdev@...r.kernel.org, kuba@...nel.org, pabeni@...hat.com,
davem@...emloft.net, Bjorn Helgaas <bhelgaas@...gle.com>,
linux-pci@...r.kernel.org
Subject: Re: [Intel-wired-lan] [PATCH] igc: Mask replay rollover/timeout
errors in I225_LMVP
On Sun, Jan 01, 2023 at 11:34:21AM +0100, Paul Menzel wrote:
> [Cc: +Bjorn, +linux-pci]
>
> Dear Leon, dear Rajat,
>
>
> Am 01.01.23 um 09:32 schrieb Leon Romanovsky:
> > On Thu, Dec 29, 2022 at 05:56:40PM +0530, Rajat Khandelwal wrote:
> > > The CPU logs get flooded with replay rollover/timeout AER errors in
> > > the system with i225_lmvp connected, usually inside thunderbolt devices.
> > >
> > > One of the prominent TBT4 docks we use is HP G4 Hook2, which incorporates
> > > an Intel Foxville chipset, which uses the igc driver.
> > > On connecting ethernet, CPU logs get inundated with these errors. The point
> > > is we shouldn't be spamming the logs with such correctible errors as it
> > > confuses other kernel developers less familiar with PCI errors, support
> > > staff, and users who happen to look at the logs.
> > >
> > > Signed-off-by: Rajat Khandelwal <rajat.khandelwal@...ux.intel.com>
> > > ---
> > > drivers/net/ethernet/intel/igc/igc_main.c | 28 +++++++++++++++++++++--
> > > 1 file changed, 26 insertions(+), 2 deletions(-)
> > >
> > > diff --git a/drivers/net/ethernet/intel/igc/igc_main.c b/drivers/net/ethernet/intel/igc/igc_main.c
> > > index ebff0e04045d..a3a6e8086c8d 100644
> > > --- a/drivers/net/ethernet/intel/igc/igc_main.c
> > > +++ b/drivers/net/ethernet/intel/igc/igc_main.c
> > > @@ -6201,6 +6201,26 @@ u32 igc_rd32(struct igc_hw *hw, u32 reg)
> > > return value;
> > > }
> > > +#ifdef CONFIG_PCIEAER
> > > +static void igc_mask_aer_replay_correctible(struct igc_adapter *adapter)
> > > +{
> > > + struct pci_dev *pdev = adapter->pdev;
> > > + u32 aer_pos, corr_mask;
> > > +
> > > + if (pdev->device != IGC_DEV_ID_I225_LMVP)
> > > + return;
> > > +
> > > + aer_pos = pci_find_ext_capability(pdev, PCI_EXT_CAP_ID_ERR);
> > > + if (!aer_pos)
> > > + return;
> > > +
> > > + pci_read_config_dword(pdev, aer_pos + PCI_ERR_COR_MASK, &corr_mask);
> > > +
> > > + corr_mask |= PCI_ERR_COR_REP_ROLL | PCI_ERR_COR_REP_TIMER;
> > > + pci_write_config_dword(pdev, aer_pos + PCI_ERR_COR_MASK, corr_mask);
> >
> > Shouldn't this igc_mask_aer_replay_correctible function be implemented
> > in drivers/pci/quirks.c and not in igc_probe()?
>
> Probably. Though I think, the PCI quirk file, is getting too big.
As long as that file is right location, we should use it.
One can refactor quirk file later.
Thanks
>
>
> Kind regards,
>
> Paul
Powered by blists - more mailing lists