Skip to contentSkip to conversation

ixgbe: fix write to VLVFB in ixgbe_clear_vf_vlans()

PATCH New Emil Tantilov 3 participants 3 messages Dec 23, 2015

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

PATCH 1/1 ixgbe: fix write to VLVFB in ixgbe_clear_vf_vlans()

Fix the write to the VLVFB register in ixgbe_clear_vf_vlans() where word is the actual offset of the register and not the index for the IXGBE_VLVFB macro.

This was causing PCI AER errors on my system.

Fixes 4c7f35f679f592804736f9303051257de2c9f021

("ixgbe: Clean stale VLANs when changing port VLAN or resetting")

---
 drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c +1 -1
index eeff3d0..fd918da 100644
@@ -640,7 +640,7 @@ update_vlvf:
 		IXGBE_WRITE_REG(hw, IXGBE_VLVF(i), 0);
 update_vlvfb:
 		/* clear pool bits */
-		IXGBE_WRITE_REG(hw, IXGBE_VLVFB(word), vlvfb);
+		IXGBE_WRITE_REG(hw, word, vlvfb);
 	}
 }
 
#1 lore raw

PATCH 1/1 ixgbe: fix write to VLVFB in ixgbe_clear_vf_vlans()

Quoted 19 lines · Emil Tantilov

Fix the write to the VLVFB register in ixgbe_clear_vf_vlans() where word is the actual offset of the register and not the index for the IXGBE_VLVFB macro.

This was causing PCI AER errors on my system.

Fixes 4c7f35f679f592804736f9303051257de2c9f021

("ixgbe: Clean stale VLANs when changing port VLAN or resetting")

---
 drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c +0 -0
index eeff3d0..fd918da 100644

drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c update_vlvf: · line 646

Quoted 8 lines
drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c +1 -1
@@ -640,7 +640,7 @@ update_vlvf:
                IXGBE_WRITE_REG(hw, IXGBE_VLVF(i), 0);
 update_vlvfb:
                /* clear pool bits */
-               IXGBE_WRITE_REG(hw, IXGBE_VLVFB(word), vlvfb);
+               IXGBE_WRITE_REG(hw, word, vlvfb);
        }
 }
 

Actually it looks like there is some other bugs here too. Specifically the register offset used for word is a 4 byte aligned value and it looks like I had a number of assumptions that it was the offset inside the VLVFB array.

- Alex

#2 lore raw

PATCH 1/1 ixgbe: fix write to VLVFB in ixgbe_clear_vf_vlans()

In reply to Emil Tantilov
Quoted 13 lines

-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Emil Tantilov
Sent: Tuesday, December 22, 2015 5:10 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [PATCH] ixgbe: fix write to VLVFB in ixgbe_clear_vf_vlans()

Fix the write to the VLVFB register in ixgbe_clear_vf_vlans() where word is the actual offset of the register and not the index for the IXGBE_VLVFB macro.

Quoted 6 lines

This was causing PCI AER errors on my system.

Fixes 4c7f35f679f592804736f9303051257de2c9f021

("ixgbe: Clean stale VLANs when changing port VLAN or resetting")