diff mbox series

PCI/DPC: print IRQ number used by DPC port

Message ID 1589018214-52752-1-git-send-email-yangyicong@hisilicon.com
State New
Headers show
Series PCI/DPC: print IRQ number used by DPC port | expand

Commit Message

Yicong Yang May 9, 2020, 9:56 a.m. UTC
Add print of IRQ number used by DPC port, like AER/PME does. It
provides convenience to track DPC interrupts counts of certain
port from /proc/interrupts.

Signed-off-by: Yicong Yang <yangyicong@hisilicon.com>
---
 drivers/pci/pcie/dpc.c | 1 +
 1 file changed, 1 insertion(+)

--
2.8.1

Comments

Bjorn Helgaas May 13, 2020, 8:50 p.m. UTC | #1
On Sat, May 09, 2020 at 05:56:54PM +0800, Yicong Yang wrote:
> Add print of IRQ number used by DPC port, like AER/PME does. It
> provides convenience to track DPC interrupts counts of certain
> port from /proc/interrupts.
> 
> Signed-off-by: Yicong Yang <yangyicong@hisilicon.com>

Applied to pci/error for v5.8, thanks!

> ---
>  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 7621704..ae6b553 100644
> --- a/drivers/pci/pcie/dpc.c
> +++ b/drivers/pci/pcie/dpc.c
> @@ -301,6 +301,7 @@ static int dpc_probe(struct pcie_device *dev)
> 
>  	ctl = (ctl & 0xfff4) | PCI_EXP_DPC_CTL_EN_FATAL | PCI_EXP_DPC_CTL_INT_EN;
>  	pci_write_config_word(pdev, pdev->dpc_cap + PCI_EXP_DPC_CTL, ctl);
> +	pci_info(pdev, "enabled with IRQ %d\n", dev->irq);
> 
>  	pci_info(pdev, "error containment capabilities: Int Msg #%d, RPExt%c PoisonedTLP%c SwTrigger%c RP PIO Log %d, DL_ActiveErr%c\n",
>  		 cap & PCI_EXP_DPC_IRQ, FLAG(cap, PCI_EXP_DPC_CAP_RP_EXT),
> --
> 2.8.1
>
diff mbox series

Patch

diff --git a/drivers/pci/pcie/dpc.c b/drivers/pci/pcie/dpc.c
index 7621704..ae6b553 100644
--- a/drivers/pci/pcie/dpc.c
+++ b/drivers/pci/pcie/dpc.c
@@ -301,6 +301,7 @@  static int dpc_probe(struct pcie_device *dev)

 	ctl = (ctl & 0xfff4) | PCI_EXP_DPC_CTL_EN_FATAL | PCI_EXP_DPC_CTL_INT_EN;
 	pci_write_config_word(pdev, pdev->dpc_cap + PCI_EXP_DPC_CTL, ctl);
+	pci_info(pdev, "enabled with IRQ %d\n", dev->irq);

 	pci_info(pdev, "error containment capabilities: Int Msg #%d, RPExt%c PoisonedTLP%c SwTrigger%c RP PIO Log %d, DL_ActiveErr%c\n",
 		 cap & PCI_EXP_DPC_IRQ, FLAG(cap, PCI_EXP_DPC_CAP_RP_EXT),