get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 13185,
    "url": "https://patches.dpdk.org/api/patches/13185/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/1464913377-30879-11-git-send-email-johndale@cisco.com/",
    "project": {
        "id": 1,
        "url": "https://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": "<1464913377-30879-11-git-send-email-johndale@cisco.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1464913377-30879-11-git-send-email-johndale@cisco.com",
    "date": "2016-06-03T00:22:54",
    "name": "[dpdk-dev,v3,10/13] enic: remove unused files and functions and variables",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "601da1dfac1341b3d7e272b0384a377db748b7c3",
    "submitter": {
        "id": 359,
        "url": "https://patches.dpdk.org/api/people/359/?format=api",
        "name": "John Daley (johndale)",
        "email": "johndale@cisco.com"
    },
    "delegate": {
        "id": 10,
        "url": "https://patches.dpdk.org/api/users/10/?format=api",
        "username": "bruce",
        "first_name": "Bruce",
        "last_name": "Richardson",
        "email": "bruce.richardson@intel.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/1464913377-30879-11-git-send-email-johndale@cisco.com/mbox/",
    "series": [],
    "comments": "https://patches.dpdk.org/api/patches/13185/comments/",
    "check": "pending",
    "checks": "https://patches.dpdk.org/api/patches/13185/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 [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id E23736A44;\n\tFri,  3 Jun 2016 02:23:26 +0200 (CEST)",
            "from alln-iport-4.cisco.com (alln-iport-4.cisco.com\n\t[173.37.142.91]) by dpdk.org (Postfix) with ESMTP id 366866883\n\tfor <dev@dpdk.org>; Fri,  3 Jun 2016 02:23:23 +0200 (CEST)",
            "from alln-core-1.cisco.com ([173.36.13.131])\n\tby alln-iport-4.cisco.com with ESMTP/TLS/DHE-RSA-AES256-SHA;\n\t03 Jun 2016 00:23:22 +0000",
            "from cisco.com (savbu-usnic-a.cisco.com [10.193.184.48])\n\tby alln-core-1.cisco.com (8.14.5/8.14.5) with ESMTP id u530NM8f028035;\n\tFri, 3 Jun 2016 00:23:22 GMT",
            "by cisco.com (Postfix, from userid 392789)\n\tid 24EED3FAADEC; Thu,  2 Jun 2016 17:23:22 -0700 (PDT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple;\n\td=cisco.com; i=@cisco.com; l=7841; q=dns/txt; s=iport;\n\tt=1464913403; x=1466123003;\n\th=from:to:cc:subject:date:message-id:in-reply-to: references;\n\tbh=ePqDaFoGwaIJr94NeO4UX8BOhFRSuZj0SIUM73muo1Y=;\n\tb=LNJL4tND9scbsdwIRhDRtoabkTi67c/iedtX0kw6vF/mYzmMdDV2P2Kd\n\tG0XiGrMKGC++dP0lpGfw95yaXym6gdPFJgCTnoIK5yz2EBsZUbV6wC+WT\n\tvS7YghJTYXDqfemFCmsUb9Clff1HhHedxHV8tq/qSp8evtBJHNRrS5+YF E=;",
        "X-IronPort-AV": "E=Sophos;i=\"5.26,409,1459814400\"; d=\"scan'208\";a=\"280244244\"",
        "From": "John Daley <johndale@cisco.com>",
        "To": "dev@dpdk.org",
        "Cc": "bruce.richarsdon@intel.com, John Daley <johndale@cisco.com>",
        "Date": "Thu,  2 Jun 2016 17:22:54 -0700",
        "Message-Id": "<1464913377-30879-11-git-send-email-johndale@cisco.com>",
        "X-Mailer": "git-send-email 2.7.0",
        "In-Reply-To": "<1464913377-30879-1-git-send-email-johndale@cisco.com>",
        "References": "<1464071579-30072-1-git-send-email-johndale@cisco.com>\n\t<1464913377-30879-1-git-send-email-johndale@cisco.com>",
        "Subject": "[dpdk-dev] [PATCH v3 10/13] enic: remove unused files and functions\n\tand variables",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "List-Id": "patches and discussions about DPDK <dev.dpdk.org>",
        "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://dpdk.org/ml/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "Remove some files, functions and variables left unused after\nTx performance improvements.\n\nSigned-off-by: John Daley <johndale@cisco.com>\n---\n drivers/net/enic/base/enic_vnic_wq.h | 63 ------------------------------------\n drivers/net/enic/base/vnic_cq.h      | 44 -------------------------\n drivers/net/enic/base/vnic_wq.c      |  4 +--\n drivers/net/enic/base/vnic_wq.h      |  6 +---\n drivers/net/enic/enic.h              |  1 -\n drivers/net/enic/enic_main.c         |  2 +-\n drivers/net/enic/enic_rxtx.c         |  1 -\n 7 files changed, 4 insertions(+), 117 deletions(-)\n delete mode 100644 drivers/net/enic/base/enic_vnic_wq.h",
    "diff": "diff --git a/drivers/net/enic/base/enic_vnic_wq.h b/drivers/net/enic/base/enic_vnic_wq.h\ndeleted file mode 100644\nindex 55c5664..0000000\n--- a/drivers/net/enic/base/enic_vnic_wq.h\n+++ /dev/null\n@@ -1,63 +0,0 @@\n-/*\n- * Copyright 2008-2015 Cisco Systems, Inc.  All rights reserved.\n- * Copyright 2007 Nuova Systems, Inc.  All rights reserved.\n- *\n- * Copyright (c) 2015, Cisco Systems, Inc.\n- * All rights reserved.\n- *\n- * Redistribution and use in source and binary forms, with or without\n- * modification, are permitted provided that the following conditions\n- * are met:\n- *\n- * 1. Redistributions of source code must retain the above copyright\n- * notice, this list of conditions and the following disclaimer.\n- *\n- * 2. Redistributions in binary form must reproduce the above copyright\n- * notice, this list of conditions and the following disclaimer in\n- * the documentation and/or other materials provided with the\n- * distribution.\n- *\n- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n- * \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS\n- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE\n- * COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,\n- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,\n- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;\n- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\n- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT\n- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN\n- * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\n- * POSSIBILITY OF SUCH DAMAGE.\n- *\n- */\n-\n-#ifndef _ENIC_VNIC_WQ_H_\n-#define _ENIC_VNIC_WQ_H_\n-\n-#include \"vnic_dev.h\"\n-#include \"vnic_cq.h\"\n-\n-static inline void enic_vnic_post_wq_index(struct vnic_wq *wq)\n-{\n-\t/* Adding write memory barrier prevents compiler and/or CPU\n-\t * reordering, thus avoiding descriptor posting before\n-\t * descriptor is initialized. Otherwise, hardware can read\n-\t * stale descriptor fields.\n-\t*/\n-\twmb();\n-\tiowrite32(wq->head_idx, &wq->ctrl->posted_index);\n-}\n-\n-static inline void enic_vnic_post_wq(struct vnic_wq *wq,\n-\t\t\t\t     void *os_buf, uint8_t cq_entry)\n-{\n-\tstruct vnic_wq_buf *buf = &wq->bufs[wq->head_idx];\n-\tbuf->mb = os_buf;\n-\twq->head_idx = enic_ring_incr(wq->ring.desc_count, wq->head_idx);\n-\n-\tif (cq_entry)\n-\t\tenic_vnic_post_wq_index(wq);\n-}\n-\n-#endif /* _ENIC_VNIC_WQ_H_ */\ndiff --git a/drivers/net/enic/base/vnic_cq.h b/drivers/net/enic/base/vnic_cq.h\nindex 922391b..13ab87c 100644\n--- a/drivers/net/enic/base/vnic_cq.h\n+++ b/drivers/net/enic/base/vnic_cq.h\n@@ -90,50 +90,6 @@ struct vnic_cq {\n #endif\n };\n \n-static inline unsigned int vnic_cq_service(struct vnic_cq *cq,\n-\tunsigned int work_to_do,\n-\tint (*q_service)(struct vnic_dev *vdev, struct cq_desc *cq_desc,\n-\tu8 type, u16 q_number, u16 completed_index, void *opaque),\n-\tvoid *opaque)\n-{\n-\tstruct cq_desc *cq_desc;\n-\tunsigned int work_done = 0;\n-\tu16 q_number, completed_index;\n-\tu8 type, color;\n-\tstruct rte_mbuf **rx_pkts = opaque;\n-\tunsigned int ret;\n-\n-\tcq_desc = (struct cq_desc *)((u8 *)cq->ring.descs +\n-\t\tcq->ring.desc_size * cq->to_clean);\n-\tcq_desc_dec(cq_desc, &type, &color,\n-\t\t&q_number, &completed_index);\n-\n-\twhile (color != cq->last_color) {\n-\t\tif (opaque)\n-\t\t\topaque = (void *)&(rx_pkts[work_done]);\n-\n-\t\tret = (*q_service)(cq->vdev, cq_desc, type,\n-\t\t\tq_number, completed_index, opaque);\n-\t\tcq->to_clean++;\n-\t\tif (cq->to_clean == cq->ring.desc_count) {\n-\t\t\tcq->to_clean = 0;\n-\t\t\tcq->last_color = cq->last_color ? 0 : 1;\n-\t\t}\n-\n-\t\tcq_desc = (struct cq_desc *)((u8 *)cq->ring.descs +\n-\t\t\tcq->ring.desc_size * cq->to_clean);\n-\t\tcq_desc_dec(cq_desc, &type, &color,\n-\t\t\t&q_number, &completed_index);\n-\n-\t\tif (ret)\n-\t\t\twork_done++;\n-\t\tif (work_done >= work_to_do)\n-\t\t\tbreak;\n-\t}\n-\n-\treturn work_done;\n-}\n-\n void vnic_cq_free(struct vnic_cq *cq);\n int vnic_cq_alloc(struct vnic_dev *vdev, struct vnic_cq *cq, unsigned int index,\n \tunsigned int socket_id,\ndiff --git a/drivers/net/enic/base/vnic_wq.c b/drivers/net/enic/base/vnic_wq.c\nindex cfef1af..9b9ff4d 100644\n--- a/drivers/net/enic/base/vnic_wq.c\n+++ b/drivers/net/enic/base/vnic_wq.c\n@@ -179,7 +179,7 @@ int vnic_wq_disable(struct vnic_wq *wq)\n }\n \n void vnic_wq_clean(struct vnic_wq *wq,\n-\tvoid (*buf_clean)(struct vnic_wq *wq, struct vnic_wq_buf *buf))\n+\t\t   void (*buf_clean)(struct vnic_wq_buf *buf))\n {\n \tstruct vnic_wq_buf *buf;\n \tunsigned int  to_clean = wq->tail_idx;\n@@ -188,7 +188,7 @@ void vnic_wq_clean(struct vnic_wq *wq,\n \n \twhile (vnic_wq_desc_used(wq) > 0) {\n \n-\t\t(*buf_clean)(wq, buf);\n+\t\t(*buf_clean)(buf);\n \t\tto_clean = buf_idx_incr(wq->ring.desc_count, to_clean);\n \n \t\tbuf = &wq->bufs[to_clean];\ndiff --git a/drivers/net/enic/base/vnic_wq.h b/drivers/net/enic/base/vnic_wq.h\nindex 7a66813..38a217f 100644\n--- a/drivers/net/enic/base/vnic_wq.h\n+++ b/drivers/net/enic/base/vnic_wq.h\n@@ -79,7 +79,6 @@ struct vnic_wq {\n \tstruct vnic_wq_buf *bufs;\n \tunsigned int head_idx;\n \tunsigned int tail_idx;\n-\tunsigned int pkts_outstanding;\n \tunsigned int socket_id;\n \tconst struct rte_memzone *cqmsg_rz;\n \tuint16_t last_completed_index;\n@@ -193,8 +192,5 @@ unsigned int vnic_wq_error_status(struct vnic_wq *wq);\n void vnic_wq_enable(struct vnic_wq *wq);\n int vnic_wq_disable(struct vnic_wq *wq);\n void vnic_wq_clean(struct vnic_wq *wq,\n-\tvoid (*buf_clean)(struct vnic_wq *wq, struct vnic_wq_buf *buf));\n-int vnic_wq_mem_size(struct vnic_wq *wq, unsigned int desc_count,\n-\tunsigned int desc_size);\n-\n+\t\t   void (*buf_clean)(struct vnic_wq_buf *buf));\n #endif /* _VNIC_WQ_H_ */\ndiff --git a/drivers/net/enic/enic.h b/drivers/net/enic/enic.h\nindex fe186de..4eb28ee 100644\n--- a/drivers/net/enic/enic.h\n+++ b/drivers/net/enic/enic.h\n@@ -233,5 +233,4 @@ uint16_t enic_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,\n \t\t\tuint16_t nb_pkts);\n uint16_t enic_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts,\n \t\t\t       uint16_t nb_pkts);\n-void enic_free_wq_buf(__rte_unused struct vnic_wq *wq, struct vnic_wq_buf *buf);\n #endif /* _ENIC_H_ */\ndiff --git a/drivers/net/enic/enic_main.c b/drivers/net/enic/enic_main.c\nindex eaa206e..996f999 100644\n--- a/drivers/net/enic/enic_main.c\n+++ b/drivers/net/enic/enic_main.c\n@@ -102,7 +102,7 @@ void enic_set_hdr_split_size(struct enic *enic, u16 split_hdr_size)\n \tvnic_set_hdr_split_size(enic->vdev, split_hdr_size);\n }\n \n-void enic_free_wq_buf(__rte_unused struct vnic_wq *wq, struct vnic_wq_buf *buf)\n+static void enic_free_wq_buf(struct vnic_wq_buf *buf)\n {\n \tstruct rte_mbuf *mbuf = (struct rte_mbuf *)buf->mb;\n \ndiff --git a/drivers/net/enic/enic_rxtx.c b/drivers/net/enic/enic_rxtx.c\nindex ba15670..a04ebd0 100644\n--- a/drivers/net/enic/enic_rxtx.c\n+++ b/drivers/net/enic/enic_rxtx.c\n@@ -37,7 +37,6 @@\n #include \"enic_compat.h\"\n #include \"rq_enet_desc.h\"\n #include \"enic.h\"\n-#include \"enic_vnic_wq.h\"\n \n #define RTE_PMD_USE_PREFETCH\n \n",
    "prefixes": [
        "dpdk-dev",
        "v3",
        "10/13"
    ]
}