[PATCH v6 05/16] PCI/AER: Rename aer_print_port_info() to aer_print_source()

Bjorn Helgaas posted 16 patches 7 months ago
There is a newer version of this series
[PATCH v6 05/16] PCI/AER: Rename aer_print_port_info() to aer_print_source()
Posted by Bjorn Helgaas 7 months ago
From: Jon Pan-Doh <pandoh@google.com>

Rename aer_print_port_info() to aer_print_source() to be more descriptive.
This logs the Error Source ID logged by a Root Port or Root Complex Event
Collector when it receives an ERR_COR, ERR_NONFATAL, or ERR_FATAL Message.

[bhelgaas: aer_print_rp_info() -> aer_print_source()]
Link: https://lore.kernel.org/r/20250321015806.954866-5-pandoh@google.com
Signed-off-by: Jon Pan-Doh <pandoh@google.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
---
 drivers/pci/pcie/aer.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/pci/pcie/aer.c b/drivers/pci/pcie/aer.c
index dc8a50e0a2b7..eb42d50b2def 100644
--- a/drivers/pci/pcie/aer.c
+++ b/drivers/pci/pcie/aer.c
@@ -733,8 +733,8 @@ void aer_print_error(struct pci_dev *dev, struct aer_err_info *info)
 			info->severity, info->tlp_header_valid, &info->tlp);
 }
 
-static void aer_print_port_info(struct pci_dev *dev, struct aer_err_info *info,
-				const char *details)
+static void aer_print_source(struct pci_dev *dev, struct aer_err_info *info,
+			     const char *details)
 {
 	u16 source = info->id;
 
@@ -932,7 +932,7 @@ static bool find_source_device(struct pci_dev *parent,
 	 * RCEC that received an ERR_* Message.
 	 */
 	if (!e_info->error_dev_num) {
-		aer_print_port_info(parent, e_info, " (no details found)");
+		aer_print_source(parent, e_info, " (no details found)");
 		return false;
 	}
 	return true;
@@ -1299,7 +1299,7 @@ static void aer_isr_one_error(struct aer_rpc *rpc,
 			e_info.multi_error_valid = 0;
 
 		if (find_source_device(pdev, &e_info)) {
-			aer_print_port_info(pdev, &e_info, "");
+			aer_print_source(pdev, &e_info, "");
 			aer_process_err_devices(&e_info);
 		}
 	}
@@ -1318,7 +1318,7 @@ static void aer_isr_one_error(struct aer_rpc *rpc,
 			e_info.multi_error_valid = 0;
 
 		if (find_source_device(pdev, &e_info)) {
-			aer_print_port_info(pdev, &e_info, "");
+			aer_print_source(pdev, &e_info, "");
 			aer_process_err_devices(&e_info);
 		}
 	}
-- 
2.43.0
Re: [PATCH v6 05/16] PCI/AER: Rename aer_print_port_info() to aer_print_source()
Posted by Ilpo Järvinen 7 months ago
On Mon, 19 May 2025, Bjorn Helgaas wrote:

> From: Jon Pan-Doh <pandoh@google.com>
> 
> Rename aer_print_port_info() to aer_print_source() to be more descriptive.
> This logs the Error Source ID logged by a Root Port or Root Complex Event
> Collector when it receives an ERR_COR, ERR_NONFATAL, or ERR_FATAL Message.
> 
> [bhelgaas: aer_print_rp_info() -> aer_print_source()]
> Link: https://lore.kernel.org/r/20250321015806.954866-5-pandoh@google.com
> Signed-off-by: Jon Pan-Doh <pandoh@google.com>
> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
> ---
>  drivers/pci/pcie/aer.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/pci/pcie/aer.c b/drivers/pci/pcie/aer.c
> index dc8a50e0a2b7..eb42d50b2def 100644
> --- a/drivers/pci/pcie/aer.c
> +++ b/drivers/pci/pcie/aer.c
> @@ -733,8 +733,8 @@ void aer_print_error(struct pci_dev *dev, struct aer_err_info *info)
>  			info->severity, info->tlp_header_valid, &info->tlp);
>  }
>  
> -static void aer_print_port_info(struct pci_dev *dev, struct aer_err_info *info,
> -				const char *details)
> +static void aer_print_source(struct pci_dev *dev, struct aer_err_info *info,
> +			     const char *details)
>  {
>  	u16 source = info->id;
>  
> @@ -932,7 +932,7 @@ static bool find_source_device(struct pci_dev *parent,
>  	 * RCEC that received an ERR_* Message.
>  	 */
>  	if (!e_info->error_dev_num) {
> -		aer_print_port_info(parent, e_info, " (no details found)");
> +		aer_print_source(parent, e_info, " (no details found)");
>  		return false;
>  	}
>  	return true;
> @@ -1299,7 +1299,7 @@ static void aer_isr_one_error(struct aer_rpc *rpc,
>  			e_info.multi_error_valid = 0;
>  
>  		if (find_source_device(pdev, &e_info)) {
> -			aer_print_port_info(pdev, &e_info, "");
> +			aer_print_source(pdev, &e_info, "");
>  			aer_process_err_devices(&e_info);
>  		}
>  	}
> @@ -1318,7 +1318,7 @@ static void aer_isr_one_error(struct aer_rpc *rpc,
>  			e_info.multi_error_valid = 0;
>  
>  		if (find_source_device(pdev, &e_info)) {
> -			aer_print_port_info(pdev, &e_info, "");
> +			aer_print_source(pdev, &e_info, "");
>  			aer_process_err_devices(&e_info);
>  		}
>  	}
> 

Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>

-- 
 i.
Re: [PATCH v6 05/16] PCI/AER: Rename aer_print_port_info() to aer_print_source()
Posted by Sathyanarayanan Kuppuswamy 7 months ago
On 5/19/25 2:35 PM, Bjorn Helgaas wrote:
> From: Jon Pan-Doh <pandoh@google.com>
>
> Rename aer_print_port_info() to aer_print_source() to be more descriptive.
> This logs the Error Source ID logged by a Root Port or Root Complex Event
> Collector when it receives an ERR_COR, ERR_NONFATAL, or ERR_FATAL Message.
>
> [bhelgaas: aer_print_rp_info() -> aer_print_source()]
> Link: https://lore.kernel.org/r/20250321015806.954866-5-pandoh@google.com
> Signed-off-by: Jon Pan-Doh <pandoh@google.com>
> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
> ---

Reviewed-by: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>

>   drivers/pci/pcie/aer.c | 10 +++++-----
>   1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/pci/pcie/aer.c b/drivers/pci/pcie/aer.c
> index dc8a50e0a2b7..eb42d50b2def 100644
> --- a/drivers/pci/pcie/aer.c
> +++ b/drivers/pci/pcie/aer.c
> @@ -733,8 +733,8 @@ void aer_print_error(struct pci_dev *dev, struct aer_err_info *info)
>   			info->severity, info->tlp_header_valid, &info->tlp);
>   }
>   
> -static void aer_print_port_info(struct pci_dev *dev, struct aer_err_info *info,
> -				const char *details)
> +static void aer_print_source(struct pci_dev *dev, struct aer_err_info *info,
> +			     const char *details)
>   {
>   	u16 source = info->id;
>   
> @@ -932,7 +932,7 @@ static bool find_source_device(struct pci_dev *parent,
>   	 * RCEC that received an ERR_* Message.
>   	 */
>   	if (!e_info->error_dev_num) {
> -		aer_print_port_info(parent, e_info, " (no details found)");
> +		aer_print_source(parent, e_info, " (no details found)");
>   		return false;
>   	}
>   	return true;
> @@ -1299,7 +1299,7 @@ static void aer_isr_one_error(struct aer_rpc *rpc,
>   			e_info.multi_error_valid = 0;
>   
>   		if (find_source_device(pdev, &e_info)) {
> -			aer_print_port_info(pdev, &e_info, "");
> +			aer_print_source(pdev, &e_info, "");
>   			aer_process_err_devices(&e_info);
>   		}
>   	}
> @@ -1318,7 +1318,7 @@ static void aer_isr_one_error(struct aer_rpc *rpc,
>   			e_info.multi_error_valid = 0;
>   
>   		if (find_source_device(pdev, &e_info)) {
> -			aer_print_port_info(pdev, &e_info, "");
> +			aer_print_source(pdev, &e_info, "");
>   			aer_process_err_devices(&e_info);
>   		}
>   	}

-- 
Sathyanarayanan Kuppuswamy
Linux Kernel Developer