Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/54382/?format=api
http://patches.dpdk.org/api/patches/54382/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/20190605081005.15716-5-maxime.coquelin@redhat.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": "<20190605081005.15716-5-maxime.coquelin@redhat.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20190605081005.15716-5-maxime.coquelin@redhat.com", "date": "2019-06-05T08:10:05", "name": "[v2,4/4] net/virtio: remove useless pointers checks", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "5ac61db7346a3012e994f7036cae577d6b23847f", "submitter": { "id": 512, "url": "http://patches.dpdk.org/api/people/512/?format=api", "name": "Maxime Coquelin", "email": "maxime.coquelin@redhat.com" }, "delegate": { "id": 2642, "url": "http://patches.dpdk.org/api/users/2642/?format=api", "username": "mcoquelin", "first_name": "Maxime", "last_name": "Coquelin", "email": "maxime.coquelin@redhat.com" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/20190605081005.15716-5-maxime.coquelin@redhat.com/mbox/", "series": [ { "id": 4899, "url": "http://patches.dpdk.org/api/series/4899/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=4899", "date": "2019-06-05T08:10:01", "name": "net/virtio: Fix packet segmentation bug", "version": 2, "mbox": "http://patches.dpdk.org/series/4899/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/54382/comments/", "check": "fail", "checks": "http://patches.dpdk.org/api/patches/54382/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 [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 4C1851B9C4;\n\tWed, 5 Jun 2019 10:10:31 +0200 (CEST)", "from mx1.redhat.com (mx1.redhat.com [209.132.183.28])\n\tby dpdk.org (Postfix) with ESMTP id 42A371B9B0;\n\tWed, 5 Jun 2019 10:10:27 +0200 (CEST)", "from smtp.corp.redhat.com\n\t(int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13])\n\t(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))\n\t(No client certificate requested)\n\tby mx1.redhat.com (Postfix) with ESMTPS id ADFCE4DB10;\n\tWed, 5 Jun 2019 08:10:26 +0000 (UTC)", "from localhost.localdomain (ovpn-112-53.ams2.redhat.com\n\t[10.36.112.53])\n\tby smtp.corp.redhat.com (Postfix) with ESMTP id 0D7BE5F7C0;\n\tWed, 5 Jun 2019 08:10:24 +0000 (UTC)" ], "From": "Maxime Coquelin <maxime.coquelin@redhat.com>", "To": "dev@dpdk.org, ybrustin@cisco.com, tiwei.bie@intel.com,\n\tjfreimann@redhat.com", "Cc": "stable@dpdk.org,\n\tMaxime Coquelin <maxime.coquelin@redhat.com>", "Date": "Wed, 5 Jun 2019 10:10:05 +0200", "Message-Id": "<20190605081005.15716-5-maxime.coquelin@redhat.com>", "In-Reply-To": "<20190605081005.15716-1-maxime.coquelin@redhat.com>", "References": "<20190605081005.15716-1-maxime.coquelin@redhat.com>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "X-Scanned-By": "MIMEDefang 2.79 on 10.5.11.13", "X-Greylist": "Sender IP whitelisted, not delayed by milter-greylist-4.5.16\n\t(mx1.redhat.com [10.5.110.29]); Wed, 05 Jun 2019 08:10:26 +0000 (UTC)", "Subject": "[dpdk-dev] [PATCH v2 4/4] net/virtio: remove useless pointers checks", "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\t<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\t<mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "This patch removes uses checks on 'prev' pointer, as it\nis always set before with a valid value.\n\nSigned-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>\n---\n drivers/net/virtio/virtio_rxtx.c | 15 ++++-----------\n 1 file changed, 4 insertions(+), 11 deletions(-)", "diff": "diff --git a/drivers/net/virtio/virtio_rxtx.c b/drivers/net/virtio/virtio_rxtx.c\nindex 33dbc78906..fabd2e31d5 100644\n--- a/drivers/net/virtio/virtio_rxtx.c\n+++ b/drivers/net/virtio/virtio_rxtx.c\n@@ -1517,9 +1517,7 @@ virtio_recv_pkts_inorder(void *rx_queue,\n \n \t\t\trx_pkts[nb_rx]->pkt_len += (uint32_t)(len[i]);\n \n-\t\t\tif (prev)\n-\t\t\t\tprev->next = rxm;\n-\n+\t\t\tprev->next = rxm;\n \t\t\tprev = rxm;\n \t\t\tseg_res -= 1;\n \t\t}\n@@ -1703,9 +1701,7 @@ virtio_recv_mergeable_pkts(void *rx_queue,\n \t\t\trx_pkts[nb_rx]->pkt_len += (uint32_t)(len[i]);\n \t\t\trx_pkts[nb_rx]->data_len += (uint16_t)(len[i]);\n \n-\t\t\tif (prev)\n-\t\t\t\tprev->next = rxm;\n-\n+\t\t\tprev->next = rxm;\n \t\t\tprev = rxm;\n \t\t\tseg_res -= 1;\n \t\t}\n@@ -1879,9 +1875,7 @@ virtio_recv_mergeable_pkts_packed(void *rx_queue,\n \t\t\trx_pkts[nb_rx]->pkt_len += (uint32_t)(len[i]);\n \t\t\trx_pkts[nb_rx]->data_len += (uint16_t)(len[i]);\n \n-\t\t\tif (prev)\n-\t\t\t\tprev->next = rxm;\n-\n+\t\t\tprev->next = rxm;\n \t\t\tprev = rxm;\n \t\t\tseg_res -= 1;\n \t\t}\n@@ -1924,8 +1918,7 @@ virtio_recv_mergeable_pkts_packed(void *rx_queue,\n \t\t} else {\n \t\t\tPMD_RX_LOG(ERR,\n \t\t\t\t\t\"No enough segments for packet.\");\n-\t\t\tif (prev)\n-\t\t\t\tvirtio_discard_rxbuf(vq, prev);\n+\t\t\tvirtio_discard_rxbuf(vq, prev);\n \t\t\trxvq->stats.errors++;\n \t\t\tbreak;\n \t\t}\n", "prefixes": [ "v2", "4/4" ] }{ "id": 54382, "url": "