Show a patch.

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

{
    "id": 346,
    "url": "http://patches.dpdk.org/api/patches/346/",
    "web_url": "http://patches.dpdk.org/patch/346/",
    "project": {
        "id": 1,
        "url": "http://patches.dpdk.org/api/projects/1/",
        "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"
    },
    "msgid": "<1410441347-22840-7-git-send-email-bruce.richardson@intel.com>",
    "date": "2014-09-11T13:15:40",
    "name": "[dpdk-dev,v2,06/13] mbuf: use macros only to access the mbuf metadata",
    "commit_ref": "",
    "pull_url": "",
    "state": "accepted",
    "archived": true,
    "hash": "f4fc8d19c014acc35b52a275dd8edf366cf41ad7",
    "submitter": {
        "id": 20,
        "url": "http://patches.dpdk.org/api/people/20/",
        "name": "Bruce Richardson",
        "email": "bruce.richardson@intel.com"
    },
    "delegate": null,
    "mbox": "http://patches.dpdk.org/patch/346/mbox/",
    "series": [],
    "comments": "http://patches.dpdk.org/api/patches/346/comments/",
    "check": "pending",
    "checks": "http://patches.dpdk.org/api/patches/346/checks/",
    "tags": {},
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "References": "<1409759378-10113-1-git-send-email-bruce.richardson@intel.com>\r\n\t<1410441347-22840-1-git-send-email-bruce.richardson@intel.com>",
        "X-Mailman-Version": "2.1.15",
        "X-IronPort-AV": "E=Sophos;i=\"5.04,505,1406617200\"; d=\"scan'208\";a=\"601443234\"",
        "Date": "Thu, 11 Sep 2014 14:15:40 +0100",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "X-BeenThere": "dev@dpdk.org",
        "Message-Id": "<1410441347-22840-7-git-send-email-bruce.richardson@intel.com>",
        "X-Original-To": "patchwork@dpdk.org",
        "Received": [
            "from [92.243.14.124] (localhost [IPv6:::1])\r\n\tby dpdk.org (Postfix) with ESMTP id 757B8B39A;\r\n\tThu, 11 Sep 2014 15:11:30 +0200 (CEST)",
            "from mga09.intel.com (mga09.intel.com [134.134.136.24])\r\n\tby dpdk.org (Postfix) with ESMTP id 09E865909\r\n\tfor <dev@dpdk.org>; Thu, 11 Sep 2014 15:11:22 +0200 (CEST)",
            "from orsmga002.jf.intel.com ([10.7.209.21])\r\n\tby orsmga102.jf.intel.com with ESMTP; 11 Sep 2014 06:09:44 -0700",
            "from irvmail001.ir.intel.com ([163.33.26.43])\r\n\tby orsmga002.jf.intel.com with ESMTP; 11 Sep 2014 06:15:50 -0700",
            "from sivswdev02.ir.intel.com (sivswdev02.ir.intel.com\r\n\t[10.237.217.46])\r\n\tby irvmail001.ir.intel.com (8.14.3/8.13.6/MailSET/Hub) with ESMTP id\r\n\ts8BDFnhL002151; Thu, 11 Sep 2014 14:15:49 +0100",
            "from sivswdev02.ir.intel.com (localhost [127.0.0.1])\r\n\tby sivswdev02.ir.intel.com with ESMTP id s8BDFn7Z023644;\r\n\tThu, 11 Sep 2014 14:15:49 +0100",
            "(from bricha3@localhost)\r\n\tby sivswdev02.ir.intel.com with  id s8BDFnAM023639;\r\n\tThu, 11 Sep 2014 14:15:49 +0100"
        ],
        "List-Post": "<mailto:dev@dpdk.org>",
        "Subject": "[dpdk-dev] [PATCH v2 06/13] mbuf: use macros only to access the\r\n\tmbuf metadata",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>",
        "X-Mailer": "git-send-email 1.7.4.1",
        "Precedence": "list",
        "From": "Bruce Richardson <bruce.richardson@intel.com>",
        "List-Archive": "<http://dpdk.org/ml/archives/dev/>",
        "X-ExtLoop1": "1",
        "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\r\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "List-Id": "patches and discussions about DPDK <dev.dpdk.org>",
        "Delivered-To": "patchwork@dpdk.org",
        "In-Reply-To": "<1410441347-22840-1-git-send-email-bruce.richardson@intel.com>",
        "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\r\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "To": "dev@dpdk.org",
        "Errors-To": "dev-bounces@dpdk.org"
    },
    "content": "Removed the explicit zero-sized metadata definition at the end of the\nmbuf data structure. Updated the metadata macros to take account of this\nchange so that all existing code which uses those macros still works.\n\nUpdates in V2:\n* None\n\nSigned-off-by: Bruce Richardson <bruce.richardson@intel.com>\n---\n lib/librte_mbuf/rte_mbuf.h | 22 ++++++++--------------\n 1 file changed, 8 insertions(+), 14 deletions(-)",
    "diff": "diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h\r\nindex 6ce852a..f855e64 100644\r\n--- a/lib/librte_mbuf/rte_mbuf.h\r\n+++ b/lib/librte_mbuf/rte_mbuf.h\r\n@@ -171,31 +171,25 @@ struct rte_mbuf {\r\n \tstruct rte_mempool *pool; /**< Pool from which mbuf was allocated. */\r\n \tstruct rte_mbuf *next;    /**< Next segment of scattered packet. */\r\n \r\n-\tunion {\r\n-\t\tuint8_t metadata[0];\r\n-\t\tuint16_t metadata16[0];\r\n-\t\tuint32_t metadata32[0];\r\n-\t\tuint64_t metadata64[0];\r\n-\t} __rte_cache_aligned;\r\n } __rte_cache_aligned;\r\n \r\n #define RTE_MBUF_METADATA_UINT8(mbuf, offset)              \\\r\n-\t(mbuf->metadata[offset])\r\n+\t(((uint8_t *)&(mbuf)[1])[offset])\r\n #define RTE_MBUF_METADATA_UINT16(mbuf, offset)             \\\r\n-\t(mbuf->metadata16[offset/sizeof(uint16_t)])\r\n+\t(((uint16_t *)&(mbuf)[1])[offset/sizeof(uint16_t)])\r\n #define RTE_MBUF_METADATA_UINT32(mbuf, offset)             \\\r\n-\t(mbuf->metadata32[offset/sizeof(uint32_t)])\r\n+\t(((uint32_t *)&(mbuf)[1])[offset/sizeof(uint32_t)])\r\n #define RTE_MBUF_METADATA_UINT64(mbuf, offset)             \\\r\n-\t(mbuf->metadata64[offset/sizeof(uint64_t)])\r\n+\t(((uint64_t *)&(mbuf)[1])[offset/sizeof(uint64_t)])\r\n \r\n #define RTE_MBUF_METADATA_UINT8_PTR(mbuf, offset)          \\\r\n-\t(&mbuf->metadata[offset])\r\n+\t(&RTE_MBUF_METADATA_UINT8(mbuf, offset))\r\n #define RTE_MBUF_METADATA_UINT16_PTR(mbuf, offset)         \\\r\n-\t(&mbuf->metadata16[offset/sizeof(uint16_t)])\r\n+\t(&RTE_MBUF_METADATA_UINT16(mbuf, offset))\r\n #define RTE_MBUF_METADATA_UINT32_PTR(mbuf, offset)         \\\r\n-\t(&mbuf->metadata32[offset/sizeof(uint32_t)])\r\n+\t(&RTE_MBUF_METADATA_UINT32(mbuf, offset))\r\n #define RTE_MBUF_METADATA_UINT64_PTR(mbuf, offset)         \\\r\n-\t(&mbuf->metadata64[offset/sizeof(uint64_t)])\r\n+\t(&RTE_MBUF_METADATA_UINT64(mbuf, offset))\r\n \r\n /**\r\n  * Given the buf_addr returns the pointer to corresponding mbuf.\r\n",
    "prefixes": [
        "dpdk-dev",
        "v2",
        "06/13"
    ]
}