get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 55139,
    "url": "http://patches.dpdk.org/api/patches/55139/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20190620192048.13814-9-stephen@networkplumber.org/",
    "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": "<20190620192048.13814-9-stephen@networkplumber.org>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20190620192048.13814-9-stephen@networkplumber.org",
    "date": "2019-06-20T19:20:47",
    "name": "[v5,8/9] kni: fix style issues",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "8d86195ca0b93275d1822e787fc2535fbb275019",
    "submitter": {
        "id": 27,
        "url": "http://patches.dpdk.org/api/people/27/?format=api",
        "name": "Stephen Hemminger",
        "email": "stephen@networkplumber.org"
    },
    "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/20190620192048.13814-9-stephen@networkplumber.org/mbox/",
    "series": [
        {
            "id": 5102,
            "url": "http://patches.dpdk.org/api/series/5102/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=5102",
            "date": "2019-06-20T19:20:39",
            "name": "kni: fixes and cleanups",
            "version": 5,
            "mbox": "http://patches.dpdk.org/series/5102/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/55139/comments/",
    "check": "fail",
    "checks": "http://patches.dpdk.org/api/patches/55139/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 554A61D4A6;\n\tThu, 20 Jun 2019 21:21:23 +0200 (CEST)",
            "from mail-pg1-f196.google.com (mail-pg1-f196.google.com\n\t[209.85.215.196]) by dpdk.org (Postfix) with ESMTP id 5C9611D473\n\tfor <dev@dpdk.org>; Thu, 20 Jun 2019 21:21:08 +0200 (CEST)",
            "by mail-pg1-f196.google.com with SMTP id n2so2062364pgp.11\n\tfor <dev@dpdk.org>; Thu, 20 Jun 2019 12:21:08 -0700 (PDT)",
            "from hermes.lan (204-195-22-127.wavecable.com. [204.195.22.127])\n\tby smtp.gmail.com with ESMTPSA id\n\tj11sm255703pfa.2.2019.06.20.12.21.05\n\t(version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256);\n\tThu, 20 Jun 2019 12:21:05 -0700 (PDT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=networkplumber-org.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=yQGVqm3LrM7rzZPEwpU4sXdV9MaF0Mw7W9U4PD+EN1Y=;\n\tb=xbVsoMEE6cZ90Zyl5Z46sSlZMEvKpSAgqger2l/glv0rEm5quZIqACo05baDHYdnSt\n\t6Swa6ufp1mG00OsBA9c/n2tiNjuTxmjDK5FiMnFtXjY1ZxIDI87SFSlYmML7DEy3yH4q\n\tq9cdIfzkIleBSxEVTWZAegdwAUJN1WHJIYA3wlyoTCNmy/hr7YNzfxsR2NXtjwAb7RfF\n\t3YYcManiZE7OrKxrhIvEm+sIjtj9VI3s70ysaZhUumStw7X+uHGbZwOIYYh5Wj+ThkgJ\n\thUT6aylxXTF1FVwPNwdQxH8RWk2fg6Ej+uWbuBg3WwyrdfWDvLSkQLcAvEpv98TVXJU+\n\toD+g==",
        "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=yQGVqm3LrM7rzZPEwpU4sXdV9MaF0Mw7W9U4PD+EN1Y=;\n\tb=eRdZJfGePw0GPSUDWgYeeJQh9F6dJOgDVO0GsDMok7yNrWrHCGzoIBLEHZ68q63mN1\n\tGWsb+jKEmNQzZFVZ5PktDl1TDmeWiwwX2D5yHp5w+pmNQJOj6cH6JE+lm553K4UOz/O0\n\tNMsbJACBXyvwjMifjFFagQ+YJktk/oHVe4MFU77OHRHAIGui02gBOXs0rfOVT5nlPciH\n\tKdVh5DxVlLwv/XjGn9825kdd+g7O6K3AhVDIWnthyfbwiA1aQmC39uIlpWsw2mXTZAvf\n\tV22vxTTsHYrLjUgy57bHurL7nd45JeXkKRuJbr4RBHhz4zHPZZ2rLMkKVktCvo2OS6hk\n\tNJWw==",
        "X-Gm-Message-State": "APjAAAXi/WWxq8WX+y3ugUQAenlG0y6QEeJ7lv9PyLnRYVvlXc1SbVdJ\n\t9fNR4FvYIce34PyBA+0h3Pr+jBLggX0=",
        "X-Google-Smtp-Source": "APXvYqz9iInm40BfS+JUYUPkf+HmZIdPz0yf6z3pfQ19uS899vkFMKjP2ThW4zIXEMrNu5e6Az2Gng==",
        "X-Received": "by 2002:a17:90b:d82:: with SMTP id\n\tbg2mr1271325pjb.87.1561058467292; \n\tThu, 20 Jun 2019 12:21:07 -0700 (PDT)",
        "From": "Stephen Hemminger <stephen@networkplumber.org>",
        "To": "dev@dpdk.org",
        "Cc": "Stephen Hemminger <stephen@networkplumber.org>",
        "Date": "Thu, 20 Jun 2019 12:20:47 -0700",
        "Message-Id": "<20190620192048.13814-9-stephen@networkplumber.org>",
        "X-Mailer": "git-send-email 2.20.1",
        "In-Reply-To": "<20190620192048.13814-1-stephen@networkplumber.org>",
        "References": "<20190610175155.21374-1-stephen@networkplumber.org>\n\t<20190620192048.13814-1-stephen@networkplumber.org>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [PATCH v5 8/9] kni: fix style issues",
        "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": "rte_kni does not follow standard style rules.\nNoticed some extra \\ line continuation etc.\n\nSigned-off-by: Stephen Hemminger <stephen@networkplumber.org>\n---\n kernel/linux/kni/kni_net.c |  7 ++++---\n lib/librte_kni/rte_kni.c   | 38 +++++++++++++++++++-------------------\n 2 files changed, 23 insertions(+), 22 deletions(-)",
    "diff": "diff --git a/kernel/linux/kni/kni_net.c b/kernel/linux/kni/kni_net.c\nindex 06310fec57bb..320d51d7fc83 100644\n--- a/kernel/linux/kni/kni_net.c\n+++ b/kernel/linux/kni/kni_net.c\n@@ -401,7 +401,7 @@ kni_net_rx_lo_fifo(struct kni_dev *kni)\n \t/* Get the number of entries in rx_q */\n \tnum_rq = kni_fifo_count(kni->rx_q);\n \n-\t/* Get the number of free entrie in tx_q */\n+\t/* Get the number of free entries in tx_q */\n \tnum_tq = kni_fifo_free_count(kni->tx_q);\n \n \t/* Get the number of entries in alloc_q */\n@@ -755,6 +755,7 @@ kni_net_config_lo_mode(char *lo_str)\n \t} else if (!strcmp(lo_str, \"lo_mode_fifo_skb\")) {\n \t\tpr_debug(\"loopback mode=lo_mode_fifo_skb enabled\");\n \t\tkni_net_rx_func = kni_net_rx_lo_fifo_skb;\n-\t} else\n-\t\tpr_debug(\"Incognizant parameter, loopback disabled\");\n+\t} else {\n+\t\tpr_debug(\"Unknown loopback parameter, disabled\");\n+\t}\n }\ndiff --git a/lib/librte_kni/rte_kni.c b/lib/librte_kni/rte_kni.c\nindex e29d0cc7df3c..9b6acc382fc3 100644\n--- a/lib/librte_kni/rte_kni.c\n+++ b/lib/librte_kni/rte_kni.c\n@@ -59,7 +59,7 @@ struct rte_kni {\n \tuint16_t group_id;                  /**< Group ID of KNI devices */\n \tuint32_t slot_id;                   /**< KNI pool slot ID */\n \tstruct rte_mempool *pktmbuf_pool;   /**< pkt mbuf mempool */\n-\tunsigned mbuf_size;                 /**< mbuf size */\n+\tunsigned int mbuf_size;                 /**< mbuf size */\n \n \tconst struct rte_memzone *m_tx_q;   /**< TX queue memzone */\n \tconst struct rte_memzone *m_rx_q;   /**< RX queue memzone */\n@@ -78,7 +78,7 @@ struct rte_kni {\n \t/* For request & response */\n \tstruct rte_kni_fifo *req_q;         /**< Request queue */\n \tstruct rte_kni_fifo *resp_q;        /**< Response queue */\n-\tvoid * sync_addr;                   /**< Req/Resp Mem address */\n+\tvoid *sync_addr;                   /**< Req/Resp Mem address */\n \n \tstruct rte_kni_ops ops;             /**< operations for request */\n };\n@@ -473,7 +473,7 @@ kni_config_promiscusity(uint16_t port_id, uint8_t to_on)\n int\n rte_kni_handle_request(struct rte_kni *kni)\n {\n-\tunsigned ret;\n+\tunsigned int ret;\n \tstruct rte_kni_request *req = NULL;\n \n \tif (kni == NULL)\n@@ -498,8 +498,8 @@ rte_kni_handle_request(struct rte_kni *kni)\n \t\tbreak;\n \tcase RTE_KNI_REQ_CFG_NETWORK_IF: /* Set network interface up/down */\n \t\tif (kni->ops.config_network_if)\n-\t\t\treq->result = kni->ops.config_network_if(\\\n-\t\t\t\t\tkni->ops.port_id, req->if_up);\n+\t\t\treq->result = kni->ops.config_network_if(kni->ops.port_id,\n+\t\t\t\t\t\t\t\t req->if_up);\n \t\tbreak;\n \tcase RTE_KNI_REQ_CHANGE_MAC_ADDR: /* Change MAC Address */\n \t\tif (kni->ops.config_mac_address)\n@@ -534,7 +534,7 @@ rte_kni_handle_request(struct rte_kni *kni)\n }\n \n unsigned\n-rte_kni_tx_burst(struct rte_kni *kni, struct rte_mbuf **mbufs, unsigned num)\n+rte_kni_tx_burst(struct rte_kni *kni, struct rte_mbuf **mbufs, unsigned int num)\n {\n \tvoid *phy_mbufs[num];\n \tunsigned int ret;\n@@ -552,9 +552,9 @@ rte_kni_tx_burst(struct rte_kni *kni, struct rte_mbuf **mbufs, unsigned num)\n }\n \n unsigned\n-rte_kni_rx_burst(struct rte_kni *kni, struct rte_mbuf **mbufs, unsigned num)\n+rte_kni_rx_burst(struct rte_kni *kni, struct rte_mbuf **mbufs, unsigned int num)\n {\n-\tunsigned ret = kni_fifo_get(kni->tx_q, (void **)mbufs, num);\n+\tunsigned int ret = kni_fifo_get(kni->tx_q, (void **)mbufs, num);\n \n \t/* If buffers removed, allocate mbufs and then put them into alloc_q */\n \tif (ret)\n@@ -605,7 +605,7 @@ kni_allocate_mbufs(struct rte_kni *kni)\n \t\treturn;\n \t}\n \n-\tallocq_free = (kni->alloc_q->read - kni->alloc_q->write - 1) \\\n+\tallocq_free = (kni->alloc_q->read - kni->alloc_q->write - 1)\n \t\t\t& (MAX_MBUF_BURST_NUM - 1);\n \tfor (i = 0; i < allocq_free; i++) {\n \t\tpkts[i] = rte_pktmbuf_alloc(kni->pktmbuf_pool);\n@@ -659,35 +659,35 @@ static enum kni_ops_status\n kni_check_request_register(struct rte_kni_ops *ops)\n {\n \t/* check if KNI request ops has been registered*/\n-\tif( NULL == ops )\n+\tif (ops == NULL)\n \t\treturn KNI_REQ_NO_REGISTER;\n \n-\tif ((ops->change_mtu == NULL)\n-\t\t&& (ops->config_network_if == NULL)\n-\t\t&& (ops->config_mac_address == NULL)\n-\t\t&& (ops->config_promiscusity == NULL))\n+\tif (ops->change_mtu == NULL\n+\t    && ops->config_network_if == NULL\n+\t    && ops->config_mac_address == NULL\n+\t    && ops->config_promiscusity == NULL)\n \t\treturn KNI_REQ_NO_REGISTER;\n \n \treturn KNI_REQ_REGISTERED;\n }\n \n int\n-rte_kni_register_handlers(struct rte_kni *kni,struct rte_kni_ops *ops)\n+rte_kni_register_handlers(struct rte_kni *kni, struct rte_kni_ops *ops)\n {\n \tenum kni_ops_status req_status;\n \n-\tif (NULL == ops) {\n+\tif (ops == NULL) {\n \t\tRTE_LOG(ERR, KNI, \"Invalid KNI request operation.\\n\");\n \t\treturn -1;\n \t}\n \n-\tif (NULL == kni) {\n+\tif (kni == NULL) {\n \t\tRTE_LOG(ERR, KNI, \"Invalid kni info.\\n\");\n \t\treturn -1;\n \t}\n \n \treq_status = kni_check_request_register(&kni->ops);\n-\tif ( KNI_REQ_REGISTERED == req_status) {\n+\tif (req_status == KNI_REQ_REGISTERED) {\n \t\tRTE_LOG(ERR, KNI, \"The KNI request operation has already registered.\\n\");\n \t\treturn -1;\n \t}\n@@ -699,7 +699,7 @@ rte_kni_register_handlers(struct rte_kni *kni,struct rte_kni_ops *ops)\n int\n rte_kni_unregister_handlers(struct rte_kni *kni)\n {\n-\tif (NULL == kni) {\n+\tif (kni == NULL) {\n \t\tRTE_LOG(ERR, KNI, \"Invalid kni info.\\n\");\n \t\treturn -1;\n \t}\n",
    "prefixes": [
        "v5",
        "8/9"
    ]
}