get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 92185,
    "url": "http://patches.dpdk.org/api/patches/92185/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20210426163310.1043438-1-kda@semihalf.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": "<20210426163310.1043438-1-kda@semihalf.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20210426163310.1043438-1-kda@semihalf.com",
    "date": "2021-04-26T16:33:10",
    "name": "[RFC] test/distributor: fix burst flush on worker quit",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "5b8d7823e13aa52dc2f1089f92dcb35fa2f09dd3",
    "submitter": {
        "id": 2179,
        "url": "http://patches.dpdk.org/api/people/2179/?format=api",
        "name": "Stanislaw Kardach",
        "email": "kda@semihalf.com"
    },
    "delegate": {
        "id": 1,
        "url": "http://patches.dpdk.org/api/users/1/?format=api",
        "username": "tmonjalo",
        "first_name": "Thomas",
        "last_name": "Monjalon",
        "email": "thomas@monjalon.net"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/20210426163310.1043438-1-kda@semihalf.com/mbox/",
    "series": [
        {
            "id": 16681,
            "url": "http://patches.dpdk.org/api/series/16681/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=16681",
            "date": "2021-04-26T16:33:10",
            "name": "[RFC] test/distributor: fix burst flush on worker quit",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/16681/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/92185/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/92185/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 28EF4A0548;\n\tMon, 26 Apr 2021 18:33:53 +0200 (CEST)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 9C1D241110;\n\tMon, 26 Apr 2021 18:33:52 +0200 (CEST)",
            "from mail-lj1-f180.google.com (mail-lj1-f180.google.com\n [209.85.208.180])\n by mails.dpdk.org (Postfix) with ESMTP id C2F5C41104\n for <dev@dpdk.org>; Mon, 26 Apr 2021 18:33:51 +0200 (CEST)",
            "by mail-lj1-f180.google.com with SMTP id b38so23692674ljf.5\n for <dev@dpdk.org>; Mon, 26 Apr 2021 09:33:51 -0700 (PDT)",
            "from toster.int.semihalf.com (89-73-146-138.dynamic.chello.pl.\n [89.73.146.138])\n by smtp.gmail.com with ESMTPSA id f11sm52692ljo.57.2021.04.26.09.33.50\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Mon, 26 Apr 2021 09:33:50 -0700 (PDT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=semihalf-com.20150623.gappssmtp.com; s=20150623;\n h=from:to:cc:subject:date:message-id:mime-version\n :content-transfer-encoding;\n bh=LeqeWJNw9pB2LQwGRgR99CfhuH62rRZ79qXJnhkf3eE=;\n b=CJoZqJ7kREiAdHtYsLm3ATSW3CHxc3wTxRliP2y44PKCLWg/t7xqNYVIgQM9410LzZ\n lwT01iMfUnIl59MiSmR6mf+ddSau2FL3EAYvvXUfXWIgH7APE/d73icB2236VG3hhuF+\n ELPcSkdwrnq082A+ZQ45tIz48LAvord/sWv11MiwX3u8bZ6l/YNIrbucXPuXLyiH5weQ\n lwF513Fw0WIHzG4fyCHNGXIgLOjzAnmE5++8T2swVwFJ3GOqfocSxaa3Tm3mzJOvi/Ov\n NNTxksj+Zt7o4eFsHM/jFk3W3m29H/mkmZkqR+Qy8ZFU3WM7wsPbWxrALBIibTdCtv6h\n +9nA==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20161025;\n h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version\n :content-transfer-encoding;\n bh=LeqeWJNw9pB2LQwGRgR99CfhuH62rRZ79qXJnhkf3eE=;\n b=I/WcYBEPPVx7hUjRTZXpixo6p74bXZzttp79hG2kZtHh9nZ/S00p3+dH9PEVuXP0Uv\n JiilEFdtXkBiPNFDnGWao+Jb6Y0QBNHmReJxdqIlXIBa31xVyY6Ue63buzYyA+obVd5l\n H+uqzjxWIHh1UQ8CCqUiFqGZn4Zp7TST/SJX4sjHD4EzEniN6fK+7yQmQZFbKZ/lHTxQ\n 4vh1gv7yCujdbdkQB6dEjByIZR6VZiPQ1MmPeEUM3Th322Ubx+ItdVMYk6NTjT6xQkD3\n kB+6a98HoPMd1T8CkMHah1X/ygGDujks+kXUVQ+Y4qhXxI10S1c3Is1tutQ5V5vx886P\n SEYw==",
        "X-Gm-Message-State": "AOAM530rEI1tMFVQtCvDMRpD2Yeirp5uMtc5MkJxKECmqkpvdTuiqBOK\n RY47GvW1HpV13ApfvIt3xqSPug==",
        "X-Google-Smtp-Source": "\n ABdhPJyW/wBZCAaqct/Vo07XIKAGNfsGX83AnTlxufye+caTmmxnqlIgyCE+MLj4/VPZCmIIbD9USw==",
        "X-Received": "by 2002:a2e:bf19:: with SMTP id\n c25mr13788165ljr.201.1619454831148;\n Mon, 26 Apr 2021 09:33:51 -0700 (PDT)",
        "From": "Stanislaw Kardach <kda@semihalf.com>",
        "To": "David Hunt <david.hunt@intel.com>,\n\tdev@dpdk.org",
        "Cc": "upstream@semihalf.com, Stanislaw Kardach <kda@semihalf.com>,\n l.wojciechow@partner.samsung.com,\n David Marchand <david.marchand@redhat.com>",
        "Date": "Mon, 26 Apr 2021 18:33:10 +0200",
        "Message-Id": "<20210426163310.1043438-1-kda@semihalf.com>",
        "X-Mailer": "git-send-email 2.27.0",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [RFC PATCH] test/distributor: fix burst flush on worker\n quit",
        "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": "While working on RISC-V port I have encountered a situation where worker\nthreads get stuck in the rte_distributor_return_pkt() function in the\nburst test.\nAfter investigation some of the threads enter this function with\nflag RTE_DISTRIB_GET_BUF set in the d->retptr64[0]. At the same time\nmain thread has already passed rte_distributor_process() so nobody will\nclear this flag and hence workers can't return.\n\nWhat I've noticed is that adding a flush just after the last _process(),\nsimilarly to how quit_workers() function is written in the\ntest_distributor.c fixes the issue.\nAdditionally the issue disappears when I remove the rdtsc delay code\ninside the rte_distributor_request_pkt().\nHowever I can't get this to reproduce on x86 (even with SIMD forced\noff) and with artificial delays, which is why I wonder whether I'm not\nactually hiding some other issue.\n\nLooking at the implementation of the distributor, it is based on\n__atomic_* builtins and the only platform related bit in the fast-path\nis the rte_rdtsc() and rte_pause(). There may be some issues in the\ntoolchain (I've tried so far with the Ubuntu one - 10.2.0-8ubuntu1).\nI should add that all unit tests for distributor are passing so either\nthere's some coverage corner case or the implementation works on RISC-V.\nAs for RDTSC I'm using a sleep-stable time counter with 1MHz frequency\nand switching to high resolution cycle counter also removes the issue\nbut that's the same as removing the rdtsc delay as mentioned above.\n\nI'd love to hear from You if this fix makes any sense.\n\nWhile modifying this test, I've also pulled in a fix from\ntest_distributor.c which ensures that each thread gets his own wakeup\npacket as it's possible that when sending a burst of packets, they won't\nbe spread over all the workers.\n\nSigned-off-by: Stanislaw Kardach <kda@semihalf.com>\nFixes: 7c3287a10535 (\"test/distributor: add performance test for burst mode\")\nCc: david.hunt@intel.com\nCc: l.wojciechow@partner.samsung.com\nCc: David Marchand <david.marchand@redhat.com>\n---\n app/test/test_distributor_perf.c | 6 ++++--\n 1 file changed, 4 insertions(+), 2 deletions(-)",
    "diff": "diff --git a/app/test/test_distributor_perf.c b/app/test/test_distributor_perf.c\nindex b25f79a34..fdbeae6d2 100644\n--- a/app/test/test_distributor_perf.c\n+++ b/app/test/test_distributor_perf.c\n@@ -188,13 +188,15 @@ quit_workers(struct rte_distributor *d, struct rte_mempool *p)\n \trte_mempool_get_bulk(p, (void *)bufs, num_workers);\n \n \tquit = 1;\n-\tfor (i = 0; i < num_workers; i++)\n+\tfor (i = 0; i < num_workers; i++) {\n \t\tbufs[i]->hash.usr = i << 1;\n-\trte_distributor_process(d, bufs, num_workers);\n+\t\trte_distributor_process(d, &bufs[i], 1);\n+\t}\n \n \trte_mempool_put_bulk(p, (void *)bufs, num_workers);\n \n \trte_distributor_process(d, NULL, 0);\n+\trte_distributor_flush(d);\n \trte_eal_mp_wait_lcore();\n \tquit = 0;\n \tworker_idx = 0;\n",
    "prefixes": [
        "RFC"
    ]
}