get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/126163/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 126163,
    "url": "http://patchwork.dpdk.org/api/patches/126163/?format=api",
    "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/20230412162636.30843-7-doshir@vmware.com/",
    "project": {
        "id": 1,
        "url": "http://patchwork.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": "<20230412162636.30843-7-doshir@vmware.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20230412162636.30843-7-doshir@vmware.com",
    "date": "2023-04-12T16:26:35",
    "name": "[next,6/7] vmxnet3: avoid updating rxprod register frequently",
    "commit_ref": null,
    "pull_url": null,
    "state": "changes-requested",
    "archived": true,
    "hash": "ddb9969df4924cda648ab784fda4249eaa3989c1",
    "submitter": {
        "id": 3045,
        "url": "http://patchwork.dpdk.org/api/people/3045/?format=api",
        "name": "Ronak Doshi",
        "email": "doshir@vmware.com"
    },
    "delegate": {
        "id": 319,
        "url": "http://patchwork.dpdk.org/api/users/319/?format=api",
        "username": "fyigit",
        "first_name": "Ferruh",
        "last_name": "Yigit",
        "email": "ferruh.yigit@amd.com"
    },
    "mbox": "http://patchwork.dpdk.org/project/dpdk/patch/20230412162636.30843-7-doshir@vmware.com/mbox/",
    "series": [
        {
            "id": 27734,
            "url": "http://patchwork.dpdk.org/api/series/27734/?format=api",
            "web_url": "http://patchwork.dpdk.org/project/dpdk/list/?series=27734",
            "date": "2023-04-12T16:26:29",
            "name": "vmxnet3: upgrade to version 7",
            "version": 1,
            "mbox": "http://patchwork.dpdk.org/series/27734/mbox/"
        }
    ],
    "comments": "http://patchwork.dpdk.org/api/patches/126163/comments/",
    "check": "warning",
    "checks": "http://patchwork.dpdk.org/api/patches/126163/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 CA7454296B;\n\tMon, 17 Apr 2023 10:15:34 +0200 (CEST)",
            "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id DC4D242D1A;\n\tMon, 17 Apr 2023 10:15:08 +0200 (CEST)",
            "from EX-PRD-EDGE01.vmware.com (EX-PRD-EDGE01.vmware.com\n [208.91.3.33]) by mails.dpdk.org (Postfix) with ESMTP id 32379410F2\n for <dev@dpdk.org>; Wed, 12 Apr 2023 18:26:47 +0200 (CEST)",
            "from sc9-mailhost1.vmware.com (10.113.161.71) by\n EX-PRD-EDGE01.vmware.com (10.188.245.6) with Microsoft SMTP Server id\n 15.1.2375.34; Wed, 12 Apr 2023 09:26:33 -0700",
            "from htb-1n-eng-dhcp122.eng.vmware.com (unknown [10.20.114.216])\n by sc9-mailhost1.vmware.com (Postfix) with ESMTP id 4F911201E4;\n Wed, 12 Apr 2023 09:26:39 -0700 (PDT)",
            "by htb-1n-eng-dhcp122.eng.vmware.com (Postfix, from userid 0)\n id 4AD68A8385; Wed, 12 Apr 2023 09:26:39 -0700 (PDT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; s=s1024; d=vmware.com;\n h=from:to:cc:subject:date:message-id:in-reply-to:mime-version:\n content-type; bh=7Qp9gpCa7+IRbcrytySuRMSJQVWMKDOipHc3Nx3mocs=;\n b=ZZ1C4qrEO3hCn7Qe1pc9LgyQaVNU8mh9ceYdTGm/SMmcxqhm18isv4kbAH2eY8\n Ikan0RfrPms3/UVFNJHv5XGfZRNMJfOyOjgxz/M3FXcronER1Euhr95MNf2y8i\n pBdMiTGCMMrsLRC3hVPZbK1CLGi3vJKmg2W/8Uj7s9mudQ0=",
        "From": "Ronak Doshi <doshir@vmware.com>",
        "To": "Jochen Behrens <jbehrens@vmware.com>",
        "CC": "<dev@dpdk.org>, Ronak Doshi <doshir@vmware.com>",
        "Subject": "[PATCH next 6/7] vmxnet3: avoid updating rxprod register frequently",
        "Date": "Wed, 12 Apr 2023 09:26:35 -0700",
        "Message-ID": "<20230412162636.30843-7-doshir@vmware.com>",
        "X-Mailer": "git-send-email 2.11.0",
        "In-Reply-To": "<20230412162636.30843-1-doshir@vmware.com>",
        "References": "<20230412162636.30843-1-doshir@vmware.com>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain",
        "Received-SPF": "None (EX-PRD-EDGE01.vmware.com: doshir@vmware.com does not\n designate permitted sender hosts)",
        "X-Mailman-Approved-At": "Mon, 17 Apr 2023 10:15:01 +0200",
        "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"
    },
    "content": "When UPT is enabled, the driver updates rxprod register to\nlet the device know that it has processed the received packets\nand new buffers are available. However, updating it too\nfrequently can lead to reduced performance.\n\nThis patch adds code to avoid updating the register frequently.\n\nSigned-off-by: Ronak Doshi <doshir@vmware.com>\nAcked-by: Jochen Behrens <jbehrens@vmware.com>\n---\n drivers/net/vmxnet3/vmxnet3_rxtx.c | 14 +++++++++-----\n 1 file changed, 9 insertions(+), 5 deletions(-)",
    "diff": "diff --git a/drivers/net/vmxnet3/vmxnet3_rxtx.c b/drivers/net/vmxnet3/vmxnet3_rxtx.c\nindex 7bbae4177e..39ad0726cb 100644\n--- a/drivers/net/vmxnet3/vmxnet3_rxtx.c\n+++ b/drivers/net/vmxnet3/vmxnet3_rxtx.c\n@@ -1007,7 +1007,8 @@ vmxnet3_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)\n \n \t\t/* It's time to renew descriptors */\n \t\tvmxnet3_renew_desc(rxq, ring_idx, newm);\n-\t\tif (unlikely(rxq->shared->ctrl.updateRxProd)) {\n+\t\tif (unlikely(rxq->shared->ctrl.updateRxProd &&\n+\t\t\t (rxq->cmd_ring[ring_idx].next2fill & 0xf) == 0)) {\n \t\t\tVMXNET3_WRITE_BAR0_REG(hw, hw->rx_prod_offset[ring_idx] +\n \t\t\t\t\t       (rxq->queue_id * VMXNET3_REG_ALIGN),\n \t\t\t\t\t       rxq->cmd_ring[ring_idx].next2fill);\n@@ -1027,18 +1028,21 @@ vmxnet3_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)\n \n \tif (unlikely(nb_rxd == 0)) {\n \t\tuint32_t avail;\n+\t\tuint32_t posted = 0;\n \t\tfor (ring_idx = 0; ring_idx < VMXNET3_RX_CMDRING_SIZE; ring_idx++) {\n \t\t\tavail = vmxnet3_cmd_ring_desc_avail(&rxq->cmd_ring[ring_idx]);\n \t\t\tif (unlikely(avail > 0)) {\n \t\t\t\t/* try to alloc new buf and renew descriptors */\n-\t\t\t\tvmxnet3_post_rx_bufs(rxq, ring_idx);\n+\t\t\t\tif (vmxnet3_post_rx_bufs(rxq, ring_idx) > 0)\n+\t\t\t\t\tposted |= (1 << ring_idx);\n \t\t\t}\n \t\t}\n \t\tif (unlikely(rxq->shared->ctrl.updateRxProd)) {\n \t\t\tfor (ring_idx = 0; ring_idx < VMXNET3_RX_CMDRING_SIZE; ring_idx++) {\n-\t\t\t\tVMXNET3_WRITE_BAR0_REG(hw, hw->rx_prod_offset[ring_idx] +\n-\t\t\t\t\t\t       (rxq->queue_id * VMXNET3_REG_ALIGN),\n-\t\t\t\t\t\t       rxq->cmd_ring[ring_idx].next2fill);\n+\t\t\t\tif (posted & (1 << ring_idx))\n+\t\t\t\t\tVMXNET3_WRITE_BAR0_REG(hw, hw->rx_prod_offset[ring_idx] +\n+\t\t\t\t\t\t\t       (rxq->queue_id * VMXNET3_REG_ALIGN),\n+\t\t\t\t\t\t\t       rxq->cmd_ring[ring_idx].next2fill);\n \t\t\t}\n \t\t}\n \t}\n",
    "prefixes": [
        "next",
        "6/7"
    ]
}