Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/66677/?format=api
http://patches.dpdk.org/api/patches/66677/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/20200316074603.10998-4-leyi.rong@intel.com/", "project": { "id": 1, "url": "http://patches.dpdk.org/api/projects/1/?format=api", "name": "DPDK", "link_name": "dpdk", "list_id": "dev.dpdk.org", "list_email": "dev@dpdk.org", "web_url": "http://core.dpdk.org", "scm_url": "git://dpdk.org/dpdk", "webscm_url": "http://git.dpdk.org/dpdk", "list_archive_url": "https://inbox.dpdk.org/dev", "list_archive_url_format": "https://inbox.dpdk.org/dev/{}", "commit_url_format": "" }, "msgid": "<20200316074603.10998-4-leyi.rong@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20200316074603.10998-4-leyi.rong@intel.com", "date": "2020-03-16T07:45:54", "name": "[03/12] net/iavf: support to query DDP package info", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "b9cce3d70c4fee9edf48b38b90816e0f0b0d59d2", "submitter": { "id": 1204, "url": "http://patches.dpdk.org/api/people/1204/?format=api", "name": "Leyi Rong", "email": "leyi.rong@intel.com" }, "delegate": { "id": 31221, "url": "http://patches.dpdk.org/api/users/31221/?format=api", "username": "yexl", "first_name": "xiaolong", "last_name": "ye", "email": "xiaolong.ye@intel.com" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/20200316074603.10998-4-leyi.rong@intel.com/mbox/", "series": [ { "id": 8918, "url": "http://patches.dpdk.org/api/series/8918/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=8918", "date": "2020-03-16T07:45:51", "name": "framework for advanced iAVF PMD", "version": 1, "mbox": "http://patches.dpdk.org/series/8918/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/66677/comments/", "check": "fail", "checks": "http://patches.dpdk.org/api/patches/66677/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@inbox.dpdk.org", "Delivered-To": "patchwork@inbox.dpdk.org", "Received": [ "from dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id A9EB5A0559;\n\tMon, 16 Mar 2020 08:57:51 +0100 (CET)", "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 90AAC1C08D;\n\tMon, 16 Mar 2020 08:57:30 +0100 (CET)", "from mga18.intel.com (mga18.intel.com [134.134.136.126])\n by dpdk.org (Postfix) with ESMTP id 1EEA01C06A\n for <dev@dpdk.org>; Mon, 16 Mar 2020 08:57:26 +0100 (CET)", "from orsmga004.jf.intel.com ([10.7.209.38])\n by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 16 Mar 2020 00:57:26 -0700", "from dpdk-lrong-srv-04.sh.intel.com ([10.67.119.221])\n by orsmga004.jf.intel.com with ESMTP; 16 Mar 2020 00:57:25 -0700" ], "IronPort-SDR": [ "\n QBvniYpGsOct322qb8lwN5VHiK4BUsYgsGh1gdoFUyxjFzkth2LL7yztqhTbWIhF0nuw4dp4w/\n EGc9/j0+BVaA==", "\n 54EX9LF2IsH/i2YkCVicTDx3C8C5Cn6EHNP/5LbnVgAimD0svmMKXRg3txYkGISSBI5DQ/QLMZ\n Sdxk87AZoC1A==" ], "X-Amp-Result": "SKIPPED(no attachment in message)", "X-Amp-File-Uploaded": "False", "X-ExtLoop1": "1", "X-IronPort-AV": "E=Sophos;i=\"5.70,559,1574150400\"; d=\"scan'208\";a=\"390622495\"", "From": "Leyi Rong <leyi.rong@intel.com>", "To": "qi.z.zhang@intel.com,\n\txiaolong.ye@intel.com", "Cc": "dev@dpdk.org,\n\tLeyi Rong <leyi.rong@intel.com>", "Date": "Mon, 16 Mar 2020 15:45:54 +0800", "Message-Id": "<20200316074603.10998-4-leyi.rong@intel.com>", "X-Mailer": "git-send-email 2.17.1", "In-Reply-To": "<20200316074603.10998-1-leyi.rong@intel.com>", "References": "<20200316074603.10998-1-leyi.rong@intel.com>", "Subject": "[dpdk-dev] [PATCH 03/12] net/iavf: support to query DDP package info", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "DPDK patches and discussions <dev.dpdk.org>", "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://mails.dpdk.org/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "Advanced iAVF supports to query DDP package info, includes\npackage version, track id, package name, device serial number\nand the list of protocols that the PF supports.\n\nSigned-off-by: Leyi Rong <leyi.rong@intel.com>\n---\n drivers/net/iavf/iavf.h | 9 ++++++++\n drivers/net/iavf/iavf_ethdev.c | 7 ++++++\n drivers/net/iavf/iavf_vchnl.c | 41 +++++++++++++++++++++++++++++++++-\n 3 files changed, 56 insertions(+), 1 deletion(-)", "diff": "diff --git a/drivers/net/iavf/iavf.h b/drivers/net/iavf/iavf.h\nindex 526040c6e..39c6eeec9 100644\n--- a/drivers/net/iavf/iavf.h\n+++ b/drivers/net/iavf/iavf.h\n@@ -67,6 +67,13 @@\n #define IAVF_48_BIT_WIDTH (CHAR_BIT * 6)\n #define IAVF_48_BIT_MASK RTE_LEN2MASK(IAVF_48_BIT_WIDTH, uint64_t)\n \n+/* VF supported comms protocols 64-bits bitmap */\n+#define IAVF_COMMS_PROTO_GTP 0x0000000000000001\n+#define IAVF_COMMS_PROTO_PPPOE 0x0000000000000002\n+#define IAVF_COMMS_PROTO_PFCP 0x0000000000000004\n+#define IAVF_COMMS_PROTO_L2TPV3 0x0000000000000008\n+#define IAVF_COMMS_PROTO_ESP 0x0000000000000010\n+\n struct iavf_adapter;\n struct iavf_rx_queue;\n struct iavf_tx_queue;\n@@ -97,6 +104,7 @@ struct iavf_info {\n \tstruct virtchnl_version_info virtchnl_version;\n \tstruct virtchnl_vf_resource *vf_res; /* VF resource */\n \tstruct virtchnl_vsi_resource *vsi_res; /* LAN VSI */\n+\tstruct virtchnl_pkg_info pkg_info; /* package info */\n \n \tvolatile enum virtchnl_ops pend_cmd; /* pending command not finished */\n \tuint32_t cmd_retval; /* return value of the cmd response from PF */\n@@ -225,6 +233,7 @@ int iavf_disable_queues(struct iavf_adapter *adapter);\n int iavf_configure_rss_lut(struct iavf_adapter *adapter);\n int iavf_configure_rss_key(struct iavf_adapter *adapter);\n int iavf_configure_queues(struct iavf_adapter *adapter);\n+int iavf_query_package_info(struct iavf_adapter *adapter);\n int iavf_config_irq_map(struct iavf_adapter *adapter);\n void iavf_add_del_all_mac_addr(struct iavf_adapter *adapter, bool add);\n int iavf_dev_link_update(struct rte_eth_dev *dev,\ndiff --git a/drivers/net/iavf/iavf_ethdev.c b/drivers/net/iavf/iavf_ethdev.c\nindex ee9f82249..9c8f789da 100644\n--- a/drivers/net/iavf/iavf_ethdev.c\n+++ b/drivers/net/iavf/iavf_ethdev.c\n@@ -1236,6 +1236,13 @@ iavf_init_vf(struct rte_eth_dev *dev)\n \t\t\tgoto err_rss;\n \t\t}\n \t}\n+\n+\tif (vf->vf_res->vf_cap_flags & VIRTCHNL_VF_OFFLOAD_QUERY_DDP) {\n+\t\tif (iavf_query_package_info(adapter) != 0) {\n+\t\t\tPMD_INIT_LOG(ERR, \"iavf_query_package_info failed\");\n+\t\t\tgoto err_rss;\n+\t\t}\n+\t}\n \treturn 0;\n err_rss:\n \trte_free(vf->rss_key);\ndiff --git a/drivers/net/iavf/iavf_vchnl.c b/drivers/net/iavf/iavf_vchnl.c\nindex b7fb05d32..288d34e8b 100644\n--- a/drivers/net/iavf/iavf_vchnl.c\n+++ b/drivers/net/iavf/iavf_vchnl.c\n@@ -88,6 +88,7 @@ iavf_execute_vf_cmd(struct iavf_adapter *adapter, struct iavf_cmd_info *args)\n \t\tbreak;\n \tcase VIRTCHNL_OP_VERSION:\n \tcase VIRTCHNL_OP_GET_VF_RESOURCES:\n+\tcase VIRTCHNL_OP_PACKAGE_INFO:\n \t\t/* for init virtchnl ops, need to poll the response */\n \t\tdo {\n \t\t\tret = iavf_read_msg_from_pf(adapter, args->out_size,\n@@ -338,7 +339,8 @@ iavf_get_vf_resource(struct iavf_adapter *adapter)\n \t * add advanced/optional offload capabilities\n \t */\n \n-\tcaps = IAVF_BASIC_OFFLOAD_CAPS | VIRTCHNL_VF_CAP_ADV_LINK_SPEED;\n+\tcaps = IAVF_BASIC_OFFLOAD_CAPS | VIRTCHNL_VF_CAP_ADV_LINK_SPEED |\n+\t\tVIRTCHNL_VF_OFFLOAD_QUERY_DDP;\n \n \targs.in_args = (uint8_t *)∩︀\n \targs.in_args_size = sizeof(caps);\n@@ -586,6 +588,43 @@ iavf_configure_queues(struct iavf_adapter *adapter)\n \treturn err;\n }\n \n+int\n+iavf_query_package_info(struct iavf_adapter *adapter)\n+{\n+\tstruct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(adapter);\n+\tstruct iavf_cmd_info args;\n+\tint ret;\n+\n+\targs.ops = VIRTCHNL_OP_PACKAGE_INFO;\n+\targs.in_args = NULL;\n+\targs.in_args_size = 0;\n+\targs.out_buffer = vf->aq_resp;\n+\targs.out_size = IAVF_AQ_BUF_SZ;\n+\n+\tret = iavf_execute_vf_cmd(adapter, &args);\n+\tif (ret) {\n+\t\tPMD_DRV_LOG(ERR,\n+\t\t\t \"Failed to execute command of OP_PACKAGE_INFO\");\n+\t\treturn ret;\n+\t}\n+\n+\trte_memcpy(&vf->pkg_info, args.out_buffer,\n+\t\t sizeof(struct virtchnl_pkg_info));\n+\tPMD_DRV_LOG(NOTICE, \"pkg version is %d.%d.%d.%d, pkg name is %s,\"\n+\t\t \" track id is %x, serial number is %02x%02x%02x%02x\"\n+\t\t \"%02x%02x%02x%02x, proto_metadata is 0x%016lx\\n\",\n+\t\t vf->pkg_info.p_ver.major, vf->pkg_info.p_ver.minor,\n+\t\t vf->pkg_info.p_ver.update, vf->pkg_info.p_ver.draft,\n+\t\t vf->pkg_info.pkg_name, vf->pkg_info.track_id,\n+\t\t vf->pkg_info.dsn[7], vf->pkg_info.dsn[6],\n+\t\t vf->pkg_info.dsn[5], vf->pkg_info.dsn[4],\n+\t\t vf->pkg_info.dsn[3], vf->pkg_info.dsn[2],\n+\t\t vf->pkg_info.dsn[1], vf->pkg_info.dsn[0],\n+\t\t vf->pkg_info.proto_metadata);\n+\n+\treturn 0;\n+}\n+\n int\n iavf_config_irq_map(struct iavf_adapter *adapter)\n {\n", "prefixes": [ "03/12" ] }{ "id": 66677, "url": "