Skip to contentSkip to conversation

r8169: remove useless PCI region size check

PATCH Applied Heiner Kallweit 2 participants 2 messages Sep 2, 2022 – Sep 5, 2022

Subsystems (3)
lore
Share & tools
lore

Heiner Kallweit

author maintainer
#0 lore raw

PATCH 1/1 r8169: remove useless PCI region size check

Let's trust the hardware here and remove this useless check.

---
 drivers/net/ethernet/realtek/r8169_main.c | 6 ------
 1 file changed, 6 deletions(-)
drivers/net/ethernet/realtek/r8169_main.c +0 -6
index e6fb6f223..1d571af4d 100644
@@ -5206,12 +5206,6 @@ static int rtl_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
 		return -ENODEV;
 	}
 
-	/* check for weird/broken PCI region reporting */
-	if (pci_resource_len(pdev, region) < R8169_REGS_SIZE) {
-		dev_err(&pdev->dev, "Invalid PCI region size(s), aborting\n");
-		return -ENODEV;
-	}
-
 	rc = pcim_iomap_regions(pdev, BIT(region), KBUILD_MODNAME);
 	if (rc < 0) {
 		dev_err(&pdev->dev, "cannot remap MMIO, aborting\n");
Signature · 1 line
2.37.3
#1 lore raw
This patch was applied to netdev/net-next.git (master) by David S. Miller <[email protected]>:

Hello:

This patch was applied to netdev/net-next.git (master) by David S. Miller <[email protected]>:

Quoted 6 lines · On Fri, 2 Sep 2022 23:16:52 +0200 you wrote:

Let's trust the hardware here and remove this useless check.

---
 drivers/net/ethernet/realtek/r8169_main.c | 6 ------
 1 file changed, 6 deletions(-)

Here is the summary with links:
- [net-next] r8169: remove useless PCI region size check

    https://git.kernel.org/netdev/net-next/c/36f9b47457f0

You are awesome, thank you!

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