Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/94313/?format=api
https://patches.dpdk.org/api/patches/94313/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/patch/20210617081449.2045195-1-ferruh.yigit@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": "<20210617081449.2045195-1-ferruh.yigit@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20210617081449.2045195-1-ferruh.yigit@intel.com", "date": "2021-06-17T08:14:46", "name": "[RFC,1/4] test/virtual_pmd: enable getting device operations", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "a9dadef357af792df51b7c416cae9cfdcb54747f", "submitter": { "id": 324, "url": "https://patches.dpdk.org/api/people/324/?format=api", "name": "Ferruh Yigit", "email": "ferruh.yigit@intel.com" }, "delegate": { "id": 1, "url": "https://patches.dpdk.org/api/users/1/?format=api", "username": "tmonjalo", "first_name": "Thomas", "last_name": "Monjalon", "email": "thomas@monjalon.net" }, "mbox": "https://patches.dpdk.org/project/dpdk/patch/20210617081449.2045195-1-ferruh.yigit@intel.com/mbox/", "series": [ { "id": 17368, "url": "https://patches.dpdk.org/api/series/17368/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=17368", "date": "2021-06-17T08:14:46", "name": "[RFC,1/4] test/virtual_pmd: enable getting device operations", "version": 1, "mbox": "https://patches.dpdk.org/series/17368/mbox/" } ], "comments": "https://patches.dpdk.org/api/patches/94313/comments/", "check": "success", "checks": "https://patches.dpdk.org/api/patches/94313/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 mails.dpdk.org (mails.dpdk.org [217.70.189.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 6AAD2A0C4D;\n\tThu, 17 Jun 2021 10:14:56 +0200 (CEST)", "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id E03024067A;\n\tThu, 17 Jun 2021 10:14:55 +0200 (CEST)", "from mga03.intel.com (mga03.intel.com [134.134.136.65])\n by mails.dpdk.org (Postfix) with ESMTP id 5F20B40150\n for <dev@dpdk.org>; Thu, 17 Jun 2021 10:14:54 +0200 (CEST)", "from fmsmga002.fm.intel.com ([10.253.24.26])\n by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 17 Jun 2021 01:14:52 -0700", "from silpixa00399752.ir.intel.com (HELO\n silpixa00399752.ger.corp.intel.com) ([10.237.222.27])\n by fmsmga002.fm.intel.com with ESMTP; 17 Jun 2021 01:14:51 -0700" ], "IronPort-SDR": [ "\n lAaLtq/LFtnYB0mFzqC+i0ZNJkHCJeIvGkcldi7nDsC1HJ/crk4yae5os8rxS+vBB5sc4jYaei\n oKiIXVvESHTg==", "\n bEu8IQfULqLTFH0G/yct4KQCahXObLqTGGuhPnbd7oKK9YtzleY6ho2tP5xfDZ5Et5NbQZQiWV\n eSrDOz8EC6wQ==" ], "X-IronPort-AV": [ "E=McAfee;i=\"6200,9189,10017\"; a=\"206361068\"", "E=Sophos;i=\"5.83,280,1616482800\"; d=\"scan'208\";a=\"206361068\"", "E=Sophos;i=\"5.83,280,1616482800\"; d=\"scan'208\";a=\"488573244\"" ], "X-ExtLoop1": "1", "From": "Ferruh Yigit <ferruh.yigit@intel.com>", "To": "dev@dpdk.org", "Cc": "Ferruh Yigit <ferruh.yigit@intel.com>", "Date": "Thu, 17 Jun 2021 09:14:46 +0100", "Message-Id": "<20210617081449.2045195-1-ferruh.yigit@intel.com>", "X-Mailer": "git-send-email 2.31.1", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[dpdk-dev] [RFC 1/4] test/virtual_pmd: enable getting device\n operations", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.29", "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": "This will be used to overwrite the dev_ops for various tests.\n\nSigned-off-by: Ferruh Yigit <ferruh.yigit@intel.com>\n---\n app/test/virtual_pmd.c | 14 ++++++++++++--\n app/test/virtual_pmd.h | 6 ++++++\n 2 files changed, 18 insertions(+), 2 deletions(-)", "diff": "diff --git a/app/test/virtual_pmd.c b/app/test/virtual_pmd.c\nindex 7036f401ed95..4d6ce302a563 100644\n--- a/app/test/virtual_pmd.c\n+++ b/app/test/virtual_pmd.c\n@@ -350,8 +350,8 @@ virtual_ethdev_rx_burst_success(void *queue __rte_unused,\n \n static uint16_t\n virtual_ethdev_rx_burst_fail(void *queue __rte_unused,\n-\t\t\t\t\t\t\t struct rte_mbuf **bufs __rte_unused,\n-\t\t\t\t\t\t\t uint16_t nb_pkts __rte_unused)\n+\t\tstruct rte_mbuf **bufs __rte_unused,\n+\t\tuint16_t nb_pkts __rte_unused)\n {\n \treturn 0;\n }\n@@ -614,3 +614,13 @@ virtual_ethdev_create(const char *name, struct rte_ether_addr *mac_addr,\n \n \treturn -1;\n }\n+\n+struct eth_dev_ops *\n+virtual_ethdev_ops_get(uint16_t port_id)\n+{\n+\tstruct rte_eth_dev *dev = &rte_eth_devices[port_id];\n+\tstruct virtual_ethdev_private *dev_private = dev->data->dev_private;\n+\tstruct eth_dev_ops *dev_ops = &dev_private->dev_ops;\n+\n+\treturn dev_ops;\n+}\ndiff --git a/app/test/virtual_pmd.h b/app/test/virtual_pmd.h\nindex 120b58b27395..517dd0d2efa6 100644\n--- a/app/test/virtual_pmd.h\n+++ b/app/test/virtual_pmd.h\n@@ -70,6 +70,12 @@ void\n virtual_ethdev_tx_burst_fn_set_tx_pkt_fail_count(uint16_t port_id,\n \t\tuint8_t packet_fail_count);\n \n+/* Let application get dev_ops to be able to overwrite some operations\n+ * per the specific test needs.\n+ */\n+struct eth_dev_ops *\n+virtual_ethdev_ops_get(uint16_t port_id);\n+\n #ifdef __cplusplus\n }\n #endif\n", "prefixes": [ "RFC", "1/4" ] }{ "id": 94313, "url": "