get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 49203,
    "url": "http://patches.dpdk.org/api/patches/49203/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1f284decd3c8d5398d6d0fb5ef7cc024562dc219.1545325395.git.gaetan.rivet@6wind.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": "<1f284decd3c8d5398d6d0fb5ef7cc024562dc219.1545325395.git.gaetan.rivet@6wind.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1f284decd3c8d5398d6d0fb5ef7cc024562dc219.1545325395.git.gaetan.rivet@6wind.com",
    "date": "2018-12-20T17:06:42",
    "name": "[v1,3/8] option: add usage string",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "b9a608bb08b8d57ee95a2de596b0bd87fbc7fced",
    "submitter": {
        "id": 269,
        "url": "http://patches.dpdk.org/api/people/269/?format=api",
        "name": "Gaëtan Rivet",
        "email": "gaetan.rivet@6wind.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/1f284decd3c8d5398d6d0fb5ef7cc024562dc219.1545325395.git.gaetan.rivet@6wind.com/mbox/",
    "series": [
        {
            "id": 2907,
            "url": "http://patches.dpdk.org/api/series/2907/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=2907",
            "date": "2018-12-20T17:06:39",
            "name": "Clean up rte_option",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/2907/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/49203/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/49203/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 35D3A1BDAC;\n\tThu, 20 Dec 2018 18:07:22 +0100 (CET)",
            "from mail-wr1-f67.google.com (mail-wr1-f67.google.com\n\t[209.85.221.67]) by dpdk.org (Postfix) with ESMTP id 8F63C1BD0F\n\tfor <dev@dpdk.org>; Thu, 20 Dec 2018 18:07:18 +0100 (CET)",
            "by mail-wr1-f67.google.com with SMTP id q18so2524437wrx.9\n\tfor <dev@dpdk.org>; Thu, 20 Dec 2018 09:07:18 -0800 (PST)",
            "from bidouze.dev.6wind.com. (host.78.145.23.62.rev.coltfrance.com.\n\t[62.23.145.78]) by smtp.gmail.com with ESMTPSA id\n\tn5sm11951688wrr.94.2018.12.20.09.07.16\n\t(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);\n\tThu, 20 Dec 2018 09:07:16 -0800 (PST)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=6wind-com.20150623.gappssmtp.com; s=20150623;\n\th=from:to:cc:subject:date:message-id:in-reply-to:references\n\t:mime-version:content-transfer-encoding;\n\tbh=TGnxPXPdq0yaEqE6pmJxxStUY2QI/1SenqJI0IH2H3c=;\n\tb=HK71wVZdaQ3ZjC/EWq0X2W+XHxTc3C70JEQCm67Xf5f9z0Zm9HnIIk8DXmP0et9OFn\n\tIzNCBjELveEcqAwuyMiQKYEmE0jY2/uBMhASgiQacZ9mFTANkmARF6GWGaIOaKz6SOfI\n\tnGaA61AEk3WViVhO9b8HrxzOctTS4uca9ett72qslctYR2GKM4UMsj//+0qy/io/eIW2\n\tF2wM4oeSi7rofmSXuXXUFfu3nWFTt0OxdYRUIt4zbC9odJJtWCgsHphQcThXKvqcykdQ\n\ttXEuZDgaL0RnlXF/c2vymsyxOLAMY/R/zJLr/BtbLMW0XEjpkn26Qy14SynbHvS54UrW\n\trD2Q==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n\t:references:mime-version:content-transfer-encoding;\n\tbh=TGnxPXPdq0yaEqE6pmJxxStUY2QI/1SenqJI0IH2H3c=;\n\tb=Ral5pr//cTY6Hy6KqdoP2Y0byY6San83hleGf9L41nge0EoH+JNI7yftBHkg+3fdVB\n\tUK4jY86XoAkYP7kUMtzkxSdxAvOjlMhpgdte710MdagInJdPrvsLLQY5nQwQYa9beuty\n\tRBxjIdOI+WrkjFr3OGjjQh7URDutlvo8rjlLG5xHWAOfZ3n1/rboP6+FWNP86FEE/zV6\n\t0ytXDK0WUFYPYAHbwudae+4xhUw24FJLUGH72TqMTrFJvDN4hNCjYUKVSN6tFDMQt6cR\n\tnMO1JuGuu9ml1rtajtyKrYmRrKfQAbB2moYMhrNSNyEoaMw6il7QjB9voGMHPe52paHK\n\tQ7Gg==",
        "X-Gm-Message-State": "AA+aEWbEh0HdPR9VcNcgkLsYbarIxppG0TqjoBztlS0mZY9i5shhmjrU\n\tIBFSChTFigCtJDyGFJTcR8A2djarcOQ=",
        "X-Google-Smtp-Source": "AFSGD/XIFSyjfae1DjEpn1nHyWfThMei2aEEIcVoU7bih2Q0pebDv8Hg59d12mHzdvnt5R28b3um+w==",
        "X-Received": "by 2002:adf:c7cc:: with SMTP id\n\ty12mr24290538wrg.52.1545325637739; \n\tThu, 20 Dec 2018 09:07:17 -0800 (PST)",
        "From": "Gaetan Rivet <gaetan.rivet@6wind.com>",
        "To": "dev@dpdk.org",
        "Cc": "Gaetan Rivet <gaetan.rivet@6wind.com>",
        "Date": "Thu, 20 Dec 2018 18:06:42 +0100",
        "Message-Id": "<1f284decd3c8d5398d6d0fb5ef7cc024562dc219.1545325395.git.gaetan.rivet@6wind.com>",
        "X-Mailer": "git-send-email 2.19.1",
        "In-Reply-To": "<cover.1545325395.git.gaetan.rivet@6wind.com>",
        "References": "<cover.1545325395.git.gaetan.rivet@6wind.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [PATCH v1 3/8] option: add usage string",
        "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": "Add a usage string field in rte_option, allowing to display\nhelp to the user and describe which options are currently available.\n\nSigned-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>\n---\n lib/librte_eal/common/eal_common_options.c |  1 +\n lib/librte_eal/common/eal_private.h        |  7 +++++++\n lib/librte_eal/common/include/rte_option.h |  1 +\n lib/librte_eal/common/rte_option.c         | 17 +++++++++++++++++\n lib/librte_telemetry/rte_telemetry.c       |  1 +\n 5 files changed, 27 insertions(+)",
    "diff": "diff --git a/lib/librte_eal/common/eal_common_options.c b/lib/librte_eal/common/eal_common_options.c\nindex 6e3a83b98..e096ac896 100644\n--- a/lib/librte_eal/common/eal_common_options.c\n+++ b/lib/librte_eal/common/eal_common_options.c\n@@ -1494,4 +1494,5 @@ eal_common_usage(void)\n \t       \"  --\"OPT_NO_HPET\"           Disable HPET\\n\"\n \t       \"  --\"OPT_NO_SHCONF\"         No shared config (mmap'd files)\\n\"\n \t       \"\\n\", RTE_MAX_LCORE);\n+\trte_option_usage();\n }\ndiff --git a/lib/librte_eal/common/eal_private.h b/lib/librte_eal/common/eal_private.h\nindex 442c6dc48..50ab58385 100644\n--- a/lib/librte_eal/common/eal_private.h\n+++ b/lib/librte_eal/common/eal_private.h\n@@ -370,4 +370,11 @@ rte_option_parse(const char *opt);\n void\n rte_option_init(void);\n \n+/**\n+ * Iterate through the registered options and show the associated\n+ * usage string.\n+ */\n+void\n+rte_option_usage(void);\n+\n #endif /* _EAL_PRIVATE_H_ */\ndiff --git a/lib/librte_eal/common/include/rte_option.h b/lib/librte_eal/common/include/rte_option.h\nindex 8957b970c..bbcc6cec9 100644\n--- a/lib/librte_eal/common/include/rte_option.h\n+++ b/lib/librte_eal/common/include/rte_option.h\n@@ -35,6 +35,7 @@ typedef int (*rte_option_cb)(void);\n struct rte_option {\n \tTAILQ_ENTRY(rte_option) next; /**< Next entry in the list. */\n \tchar *opt_str;             /**< The option name. */\n+\tconst char *usage; /**< Option summary string. */\n \trte_option_cb cb;          /**< Function called when option is used. */\n \tint enabled;               /**< Set when the option is used. */\n };\ndiff --git a/lib/librte_eal/common/rte_option.c b/lib/librte_eal/common/rte_option.c\nindex 9e233f7d2..2ed74873b 100644\n--- a/lib/librte_eal/common/rte_option.c\n+++ b/lib/librte_eal/common/rte_option.c\n@@ -61,3 +61,20 @@ rte_option_init(void)\n \t\t\toption->cb();\n \t}\n }\n+\n+void\n+rte_option_usage(void)\n+{\n+\tstruct rte_option *option;\n+\tint opt_count = 0;\n+\n+\tTAILQ_FOREACH(option, &rte_option_list, next)\n+\t\topt_count += 1;\n+\tif (opt_count == 0)\n+\t\treturn;\n+\n+\tprintf(\"EAL dynamic options:\\n\");\n+\tTAILQ_FOREACH(option, &rte_option_list, next)\n+\t\tprintf(\"  --%-*s %s\\n\", 17, option->opt_str, option->usage);\n+\tprintf(\"\\n\");\n+}\ndiff --git a/lib/librte_telemetry/rte_telemetry.c b/lib/librte_telemetry/rte_telemetry.c\nindex 3080bb715..0ba6626c1 100644\n--- a/lib/librte_telemetry/rte_telemetry.c\n+++ b/lib/librte_telemetry/rte_telemetry.c\n@@ -1799,6 +1799,7 @@ int telemetry_log_level;\n \n static struct rte_option option = {\n \t.opt_str = \"telemetry\",\n+\t.usage = \"Enable telemetry backend\",\n \t.cb = &rte_telemetry_init,\n \t.enabled = 0\n };\n",
    "prefixes": [
        "v1",
        "3/8"
    ]
}