All of lore.kernel.org
 help / color / mirror / Atom feed
From: Huacai Chen <chenhuacai@gmail.com>
To: Sinan Kaya <okaya@kernel.org>
Cc: Bjorn Helgaas <bhelgaas@google.com>,
	linux-pci <linux-pci@vger.kernel.org>,
	Jiaxun Yang <jiaxun.yang@flygoat.com>,
	Tiezhu Yang <yangtiezhu@loongson.cn>
Subject: Re: [PATCH] PCI/portdrv: Don't disable pci device during shutdown
Date: Thu, 31 Dec 2020 14:15:17 +0800	[thread overview]
Message-ID: <CAAhV-H5SDrOUO-BdptM=e-VwOBrVQ+UtqxVx+qYNU2FO12w+SQ@mail.gmail.com> (raw)
In-Reply-To: <CAAhV-H6_BBe1MWJyuVrQNd7NyOarUtz1_YKrQJYxXs3Jby-bsw@mail.gmail.com>

Hi, Bjorn

On Tue, Sep 22, 2020 at 2:16 PM Huacai Chen <chenhuacai@gmail.com> wrote:
>
> Hi, Sinan,
>
> On Tue, Sep 22, 2020 at 10:11 AM Huacai Chen <chenhc@lemote.com> wrote:
> >
> > Hi, Sinan,
> >
> > On Mon, Sep 21, 2020 at 11:50 PM Sinan Kaya <okaya@kernel.org> wrote:
> > >
> > > On 9/21/2020 5:22 AM, Huacai Chen wrote:
> > > > Use separate remove()/shutdown() callback, and don't disable pci device
> > > > during shutdown. This can avoid some poweroff/reboot failures.
> > > >
> > > > The poweroff/reboot failures can easily reproduce on Loongson platforms.
> > > > I think this is not a Loongson-specific problem, instead, is a problem
> > > > related to some specific PCI hosts. On some x86 platforms, radeon/amdgpu
> > > > devices can cause the same problem, and commit faefba95c9e8ca3a523831c2e
> > > > ("drm/amdgpu: just suspend the hw on pci shutdown") can resolve it.
> > >
> > > This sounds like a quirk to me rather than a behavior that should be
> > > applied to all platforms.
> > Yes, this is very like a quirk, but it seems there are a lot of
> > platforms that have problems, and removing the pci_disable_device()
> > has no side effect.
> I have seen that you talk about kexec (but this email didn't go to my
> inbox). This has been discussed in another thread, and Lucas told us
> that in pci_device_shutdown the Bus Master is disabled for kexec. So I
> think there will be no memory corruption. Moreover, before 4.15 there
> is no .shutdown callback for portdrv, but kexec still works.
>
> Yes, the perfect way is to modify all problematic drivers, as
> radeon/amdgpu does. But I don't have enough knowledge about all of the
> devices.
>
> Huacai
Any new comments?

Huacai
> >
> > Huacai

      reply	other threads:[~2020-12-31  6:16 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-21  9:22 [PATCH] PCI/portdrv: Don't disable pci device during shutdown Huacai Chen
2020-09-21 15:50 ` Sinan Kaya
2020-09-22  2:11   ` Huacai Chen
2020-09-22  4:30     ` Sinan Kaya
2020-09-22  6:20       ` Tiezhu Yang
2020-09-22  6:16     ` Huacai Chen
2020-12-31  6:15       ` Huacai Chen [this message]

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='CAAhV-H5SDrOUO-BdptM=e-VwOBrVQ+UtqxVx+qYNU2FO12w+SQ@mail.gmail.com' \
    --to=chenhuacai@gmail.com \
    --cc=bhelgaas@google.com \
    --cc=jiaxun.yang@flygoat.com \
    --cc=linux-pci@vger.kernel.org \
    --cc=okaya@kernel.org \
    --cc=yangtiezhu@loongson.cn \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.