Commit b47a57a2 authored by George Cherian's avatar George Cherian Committed by David S. Miller

net: thunderx: Fix set_max_bgx_per_node for 81xx rgx

Add the PCI_SUBSYS_DEVID_81XX_RGX and use the same to set
the max bgx per node count.

This fixes the issue intoduced by following commit
78aacb6f net: thunderx: Fix invalid mac addresses for node1 interfaces
With this commit the max_bgx_per_node for 81xx is set as 2 instead of 3
because of which num_vfs is always calculated as zero.
Signed-off-by: default avatarGeorge Cherian <george.cherian@cavium.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 1862d620
...@@ -134,6 +134,7 @@ static void set_max_bgx_per_node(struct pci_dev *pdev) ...@@ -134,6 +134,7 @@ static void set_max_bgx_per_node(struct pci_dev *pdev)
pci_read_config_word(pdev, PCI_SUBSYSTEM_ID, &sdevid); pci_read_config_word(pdev, PCI_SUBSYSTEM_ID, &sdevid);
switch (sdevid) { switch (sdevid) {
case PCI_SUBSYS_DEVID_81XX_BGX: case PCI_SUBSYS_DEVID_81XX_BGX:
case PCI_SUBSYS_DEVID_81XX_RGX:
max_bgx_per_node = MAX_BGX_PER_CN81XX; max_bgx_per_node = MAX_BGX_PER_CN81XX;
break; break;
case PCI_SUBSYS_DEVID_83XX_BGX: case PCI_SUBSYS_DEVID_83XX_BGX:
......
...@@ -16,6 +16,7 @@ ...@@ -16,6 +16,7 @@
/* Subsystem device IDs */ /* Subsystem device IDs */
#define PCI_SUBSYS_DEVID_88XX_BGX 0xA126 #define PCI_SUBSYS_DEVID_88XX_BGX 0xA126
#define PCI_SUBSYS_DEVID_81XX_BGX 0xA226 #define PCI_SUBSYS_DEVID_81XX_BGX 0xA226
#define PCI_SUBSYS_DEVID_81XX_RGX 0xA254
#define PCI_SUBSYS_DEVID_83XX_BGX 0xA326 #define PCI_SUBSYS_DEVID_83XX_BGX 0xA326
#define MAX_BGX_THUNDER 8 /* Max 2 nodes, 4 per node */ #define MAX_BGX_THUNDER 8 /* Max 2 nodes, 4 per node */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment