Skip to contentSkip to conversation

net: macb: Use predefined PCI vendor ID constant

PATCH Applied Andy Shevchenko 2 participants 2 messages Sep 13, 2024 – Sep 14, 2024

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net: macb: Use predefined PCI vendor ID constant

The PCI vendor ID for Cadence is defined in pci_ids.h. Use it. While at it, move to PCI_VDEVICE() macro and usual pattern for PCI device ID.

---
 drivers/net/ethernet/cadence/macb_pci.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/net/ethernet/cadence/macb_pci.c +2 -3
index f66d22de5168..fc4f5aee6ab3 100644
@@ -19,8 +19,7 @@
 #define PCI_DRIVER_NAME "macb_pci"
 #define PLAT_DRIVER_NAME "macb"
 
-#define CDNS_VENDOR_ID 0x17cd
-#define CDNS_DEVICE_ID 0xe007
+#define PCI_DEVICE_ID_CDNS_MACB 0xe007
 
 #define GEM_PCLK_RATE 50000000
 #define GEM_HCLK_RATE 50000000
@@ -117,7 +116,7 @@ static void macb_remove(struct pci_dev *pdev)
 }
 
 static const struct pci_device_id dev_id_table[] = {
-	{ PCI_DEVICE(CDNS_VENDOR_ID, CDNS_DEVICE_ID), },
+	{ PCI_VDEVICE(CDNS, PCI_DEVICE_ID_CDNS_MACB) },
 	{ 0, }
 };
 
Signature · 1 line
2.43.0.rc1.1336.g36b5255a03ac
#1 lore raw
This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:

Hello:

This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:

Quoted 8 lines · On Fri, 13 Sep 2024 15:51:46 +0300 you wrote:

The PCI vendor ID for Cadence is defined in pci_ids.h. Use it. While at it, move to PCI_VDEVICE() macro and usual pattern for PCI device ID.

---
 drivers/net/ethernet/cadence/macb_pci.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Here is the summary with links:
- [net-next,v1,1/1] net: macb: Use predefined PCI vendor ID constant

    https://git.kernel.org/netdev/net-next/c/6503734916cc

You are awesome, thank you!

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