get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 55913,
    "url": "https://patches.dpdk.org/api/patches/55913/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20190702221247.28391-6-stephen@networkplumber.org/",
    "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": "<20190702221247.28391-6-stephen@networkplumber.org>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20190702221247.28391-6-stephen@networkplumber.org",
    "date": "2019-07-02T22:12:40",
    "name": "[v7,05/12] net/ether: mark ethernet addresses as being 2-byte aligned",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "9ed1a95dc190026c0aee1670da79cfd5d64ad701",
    "submitter": {
        "id": 27,
        "url": "https://patches.dpdk.org/api/people/27/?format=api",
        "name": "Stephen Hemminger",
        "email": "stephen@networkplumber.org"
    },
    "delegate": null,
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/20190702221247.28391-6-stephen@networkplumber.org/mbox/",
    "series": [
        {
            "id": 5291,
            "url": "https://patches.dpdk.org/api/series/5291/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=5291",
            "date": "2019-07-02T22:12:35",
            "name": "ether: improvements and optimizations",
            "version": 7,
            "mbox": "https://patches.dpdk.org/series/5291/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/55913/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/55913/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 845091BE22;\n\tWed,  3 Jul 2019 00:13:02 +0200 (CEST)",
            "from mail-pf1-f196.google.com (mail-pf1-f196.google.com\n\t[209.85.210.196]) by dpdk.org (Postfix) with ESMTP id 9706E1BE0E\n\tfor <dev@dpdk.org>; Wed,  3 Jul 2019 00:12:58 +0200 (CEST)",
            "by mail-pf1-f196.google.com with SMTP id t16so113288pfe.11\n\tfor <dev@dpdk.org>; Tue, 02 Jul 2019 15:12:58 -0700 (PDT)",
            "from hermes.lan (204-195-22-127.wavecable.com. [204.195.22.127])\n\tby smtp.gmail.com with ESMTPSA id q4sm25035pjq.27.2019.07.02.15.12.55\n\t(version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256);\n\tTue, 02 Jul 2019 15:12:56 -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=5jmpHlnhidg0ShQ7XItCpgaXpVK1xXtowoDpbYktXUk=;\n\tb=PGCX/9P4A3hho78zXtEEWnBoj1FAxMNsW/i3e4Owxt+66tpKd0HFDgh89DOqcUDxld\n\tG3JAeqXCbmNPnUliDtQZya+x/94vKZlCwVQK1olVkonUuE02hkehuLLH/TiTDpNTnWZn\n\tBg4ush5+gDqN+JJDYe+ZjbD7NyZw5m9ydQlieMucZTGEYuORrIImIxxv84LiRZ4RRKqp\n\tHfXQ+rpTCgTvh+Y4ljKZKOeexqAEQgH+Fz/0OgjWwsk0enpD3CQlNXx09InbfpEQMe4U\n\t7bySp6P1m+slounnjUpY4R/qPmNI6KW2v5VR1kwBiZve1TyvXveVCRqHQ+bhDM3ldz68\n\ta5lw==",
        "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=5jmpHlnhidg0ShQ7XItCpgaXpVK1xXtowoDpbYktXUk=;\n\tb=SAdz2fNGXAT+bwPmSo7XQIMggkuJJ8phQr/UbxPi6QZ8TgYpBf1F3UsSpz8S667Icm\n\t8Fl/P/71YWn8k4LCYczpLbffGaPJlNuN4GCDXNfOvkJf2ZwBP+EXdiGaoiqsH8fp9piJ\n\tAJgCqOZnC9mMieA9u27VBpPTTf2RDc+HsIuHJ/S8JvfLUFhVx2WW7Z8GORJlfDagqh8w\n\t0t/ZdUgQk4pTWJrmV6axdxmU73E4tdL+cw7nw1URWeKSGPhGadHF2gt2MitZj1ZURyrV\n\ttvfIdZpCvbAFREejRj6makLoYh1nXZ2hgNW3Qw4oT/gDhHWTIrn8XgQHbih9l0FtmFQ9\n\tKYVA==",
        "X-Gm-Message-State": "APjAAAWzjCKyCcR3jXc9Iyt+JGu3AO1/0FkoPCg/5da5bfm7pdCsRYYM\n\tyJ9PoCfLnDZPwUnp41vJiG8cbd+0q+U=",
        "X-Google-Smtp-Source": "APXvYqxeHh39tCrxDmfnPBawAcKrZy/jEjbUXXkjCt8zNqJ1rau99EK4ACDvCJfF/+3UWT0ynFAJ3Q==",
        "X-Received": "by 2002:a65:4844:: with SMTP id\n\ti4mr16113056pgs.113.1562105577229; \n\tTue, 02 Jul 2019 15:12:57 -0700 (PDT)",
        "From": "Stephen Hemminger <stephen@networkplumber.org>",
        "To": "dev@dpdk.org",
        "Cc": "Bruce Richardson <bruce.richardson@intel.com>,\n\tStephen Hemminger <stephen@networkplumber.org>,\n\tAndrew Rybchenko <arybchenko@solarflare.com>",
        "Date": "Tue,  2 Jul 2019 15:12:40 -0700",
        "Message-Id": "<20190702221247.28391-6-stephen@networkplumber.org>",
        "X-Mailer": "git-send-email 2.20.1",
        "In-Reply-To": "<20190702221247.28391-1-stephen@networkplumber.org>",
        "References": "<20190516180427.17270-1-stephen@networkplumber.org>\n\t<20190702221247.28391-1-stephen@networkplumber.org>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=UTF-8",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [PATCH v7 05/12] net/ether: mark ethernet addresses as\n\tbeing 2-byte aligned",
        "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": "From: Bruce Richardson <bruce.richardson@intel.com>\n\nWhen including the rte_ether.h header in applications with warnings\nenabled, a warning was given because of the assumption of 2-byte alignment\nof ethernet addresses when processing them.\n\n.../include/rte_ether.h:149:2: warning: converting a packed ‘const\n  struct ether_addr’ pointer (alignment 1) to a ‘unaligned_uint16_t’\n  {aka ‘const short unsigned int’} pointer (alignment 2) may result in\n  an unaligned pointer value [-Waddress-of-packed-member]\n149 |  const unaligned_uint16_t *ea_words = (const unaligned_uint16_t *)ea;\n    |  ^~~~~\n\nSince ethernet addresses should always be aligned on a two-byte boundary,\nwe can just inform the compiler of this assumption to remove the warnings\nand allow us to always access the addresses using 16-bit operations.\n\nSigned-off-by: Bruce Richardson <bruce.richardson@intel.com>\nSigned-off-by: Stephen Hemminger <stephen@networkplumber.org>\nReviewed-by: Andrew Rybchenko <arybchenko@solarflare.com>\n---\n lib/librte_net/rte_ether.h | 11 ++++++-----\n 1 file changed, 6 insertions(+), 5 deletions(-)",
    "diff": "diff --git a/lib/librte_net/rte_ether.h b/lib/librte_net/rte_ether.h\nindex feb35a33c94b..d7b76ddf63eb 100644\n--- a/lib/librte_net/rte_ether.h\n+++ b/lib/librte_net/rte_ether.h\n@@ -58,7 +58,8 @@ extern \"C\" {\n  * See http://standards.ieee.org/regauth/groupmac/tutorial.html\n  */\n struct rte_ether_addr {\n-\tuint8_t addr_bytes[RTE_ETHER_ADDR_LEN]; /**< Addr bytes in tx order */\n+\tuint8_t addr_bytes[RTE_ETHER_ADDR_LEN] __rte_aligned(2);\n+\t/**< Addr bytes in tx order */\n } __attribute__((__packed__));\n \n #define RTE_ETHER_LOCAL_ADMIN_ADDR 0x02 /**< Locally assigned Eth. address. */\n@@ -81,8 +82,8 @@ struct rte_ether_addr {\n static inline int rte_is_same_ether_addr(const struct rte_ether_addr *ea1,\n \t\t\t\t     const struct rte_ether_addr *ea2)\n {\n-\tconst unaligned_uint16_t *w1 = (const uint16_t *)ea1;\n-\tconst unaligned_uint16_t *w2 = (const uint16_t *)ea2;\n+\tconst uint16_t *w1 = (const uint16_t *)ea1;\n+\tconst uint16_t *w2 = (const uint16_t *)ea2;\n \n \treturn ((w1[0] ^ w2[0]) | (w1[1] ^ w2[1]) | (w1[2] ^ w2[2])) == 0;\n }\n@@ -99,7 +100,7 @@ static inline int rte_is_same_ether_addr(const struct rte_ether_addr *ea1,\n  */\n static inline int rte_is_zero_ether_addr(const struct rte_ether_addr *ea)\n {\n-\tconst unaligned_uint16_t *w = (const uint16_t *)ea;\n+\tconst uint16_t *w = (const uint16_t *)ea;\n \n \treturn (w[0] | w[1] | w[2]) == 0;\n }\n@@ -146,7 +147,7 @@ static inline int rte_is_multicast_ether_addr(const struct rte_ether_addr *ea)\n  */\n static inline int rte_is_broadcast_ether_addr(const struct rte_ether_addr *ea)\n {\n-\tconst unaligned_uint16_t *ea_words = (const unaligned_uint16_t *)ea;\n+\tconst uint16_t *ea_words = (const uint16_t *)ea;\n \n \treturn (ea_words[0] == 0xFFFF && ea_words[1] == 0xFFFF &&\n \t\tea_words[2] == 0xFFFF);\n",
    "prefixes": [
        "v7",
        "05/12"
    ]
}