From: Gordon@dpdk.org, Noonan@dpdk.org, gordon.noonan@intel.com
To: dev@dpdk.org
Cc: gordon.noonan@intel.com, Qi Zhang <qi.z.zhang@intel.com>
Subject: [dpdk-dev] [PATCH RFC 1/8] common/iavf: add large queue VC ops
Date: Fri, 3 Jul 2020 11:28:22 +0100 [thread overview]
Message-ID: <20200703102829.52581-2-gordon.noonan@intel.com> (raw)
In-Reply-To: <20200703102829.52581-1-gordon.noonan@intel.com>
From: Qi Zhang <qi.z.zhang@intel.com>
Add VC ops to support 64 queue
VIRTCHNL_OP_ENABLE_LARGE_QUEUES
VIRTCHNL_OP_DISABLE_LARGE_QUEUES
VIRTCHNL_OP_CONFIG_LARGE_IRQ_MAP
Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
---
drivers/common/iavf/virtchnl.h | 59 ++++++++++++++++++++++++++++++++++
1 file changed, 59 insertions(+)
diff --git a/drivers/common/iavf/virtchnl.h b/drivers/common/iavf/virtchnl.h
index 79515ee8b..5b0455fb4 100644
--- a/drivers/common/iavf/virtchnl.h
+++ b/drivers/common/iavf/virtchnl.h
@@ -140,6 +140,9 @@ enum virtchnl_ops {
VIRTCHNL_OP_ADD_FDIR_FILTER = 47,
VIRTCHNL_OP_DEL_FDIR_FILTER = 48,
VIRTCHNL_OP_QUERY_FDIR_FILTER = 49,
+ VIRTCHNL_OP_ENABLE_LARGE_QUEUES = 50,
+ VIRTCHNL_OP_DISABLE_LARGE_QUEUES = 51,
+ VIRTCHNL_OP_CONFIG_LARGE_IRQ_MAP = 52,
};
/* These macros are used to generate compilation errors if a structure/union
@@ -258,6 +261,7 @@ VIRTCHNL_CHECK_STRUCT_LEN(16, virtchnl_vsi_resource);
#define VIRTCHNL_VF_OFFLOAD_RX_FLEX_DESC 0X04000000
#define VIRTCHNL_VF_OFFLOAD_ADV_RSS_PF 0X08000000
#define VIRTCHNL_VF_OFFLOAD_FDIR_PF 0X10000000
+#define VIRTCHNL_VF_OFFLOAD_LARGE_VF 0X20000000
/* 0X80000000 is reserved */
/* Define below the capability flags that are not offloads */
@@ -396,6 +400,18 @@ struct virtchnl_vector_map {
VIRTCHNL_CHECK_STRUCT_LEN(12, virtchnl_vector_map);
+struct virtchnl_large_vector_map {
+ u64 rxq_map;
+ u64 txq_map;
+ u16 vsi_id;
+ u16 vector_id;
+ u16 rxitr_idx;
+ u16 txitr_idx;
+};
+
+VIRTCHNL_CHECK_STRUCT_LEN(24, virtchnl_large_vector_map);
+
+
struct virtchnl_irq_map_info {
u16 num_vectors;
struct virtchnl_vector_map vecmap[1];
@@ -403,6 +419,14 @@ struct virtchnl_irq_map_info {
VIRTCHNL_CHECK_STRUCT_LEN(14, virtchnl_irq_map_info);
+struct virtchnl_large_irq_map_info {
+ u16 num_vectors;
+ struct virtchnl_large_vector_map vecmap[1];
+};
+
+VIRTCHNL_CHECK_STRUCT_LEN(32, virtchnl_large_irq_map_info);
+
+
/* VIRTCHNL_OP_ENABLE_QUEUES
* VIRTCHNL_OP_DISABLE_QUEUES
* VF sends these message to enable or disable TX/RX queue pairs.
@@ -423,6 +447,16 @@ struct virtchnl_queue_select {
VIRTCHNL_CHECK_STRUCT_LEN(12, virtchnl_queue_select);
+struct virtchnl_large_queue_select {
+ u64 rx_queues;
+ u64 tx_queues;
+ u16 vsi_id;
+ u16 pad;
+};
+
+VIRTCHNL_CHECK_STRUCT_LEN(24, virtchnl_large_queue_select);
+
+
/* VIRTCHNL_OP_ADD_ETH_ADDR
* VF sends this message in order to add one or more unicast or multicast
* address filters for the specified VSI.
@@ -771,6 +805,10 @@ enum virtchnl_vector_limits {
VIRTCHNL_OP_ENABLE_CHANNELS_MAX =
((u16)(~0) - sizeof(struct virtchnl_tc_info)) /
sizeof(struct virtchnl_channel_info),
+
+ VIRTCHNL_OP_CONFIG_LARGE_IRQ_MAP_MAX =
+ ((u16)(~0) - sizeof(struct virtchnl_large_irq_map_info)) /
+ sizeof(struct virtchnl_large_vector_map),
};
/* VF reset states - these are written into the RSTAT register:
@@ -1163,10 +1201,31 @@ virtchnl_vc_validate_vf_msg(struct virtchnl_version_info *ver, u32 v_opcode,
sizeof(struct virtchnl_vector_map));
}
break;
+ case VIRTCHNL_OP_CONFIG_LARGE_IRQ_MAP:
+ valid_len = sizeof(struct virtchnl_large_irq_map_info);
+ if (msglen >= valid_len) {
+ struct virtchnl_large_irq_map_info *vimi =
+ (struct virtchnl_large_irq_map_info *)msg;
+
+ if (vimi->num_vectors == 0 || vimi->num_vectors >
+ VIRTCHNL_OP_CONFIG_LARGE_IRQ_MAP_MAX) {
+ err_msg_format = true;
+ break;
+ }
+
+ valid_len += (vimi->num_vectors *
+ sizeof(struct virtchnl_large_vector_map));
+ }
+ break;
+
case VIRTCHNL_OP_ENABLE_QUEUES:
case VIRTCHNL_OP_DISABLE_QUEUES:
valid_len = sizeof(struct virtchnl_queue_select);
break;
+ case VIRTCHNL_OP_ENABLE_LARGE_QUEUES:
+ case VIRTCHNL_OP_DISABLE_LARGE_QUEUES:
+ valid_len = sizeof(struct virtchnl_large_queue_select);
+ break;
case VIRTCHNL_OP_ADD_ETH_ADDR:
case VIRTCHNL_OP_DEL_ETH_ADDR:
valid_len = sizeof(struct virtchnl_ether_addr_list);
--
2.17.1
next prev parent reply other threads:[~2020-07-03 14:37 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-03 10:28 [dpdk-dev] [PATCH RFC 0/8] net/iavf: Enable 256 queues Gordon, Noonan, gordon.noonan
2020-07-03 10:28 ` Gordon, Noonan, gordon.noonan [this message]
2020-07-03 10:28 ` [dpdk-dev] [PATCH RFC 2/8] net/iavf: support 64 queues Gordon, Noonan, gordon.noonan
2020-07-03 10:28 ` [dpdk-dev] [PATCH RFC 3/8] common/iavf: add large vsi queue config Gordon, Noonan, gordon.noonan
2020-07-03 10:28 ` [dpdk-dev] [PATCH RFC 4/8] net/iavf: support > 256 lut table size Gordon, Noonan, gordon.noonan
2020-07-03 10:28 ` [dpdk-dev] [PATCH RFC 5/8] Support dst ip only for RSS Gordon, Noonan, gordon.noonan
2020-07-03 10:28 ` [dpdk-dev] [PATCH RFC 6/8] ICE: Enable advanced RSS for PPPoE Gordon, Noonan, gordon.noonan
2020-07-03 10:28 ` [dpdk-dev] [PATCH RFC 7/8] Update/Add support for RSS on 5 Tuple Flows for GTPU encapsulated packets (AVF) Gordon, Noonan, gordon.noonan
2020-07-03 10:28 ` [dpdk-dev] [PATCH RFC 8/8] net/iavf: fix gtpu ip udp issue Gordon, Noonan, gordon.noonan
2020-07-03 11:16 [dpdk-dev] [PATCH RFC 0/8] net/iavf: Enable 256 queues Gordon, Noonan, gordon.noonan
2020-07-03 11:16 ` [dpdk-dev] [PATCH RFC 1/8] common/iavf: add large queue VC ops Gordon, Noonan, gordon.noonan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200703102829.52581-2-gordon.noonan@intel.com \
--to=gordon@dpdk.org \
--cc=Noonan@dpdk.org \
--cc=dev@dpdk.org \
--cc=gordon.noonan@intel.com \
--cc=qi.z.zhang@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).