Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/25991/?format=api
https://patches.dpdk.org/api/patches/25991/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/patch/1498748282-69914-4-git-send-email-wei.dai@intel.com/", "project": { "id": 1, "url": "https://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": "<1498748282-69914-4-git-send-email-wei.dai@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/1498748282-69914-4-git-send-email-wei.dai@intel.com", "date": "2017-06-29T14:58:00", "name": "[dpdk-dev,v4,3/5] net/i40e: add support of reset", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "a8a9e5c65ab9820e5d904de11958d0f63b63388a", "submitter": { "id": 490, "url": "https://patches.dpdk.org/api/people/490/?format=api", "name": "Wei Dai", "email": "wei.dai@intel.com" }, "delegate": null, "mbox": "https://patches.dpdk.org/project/dpdk/patch/1498748282-69914-4-git-send-email-wei.dai@intel.com/mbox/", "series": [], "comments": "https://patches.dpdk.org/api/patches/25991/comments/", "check": "success", "checks": "https://patches.dpdk.org/api/patches/25991/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@dpdk.org", "Delivered-To": "patchwork@dpdk.org", "Received": [ "from [92.243.14.124] (localhost [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id D722358CE;\n\tThu, 29 Jun 2017 17:08:23 +0200 (CEST)", "from mga01.intel.com (mga01.intel.com [192.55.52.88])\n\tby dpdk.org (Postfix) with ESMTP id 78BF539EA\n\tfor <dev@dpdk.org>; Thu, 29 Jun 2017 17:08:18 +0200 (CEST)", "from fmsmga002.fm.intel.com ([10.253.24.26])\n\tby fmsmga101.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t29 Jun 2017 08:08:18 -0700", "from dpdk6.bj.intel.com ([172.16.182.81])\n\tby fmsmga002.fm.intel.com with ESMTP; 29 Jun 2017 08:08:15 -0700" ], "X-ExtLoop1": "1", "X-IronPort-AV": "E=Sophos; i=\"5.40,281,1496127600\"; d=\"scan'208\";\n\ta=\"1188552270\"", "From": "Wei Dai <wei.dai@intel.com>", "To": "thomas@monjalon.net, wenzhuo.lu@intel.com,\n\tkonstantin.ananyev@intel.com, helin.zhang@intel.com,\n\tjingjing.wu@intel.com, yuan.pntel.com@dpdk.org", "Cc": "dev@dpdk.org,\n\tWei Dai <wei.dai@intel.com>", "Date": "Thu, 29 Jun 2017 22:58:00 +0800", "Message-Id": "<1498748282-69914-4-git-send-email-wei.dai@intel.com>", "X-Mailer": "git-send-email 2.7.4", "In-Reply-To": "<1498748282-69914-1-git-send-email-wei.dai@intel.com>", "References": "<20170629083404.1271-1-wei.dai@intel.com>\n\t<1498748282-69914-1-git-send-email-wei.dai@intel.com>", "Subject": "[dpdk-dev] [PATCH v4 3/5] net/i40e: add support of reset", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "DPDK patches and discussions <dev.dpdk.org>", "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://dpdk.org/ml/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "Reset a NIC by calling dev_uninit() and then dev_init().\nGo through the same way in NIC PCI remove without release\nof ethdev resource and then NIC PCI probe function without\nethdev resource allocation.\n\nSigned-off-by: Wei Dai <wei.dai@intel.com>\n---\n drivers/net/i40e/i40e_ethdev.c | 16 ++++++++++++++++\n drivers/net/i40e/i40e_ethdev_vf.c | 16 ++++++++++++++++\n 2 files changed, 32 insertions(+)", "diff": "diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c\nindex 4ee1113..7694957 100644\n--- a/drivers/net/i40e/i40e_ethdev.c\n+++ b/drivers/net/i40e/i40e_ethdev.c\n@@ -250,6 +250,7 @@ static int i40e_dev_configure(struct rte_eth_dev *dev);\n static int i40e_dev_start(struct rte_eth_dev *dev);\n static void i40e_dev_stop(struct rte_eth_dev *dev);\n static void i40e_dev_close(struct rte_eth_dev *dev);\n+static int i40e_dev_reset(struct rte_eth_dev *dev);\n static void i40e_dev_promiscuous_enable(struct rte_eth_dev *dev);\n static void i40e_dev_promiscuous_disable(struct rte_eth_dev *dev);\n static void i40e_dev_allmulticast_enable(struct rte_eth_dev *dev);\n@@ -449,6 +450,7 @@ static const struct eth_dev_ops i40e_eth_dev_ops = {\n \t.dev_start = i40e_dev_start,\n \t.dev_stop = i40e_dev_stop,\n \t.dev_close = i40e_dev_close,\n+\t.dev_reset = i40e_dev_reset,\n \t.promiscuous_enable = i40e_dev_promiscuous_enable,\n \t.promiscuous_disable = i40e_dev_promiscuous_disable,\n \t.allmulticast_enable = i40e_dev_allmulticast_enable,\n@@ -2135,6 +2137,20 @@ i40e_dev_close(struct rte_eth_dev *dev)\n \tI40E_WRITE_FLUSH(hw);\n }\n \n+static int\n+i40e_dev_reset(struct rte_eth_dev *dev)\n+{\n+\tint ret;\n+\n+\tret = eth_i40e_dev_uninit(dev);\n+\tif (ret)\n+\t\treturn ret;\n+\n+\tret = eth_i40e_dev_init(dev);\n+\n+\treturn ret;\n+}\n+\n static void\n i40e_dev_promiscuous_enable(struct rte_eth_dev *dev)\n {\ndiff --git a/drivers/net/i40e/i40e_ethdev_vf.c b/drivers/net/i40e/i40e_ethdev_vf.c\nindex 2d5a9b5..bf287a0 100644\n--- a/drivers/net/i40e/i40e_ethdev_vf.c\n+++ b/drivers/net/i40e/i40e_ethdev_vf.c\n@@ -123,6 +123,7 @@ static void i40evf_vlan_offload_set(struct rte_eth_dev *dev, int mask);\n static int i40evf_vlan_pvid_set(struct rte_eth_dev *dev, uint16_t pvid,\n \t\t\t\tint on);\n static void i40evf_dev_close(struct rte_eth_dev *dev);\n+static int i40evf_dev_reset(struct rte_eth_dev *dev);\n static void i40evf_dev_promiscuous_enable(struct rte_eth_dev *dev);\n static void i40evf_dev_promiscuous_disable(struct rte_eth_dev *dev);\n static void i40evf_dev_allmulticast_enable(struct rte_eth_dev *dev);\n@@ -204,6 +205,7 @@ static const struct eth_dev_ops i40evf_eth_dev_ops = {\n \t.xstats_get_names = i40evf_dev_xstats_get_names,\n \t.xstats_reset = i40evf_dev_xstats_reset,\n \t.dev_close = i40evf_dev_close,\n+\t.dev_reset = i40evf_dev_reset,\n \t.dev_infos_get = i40evf_dev_info_get,\n \t.dev_supported_ptypes_get = i40e_dev_supported_ptypes_get,\n \t.vlan_filter_set = i40evf_vlan_filter_set,\n@@ -2347,6 +2349,20 @@ i40evf_dev_close(struct rte_eth_dev *dev)\n }\n \n static int\n+i40evf_dev_reset(struct rte_eth_dev *dev)\n+{\n+\tint ret;\n+\n+\tret = i40evf_dev_uninit(dev);\n+\tif (ret)\n+\t\treturn ret;\n+\n+\tret = i40evf_dev_init(dev);\n+\n+\treturn ret;\n+}\n+\n+static int\n i40evf_get_rss_lut(struct i40e_vsi *vsi, uint8_t *lut, uint16_t lut_size)\n {\n \tstruct i40e_vf *vf = I40E_VSI_TO_VF(vsi);\n", "prefixes": [ "dpdk-dev", "v4", "3/5" ] }{ "id": 25991, "url": "