i40e/base: explicitly assign index for VSI type
authorJingjing Wu <jingjing.wu@intel.com>
Sun, 6 Sep 2015 07:12:05 +0000 (15:12 +0800)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Thu, 1 Oct 2015 23:35:22 +0000 (01:35 +0200)
The change is to explicitly assign enum index for each VSI type
so that PF and VF always reference to the same VSI type even if the
enum lists are different.

Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Tested-by: Huilong Xu <huilongx.xu@intel.com>
drivers/net/i40e/base/i40e_type.h

index fa8efd1..5dfae62 100644 (file)
@@ -222,14 +222,14 @@ enum i40e_set_fc_aq_failures {
 };
 
 enum i40e_vsi_type {
 };
 
 enum i40e_vsi_type {
-       I40E_VSI_MAIN = 0,
-       I40E_VSI_VMDQ1,
-       I40E_VSI_VMDQ2,
-       I40E_VSI_CTRL,
-       I40E_VSI_FCOE,
-       I40E_VSI_MIRROR,
-       I40E_VSI_SRIOV,
-       I40E_VSI_FDIR,
+       I40E_VSI_MAIN   = 0,
+       I40E_VSI_VMDQ1  = 1,
+       I40E_VSI_VMDQ2  = 2,
+       I40E_VSI_CTRL   = 3,
+       I40E_VSI_FCOE   = 4,
+       I40E_VSI_MIRROR = 5,
+       I40E_VSI_SRIOV  = 6,
+       I40E_VSI_FDIR   = 7,
        I40E_VSI_TYPE_UNKNOWN
 };
 
        I40E_VSI_TYPE_UNKNOWN
 };