Linux PCI subsystem development
 help / color / mirror / Atom feed
From: "Kuppuswamy, Sathyanarayanan"  <sathyanarayanan.kuppuswamy@linux.intel.com>
To: Saheed Olayemi Bolarinwa <refactormyself@gmail.com>,
	helgaas@kernel.org, linux-pci@vger.kernel.org
Subject: Re: [RFC PATCH] PCI/DPC: Fix info->id initialization in dpc_process_error()
Date: Wed, 4 Nov 2020 19:06:44 -0800	[thread overview]
Message-ID: <0f4c022a-a669-096c-d318-1e202c9eebbf@linux.intel.com> (raw)
In-Reply-To: <20201031100121.21391-1-refactormyself@gmail.com>



On 10/31/20 3:01 AM, Saheed Olayemi Bolarinwa wrote:
> From: "Saheed O. Bolarinwa" <refactormyself@gmail.com>
> 
> In the dpc_process_error() path, the error source ID is obtained
> but not stored inside the aer_err_info object. So aer_print_error()
> is not aware of the error source if it gets called.
> 
> Use the obtained valued to initialise info->id
Is it useful for DPC case ? I don't think we set info->error_dev_num for
DPC case right ?

if (info->id && info->error_dev_num > 1 && info->id == id)
  726                 pci_err(dev, "  Error of this Agent is reported first\n");

> 
> Signed-off-by: Saheed O. Bolarinwa <refactormyself@gmail.com>
> ---
>   drivers/pci/pcie/dpc.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/pci/pcie/dpc.c b/drivers/pci/pcie/dpc.c
> index e05aba86a317..9f8698812939 100644
> --- a/drivers/pci/pcie/dpc.c
> +++ b/drivers/pci/pcie/dpc.c
> @@ -223,6 +223,7 @@ void dpc_process_error(struct pci_dev *pdev)
>   	else if (reason == 0 &&
>   		 dpc_get_aer_uncorrect_severity(pdev, &info) &&
>   		 aer_get_device_error_info(pdev, &info)) {
> +		info.id = source;
>   		aer_print_error(pdev, &info);
>   		pci_aer_clear_nonfatal_status(pdev);
>   		pci_aer_clear_fatal_status(pdev);
> 

-- 
Sathyanarayanan Kuppuswamy
Linux Kernel Developer

  reply	other threads:[~2020-11-05  3:06 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-31 10:01 [RFC PATCH] PCI/DPC: Fix info->id initialization in dpc_process_error() Saheed Olayemi Bolarinwa
2020-11-05  3:06 ` Kuppuswamy, Sathyanarayanan [this message]
2020-11-18 19:33   ` Bjorn Helgaas

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=0f4c022a-a669-096c-d318-1e202c9eebbf@linux.intel.com \
    --to=sathyanarayanan.kuppuswamy@linux.intel.com \
    --cc=helgaas@kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=refactormyself@gmail.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