get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 2198254,
    "url": "http://patchwork.ozlabs.org/api/1.0/patches/2198254/?format=api",
    "project": {
        "id": 14,
        "url": "http://patchwork.ozlabs.org/api/1.0/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": ""
    },
    "msgid": "<20260219171810.602667-3-alex.bennee@linaro.org>",
    "date": "2026-02-19T17:17:58",
    "name": "[RFC,v2,02/14] target/m68k: initialise pc/sp vector during reset",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "d4050b593fad6a3c2b3c53d46f4102b61b2148c3",
    "submitter": {
        "id": 39532,
        "url": "http://patchwork.ozlabs.org/api/1.0/people/39532/?format=api",
        "name": "Alex Bennée",
        "email": "alex.bennee@linaro.org"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260219171810.602667-3-alex.bennee@linaro.org/mbox/",
    "series": [
        {
            "id": 492705,
            "url": "http://patchwork.ozlabs.org/api/1.0/series/492705/?format=api",
            "date": "2026-02-19T17:17:57",
            "name": "cpu_reset clean-ups for arm, alpha, mips, m68k and tricore",
            "version": 2,
            "mbox": "http://patchwork.ozlabs.org/series/492705/mbox/"
        }
    ],
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2198254/checks/",
    "tags": {},
    "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=n35egehw;\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 4fH0Tk5GYcz1xxQ\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 20 Feb 2026 04:18:50 +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 1vt7fO-0005Lf-GQ; Thu, 19 Feb 2026 12:18:18 -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 <alex.bennee@linaro.org>)\n id 1vt7fM-0005Kk-38\n for qemu-devel@nongnu.org; Thu, 19 Feb 2026 12:18:16 -0500",
            "from mail-ed1-x529.google.com ([2a00:1450:4864:20::529])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)\n (Exim 4.90_1) (envelope-from <alex.bennee@linaro.org>)\n id 1vt7fK-0000Py-F2\n for qemu-devel@nongnu.org; Thu, 19 Feb 2026 12:18:15 -0500",
            "by mail-ed1-x529.google.com with SMTP id\n 4fb4d7f45d1cf-65be78011c8so1553011a12.3\n for <qemu-devel@nongnu.org>; Thu, 19 Feb 2026 09:18:14 -0800 (PST)",
            "from draig.lan ([185.124.0.126]) by smtp.gmail.com with ESMTPSA id\n a640c23a62f3a-b8fc735e5a6sm597992366b.1.2026.02.19.09.18.11\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Thu, 19 Feb 2026 09:18:11 -0800 (PST)",
            "from draig.lan (localhost [IPv6:::1])\n by draig.lan (Postfix) with ESMTP id B417D5F8A0;\n Thu, 19 Feb 2026 17:18:10 +0000 (GMT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=linaro.org; s=google; t=1771521493; x=1772126293; 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=PctGYd5Mfdikoz9PktEn3l1PiB58v2keUC2KBTjncYk=;\n b=n35egehwbG748bnECAXwCMMsqrAbn8dFTPDqOt0RQgqHCcLgyJScqh6n1CeYD781j+\n tJg17l0OR5+whzZHoVrXXJrb5nKs+jfi4Zy8iaX34f2yAhEeeXwGKC7Ccr3010eG0CAF\n syWsa0QEjLnQpGeIA5WiFl5U3IgOqMxNqVvyWI2WYB+xMhDhYEhQ6lfKnnuzK5P1Z9en\n tj6Rkwp78Lo3Jhz+CPIpNxG5hikZkXDr9a8IDn1NMFb/TdyDBnPwL7NGcLt5xD/FAwpn\n ZHcR+pkiHe3cdCM0hbOBBkC6/7SeIpuDH87+OK5sK9yY7dsD9u+uIfBcYvGh6X9Un13+\n Kxjg==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20230601; t=1771521493; x=1772126293;\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=PctGYd5Mfdikoz9PktEn3l1PiB58v2keUC2KBTjncYk=;\n b=Ld2US6udC3FUFmlyWKyYz7JENpFPNeqzthaTAHDF/yt3QUbxZPGegByvGZlFTOG04s\n AbWSF9RYZCvJDBjaG19xzcPIYeyl2lGODaadUnUDjFHW5AN5nRTFPfGg82ICr2/0GFAW\n 40lfE1PZafKFtUfTWhfKHY2AAzJl7vnYjgQzV7iPdvPNAq2IOUieuYeytzzQo0yYikUr\n mlCIm1ctO3O8kAqX6VMlYAaesGn46WbRQnMkjQ0XBUoFfbxX38c9CADIQyf5ZyDT8EnW\n /G20lwMf1G75AXoL7h3DiLXJxLYS5jfiKL15sm9HIj6v69hFw69MK+p7NNKxuNVyZXll\n COLQ==",
        "X-Gm-Message-State": "AOJu0YyGpMSgkOFNwDTiI9PVnKLKb5vkwOzvRKJWPjSw/Oq3LS3ODfJb\n 2xC71QHU85E1RMV+9VxREWz+ZUmwpDZ6H5LiGfQCwug/7baHvlqJbKmMYNF2WWghMq8=",
        "X-Gm-Gg": "AZuq6aI8KhblDLSfIUqPmEeb/Xb6Byx7uKndmy2hQF/y9itIhxhXE8Q3QhNZyDWz0gs\n 7u/xJ5UCsNeBuA8qF7XhTJlV9Rnl1qkPSRcaGTNDFGnwoD0VTuNWQ3QiUxyKkyP70zBzFR3A22p\n JeAZe5abywAM+I+9X6Z2kmno6Sgk6OcW/+RGLejmFLi0O9XHCRnG1RStwJ5EICOncTAiayJgYSQ\n w8hIMrsHBcK/0li7heiUO1NHJ9XdnCcx6TXtFCWUNCfNxw0V5n30DJRmNRrEafLJ+J4XLfNaTUQ\n X8dNFi9ezkARmpePkjm3cxieL5jqzix/wCYldIfLkTSuPYYHSmanJyKtZHJwkjzPSrzs+QoDlst\n hQd8elkm4+0WopGVwBmpX26WlMHIIZ/qKT8ySnfLymB6YOASJTLEFjLZZFkCaJzg8D8xaUftJwk\n RCvDGBwxbvEVUYcu+y+USdnHo=",
        "X-Received": "by 2002:a17:907:980a:b0:b84:1fc7:944f with SMTP id\n a640c23a62f3a-b8face4d5c1mr1161789166b.45.1771521492516;\n Thu, 19 Feb 2026 09:18:12 -0800 (PST)",
        "From": "=?utf-8?q?Alex_Benn=C3=A9e?= <alex.bennee@linaro.org>",
        "To": "qemu-devel@nongnu.org",
        "Cc": "Yoshinori Sato <yoshinori.sato@nifty.com>, qemu-arm@nongnu.org,\n Laurent Vivier <laurent@vivier.eu>, Thomas Huth <huth@tuxfamily.org>,\n Marcel Apfelbaum <marcel.apfelbaum@gmail.com>,\n Akihiko Odaki <odaki@rsg.ci.i.u-tokyo.ac.jp>,\n Aurelien Jarno <aurelien@aurel32.net>,\n Jim MacArthur <jim.macarthur@linaro.org>,\n Eduardo Habkost <eduardo@habkost.net>,\n Peter Maydell <peter.maydell@linaro.org>,\n Bastian Koppelmann <kbastian@rumtueddeln.de>, =?utf-8?q?Philippe_Mathieu-Da?=\n\t=?utf-8?q?ud=C3=A9?= <philmd@linaro.org>,\n Aleksandar Rikalo <arikalo@gmail.com>,\n Richard Henderson <richard.henderson@linaro.org>,\n Zhao Liu <zhao1.liu@intel.com>, Jiaxun Yang <jiaxun.yang@flygoat.com>,\n Yanan Wang <wangyanan55@huawei.com>,\n =?utf-8?q?Alex_Benn=C3=A9e?= <alex.bennee@linaro.org>",
        "Subject": "[RFC PATCH v2 02/14] target/m68k: initialise pc/sp vector during\n reset",
        "Date": "Thu, 19 Feb 2026 17:17:58 +0000",
        "Message-ID": "<20260219171810.602667-3-alex.bennee@linaro.org>",
        "X-Mailer": "git-send-email 2.47.3",
        "In-Reply-To": "<20260219171810.602667-1-alex.bennee@linaro.org>",
        "References": "<20260219171810.602667-1-alex.bennee@linaro.org>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=UTF-8",
        "Content-Transfer-Encoding": "8bit",
        "Received-SPF": "pass client-ip=2a00:1450:4864:20::529;\n envelope-from=alex.bennee@linaro.org; helo=mail-ed1-x529.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": "All 68k chips should be able to follow the architectural behaviour on\nreset which is to load the initial sp/pc from the first 8 bytes of the\naddress space.\n\nTo avoid any potential issues with un-reset memory controllers we\npunt the final setting of the register to the exit phase when\neverything else is guaranteed to have been through the hold phase.\n\nSigned-off-by: Alex Bennée <alex.bennee@linaro.org>\n---\n target/m68k/cpu.c | 25 +++++++++++++++++++++----\n 1 file changed, 21 insertions(+), 4 deletions(-)",
    "diff": "diff --git a/target/m68k/cpu.c b/target/m68k/cpu.c\nindex d849a4a90fc..0dce8ef282e 100644\n--- a/target/m68k/cpu.c\n+++ b/target/m68k/cpu.c\n@@ -25,6 +25,7 @@\n \n #ifndef CONFIG_USER_ONLY\n #include \"migration/vmstate.h\"\n+#include \"system/memory.h\"\n #endif\n \n #include \"cpu.h\"\n@@ -174,9 +175,25 @@ static void m68k_cpu_reset_hold(Object *obj, ResetType type)\n     }\n     cpu_m68k_set_fpcr(env, 0);\n     env->fpsr = 0;\n+}\n \n-    /* TODO: We should set PC from the interrupt vector.  */\n-    env->pc = 0;\n+/*\n+ * We defer the final setting of the PC to the exit phase to ensure\n+ * if any memory controllers need to be reset they are before we read\n+ * the initial reset vector. This is a NOP for user-mode which will\n+ * set the PC in init_main_thread() after the CPU is reset.\n+ */\n+static void m68k_cpu_reset_exit(Object *obj, ResetType type)\n+{\n+#ifndef CONFIG_USER_ONLY\n+    CPUState *cs = CPU(obj);\n+    CPUM68KState *env = cpu_env(cs);\n+\n+    env->aregs[7] = address_space_ldl_be(cs->as, 0,\n+                                         MEMTXATTRS_UNSPECIFIED, NULL);\n+    env->pc = address_space_ldl_be(cs->as, 4,\n+                                   MEMTXATTRS_UNSPECIFIED, NULL);\n+#endif\n }\n \n static void m68k_cpu_disas_set_info(const CPUState *cs, disassemble_info *info)\n@@ -396,7 +413,6 @@ static void m68k_cpu_realizefn(DeviceState *dev, Error **errp)\n \n     m68k_cpu_init_gdb(cpu);\n \n-    cpu_reset(cs);\n     qemu_init_vcpu(cs);\n \n     mcc->parent_realize(dev, errp);\n@@ -641,7 +657,8 @@ static void m68k_cpu_class_init(ObjectClass *c, const void *data)\n \n     device_class_set_parent_realize(dc, m68k_cpu_realizefn,\n                                     &mcc->parent_realize);\n-    resettable_class_set_parent_phases(rc, NULL, m68k_cpu_reset_hold, NULL,\n+    resettable_class_set_parent_phases(rc, NULL,\n+                                       m68k_cpu_reset_hold, m68k_cpu_reset_exit,\n                                        &mcc->parent_phases);\n \n     cc->class_by_name = m68k_cpu_class_by_name;\n",
    "prefixes": [
        "RFC",
        "v2",
        "02/14"
    ]
}