Show a patch.

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

{
    "id": 341,
    "url": "http://patches.dpdk.org/api/patches/341/",
    "web_url": "http://patches.dpdk.org/patch/341/",
    "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-9-git-send-email-bruce.richardson@intel.com>",
    "date": "2014-09-11T13:15:42",
    "name": "[dpdk-dev,v2,08/13] mbuf: add named points inside the mbuf structure",
    "commit_ref": "",
    "pull_url": "",
    "state": "accepted",
    "archived": true,
    "hash": "0d72c80ddde763e0e88bbe59cbd25576e72d62ef",
    "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/341/mbox/",
    "series": [],
    "comments": "http://patches.dpdk.org/api/patches/341/comments/",
    "check": "pending",
    "checks": "http://patches.dpdk.org/api/patches/341/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=\"4.97,862,1389772800\"; d=\"scan'208\";a=\"384718627\"",
        "Date": "Thu, 11 Sep 2014 14:15:42 +0100",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "X-BeenThere": "dev@dpdk.org",
        "Message-Id": "<1410441347-22840-9-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 EE061B392;\r\n\tThu, 11 Sep 2014 15:10:43 +0200 (CEST)",
            "from mga14.intel.com (mga14.intel.com [192.55.52.115])\r\n\tby dpdk.org (Postfix) with ESMTP id EC6355909\r\n\tfor <dev@dpdk.org>; Thu, 11 Sep 2014 15:10:38 +0200 (CEST)",
            "from fmsmga003.fm.intel.com ([10.253.24.29])\r\n\tby fmsmga103.fm.intel.com with ESMTP; 11 Sep 2014 06:07:13 -0700",
            "from irvmail001.ir.intel.com ([163.33.26.43])\r\n\tby FMSMGA003.fm.intel.com with ESMTP; 11 Sep 2014 06:10:42 -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\ts8BDFna8002153; 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 s8BDFnZT023659;\r\n\tThu, 11 Sep 2014 14:15:49 +0100",
            "(from bricha3@localhost)\r\n\tby sivswdev02.ir.intel.com with  id s8BDFn4F023655;\r\n\tThu, 11 Sep 2014 14:15:49 +0100"
        ],
        "List-Post": "<mailto:dev@dpdk.org>",
        "Subject": "[dpdk-dev] [PATCH v2 08/13] mbuf: add named points inside the mbuf\r\n\tstructure",
        "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": "Add markers or \"labels\" at given points inside the mbuf which can be\nused instead of individual fields to identify the start of logical\nsections inside the mbuf.\n\nThe use of typedefs and dummy fields was chosen over using unions\nbecause of a couple reasons:\n* unions cause an extra level of indentation (more likely two levels as\n  a union containing a struct for multiple fields would be needed). This\n  makes the lines longer than they need to be and increases the need for\n  wrapping. [This was the main reason]\n* with markers, you can apply multiple markers at the same point if\n  wanted.\n\nUpdates in V2:\n* None\n\nSigned-off-by: Bruce Richardson <bruce.richardson@intel.com>\n---\n lib/librte_mbuf/rte_mbuf.h | 9 +++++++++\n 1 file changed, 9 insertions(+)",
    "diff": "diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h\r\nindex 2f1bd4a..34900d4 100644\r\n--- a/lib/librte_mbuf/rte_mbuf.h\r\n+++ b/lib/librte_mbuf/rte_mbuf.h\r\n@@ -115,14 +115,22 @@ extern \"C\" {\r\n  */\r\n #define PKT_TX_OFFLOAD_MASK (PKT_TX_VLAN_PKT | PKT_TX_IP_CKSUM | PKT_TX_L4_MASK)\r\n \r\n+/* define a set of marker types that can be used to refer to set points in the\r\n+ * mbuf */\r\n+typedef void    *MARKER[0];   /**< generic marker for a point in a structure */\r\n+typedef uint64_t MARKER64[0]; /**< marker that allows us to overwrite 8 bytes\r\n+                               * with a single assignment */\r\n /**\r\n  * The generic rte_mbuf, containing a packet mbuf.\r\n  */\r\n struct rte_mbuf {\r\n+\tMARKER cacheline0;\r\n+\r\n \tvoid *buf_addr;           /**< Virtual address of segment buffer. */\r\n \tphys_addr_t buf_physaddr; /**< Physical address of segment buffer. */\r\n \r\n \t/* next 8 bytes are initialised on RX descriptor rearm */\r\n+\tMARKER64 rearm_data;\r\n \tuint16_t buf_len;         /**< Length of segment buffer. */\r\n \tuint16_t data_off;\r\n \r\n@@ -147,6 +155,7 @@ struct rte_mbuf {\r\n \tuint64_t ol_flags;        /**< Offload features. */\r\n \r\n \t/* remaining bytes are set on RX when pulling packet from descriptor */\r\n+\tMARKER rx_descriptor_fields1;\r\n \tuint16_t reserved2;       /**< Unused field. Required for padding */\r\n \tuint16_t data_len;        /**< Amount of data in segment buffer. */\r\n \tuint32_t pkt_len;         /**< Total pkt len: sum of all segments. */\r\n",
    "prefixes": [
        "dpdk-dev",
        "v2",
        "08/13"
    ]
}