summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/intel/iavf/iavf_adv_rss.h
diff options
context:
space:
mode:
authorHaiyue Wang <haiyue.wang@intel.com>2021-04-13 03:48:41 +0300
committerTony Nguyen <anthony.l.nguyen@intel.com>2021-04-22 19:26:23 +0300
commit0aaeb4fbc842b9e6ef11ee1415e6e88171056afb (patch)
tree66769f2f76941c9231a369b805514c45e4fc60c5 /drivers/net/ethernet/intel/iavf/iavf_adv_rss.h
parentddd1f3cfed3f06906c25f917eb703d683c415e24 (diff)
downloadlinux-0aaeb4fbc842b9e6ef11ee1415e6e88171056afb.tar.xz
iavf: Add framework to enable ethtool RSS config
Add the virtchnl message interface to VF, so that VF can request RSS input set(s) based on PF's capability. This framework allows ethtool RSS config support on the VF driver. Signed-off-by: Haiyue Wang <haiyue.wang@intel.com> Tested-by: Konrad Jankowski <konrad0.jankowski@intel.com> Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/iavf/iavf_adv_rss.h')
-rw-r--r--drivers/net/ethernet/intel/iavf/iavf_adv_rss.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/iavf/iavf_adv_rss.h b/drivers/net/ethernet/intel/iavf/iavf_adv_rss.h
new file mode 100644
index 000000000000..66262090e697
--- /dev/null
+++ b/drivers/net/ethernet/intel/iavf/iavf_adv_rss.h
@@ -0,0 +1,25 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+/* Copyright (c) 2021, Intel Corporation. */
+
+#ifndef _IAVF_ADV_RSS_H_
+#define _IAVF_ADV_RSS_H_
+
+struct iavf_adapter;
+
+/* State of advanced RSS configuration */
+enum iavf_adv_rss_state_t {
+ IAVF_ADV_RSS_ADD_REQUEST, /* User requests to add RSS */
+ IAVF_ADV_RSS_ADD_PENDING, /* RSS pending add by the PF */
+ IAVF_ADV_RSS_DEL_REQUEST, /* Driver requests to delete RSS */
+ IAVF_ADV_RSS_DEL_PENDING, /* RSS pending delete by the PF */
+ IAVF_ADV_RSS_ACTIVE, /* RSS configuration is active */
+};
+
+/* bookkeeping of advanced RSS configuration */
+struct iavf_adv_rss {
+ enum iavf_adv_rss_state_t state;
+ struct list_head list;
+
+ struct virtchnl_rss_cfg cfg_msg;
+};
+#endif /* _IAVF_ADV_RSS_H_ */