All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Kelley, Sean V" <sean.v.kelley@intel.com>
To: Keith Busch <kbusch@kernel.org>
Cc: Linux PCI <linux-pci@vger.kernel.org>,
	Bjorn Helgaas <bhelgaas@google.com>,
	Hinko Kocevar <hinko.kocevar@ess.eu>
Subject: Re: [PATCH 3/3] PCI/ERR: Retain status from error notification
Date: Mon, 4 Jan 2021 18:43:07 +0000	[thread overview]
Message-ID: <A7EF1D77-1FBC-4B8E-8720-7D33F127CFFF@intel.com> (raw)
In-Reply-To: <20201217171431.502030-3-kbusch@kernel.org>

Hi Keith,

> On Dec 17, 2020, at 9:14 AM, Keith Busch <kbusch@kernel.org> wrote:
> 
> Overwriting the frozen detected status with the result of the link reset
> loses the NEED_RESET result that drivers are depending on for error
> handling to report the .slot_reset() callback. Retain this status so
> that subsequent error handling has the correct flow.
> 
> Reported-by: Hinko Kocevar <hinko.kocevar@ess.eu>
> Signed-off-by: Keith Busch <kbusch@kernel.org>
> ---
> drivers/pci/pcie/err.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/pci/pcie/err.c b/drivers/pci/pcie/err.c
> index a84f0bf4c1e2..b576aa890c76 100644
> --- a/drivers/pci/pcie/err.c
> +++ b/drivers/pci/pcie/err.c
> @@ -198,8 +198,7 @@ pci_ers_result_t pcie_do_recovery(struct pci_dev *dev,
> 	pci_dbg(bridge, "broadcast error_detected message\n");
> 	if (state == pci_channel_io_frozen) {
> 		pci_walk_bridge(bridge, report_frozen_detected, &status);
> -		status = reset_subordinates(bridge);
> -		if (status != PCI_ERS_RESULT_RECOVERED) {
> +		if (reset_subordinates(bridge) != PCI_ERS_RESULT_RECOVERED) {
> 			pci_warn(bridge, "subordinate device reset failed\n");
> 			goto failed;
> 		}

This was an interesting scenario for Hinko not getting the NEED_RESET.

Reviewed-by: Sean V Kelley <sean.v.kelley@intel.com>

> -- 
> 2.24.1
> 


  reply	other threads:[~2021-01-04 18:43 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-17 17:14 [PATCH 1/3] PCI/ERR: Clear status of the reporting device Keith Busch
2020-12-17 17:14 ` [PATCH 2/3] PCI/AER: Actually get the root port Keith Busch
2020-12-17 23:15   ` kernel test robot
2020-12-17 23:15     ` kernel test robot
2020-12-17 23:34   ` kernel test robot
2020-12-17 23:34     ` kernel test robot
2021-01-04 18:42   ` Kelley, Sean V
2021-01-04 22:05     ` Keith Busch
2021-01-04 22:10       ` Kelley, Sean V
2020-12-17 17:14 ` [PATCH 3/3] PCI/ERR: Retain status from error notification Keith Busch
2021-01-04 18:43   ` Kelley, Sean V [this message]
2021-01-05 14:12   ` Hinko Kocevar
2021-01-04 18:42 ` [PATCH 1/3] PCI/ERR: Clear status of the reporting device Kelley, Sean V

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=A7EF1D77-1FBC-4B8E-8720-7D33F127CFFF@intel.com \
    --to=sean.v.kelley@intel.com \
    --cc=bhelgaas@google.com \
    --cc=hinko.kocevar@ess.eu \
    --cc=kbusch@kernel.org \
    --cc=linux-pci@vger.kernel.org \
    /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.