get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 806937,
    "url": "http://patchwork.ozlabs.org/api/patches/806937/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/openvswitch/patch/1503981024-3627-2-git-send-email-roid@mellanox.com/",
    "project": {
        "id": 47,
        "url": "http://patchwork.ozlabs.org/api/projects/47/?format=api",
        "name": "Open vSwitch",
        "link_name": "openvswitch",
        "list_id": "ovs-dev.openvswitch.org",
        "list_email": "ovs-dev@openvswitch.org",
        "web_url": "http://openvswitch.org/",
        "scm_url": "git@github.com:openvswitch/ovs.git",
        "webscm_url": "https://github.com/openvswitch/ovs",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<1503981024-3627-2-git-send-email-roid@mellanox.com>",
    "list_archive_url": null,
    "date": "2017-08-29T04:30:23",
    "name": "[ovs-dev,1/2] lib/odp: Fix handling of set masked action in parse_odp_action",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "61fdf62330ea9e14e0204637d0d5c99a7e5a7338",
    "submitter": {
        "id": 70307,
        "url": "http://patchwork.ozlabs.org/api/people/70307/?format=api",
        "name": "Roi Dayan",
        "email": "roid@mellanox.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/openvswitch/patch/1503981024-3627-2-git-send-email-roid@mellanox.com/mbox/",
    "series": [
        {
            "id": 300,
            "url": "http://patchwork.ozlabs.org/api/series/300/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/openvswitch/list/?series=300",
            "date": "2017-08-29T04:30:23",
            "name": "[ovs-dev,1/2] lib/odp: Fix handling of set masked action in parse_odp_action",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/300/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/806937/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/806937/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<ovs-dev-bounces@openvswitch.org>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "dev@openvswitch.org"
        ],
        "Delivered-To": [
            "patchwork-incoming@bilbo.ozlabs.org",
            "ovs-dev@mail.linuxfoundation.org"
        ],
        "Authentication-Results": "ozlabs.org;\n\tspf=pass (mailfrom) smtp.mailfrom=openvswitch.org\n\t(client-ip=140.211.169.12; helo=mail.linuxfoundation.org;\n\tenvelope-from=ovs-dev-bounces@openvswitch.org;\n\treceiver=<UNKNOWN>)",
        "Received": [
            "from mail.linuxfoundation.org (mail.linuxfoundation.org\n\t[140.211.169.12])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256\n\tbits)) (No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3xhG0F3Qhjz9s7c\n\tfor <incoming@patchwork.ozlabs.org>;\n\tTue, 29 Aug 2017 14:30:37 +1000 (AEST)",
            "from mail.linux-foundation.org (localhost [127.0.0.1])\n\tby mail.linuxfoundation.org (Postfix) with ESMTP id 1AAF897A;\n\tTue, 29 Aug 2017 04:30:33 +0000 (UTC)",
            "from smtp1.linuxfoundation.org (smtp1.linux-foundation.org\n\t[172.17.192.35])\n\tby mail.linuxfoundation.org (Postfix) with ESMTPS id E526288A\n\tfor <dev@openvswitch.org>; Tue, 29 Aug 2017 04:30:31 +0000 (UTC)",
            "from mellanox.co.il (mail-il-dmz.mellanox.com [193.47.165.129])\n\tby smtp1.linuxfoundation.org (Postfix) with ESMTP id 24FB83DC\n\tfor <dev@openvswitch.org>; Tue, 29 Aug 2017 04:30:30 +0000 (UTC)",
            "from Internal Mail-Server by MTLPINE1 (envelope-from\n\troid@mellanox.com)\n\twith ESMTPS (AES256-SHA encrypted); 29 Aug 2017 07:30:27 +0300",
            "from dev-r-vrt-189.mtr.labs.mlnx (dev-r-vrt-189.mtr.labs.mlnx\n\t[10.212.189.1])\n\tby labmailer.mlnx (8.13.8/8.13.8) with ESMTP id v7T4UQP6026904;\n\tTue, 29 Aug 2017 07:30:27 +0300"
        ],
        "X-Greylist": "domain auto-whitelisted by SQLgrey-1.7.6",
        "From": "Roi Dayan <roid@mellanox.com>",
        "To": "dev@openvswitch.org",
        "Date": "Tue, 29 Aug 2017 07:30:23 +0300",
        "Message-Id": "<1503981024-3627-2-git-send-email-roid@mellanox.com>",
        "X-Mailer": "git-send-email 2.7.5",
        "In-Reply-To": "<1503981024-3627-1-git-send-email-roid@mellanox.com>",
        "References": "<1503981024-3627-1-git-send-email-roid@mellanox.com>",
        "X-Spam-Status": "No, score=0.0 required=5.0 tests=RP_MATCHES_RCVD,\n\tUNPARSEABLE_RELAY autolearn=disabled version=3.3.1",
        "X-Spam-Checker-Version": "SpamAssassin 3.3.1 (2010-03-16) on\n\tsmtp1.linux-foundation.org",
        "Cc": "Simon Horman <simon.horman@netronome.com>",
        "Subject": "[ovs-dev] [PATCH 1/2] lib/odp: Fix handling of set masked action in\n\tparse_odp_action",
        "X-BeenThere": "ovs-dev@openvswitch.org",
        "X-Mailman-Version": "2.1.12",
        "Precedence": "list",
        "List-Id": "<ovs-dev.openvswitch.org>",
        "List-Unsubscribe": "<https://mail.openvswitch.org/mailman/options/ovs-dev>,\n\t<mailto:ovs-dev-request@openvswitch.org?subject=unsubscribe>",
        "List-Archive": "<http://mail.openvswitch.org/pipermail/ovs-dev/>",
        "List-Post": "<mailto:ovs-dev@openvswitch.org>",
        "List-Help": "<mailto:ovs-dev-request@openvswitch.org?subject=help>",
        "List-Subscribe": "<https://mail.openvswitch.org/mailman/listinfo/ovs-dev>,\n\t<mailto:ovs-dev-request@openvswitch.org?subject=subscribe>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Sender": "ovs-dev-bounces@openvswitch.org",
        "Errors-To": "ovs-dev-bounces@openvswitch.org"
    },
    "content": "From: Paul Blakey <paulb@mellanox.com>\n\nIf we find that we need to change from a SET to SET_MASKED action,\nthen we write the mask to the actions opfbuf. But if there was netlink\npad added to the buffer when writing the key, mask won't follow the\nkey data as per SET_MASKED spec.\n\nFix that by removing the padding before writing the mask, and\nreadding it if needed for alignment.\n\nFixes: 6d670e7f0d45 (\"lib/odp: Masked set action execution and printing.\")\nSigned-off-by: Paul Blakey <paulb@mellanox.com>\nReviewed-by: Roi Dayan <roid@mellanox.com>\n---\n lib/odp-util.c | 9 +++++++++\n 1 file changed, 9 insertions(+)",
    "diff": "diff --git a/lib/odp-util.c b/lib/odp-util.c\nindex 4f1499e..0594840 100644\n--- a/lib/odp-util.c\n+++ b/lib/odp-util.c\n@@ -1990,8 +1990,17 @@ parse_odp_action(const char *s, const struct simap *port_names,\n         if (size == nl_attr_get_size(key)) {\n             /* Change to masked set action if not fully masked. */\n             if (!is_all_ones(mask + 1, size)) {\n+                /* remove padding of eariler key payload  */\n+                actions->size -= NLA_ALIGN(key->nla_len) - key->nla_len;\n+\n+                /* put mask payload right after key payload */\n                 key->nla_len += size;\n                 ofpbuf_put(actions, mask + 1, size);\n+\n+                /* add back the netlink padding, if needed */\n+                ofpbuf_put_zeros(actions, NLA_ALIGN(key->nla_len) -\n+                                          key->nla_len);\n+\n                 /* 'actions' may have been reallocated by ofpbuf_put(). */\n                 nested = ofpbuf_at_assert(actions, start_ofs, sizeof *nested);\n                 nested->nla_type = OVS_ACTION_ATTR_SET_MASKED;\n",
    "prefixes": [
        "ovs-dev",
        "1/2"
    ]
}