net/i40e: initialise L3 MAP register
authorBernard Iremonger <bernard.iremonger@intel.com>
Fri, 31 Mar 2017 17:58:31 +0000 (18:58 +0100)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 4 Apr 2017 17:03:01 +0000 (19:03 +0200)
The L3 MAP register is initialised to support QinQ
cloud filters.

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
drivers/net/i40e/i40e_ethdev.c

index 00079bb..3a06f0c 100644 (file)
@@ -688,6 +688,9 @@ RTE_PMD_REGISTER_KMOD_DEP(net_i40e, "* igb_uio | uio_pci_generic | vfio");
 #ifndef I40E_GLQF_PIT
 #define I40E_GLQF_PIT(_i)    (0x00268C80 + ((_i) * 4))
 #endif
+#ifndef I40E_GLQF_L3_MAP
+#define I40E_GLQF_L3_MAP(_i) (0x0026C700 + ((_i) * 4))
+#endif
 
 static inline void i40e_GLQF_reg_init(struct i40e_hw *hw)
 {
@@ -1129,6 +1132,12 @@ eth_i40e_dev_init(struct rte_eth_dev *dev)
                     ((hw->nvm.version >> 4) & 0xff),
                     (hw->nvm.version & 0xf), hw->nvm.eetrack);
 
+       /* initialise the L3_MAP register */
+       ret = i40e_aq_debug_write_register(hw, I40E_GLQF_L3_MAP(40),
+                                  0x00000028,  NULL);
+       if (ret)
+               PMD_INIT_LOG(ERR, "Failed to write L3 MAP register %d", ret);
+
        /* Need the special FW version to support floating VEB */
        config_floating_veb(dev);
        /* Clear PXE mode */