linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: Sinan Kaya <okaya@codeaurora.org>
Cc: Paul Menzel <pmenzel+linux-pci@molgen.mpg.de>,
	Bjorn Helgaas <bhelgaas@google.com>,
	linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org,
	Lukas Wunner <lukas@wunner.de>,
	Eric Biederman <ebiederm@xmission.com>,
	Vivek Goyal <vgoyal@redhat.com>,
	kexec@lists.infradead.org
Subject: Re: pciehp 0000:00:1c.0:pcie004: Timeout on hotplug command 0x1038 (issued 65284 msec ago)
Date: Fri, 27 Apr 2018 16:12:55 -0500	[thread overview]
Message-ID: <20180427211255.GI8199@bhelgaas-glaptop.roam.corp.google.com> (raw)
In-Reply-To: <b62c2a8e-fe14-6d7d-147c-0ce3b0c0ab2f@codeaurora.org>

[+cc Eric, Vivek, kexec list]

On Fri, Apr 27, 2018 at 03:34:30PM -0400, Sinan Kaya wrote:
> On 4/27/2018 3:22 PM, Bjorn Helgaas wrote:
> > Sinan mooted the idea of using a "no-wait" path of sending the "don't
> > generate hotplug interrupts" command.  I think we should work on this
> > idea a little more.  If we're shutting down the whole system, I can't
> > believe there's much value in *anything* we do in the pciehp_remove()
> > path.
> > 
> > Maybe we should just get rid of pciehp_remove() (and probably
> > pcie_port_remove_service() and the other service driver remove methods)
> > completely.  That dates from when the service drivers could be modules that
> > could be potentially unloaded, but unloading them hasn't been possible for
> > years.
> 
> Shutdown path is also used for kexec. Leaving hotplug interrupts
> pending is dangerous for the newly loaded kernel as it leaves
> spurious interrupts during the new kernel boot.
> 
> I think we should always disable the hotplug interrupt on shutdown.
> We might think of not waiting for command-completion as a
> middle-ground or go to polling path instead of interrupts all the
> time.

Ah, I forgot about the kexec path.  The kexec path is used for
crashdump, too, so ideally the newly-loaded kernel would defend itself
when possible so it doesn't depend on the original kernel doing things
correctly.

Seems like this question of whether to do things in the original
kernel or the kexec-ed kernel comes up periodically, but I can never
remember a definitive answer.  My initial reaction is that it'd be
nice if we didn't have to do *any* shutdown in the original kernel,
but I'm sure there are reasons that's not practical.

I copied Eric (kexec maintainer) and Vivek (contact listed in
Documentation/kdump/kdump.txt) in case they have suggestions or would
consider some sort of Documentation/ update.

Bjorn

  reply	other threads:[~2018-04-27 21:12 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-26 10:17 Paul Menzel
2018-04-27 19:22 ` Bjorn Helgaas
2018-04-27 19:34   ` Sinan Kaya
2018-04-27 21:12     ` Bjorn Helgaas [this message]
2018-04-28  0:56       ` Dave Young
2018-04-28  1:18         ` Dave Young
2018-04-28 13:03           ` okaya
2018-04-30 20:48             ` Sinan Kaya
2018-04-30 21:17               ` Bjorn Helgaas
2018-04-30 21:27                 ` Sinan Kaya
2018-04-30 21:38                   ` Lukas Wunner
2018-05-01 12:38                   ` Sinan Kaya
2018-05-01 12:59                     ` Marc Zyngier
2018-05-01 13:25                       ` Bjorn Helgaas
2018-05-01 16:31                         ` Marc Zyngier
2018-05-01 22:32                           ` Eric W. Biederman
2018-05-03  8:49   ` Paul Menzel
2018-05-04  2:45     ` Bjorn Helgaas
2018-05-04  6:37       ` okaya
2018-05-04 13:33         ` Bjorn Helgaas
2018-05-04 14:24           ` okaya
2018-05-06  9:35           ` Paul Menzel
2018-05-07 21:33           ` Bjorn Helgaas
2018-05-08  6:59             ` Paul Menzel
2018-05-08 12:34               ` Bjorn Helgaas
2018-05-08 13:22                 ` Paul Menzel
2018-05-09 11:41   ` Lukas Wunner
2018-05-09 12:57     ` Bjorn Helgaas
2018-05-09 13:16       ` Lukas Wunner

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=20180427211255.GI8199@bhelgaas-glaptop.roam.corp.google.com \
    --to=helgaas@kernel.org \
    --cc=bhelgaas@google.com \
    --cc=ebiederm@xmission.com \
    --cc=kexec@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lukas@wunner.de \
    --cc=okaya@codeaurora.org \
    --cc=pmenzel+linux-pci@molgen.mpg.de \
    --cc=vgoyal@redhat.com \
    --subject='Re: pciehp 0000:00:1c.0:pcie004: Timeout on hotplug command 0x1038 (issued 65284 msec ago)' \
    /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

This is a public inbox, see mirroring instructions
on how to clone and mirror all data and code used for this inbox