linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Gleixner <tglx@linutronix.de>
To: Heiner Kallweit <hkallweit1@gmail.com>
Cc: David Miller <davem@davemloft.net>,
	helgaas@kernel.org, jian-hong@endlessm.com, nic_swsd@realtek.com,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux@endlessm.com, linux-pci@vger.kernel.org,
	marc.zyngier@arm.com, hch@lst.de
Subject: Re: [PATCH] r8169: don't use MSI-X on RTL8106e
Date: Wed, 22 Aug 2018 13:44:44 +0200 (CEST)	[thread overview]
Message-ID: <alpine.DEB.2.21.1808221222260.2514@nanos.tec.linutronix.de> (raw)
In-Reply-To: <da97e198-7683-e0ff-92a9-3b1b22da3757@gmail.com>

On Tue, 21 Aug 2018, Heiner Kallweit wrote:
> On 21.08.2018 21:31, David Miller wrote:
> > From: Heiner Kallweit <hkallweit1@gmail.com>
> > Date: Mon, 20 Aug 2018 22:46:48 +0200
> > 
> >> I'm in contact with Realtek and according to them few chip versions
> >> seem to clear MSI-X table entries on resume from suspend. Checking
> >> with them how this could be fixed / worked around.
> >> Worst case we may have to disable MSI-X in general.
> > 
> > I worry that if the chip does this, and somehow MSI-X is enabled and
> > an interrupt is generated, the chip will write to the cleared out
> > MSI-X address.  This will either write garbage into memory or cause
> > a bus error and require PCI error recovery.
> > 
> > It also looks like your test patch doesn't fix things for people who
> > have tested it.
> > 
> The test patch was based on the first info from Realtek which made me
> think that the base address of the MSI-X table is cleared, what
> obviously is not the case.
> 
> After some further tests it seems that the solution isn't as simple
> as storing the MSI-X table entries on suspend and restore them on
> resume. On my system (where MSI-X works fine) MSI-X table entries
> on resume are partially different from the ones on suspend.

Which is not a surprise. Please don't try to fiddle with that at the driver
level. The irq and PCI core code are the ones in charge and if you'd
restore at the wrong point then hell breaks lose.

Can you please do the following:

 1) Store the PCI config space at suspend time
 2) Compare the PCI config space at resume time and print the difference

Do that on a working and a non-working version of Realtek NICs.

Thanks,

	tglx



  reply	other threads:[~2018-08-22 11:44 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-15  6:21 [PATCH] r8169: don't use MSI-X on RTL8106e jian-hong
2018-08-16 19:21 ` David Miller
2018-08-16 19:37   ` Heiner Kallweit
2018-08-16 19:39     ` David Miller
2018-08-16 19:50       ` Heiner Kallweit
2018-08-20 18:44         ` Bjorn Helgaas
2018-08-20 20:46           ` Heiner Kallweit
2018-08-21 19:31             ` David Miller
2018-08-21 20:48               ` Heiner Kallweit
2018-08-22 11:44                 ` Thomas Gleixner [this message]
2018-08-22 19:49                   ` Heiner Kallweit
2018-08-23 10:46                     ` Jian-Hong Pan
2018-08-23 13:38                       ` Bjorn Helgaas
2018-08-27 10:46                         ` Jian-Hong Pan
2018-08-21  8:28           ` Marc Zyngier
2018-08-21 20:54             ` Heiner Kallweit
2018-08-20 20:40         ` Florian Fainelli
2018-08-20 20:56           ` Heiner Kallweit
2018-08-17  5:07 ` [PATCH v2 net] " Jian-Hong Pan
2018-08-19 18:01   ` David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.DEB.2.21.1808221222260.2514@nanos.tec.linutronix.de \
    --to=tglx@linutronix.de \
    --cc=davem@davemloft.net \
    --cc=hch@lst.de \
    --cc=helgaas@kernel.org \
    --cc=hkallweit1@gmail.com \
    --cc=jian-hong@endlessm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=linux@endlessm.com \
    --cc=marc.zyngier@arm.com \
    --cc=netdev@vger.kernel.org \
    --cc=nic_swsd@realtek.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).