get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 49470,
    "url": "http://patches.dpdk.org/api/patches/49470/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20190107153829.34047-7-vipin.varghese@intel.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": "<20190107153829.34047-7-vipin.varghese@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20190107153829.34047-7-vipin.varghese@intel.com",
    "date": "2019-01-07T15:38:28",
    "name": "[v8,6/7] app/procinfo: add support for show mempool",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "62372a25e9790b2857389538e158b0babb0c8e3b",
    "submitter": {
        "id": 882,
        "url": "http://patches.dpdk.org/api/people/882/?format=api",
        "name": "Varghese, Vipin",
        "email": "vipin.varghese@intel.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/20190107153829.34047-7-vipin.varghese@intel.com/mbox/",
    "series": [
        {
            "id": 3028,
            "url": "http://patches.dpdk.org/api/series/3028/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=3028",
            "date": "2019-01-07T15:38:22",
            "name": "app/proc-info: enhance debug of proc-info tool",
            "version": 8,
            "mbox": "http://patches.dpdk.org/series/3028/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/49470/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/49470/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 E286D1B51C;\n\tMon,  7 Jan 2019 10:42:05 +0100 (CET)",
            "from mga03.intel.com (mga03.intel.com [134.134.136.65])\n\tby dpdk.org (Postfix) with ESMTP id 957121B515\n\tfor <dev@dpdk.org>; Mon,  7 Jan 2019 10:42:04 +0100 (CET)",
            "from orsmga005.jf.intel.com ([10.7.209.41])\n\tby orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t07 Jan 2019 01:42:04 -0800",
            "from unknown (HELO saesrv02-S2600CWR.intel.com) ([10.224.122.203])\n\tby orsmga005.jf.intel.com with ESMTP; 07 Jan 2019 01:42:01 -0800"
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.56,450,1539673200\"; d=\"scan'208\";a=\"289445033\"",
        "From": "Vipin Varghese <vipin.varghese@intel.com>",
        "To": "dev@dpdk.org,\n\tthomas@monjalon.net",
        "Cc": "reshma.pattan@intel.com, john.mcnamara@intel.com, amol.patel@intel.com, \n\tstephen@networkplumber.org, konstantin.ananyev@intel.com,\n\tjasvinder.singh@intel.com, Vipin Varghese <vipin.varghese@intel.com>",
        "Date": "Mon,  7 Jan 2019 21:08:28 +0530",
        "Message-Id": "<20190107153829.34047-7-vipin.varghese@intel.com>",
        "X-Mailer": "git-send-email 2.17.1",
        "In-Reply-To": "<20190107153829.34047-1-vipin.varghese@intel.com>",
        "References": "<20181213050842.64587-1-vipin.varghese@intel.com>\n\t<20190107153829.34047-1-vipin.varghese@intel.com>",
        "Subject": "[dpdk-dev] [PATCH v8 6/7] app/procinfo: add support for show mempool",
        "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": "Function show_mempool is used for displaying valid MEMPOOL.\nIn case of invalid or no name, whole list is dump.\n\nSigned-off-by: Vipin Varghese <vipin.varghese@intel.com>\nAcked-by: Reshma  Pattan <reshma.pattan@intel.com>\nAcked-by: John McNamara <john.mcnamara@intel.com>\n---\n app/proc-info/main.c           | 65 +++++++++++++++++++++++++++++++++-\n doc/guides/tools/proc_info.rst |  7 +++-\n 2 files changed, 70 insertions(+), 2 deletions(-)",
    "diff": "diff --git a/app/proc-info/main.c b/app/proc-info/main.c\nindex ed136d828..4aeab926d 100644\n--- a/app/proc-info/main.c\n+++ b/app/proc-info/main.c\n@@ -85,6 +85,9 @@ static uint32_t enable_shw_crypto;\n /**< Enable show ring. */\n static uint32_t enable_shw_ring;\n static char *ring_name;\n+/**< Enable show mempool. */\n+static uint32_t enable_shw_mempool;\n+static char *mempool_name;\n \n /**< display usage */\n static void\n@@ -108,7 +111,8 @@ proc_info_usage(const char *prgname)\n \t\t\"  --show-port: to display ports information\\n\"\n \t\t\"  --show-tm: to display traffic manager information for ports\\n\"\n \t\t\"  --show-crypto: to display crypto information\\n\"\n-\t\t\"  --show-ring[=name]: to display ring information\\n\",\n+\t\t\"  --show-ring[=name]: to display ring information\\n\"\n+\t\t\"  --show-mempool[=name]: to display mempool information\\n\",\n \t\tprgname);\n }\n \n@@ -219,6 +223,7 @@ proc_info_parse_args(int argc, char **argv)\n \t\t{\"show-tm\", 0, NULL, 0},\n \t\t{\"show-crypto\", 0, NULL, 0},\n \t\t{\"show-ring\", optional_argument, NULL, 0},\n+\t\t{\"show-mempool\", optional_argument, NULL, 0},\n \t\t{NULL, 0, 0, 0}\n \t};\n \n@@ -275,6 +280,10 @@ proc_info_parse_args(int argc, char **argv)\n \t\t\t\t\t\"show-ring\", MAX_LONG_OPT_SZ)) {\n \t\t\t\tenable_shw_ring = 1;\n \t\t\t\tring_name = optarg;\n+\t\t\t} else if (!strncmp(long_option[option_index].name,\n+\t\t\t\t\t\"show-mempool\", MAX_LONG_OPT_SZ)) {\n+\t\t\t\tenable_shw_mempool = 1;\n+\t\t\t\tmempool_name = optarg;\n \t\t\t}\n \t\t\tbreak;\n \t\tcase 1:\n@@ -1118,6 +1127,58 @@ show_ring(char *name)\n \tSTATS_BDR_STR(50, \"\");\n }\n \n+static void\n+show_mempool(char *name)\n+{\n+\tuint64_t flags = 0;\n+\n+\tsnprintf(bdr_str, MAX_STRING_LEN, \" show - MEMPOOL %\"PRIu64,\n+\t\t\trte_get_tsc_hz());\n+\tSTATS_BDR_STR(10, bdr_str);\n+\n+\tif (name != NULL) {\n+\t\tstruct rte_mempool *ptr = rte_mempool_lookup(name);\n+\t\tif (ptr != NULL) {\n+\t\t\tflags = ptr->flags;\n+\t\t\tprintf(\"  - Name: %s on socket %d\\n\"\n+\t\t\t\t\"  - flags:\\n\"\n+\t\t\t\t\"\\t  -- No spread (%c)\\n\"\n+\t\t\t\t\"\\t  -- No cache align (%c)\\n\"\n+\t\t\t\t\"\\t  -- SP put (%c), SC get (%c)\\n\"\n+\t\t\t\t\"\\t  -- Pool created (%c)\\n\"\n+\t\t\t\t\"\\t  -- No IOVA config (%c)\\n\",\n+\t\t\t\tptr->name,\n+\t\t\t\tptr->socket_id,\n+\t\t\t\t(flags & MEMPOOL_F_NO_SPREAD) ? 'y' : 'n',\n+\t\t\t\t(flags & MEMPOOL_F_NO_CACHE_ALIGN) ? 'y' : 'n',\n+\t\t\t\t(flags & MEMPOOL_F_SP_PUT) ? 'y' : 'n',\n+\t\t\t\t(flags & MEMPOOL_F_SC_GET) ? 'y' : 'n',\n+\t\t\t\t(flags & MEMPOOL_F_POOL_CREATED) ? 'y' : 'n',\n+\t\t\t\t(flags & MEMPOOL_F_NO_IOVA_CONTIG) ? 'y' : 'n');\n+\t\t\tprintf(\"  - Size %u Cache %u element %u\\n\"\n+\t\t\t\t\"  - header %u trailer %u\\n\"\n+\t\t\t\t\"  - private data size %u\\n\",\n+\t\t\t\tptr->size,\n+\t\t\t\tptr->cache_size,\n+\t\t\t\tptr->elt_size,\n+\t\t\t\tptr->header_size,\n+\t\t\t\tptr->trailer_size,\n+\t\t\t\tptr->private_data_size);\n+\t\t\tprintf(\"  - memezone - socket %d\\n\",\n+\t\t\t\tptr->mz->socket_id);\n+\t\t\tprintf(\"  - Count: avail (%u), in use (%u)\\n\",\n+\t\t\t\trte_mempool_avail_count(ptr),\n+\t\t\t\trte_mempool_in_use_count(ptr));\n+\n+\t\t\tSTATS_BDR_STR(50, \"\");\n+\t\t\treturn;\n+\t\t}\n+\t}\n+\n+\trte_mempool_list_dump(stdout);\n+\tSTATS_BDR_STR(50, \"\");\n+}\n+\n int\n main(int argc, char **argv)\n {\n@@ -1207,6 +1268,8 @@ main(int argc, char **argv)\n \t\tshow_crypto();\n \tif (enable_shw_ring)\n \t\tshow_ring(ring_name);\n+\tif (enable_shw_mempool)\n+\t\tshow_mempool(mempool_name);\n \n \tret = rte_eal_cleanup();\n \tif (ret)\ndiff --git a/doc/guides/tools/proc_info.rst b/doc/guides/tools/proc_info.rst\nindex ba5c3dbd1..42c5d45e0 100644\n--- a/doc/guides/tools/proc_info.rst\n+++ b/doc/guides/tools/proc_info.rst\n@@ -19,7 +19,7 @@ The application has a number of command line options:\n \n    ./$(RTE_TARGET)/app/dpdk-procinfo -- -m | [-p PORTMASK] [--stats | --xstats |\n    --stats-reset | --xstats-reset] [ --show-port | --show-tm | --show-crypto |\n-   --show-ring[=name] ]\n+   --show-ring[=name] | --show-mempool[=name] ]\n \n Parameters\n ~~~~~~~~~~\n@@ -60,6 +60,11 @@ The show-ring pararmeter display current allocation of all ring with\n debug information. Specifying the name allows to display details for specific\n ring. For invalid or no ring name, whole list is dump.\n \n+**--show-mempool[=name]**\n+The show-mempool parameter display current allocation of all mempool\n+debug information. Specifying the name allows to display details for specific\n+specific mempool. For invalid or no mempool name, whole list is dump.\n+\n Limitations\n -----------\n \n",
    "prefixes": [
        "v8",
        "6/7"
    ]
}