get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 2222890,
    "url": "http://patchwork.ozlabs.org/api/1.1/patches/2222890/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260414003001.97571-10-philmd@linaro.org/",
    "project": {
        "id": 14,
        "url": "http://patchwork.ozlabs.org/api/1.1/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": "<20260414003001.97571-10-philmd@linaro.org>",
    "date": "2026-04-14T00:29:41",
    "name": "[v3,09/27] monitor: Do not check TARGET_S390X to build s390x commands",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "43b37eaa4de3ecd1c1f5d8ddf7b2bcce58c72887",
    "submitter": {
        "id": 85046,
        "url": "http://patchwork.ozlabs.org/api/1.1/people/85046/?format=api",
        "name": "Philippe Mathieu-Daudé",
        "email": "philmd@linaro.org"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260414003001.97571-10-philmd@linaro.org/mbox/",
    "series": [
        {
            "id": 499762,
            "url": "http://patchwork.ozlabs.org/api/1.1/series/499762/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/list/?series=499762",
            "date": "2026-04-14T00:29:32",
            "name": "monitor: Remove need of per-target handlers",
            "version": 3,
            "mbox": "http://patchwork.ozlabs.org/series/499762/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2222890/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2222890/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=DfeoilOn;\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=lists1p.gnu.org;\n envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org;\n receiver=patchwork.ozlabs.org)"
        ],
        "Received": [
            "from lists1p.gnu.org (lists1p.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 4fvlb41JLNz1yCv\n\tfor <incoming@patchwork.ozlabs.org>; Tue, 14 Apr 2026 10:32:00 +1000 (AEST)",
            "from localhost ([::1] helo=lists1p.gnu.org)\n\tby lists1p.gnu.org with esmtp (Exim 4.90_1)\n\t(envelope-from <qemu-devel-bounces@nongnu.org>)\n\tid 1wCRgT-00020u-SN; Mon, 13 Apr 2026 20:31:17 -0400",
            "from eggs.gnu.org ([2001:470:142:3::10])\n by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <philmd@linaro.org>) id 1wCRgS-0001oq-2L\n for qemu-devel@nongnu.org; Mon, 13 Apr 2026 20:31:16 -0400",
            "from mail-wm1-x32c.google.com ([2a00:1450:4864:20::32c])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)\n (Exim 4.90_1) (envelope-from <philmd@linaro.org>) id 1wCRgP-0003Bm-H2\n for qemu-devel@nongnu.org; Mon, 13 Apr 2026 20:31:15 -0400",
            "by mail-wm1-x32c.google.com with SMTP id\n 5b1f17b1804b1-488aa77a06eso83638825e9.0\n for <qemu-devel@nongnu.org>; Mon, 13 Apr 2026 17:31:12 -0700 (PDT)",
            "from localhost.localdomain (88-187-86-199.subs.proxad.net.\n [88.187.86.199]) by smtp.gmail.com with ESMTPSA id\n 5b1f17b1804b1-488ede1de4asm15084895e9.4.2026.04.13.17.31.09\n (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256);\n Mon, 13 Apr 2026 17:31:10 -0700 (PDT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=linaro.org; s=google; t=1776126670; x=1776731470; 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=QyVhBxhNqIKQm4mEyhy8i6F7z6Ge4ld3eF+gEeCDR2s=;\n b=DfeoilOnivvmryKNscefH+nzIR5AHUbtGeCB3W8MzaoXayzVVznRnoUpHaUBzNA2b9\n KAOtEhEmTkQJmcVL0XVn/6nokuiwq4N384YAfaeKFSJLEOx7Vb7UKnOeJcJL4pL/Y1pi\n J9L/7dk816o9Cb9NAMfhgPBWFma2E2GxpQf1cZP5wy9lawHEw34zj3gZXjxzUFuuIlI5\n gM9r3mSyRscX1tguLCEkwUGrlibPEPM6pNJQ2cr4Bnr9vtW1Q+L5xwH3llBZUoX/PDDe\n EJIRpxcYonbEh6We3kkBuyjbQZ25XNltxiE16nvApP48xzlot+dXmVe5pIyic65vFdAz\n FKIA==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1776126670; x=1776731470;\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=QyVhBxhNqIKQm4mEyhy8i6F7z6Ge4ld3eF+gEeCDR2s=;\n b=r0Y5KWPIXvNL+aKyP7/cttUXs82Mqyk8u3DR2OBWvaW2hutcGvaC9NQBByfYCoQjOm\n lCSq6+QUD5XhDXe9KBzZ2tXKm0xEVfZZSbXnTo6UpPpbsilqMNVirxvsvpm9EHkHmrUV\n /hd91YSs2wQIZDM73sT/YnNuv0wVM8VebDQmbNl5Tu2JfA9KorQ5y20OJabSqrOgOOHF\n HHbp1fXZpelawuAUPGYeDO+g1yNzajS6OVuLeLKXaz89u7NwlH03Grgk7iIiIwhhOUPl\n RAct7a3wUODCwOyboW8yzO+x2uXqOp9aqTLjOu6V0sqZk4u4eLhviv0IoLQI5KndQAKU\n 2uWQ==",
        "X-Gm-Message-State": "AOJu0YwQZ7xskD39k2L2Xk93KMrLCpA4fWXegdWaawdKjStLqZzOfIo9\n y50+aXZYYhtEFAf0/CG6SWJZZlj1j4CC8YiS5oGIGBscstyxDb1QVrBbBABEwsEOYXnz5n7cdDl\n MDOyeNRc=",
        "X-Gm-Gg": "AeBDiet6jNCz356xthC1nsEUVhx2BfZqLvPwgxEx9VYfEVvu+7uS0SP0ARUPija7cWe\n UKdQ1lft/oabUAAlp+2LulJsNhFEGg+Gc89t9iZdB6atxRAWf8nUjnAMicBwyVaZYhI8mgjllN9\n BRpiFwDqIyQ4FCJS1uwZdxY6GulzgkKI7BqFYObR94OrEBzIbxyxBJKcmHcaThyC0KSqsIom4k5\n KHF513Q/iQpWMd55SFffpYl6Qqcg1+9ZwbGfZhgpX1jBb0nIEEKEDhNp3vVDsD7oLrTXsukxfQl\n nXEB49Wqf9jeZt7cPXrm+EcXEB+ujci6tmhByjzyBsGAoJmvSEo06AftJvXdZhrPniRmdRxVsPJ\n 7IzHAB+G3tgbNk6nMREd9x/RtkiLpDL7Ab7gXYb3LR8aY5iKdo6gYhOGxBrRFuCqOks7CsaCBri\n xpPpjIlCDUFY6N/KTpeu6rgwmmhfVzFsMqPKThkDogbQF61mbpf8YiI/ljZvLUcCmFz55Flffo",
        "X-Received": "by 2002:a05:600c:331e:b0:486:fba7:b150 with SMTP id\n 5b1f17b1804b1-488d684323amr118458355e9.15.1776126670568;\n Mon, 13 Apr 2026 17:31:10 -0700 (PDT)",
        "From": "=?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= <philmd@linaro.org>",
        "To": "qemu-devel@nongnu.org",
        "Cc": "Pierrick Bouvier <pierrick.bouvier@linaro.org>,\n Markus Armbruster <armbru@redhat.com>,\n Richard Henderson <richard.henderson@linaro.org>,\n \"Dr. David Alan Gilbert\" <dave@treblig.org>,\n Paolo Bonzini <pbonzini@redhat.com>,\n =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= <philmd@linaro.org>,\n Cornelia Huck <cohuck@redhat.com>, Eric Farman <farman@linux.ibm.com>,\n Matthew Rosato <mjrosato@linux.ibm.com>, qemu-s390x@nongnu.org",
        "Subject": "[PATCH v3 09/27] monitor: Do not check TARGET_S390X to build s390x\n commands",
        "Date": "Tue, 14 Apr 2026 02:29:41 +0200",
        "Message-ID": "<20260414003001.97571-10-philmd@linaro.org>",
        "X-Mailer": "git-send-email 2.53.0",
        "In-Reply-To": "<20260414003001.97571-1-philmd@linaro.org>",
        "References": "<20260414003001.97571-1-philmd@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::32c;\n envelope-from=philmd@linaro.org; helo=mail-wm1-x32c.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": "These commands are filtered at build-time for s390x binary.\nBy using the recently introduced HMPCommand::arch_bitmask flag\nwe can filter them at runtime, making it possible to compile\nhmp-commands[-info].hx files once.\n\nSince the methods are used inconditionally within hw/s390x/,\ndefine them in the same stub file.\n\nSigned-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>\nReviewed-by: Richard Henderson <richard.henderson@linaro.org>\nAcked-by: Cornelia Huck <cohuck@redhat.com>\n---\n MAINTAINERS               |  1 +\n include/monitor/hmp.h     |  7 +++++++\n monitor/hmp-target.c      |  5 -----\n stubs/hmp-cmds-hw-s390x.c | 15 +++++++++++++++\n hmp-commands-info.hx      |  6 ++----\n hmp-commands.hx           |  6 ++----\n stubs/meson.build         |  1 +\n 7 files changed, 28 insertions(+), 13 deletions(-)\n create mode 100644 stubs/hmp-cmds-hw-s390x.c",
    "diff": "diff --git a/MAINTAINERS b/MAINTAINERS\nindex cf462793a79..306835ff678 100644\n--- a/MAINTAINERS\n+++ b/MAINTAINERS\n@@ -122,6 +122,7 @@ F: include/hw/watchdog/wdt_diag288.h\n F: pc-bios/s390-ccw/\n F: pc-bios/s390-ccw.img\n F: stubs/qmp-cpu-s390x.c\n+F: stubs/hmp-cmds-hw-s390x.c\n F: target/s390x/\n F: docs/system/target-s390x.rst\n F: docs/system/s390x/\ndiff --git a/include/monitor/hmp.h b/include/monitor/hmp.h\nindex d694bfdf768..a29185741b8 100644\n--- a/include/monitor/hmp.h\n+++ b/include/monitor/hmp.h\n@@ -16,6 +16,13 @@\n \n #include \"qemu/readline.h\"\n #include \"qapi/qapi-types-common.h\"\n+#include \"monitor/monitor.h\"\n+\n+#define HMP_STUB(cmd) \\\n+    void hmp_##cmd(Monitor *mon, const QDict *qdict) \\\n+    { \\\n+        g_assert_not_reached(); \\\n+    }\n \n bool hmp_handle_error(Monitor *mon, Error *err);\n void hmp_help_cmd(Monitor *mon, const char *name);\ndiff --git a/monitor/hmp-target.c b/monitor/hmp-target.c\nindex f6dce326cf5..a222fd4c96a 100644\n--- a/monitor/hmp-target.c\n+++ b/monitor/hmp-target.c\n@@ -36,11 +36,6 @@\n #include \"qapi/qapi-commands-misc.h\"\n #include \"qapi/qapi-commands-machine.h\"\n \n-#if defined(TARGET_S390X)\n-#include \"hw/s390x/storage-keys.h\"\n-#include \"hw/s390x/storage-attributes.h\"\n-#endif\n-\n /* Make devices configuration available for use in hmp-commands*.hx templates */\n #include CONFIG_DEVICES\n \ndiff --git a/stubs/hmp-cmds-hw-s390x.c b/stubs/hmp-cmds-hw-s390x.c\nnew file mode 100644\nindex 00000000000..2b4f4cac79f\n--- /dev/null\n+++ b/stubs/hmp-cmds-hw-s390x.c\n@@ -0,0 +1,15 @@\n+/*\n+ * Human Monitor hw/s390x stubs\n+ *\n+ * Copyright (c) Linaro\n+ *\n+ * SPDX-License-Identifier: GPL-2.0-or-later\n+ */\n+\n+#include \"qemu/osdep.h\"\n+#include \"monitor/hmp.h\"\n+\n+HMP_STUB(dump_skeys)\n+HMP_STUB(info_cmma)\n+HMP_STUB(info_skeys)\n+HMP_STUB(migrationmode)\ndiff --git a/hmp-commands-info.hx b/hmp-commands-info.hx\nindex 463038c302a..28dec25642d 100644\n--- a/hmp-commands-info.hx\n+++ b/hmp-commands-info.hx\n@@ -717,30 +717,28 @@ SRST\n     Show rocker OF-DPA groups.\n ERST\n \n-#if defined(TARGET_S390X)\n     {\n         .name       = \"skeys\",\n         .args_type  = \"addr:l\",\n         .params     = \"address\",\n         .help       = \"Display the value of a storage key\",\n         .cmd        = hmp_info_skeys,\n+        .arch_bitmask = QEMU_ARCH_S390X,\n     },\n-#endif\n \n SRST\n   ``info skeys`` *address*\n     Display the value of a storage key (s390 only)\n ERST\n \n-#if defined(TARGET_S390X)\n     {\n         .name       = \"cmma\",\n         .args_type  = \"addr:l,count:l?\",\n         .params     = \"address [count]\",\n         .help       = \"Display the values of the CMMA storage attributes for a range of pages\",\n         .cmd        = hmp_info_cmma,\n+        .arch_bitmask = QEMU_ARCH_S390X,\n     },\n-#endif\n \n SRST\n   ``info cmma`` *address*\ndiff --git a/hmp-commands.hx b/hmp-commands.hx\nindex 06d7b17bf25..ff65b39b454 100644\n--- a/hmp-commands.hx\n+++ b/hmp-commands.hx\n@@ -1125,30 +1125,28 @@ SRST\n \n ERST\n \n-#if defined(TARGET_S390X)\n     {\n         .name       = \"dump-skeys\",\n         .args_type  = \"filename:F\",\n         .params     = \"\",\n         .help       = \"Save guest storage keys into file 'filename'.\\n\",\n         .cmd        = hmp_dump_skeys,\n+        .arch_bitmask = QEMU_ARCH_S390X,\n     },\n-#endif\n \n SRST\n ``dump-skeys`` *filename*\n   Save guest storage keys to a file.\n ERST\n \n-#if defined(TARGET_S390X)\n     {\n         .name       = \"migration_mode\",\n         .args_type  = \"mode:i\",\n         .params     = \"mode\",\n         .help       = \"Enables or disables migration mode\\n\",\n         .cmd        = hmp_migrationmode,\n+        .arch_bitmask = QEMU_ARCH_S390X,\n     },\n-#endif\n \n SRST\n ``migration_mode`` *mode*\ndiff --git a/stubs/meson.build b/stubs/meson.build\nindex 2d334a5a8f3..32c16209543 100644\n--- a/stubs/meson.build\n+++ b/stubs/meson.build\n@@ -86,6 +86,7 @@ if have_system\n   stub_ss.add(files('qmp-cpu.c'))\n   stub_ss.add(files('qmp-cpu-s390x.c'))\n   stub_ss.add(files('qmp-cpu-s390x-kvm.c'))\n+  stub_ss.add(files('hmp-cmds-hw-s390x.c'))\n endif\n \n if have_system or have_user\n",
    "prefixes": [
        "v3",
        "09/27"
    ]
}