Skip to contentSkip to conversation

Intel Wired LAN: Remove redundant Device Control Error Reporting Enable

GIT PULL New Tony Nguyen 4 participants 13 messages Jan 30, 2023 – Feb 1, 2023

Subsystems (3)
lore
Share & tools
lore

Tony Nguyen

author maintainer
#0 lore raw

Bjorn Helgaas says:

Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core sets the Device Control bits that enable error reporting for PCIe devices.

This series removes redundant calls to pci_enable_pcie_error_reporting() that do the same thing from several NIC drivers.

There are several more drivers where this should be removed; I started with just the Intel drivers here.
---
TN: Removed mention of AER driver as this was taken through PCI tree [1] and fixed a typo.

[1] https://lore.kernel.org/all/20230126231527.GA1322015@bhelgaas/

The following are changes since commit 90e8ca0abb05ada6c1e2710eaa21688dafca26f2:
Merge branch 'devlink-next'
and are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue 10GbE

Bjorn Helgaas (8):
e1000e: Remove redundant pci_enable_pcie_error_reporting()
fm10k: Remove redundant pci_enable_pcie_error_reporting()
i40e: Remove redundant pci_enable_pcie_error_reporting()
iavf: Remove redundant pci_enable_pcie_error_reporting()
ice: Remove redundant pci_enable_pcie_error_reporting()
igb: Remove redundant pci_enable_pcie_error_reporting()
igc: Remove redundant pci_enable_pcie_error_reporting()
ixgbe: Remove redundant pci_enable_pcie_error_reporting()

 drivers/net/ethernet/intel/e1000e/netdev.c    | 7 -------
 drivers/net/ethernet/intel/fm10k/fm10k_pci.c  | 5 -----
 drivers/net/ethernet/intel/i40e/i40e_main.c   | 4 ----
 drivers/net/ethernet/intel/iavf/iavf_main.c   | 5 -----
 drivers/net/ethernet/intel/ice/ice_main.c     | 3 ---
 drivers/net/ethernet/intel/igb/igb_main.c     | 5 -----
 drivers/net/ethernet/intel/igc/igc_main.c     | 5 -----
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 5 -----
 8 files changed, 39 deletions(-)
Signature · 1 line
2.38.1
author maintainer
#1 lore raw

PATCH 1/8 e1000e: Remove redundant pci_enable_pcie_error_reporting()

From: Bjorn Helgaas <[email protected]>

pci_enable_pcie_error_reporting() enables the device to send ERR_* Messages. Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core does this for all devices during enumeration.

Remove the redundant pci_enable_pcie_error_reporting() call from the driver. Also remove the corresponding pci_disable_pcie_error_reporting() from the driver .remove() path.

Note that this doesn't control interrupt generation by the Root Port; that is controlled by the AER Root Error Command register, which is managed by the AER service driver.

---
 drivers/net/ethernet/intel/e1000e/netdev.c | 7 -------
 1 file changed, 7 deletions(-)
drivers/net/ethernet/intel/e1000e/netdev.c +0 -7
index 04acd1a992fa..e1eb1de88bf9 100644
@@ -7418,9 +7418,6 @@ static int e1000_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 	if (err)
 		goto err_pci_reg;
 
-	/* AER (Advanced Error Reporting) hooks */
-	pci_enable_pcie_error_reporting(pdev);
-
 	pci_set_master(pdev);
 	/* PCI config space info */
 	err = pci_save_state(pdev);
@@ -7708,7 +7705,6 @@ static int e1000_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 err_ioremap:
 	free_netdev(netdev);
 err_alloc_etherdev:
-	pci_disable_pcie_error_reporting(pdev);
 	pci_release_mem_regions(pdev);
 err_pci_reg:
 err_dma:
@@ -7775,9 +7771,6 @@ static void e1000_remove(struct pci_dev *pdev)
 
 	free_netdev(netdev);
 
-	/* AER disable */
-	pci_disable_pcie_error_reporting(pdev);
-
 	pci_disable_device(pdev);
 }
 
Signature · 6 lines
2.38.1

_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
author maintainer
#2 lore raw

PATCH 2/8 fm10k: Remove redundant pci_enable_pcie_error_reporting()

In reply to Tony Nguyen

From: Bjorn Helgaas <[email protected]>

pci_enable_pcie_error_reporting() enables the device to send ERR_* Messages. Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core does this for all devices during enumeration.

Remove the redundant pci_enable_pcie_error_reporting() call from the driver. Also remove the corresponding pci_disable_pcie_error_reporting() from the driver .remove() path.

Note that this doesn't control interrupt generation by the Root Port; that is controlled by the AER Root Error Command register, which is managed by the AER service driver.

---
 drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 5 -----
 1 file changed, 5 deletions(-)
drivers/net/ethernet/intel/fm10k/fm10k_pci.c +0 -5
index b473cb7d7c57..027d721feb18 100644
@@ -2127,8 +2127,6 @@ static int fm10k_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 		goto err_pci_reg;
 	}
 
-	pci_enable_pcie_error_reporting(pdev);
-
 	pci_set_master(pdev);
 	pci_save_state(pdev);
 
@@ -2227,7 +2225,6 @@ static int fm10k_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 err_ioremap:
 	free_netdev(netdev);
 err_alloc_netdev:
-	pci_disable_pcie_error_reporting(pdev);
 	pci_release_mem_regions(pdev);
 err_pci_reg:
 err_dma:
@@ -2281,8 +2278,6 @@ static void fm10k_remove(struct pci_dev *pdev)
 
 	pci_release_mem_regions(pdev);
 
-	pci_disable_pcie_error_reporting(pdev);
-
 	pci_disable_device(pdev);
 }
 
Signature · 6 lines
2.38.1

_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
author maintainer
#3 lore raw

PATCH 3/8 i40e: Remove redundant pci_enable_pcie_error_reporting()

In reply to Tony Nguyen

From: Bjorn Helgaas <[email protected]>

pci_enable_pcie_error_reporting() enables the device to send ERR_* Messages. Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core does this for all devices during enumeration.

Remove the redundant pci_enable_pcie_error_reporting() call from the driver. Also remove the corresponding pci_disable_pcie_error_reporting() from the driver .remove() path.

Note that this doesn't control interrupt generation by the Root Port; that is controlled by the AER Root Error Command register, which is managed by the AER service driver.

---
 drivers/net/ethernet/intel/i40e/i40e_main.c | 4 ----
 1 file changed, 4 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_main.c +0 -4
index 53d0083e35da..43693f902c27 100644
@@ -15589,7 +15589,6 @@ static int i40e_init_recovery_mode(struct i40e_pf *pf, struct i40e_hw *hw)
 	timer_shutdown_sync(&pf->service_timer);
 	i40e_shutdown_adminq(hw);
 	iounmap(hw->hw_addr);
-	pci_disable_pcie_error_reporting(pf->pdev);
 	pci_release_mem_regions(pf->pdev);
 	pci_disable_device(pf->pdev);
 	kfree(pf);
@@ -15660,7 +15659,6 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 		goto err_pci_reg;
 	}
 
-	pci_enable_pcie_error_reporting(pdev);
 	pci_set_master(pdev);
 
 	/* Now that we have a PCI connection, we need to do the
@@ -16218,7 +16216,6 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 err_ioremap:
 	kfree(pf);
 err_pf_alloc:
-	pci_disable_pcie_error_reporting(pdev);
 	pci_release_mem_regions(pdev);
 err_pci_reg:
 err_dma:
@@ -16366,7 +16363,6 @@ static void i40e_remove(struct pci_dev *pdev)
 	kfree(pf);
 	pci_release_mem_regions(pdev);
 
-	pci_disable_pcie_error_reporting(pdev);
 	pci_disable_device(pdev);
 }
 
Signature · 6 lines
2.38.1

_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
author maintainer
#4 lore raw

PATCH 4/8 iavf: Remove redundant pci_enable_pcie_error_reporting()

In reply to Tony Nguyen

From: Bjorn Helgaas <[email protected]>

pci_enable_pcie_error_reporting() enables the device to send ERR_* Messages. Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core does this for all devices during enumeration.

Remove the redundant pci_enable_pcie_error_reporting() call from the driver. Also remove the corresponding pci_disable_pcie_error_reporting() from the driver .remove() path.

Note that this doesn't control interrupt generation by the Root Port; that is controlled by the AER Root Error Command register, which is managed by the AER service driver.

---
 drivers/net/ethernet/intel/iavf/iavf_main.c | 5 -----
 1 file changed, 5 deletions(-)
drivers/net/ethernet/intel/iavf/iavf_main.c +0 -5
index 2c4480b20db3..3273aeb8fa67 100644
@@ -4868,8 +4868,6 @@ static int iavf_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 		goto err_pci_reg;
 	}
 
-	pci_enable_pcie_error_reporting(pdev);
-
 	pci_set_master(pdev);
 
 	netdev = alloc_etherdev_mq(sizeof(struct iavf_adapter),
@@ -4957,7 +4955,6 @@ static int iavf_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 err_alloc_wq:
 	free_netdev(netdev);
 err_alloc_etherdev:
-	pci_disable_pcie_error_reporting(pdev);
 	pci_release_regions(pdev);
 err_pci_reg:
 err_dma:
@@ -5175,8 +5172,6 @@ static void iavf_remove(struct pci_dev *pdev)
 
 	free_netdev(netdev);
 
-	pci_disable_pcie_error_reporting(pdev);
-
 	pci_disable_device(pdev);
 }
 
Signature · 1 line
2.38.1
author maintainer
#5 lore raw

PATCH 5/8 ice: Remove redundant pci_enable_pcie_error_reporting()

In reply to Tony Nguyen

From: Bjorn Helgaas <[email protected]>

pci_enable_pcie_error_reporting() enables the device to send ERR_* Messages. Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core does this for all devices during enumeration.

Remove the redundant pci_enable_pcie_error_reporting() call from the driver. Also remove the corresponding pci_disable_pcie_error_reporting() from the driver .remove() path.

Note that this doesn't control interrupt generation by the Root Port; that is controlled by the AER Root Error Command register, which is managed by the AER service driver.

---
 drivers/net/ethernet/intel/ice/ice_main.c | 3 ---
 1 file changed, 3 deletions(-)
drivers/net/ethernet/intel/ice/ice_main.c +0 -3
index fce86e8ff834..4aa19562fe93 100644
@@ -4664,7 +4664,6 @@ ice_probe(struct pci_dev *pdev, const struct pci_device_id __always_unused *ent)
 		return err;
 	}
 
-	pci_enable_pcie_error_reporting(pdev);
 	pci_set_master(pdev);
 
 	pf->pdev = pdev;
@@ -4981,7 +4980,6 @@ ice_probe(struct pci_dev *pdev, const struct pci_device_id __always_unused *ent)
 	ice_devlink_destroy_regions(pf);
 	ice_deinit_hw(hw);
 err_exit_unroll:
-	pci_disable_pcie_error_reporting(pdev);
 	pci_disable_device(pdev);
 	return err;
 }
@@ -5113,7 +5111,6 @@ static void ice_remove(struct pci_dev *pdev)
 	ice_reset(hw, ICE_RESET_PFR);
 	pci_wait_for_pending_transaction(pdev);
 	ice_clear_interrupt_scheme(pf);
-	pci_disable_pcie_error_reporting(pdev);
 	pci_disable_device(pdev);
 }
 
Signature · 6 lines
2.38.1

_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
author maintainer
#6 lore raw

PATCH 6/8 igb: Remove redundant pci_enable_pcie_error_reporting()

In reply to Tony Nguyen

From: Bjorn Helgaas <[email protected]>

pci_enable_pcie_error_reporting() enables the device to send ERR_* Messages. Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core does this for all devices during enumeration.

Remove the redundant pci_enable_pcie_error_reporting() call from the driver. Also remove the corresponding pci_disable_pcie_error_reporting() from the driver .remove() path.

Note that this doesn't control interrupt generation by the Root Port; that is controlled by the AER Root Error Command register, which is managed by the AER service driver.

---
 drivers/net/ethernet/intel/igb/igb_main.c | 5 -----
 1 file changed, 5 deletions(-)
drivers/net/ethernet/intel/igb/igb_main.c +0 -5
index 3c0c35ecea10..c56b991fa610 100644
@@ -3194,8 +3194,6 @@ static int igb_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 	if (err)
 		goto err_pci_reg;
 
-	pci_enable_pcie_error_reporting(pdev);
-
 	pci_set_master(pdev);
 	pci_save_state(pdev);
 
@@ -3626,7 +3624,6 @@ static int igb_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 err_ioremap:
 	free_netdev(netdev);
 err_alloc_etherdev:
-	pci_disable_pcie_error_reporting(pdev);
 	pci_release_mem_regions(pdev);
 err_pci_reg:
 err_dma:
@@ -3837,8 +3834,6 @@ static void igb_remove(struct pci_dev *pdev)
 	kfree(adapter->shadow_vfta);
 	free_netdev(netdev);
 
-	pci_disable_pcie_error_reporting(pdev);
-
 	pci_disable_device(pdev);
 }
 
Signature · 6 lines
2.38.1

_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
author maintainer
#7 lore raw

PATCH 7/8 igc: Remove redundant pci_enable_pcie_error_reporting()

In reply to Tony Nguyen

From: Bjorn Helgaas <[email protected]>

pci_enable_pcie_error_reporting() enables the device to send ERR_* Messages. Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core does this for all devices during enumeration.

Remove the redundant pci_enable_pcie_error_reporting() call from the driver. Also remove the corresponding pci_disable_pcie_error_reporting() from the driver .remove() path.

Note that this doesn't control interrupt generation by the Root Port; that is controlled by the AER Root Error Command register, which is managed by the AER service driver.

---
 drivers/net/ethernet/intel/igc/igc_main.c | 5 -----
 1 file changed, 5 deletions(-)
drivers/net/ethernet/intel/igc/igc_main.c +0 -5
index e86b15efaeb8..6ddcbc8b7b6a 100644
@@ -6434,8 +6434,6 @@ static int igc_probe(struct pci_dev *pdev,
 	if (err)
 		goto err_pci_reg;
 
-	pci_enable_pcie_error_reporting(pdev);
-
 	err = pci_enable_ptm(pdev, NULL);
 	if (err < 0)
 		dev_info(&pdev->dev, "PCIe PTM not supported by PCIe bus/controller\n");
@@ -6640,7 +6638,6 @@ static int igc_probe(struct pci_dev *pdev,
 err_ioremap:
 	free_netdev(netdev);
 err_alloc_etherdev:
-	pci_disable_pcie_error_reporting(pdev);
 	pci_release_mem_regions(pdev);
 err_pci_reg:
 err_dma:
@@ -6688,8 +6685,6 @@ static void igc_remove(struct pci_dev *pdev)
 
 	free_netdev(netdev);
 
-	pci_disable_pcie_error_reporting(pdev);
-
 	pci_disable_device(pdev);
 }
 
Signature · 1 line
2.38.1
author maintainer
#8 lore raw

PATCH 8/8 ixgbe: Remove redundant pci_enable_pcie_error_reporting()

In reply to Tony Nguyen

From: Bjorn Helgaas <[email protected]>

pci_enable_pcie_error_reporting() enables the device to send ERR_* Messages. Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core does this for all devices during enumeration.

Remove the redundant pci_enable_pcie_error_reporting() call from the driver. Also remove the corresponding pci_disable_pcie_error_reporting() from the driver .remove() path.

Note that this doesn't control interrupt generation by the Root Port; that is controlled by the AER Root Error Command register, which is managed by the AER service driver.

---
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 5 -----
 1 file changed, 5 deletions(-)
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c +0 -5
index 43a44c1e1576..992b7ae75233 100644
@@ -10809,8 +10809,6 @@ static int ixgbe_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 		goto err_pci_reg;
 	}
 
-	pci_enable_pcie_error_reporting(pdev);
-
 	pci_set_master(pdev);
 	pci_save_state(pdev);
 
@@ -11238,7 +11236,6 @@ static int ixgbe_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 	disable_dev = !test_and_set_bit(__IXGBE_DISABLED, &adapter->state);
 	free_netdev(netdev);
 err_alloc_etherdev:
-	pci_disable_pcie_error_reporting(pdev);
 	pci_release_mem_regions(pdev);
 err_pci_reg:
 err_dma:
@@ -11327,8 +11324,6 @@ static void ixgbe_remove(struct pci_dev *pdev)
 	disable_dev = !test_and_set_bit(__IXGBE_DISABLED, &adapter->state);
 	free_netdev(netdev);
 
-	pci_disable_pcie_error_reporting(pdev);
-
 	if (disable_dev)
 		pci_disable_device(pdev);
 }
Signature · 1 line
2.38.1
#9 lore raw
In reply to Tony Nguyen
Quoted 32 lines · Tony Nguyen

Bjorn Helgaas says:

Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core sets the Device Control bits that enable error reporting for PCIe devices.

This series removes redundant calls to pci_enable_pcie_error_reporting() that do the same thing from several NIC drivers.

There are several more drivers where this should be removed; I started with just the Intel drivers here.
---
TN: Removed mention of AER driver as this was taken through PCI tree [1] and fixed a typo.

[1] https://lore.kernel.org/all/20230126231527.GA1322015@bhelgaas/

The following are changes since commit 90e8ca0abb05ada6c1e2710eaa21688dafca26f2:
Merge branch 'devlink-next'
and are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue 10GbE

Bjorn Helgaas (8):
e1000e: Remove redundant pci_enable_pcie_error_reporting()
fm10k: Remove redundant pci_enable_pcie_error_reporting()
i40e: Remove redundant pci_enable_pcie_error_reporting()
iavf: Remove redundant pci_enable_pcie_error_reporting()
ice: Remove redundant pci_enable_pcie_error_reporting()
igb: Remove redundant pci_enable_pcie_error_reporting()
igc: Remove redundant pci_enable_pcie_error_reporting()
ixgbe: Remove redundant pci_enable_pcie_error_reporting()

Quoted 9 lines
 drivers/net/ethernet/intel/e1000e/netdev.c    | 7 -------
 drivers/net/ethernet/intel/fm10k/fm10k_pci.c  | 5 -----
 drivers/net/ethernet/intel/i40e/i40e_main.c   | 4 ----
 drivers/net/ethernet/intel/iavf/iavf_main.c   | 5 -----
 drivers/net/ethernet/intel/ice/ice_main.c     | 3 ---
 drivers/net/ethernet/intel/igb/igb_main.c     | 5 -----
 drivers/net/ethernet/intel/igc/igc_main.c     | 5 -----
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 5 -----
 8 files changed, 39 deletions(-)

I see that you didn't touch any other places except drivers/net/ethernet/intel/. Are you planning to remove other occurrences too?

➜ kernel git:(rdma-next) git grep pci_enable_pcie_error_reporting -- drivers/infiniband/
drivers/infiniband/hw/hfi1/pcie.c: (void)pci_enable_pcie_error_reporting(pdev);
drivers/infiniband/hw/qib/qib_pcie.c: ret = pci_enable_pcie_error_reporting(pdev);

Thanks

Quoted 4 lines
Signature · 2 lines
-- 
2.38.1
#10 lore raw
Quoted 44 lines · Leon Romanovsky
Quoted 32 lines · Tony Nguyen

Bjorn Helgaas says:

Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core sets the Device Control bits that enable error reporting for PCIe devices.

This series removes redundant calls to pci_enable_pcie_error_reporting() that do the same thing from several NIC drivers.

There are several more drivers where this should be removed; I started with just the Intel drivers here.
---
TN: Removed mention of AER driver as this was taken through PCI tree [1] and fixed a typo.

[1] https://lore.kernel.org/all/20230126231527.GA1322015@bhelgaas/

The following are changes since commit 90e8ca0abb05ada6c1e2710eaa21688dafca26f2:
Merge branch 'devlink-next'
and are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue 10GbE

Bjorn Helgaas (8):
e1000e: Remove redundant pci_enable_pcie_error_reporting()
fm10k: Remove redundant pci_enable_pcie_error_reporting()
i40e: Remove redundant pci_enable_pcie_error_reporting()
iavf: Remove redundant pci_enable_pcie_error_reporting()
ice: Remove redundant pci_enable_pcie_error_reporting()
igb: Remove redundant pci_enable_pcie_error_reporting()
igc: Remove redundant pci_enable_pcie_error_reporting()
ixgbe: Remove redundant pci_enable_pcie_error_reporting()

Quoted 9 lines
 drivers/net/ethernet/intel/e1000e/netdev.c    | 7 -------
 drivers/net/ethernet/intel/fm10k/fm10k_pci.c  | 5 -----
 drivers/net/ethernet/intel/i40e/i40e_main.c   | 4 ----
 drivers/net/ethernet/intel/iavf/iavf_main.c   | 5 -----
 drivers/net/ethernet/intel/ice/ice_main.c     | 3 ---
 drivers/net/ethernet/intel/igb/igb_main.c     | 5 -----
 drivers/net/ethernet/intel/igc/igc_main.c     | 5 -----
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 5 -----
 8 files changed, 39 deletions(-)
Quoted 6 lines

I see that you didn't touch any other places except drivers/net/ethernet/intel/. Are you planning to remove other occurrences too?

➜ kernel git:(rdma-next) git grep pci_enable_pcie_error_reporting -- drivers/infiniband/
drivers/infiniband/hw/hfi1/pcie.c: (void)pci_enable_pcie_error_reporting(pdev);
drivers/infiniband/hw/qib/qib_pcie.c: ret = pci_enable_pcie_error_reporting(pdev);

Yes, definitely, I just haven't had a chance yet. Some of the others are a little more complicated than the simple removals for the Intel drivers.

Bjorn

#11 lore raw
Quoted 48 lines · Bjorn Helgaas
Quoted 47 lines · Leon Romanovsky
Quoted 32 lines · Tony Nguyen

Bjorn Helgaas says:

Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core sets the Device Control bits that enable error reporting for PCIe devices.

This series removes redundant calls to pci_enable_pcie_error_reporting() that do the same thing from several NIC drivers.

There are several more drivers where this should be removed; I started with just the Intel drivers here.
---
TN: Removed mention of AER driver as this was taken through PCI tree [1] and fixed a typo.

[1] https://lore.kernel.org/all/20230126231527.GA1322015@bhelgaas/

The following are changes since commit 90e8ca0abb05ada6c1e2710eaa21688dafca26f2:
Merge branch 'devlink-next'
and are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue 10GbE

Bjorn Helgaas (8):
e1000e: Remove redundant pci_enable_pcie_error_reporting()
fm10k: Remove redundant pci_enable_pcie_error_reporting()
i40e: Remove redundant pci_enable_pcie_error_reporting()
iavf: Remove redundant pci_enable_pcie_error_reporting()
ice: Remove redundant pci_enable_pcie_error_reporting()
igb: Remove redundant pci_enable_pcie_error_reporting()
igc: Remove redundant pci_enable_pcie_error_reporting()
ixgbe: Remove redundant pci_enable_pcie_error_reporting()

Quoted 9 lines
 drivers/net/ethernet/intel/e1000e/netdev.c    | 7 -------
 drivers/net/ethernet/intel/fm10k/fm10k_pci.c  | 5 -----
 drivers/net/ethernet/intel/i40e/i40e_main.c   | 4 ----
 drivers/net/ethernet/intel/iavf/iavf_main.c   | 5 -----
 drivers/net/ethernet/intel/ice/ice_main.c     | 3 ---
 drivers/net/ethernet/intel/igb/igb_main.c     | 5 -----
 drivers/net/ethernet/intel/igc/igc_main.c     | 5 -----
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 5 -----
 8 files changed, 39 deletions(-)

I see that you didn't touch any other places except drivers/net/ethernet/intel/. Are you planning to remove other occurrences too?

Quoted 7 lines
Quoted 3 lines

➜ kernel git:(rdma-next) git grep pci_enable_pcie_error_reporting -- drivers/infiniband/
drivers/infiniband/hw/hfi1/pcie.c: (void)pci_enable_pcie_error_reporting(pdev);
drivers/infiniband/hw/qib/qib_pcie.c: ret = pci_enable_pcie_error_reporting(pdev);

Yes, definitely, I just haven't had a chance yet. Some of the others are a little more complicated than the simple removals for the Intel drivers.

Great, I'll wait for your patch :)

Thanks.

Quoted 2 lines

Bjorn

#12 lore raw
In reply to Tony Nguyen
This series was applied to netdev/net-next.git (master) by Tony Nguyen <[email protected]>:

Hello:

This series was applied to netdev/net-next.git (master) by Tony Nguyen <[email protected]>:

Quoted 10 lines · On Mon, 30 Jan 2023 11:25:11 -0800 you wrote:

Bjorn Helgaas says:

Since f26e58bf6f54 ("PCI/AER: Enable error reporting when AER is native"), the PCI core sets the Device Control bits that enable error reporting for PCIe devices.

This series removes redundant calls to pci_enable_pcie_error_reporting() that do the same thing from several NIC drivers.

[...]

Here is the summary with links:
- [net-next,1/8] e1000e: Remove redundant pci_enable_pcie_error_reporting()

    https://git.kernel.org/netdev/net-next/c/601f46282cd8
  - [net-next,2/8] fm10k: Remove redundant pci_enable_pcie_error_reporting()
    https://git.kernel.org/netdev/net-next/c/3218487afdc4
  - [net-next,3/8] i40e: Remove redundant pci_enable_pcie_error_reporting()
    https://git.kernel.org/netdev/net-next/c/d04d9e769993
  - [net-next,4/8] iavf: Remove redundant pci_enable_pcie_error_reporting()
    https://git.kernel.org/netdev/net-next/c/bc4fddc3b306
  - [net-next,5/8] ice: Remove redundant pci_enable_pcie_error_reporting()
    https://git.kernel.org/netdev/net-next/c/ba153552c18d
  - [net-next,6/8] igb: Remove redundant pci_enable_pcie_error_reporting()
    https://git.kernel.org/netdev/net-next/c/8aea4c325296
  - [net-next,7/8] igc: Remove redundant pci_enable_pcie_error_reporting()
    https://git.kernel.org/netdev/net-next/c/c3c14ecfe04a
  - [net-next,8/8] ixgbe: Remove redundant pci_enable_pcie_error_reporting()
    https://git.kernel.org/netdev/net-next/c/dec6b8016445

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html