get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 2195950,
    "url": "http://patchwork.ozlabs.org/api/patches/2195950/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260212140917.1443253-6-peter.maydell@linaro.org/",
    "project": {
        "id": 14,
        "url": "http://patchwork.ozlabs.org/api/projects/14/?format=api",
        "name": "QEMU Development",
        "link_name": "qemu-devel",
        "list_id": "qemu-devel.nongnu.org",
        "list_email": "qemu-devel@nongnu.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": "",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20260212140917.1443253-6-peter.maydell@linaro.org>",
    "list_archive_url": null,
    "date": "2026-02-12T14:09:17",
    "name": "[5/5] net: mark struct tcp_header as QEMU_PACKED",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "9a8d182f260fdc4f66d01c26187b871229293c4a",
    "submitter": {
        "id": 5111,
        "url": "http://patchwork.ozlabs.org/api/people/5111/?format=api",
        "name": "Peter Maydell",
        "email": "peter.maydell@linaro.org"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260212140917.1443253-6-peter.maydell@linaro.org/mbox/",
    "series": [
        {
            "id": 491981,
            "url": "http://patchwork.ozlabs.org/api/series/491981/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/list/?series=491981",
            "date": "2026-02-12T14:09:12",
            "name": "net: mark eth_header, udp_header, tcp_header as QEMU_PACKED",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/491981/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2195950/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2195950/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>",
        "X-Original-To": "incoming@patchwork.ozlabs.org",
        "Delivered-To": "patchwork-incoming@legolas.ozlabs.org",
        "Authentication-Results": [
            "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256\n header.s=google header.b=YixYzT5g;\n\tdkim-atps=neutral",
            "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=nongnu.org\n (client-ip=209.51.188.17; helo=lists.gnu.org;\n envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org;\n receiver=patchwork.ozlabs.org)"
        ],
        "Received": [
            "from lists.gnu.org (lists.gnu.org [209.51.188.17])\n\t(using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fBcgN1pmXz1xxG\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 13 Feb 2026 01:12:00 +1100 (AEDT)",
            "from localhost ([::1] helo=lists1p.gnu.org)\n\tby lists.gnu.org with esmtp (Exim 4.90_1)\n\t(envelope-from <qemu-devel-bounces@nongnu.org>)\n\tid 1vqXO5-0000mF-Fl; Thu, 12 Feb 2026 09:09:45 -0500",
            "from eggs.gnu.org ([2001:470:142:3::10])\n by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <peter.maydell@linaro.org>)\n id 1vqXNq-0000h0-5Y\n for qemu-devel@nongnu.org; Thu, 12 Feb 2026 09:09:31 -0500",
            "from mail-wm1-x32f.google.com ([2a00:1450:4864:20::32f])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)\n (Exim 4.90_1) (envelope-from <peter.maydell@linaro.org>)\n id 1vqXNo-0006QR-Kc\n for qemu-devel@nongnu.org; Thu, 12 Feb 2026 09:09:29 -0500",
            "by mail-wm1-x32f.google.com with SMTP id\n 5b1f17b1804b1-4806dffc64cso69380555e9.1\n for <qemu-devel@nongnu.org>; Thu, 12 Feb 2026 06:09:28 -0800 (PST)",
            "from lanath.. (wildly.archaic.org.uk. [81.2.115.145])\n by smtp.gmail.com with ESMTPSA id\n 5b1f17b1804b1-4835dd0e327sm123266885e9.14.2026.02.12.06.09.25\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Thu, 12 Feb 2026 06:09:26 -0800 (PST)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=linaro.org; s=google; t=1770905367; x=1771510167; darn=nongnu.org;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=umz9FaOJkrxhBScr7QTLwHMuZF/7lh+gWKhwaBjbmJE=;\n b=YixYzT5gaIROnH5xBxumfeSwjqI+mTH+0HZb8QhcyQAgrgNDjTLCwfmqGpTF4QtVOB\n 3fXvKJzVn7VV/gOoJGnuUlldmRYJnD/MH8nOWhG63mNcI2QTUS48dfZd8SaiQiYMgdv3\n LLtVfagaLSbMiZ84zEscBYc5Sm5YrXTI9Ee/pTU3Xt6iNac1/QbRSv5PhkKxq7woZd6B\n KeqpPmO3w53AahF5B/sWhFIl2Qe3IYkJBnn+GQpI8D96UiC95g4qkAT9J17Eh3ba0JUS\n odvadU2qUhS30YW1VVENQd1yEe2bm6R0V6kZuY5t7zEDD0PIzqz/GahSekIq/CVqIf35\n 1MIA==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20230601; t=1770905367; x=1771510167;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=umz9FaOJkrxhBScr7QTLwHMu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i+REtjSukQLGRTfZ\n tFOQRxKwBHd072tJU4SZeJJ8XXdMNM=",
        "X-Received": "by 2002:a05:600c:4584:b0:47e:e2eb:bc22 with SMTP id\n 5b1f17b1804b1-483656b08cdmr44367035e9.5.1770905366947;\n Thu, 12 Feb 2026 06:09:26 -0800 (PST)",
        "From": "Peter Maydell <peter.maydell@linaro.org>",
        "To": "qemu-devel@nongnu.org",
        "Cc": "Jiri Pirko <jiri@resnulli.us>, Jason Wang <jasowang@redhat.com>,\n Dmitry Fleytman <dmitry.fleytman@gmail.com>,\n Akihiko Odaki <odaki@rsg.ci.i.u-tokyo.ac.jp>,\n Patrick Venture <venture@google.com>",
        "Subject": "[PATCH 5/5] net: mark struct tcp_header as QEMU_PACKED",
        "Date": "Thu, 12 Feb 2026 14:09:17 +0000",
        "Message-ID": "<20260212140917.1443253-6-peter.maydell@linaro.org>",
        "X-Mailer": "git-send-email 2.43.0",
        "In-Reply-To": "<20260212140917.1443253-1-peter.maydell@linaro.org>",
        "References": "<20260212140917.1443253-1-peter.maydell@linaro.org>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Received-SPF": "pass client-ip=2a00:1450:4864:20::32f;\n envelope-from=peter.maydell@linaro.org; helo=mail-wm1-x32f.google.com",
        "X-Spam_score_int": "-20",
        "X-Spam_score": "-2.1",
        "X-Spam_bar": "--",
        "X-Spam_report": "(-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,\n DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,\n RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001,\n SPF_PASS=-0.001 autolearn=ham autolearn_force=no",
        "X-Spam_action": "no action",
        "X-BeenThere": "qemu-devel@nongnu.org",
        "X-Mailman-Version": "2.1.29",
        "Precedence": "list",
        "List-Id": "qemu development <qemu-devel.nongnu.org>",
        "List-Unsubscribe": "<https://lists.nongnu.org/mailman/options/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe>",
        "List-Archive": "<https://lists.nongnu.org/archive/html/qemu-devel>",
        "List-Post": "<mailto:qemu-devel@nongnu.org>",
        "List-Help": "<mailto:qemu-devel-request@nongnu.org?subject=help>",
        "List-Subscribe": "<https://lists.nongnu.org/mailman/listinfo/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=subscribe>",
        "Errors-To": "qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org",
        "Sender": "qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org"
    },
    "content": "The eth_header is not actually guaranteed to be aligned.  We attempt\nto deal with this in some places such as net_checksum_calculate() by\nusing lduw_be_p() and so on to access the fields, but this is not\nsufficient to be correct, because even accessing a byte member within\na misaligned struct is undefined behaviour.  The clang sanitizer will\nemit an error like this if you run the sifive_u_mmc functional test\nwith sanitizers enabled:\n\n../../net/checksum.c:144:24: runtime error: member access within misaligned address 0x619a74c32033 for type 'tcp_header' (aka 'struct tcp_header'), which requires 4 byte alignment\n0x619a74c32033: note: pointer points here\n 0a  00 02 02 86 aa 00 16 52  c1 d3 70 00 00 00 00 a0  02 fa f0 00 00 00 00 02  04 05 b4 04 02 08 0a\n              ^\n    #0 0x619a6ba84794 in net_checksum_calculate /home/pm215/qemu/build/clang/../../net/checksum.c:144:24\n    #1 0x619a6b5940da in gem_transmit /home/pm215/qemu/build/clang/../../hw/net/cadence_gem.c:1386:21\n    #2 0x619a6b592141 in gem_write /home/pm215/qemu/build/clang/../../hw/net/cadence_gem.c:1650:13\n\nFix this by marking the tcp_header struct as QEMU_PACKED.\n\nSigned-off-by: Peter Maydell <peter.maydell@linaro.org>\n---\n include/net/eth.h | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)",
    "diff": "diff --git a/include/net/eth.h b/include/net/eth.h\nindex df90ff0837..efe270dbfe 100644\n--- a/include/net/eth.h\n+++ b/include/net/eth.h\n@@ -68,7 +68,7 @@ typedef struct tcp_header {\n     uint16_t th_win;            /* window */\n     uint16_t th_sum;            /* checksum */\n     uint16_t th_urp;            /* urgent pointer */\n-} tcp_header;\n+} QEMU_PACKED tcp_header;\n \n #define TCP_FLAGS_ONLY(flags) ((flags) & 0x3f)\n \n",
    "prefixes": [
        "5/5"
    ]
}