Show a patch.

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

{
    "id": 306,
    "url": "https://patches.dpdk.org/api/patches/306/?format=api",
    "web_url": "https://patches.dpdk.org/patch/306/",
    "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"
    },
    "msgid": "<1409759378-10113-8-git-send-email-bruce.richardson@intel.com>",
    "date": "2014-09-03T15:49:32",
    "name": "[dpdk-dev,07/13] mbuf: use macros only to access the mbuf metadata",
    "commit_ref": "",
    "pull_url": "",
    "state": "superseded",
    "archived": true,
    "hash": "f4fc8d19c014acc35b52a275dd8edf366cf41ad7",
    "submitter": {
        "id": 20,
        "url": "https://patches.dpdk.org/api/people/20/?format=api",
        "name": "Bruce Richardson",
        "email": "bruce.richardson@intel.com"
    },
    "delegate": null,
    "mbox": "https://patches.dpdk.org/patch/306/mbox/",
    "series": [],
    "comments": "https://patches.dpdk.org/api/patches/306/comments/",
    "check": "pending",
    "checks": "https://patches.dpdk.org/api/patches/306/checks/",
    "tags": {},
    "headers": {
        "List-Archive": "<http://dpdk.org/ml/archives/dev/>",
        "Return-Path": "<bricha3@ecsmtp.ir.intel.com>",
        "Message-Id": "<1409759378-10113-8-git-send-email-bruce.richardson@intel.com>",
        "X-Mailer": "git-send-email 1.7.0.7",
        "To": "dev@dpdk.org",
        "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\r\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "X-BeenThere": "dev@dpdk.org",
        "Received": [
            "from mga11.intel.com (mga11.intel.com [192.55.52.93])\r\n\tby dpdk.org (Postfix) with ESMTP id 77633B361\r\n\tfor <dev@dpdk.org>; Wed,  3 Sep 2014 17:45:40 +0200 (CEST)",
            "from fmsmga002.fm.intel.com ([10.253.24.26])\r\n\tby fmsmga102.fm.intel.com with ESMTP; 03 Sep 2014 08:49:41 -0700",
            "from irvmail001.ir.intel.com ([163.33.26.43])\r\n\tby fmsmga002.fm.intel.com with ESMTP; 03 Sep 2014 08:49:40 -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\ts83FndJi025432; Wed, 3 Sep 2014 16:49:40 +0100",
            "from sivswdev02.ir.intel.com (localhost [127.0.0.1])\r\n\tby sivswdev02.ir.intel.com with ESMTP id s83FndUY010462;\r\n\tWed, 3 Sep 2014 16:49:39 +0100",
            "(from bricha3@localhost)\r\n\tby sivswdev02.ir.intel.com with  id s83FndDX010458;\r\n\tWed, 3 Sep 2014 16:49:39 +0100"
        ],
        "Subject": "[dpdk-dev] [PATCH 07/13] mbuf: use macros only to access the mbuf\r\n\tmetadata",
        "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\r\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Id": "patches and discussions about DPDK <dev.dpdk.org>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "In-Reply-To": "<1409759378-10113-1-git-send-email-bruce.richardson@intel.com>",
        "X-ExtLoop1": "1",
        "Precedence": "list",
        "From": "Bruce Richardson <bruce.richardson@intel.com>",
        "X-IronPort-AV": "E=Sophos;i=\"5.04,458,1406617200\"; d=\"scan'208\";a=\"593984543\"",
        "References": "<1409759378-10113-1-git-send-email-bruce.richardson@intel.com>",
        "X-List-Received-Date": "Wed, 03 Sep 2014 15:45:41 -0000",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "Date": "Wed,  3 Sep 2014 16:49:32 +0100",
        "X-Mailman-Version": "2.1.15"
    },
    "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\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 5260001..ca66d9a 100644\r\n--- a/lib/librte_mbuf/rte_mbuf.h\r\n+++ b/lib/librte_mbuf/rte_mbuf.h\r\n@@ -166,31 +166,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",
        "07/13"
    ]
}