get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 2216904,
    "url": "http://patchwork.ozlabs.org/api/patches/2216904/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260327111700.795099-56-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": "<20260327111700.795099-56-peter.maydell@linaro.org>",
    "list_archive_url": null,
    "date": "2026-03-27T11:16:50",
    "name": "[v2,55/65] hw/intc/arm_gicv3_cpuif: Don't allow GICv3 if CPU has GICv5 cpuif",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "4cc0ad825d2ef0a82fb183ec57c0fb549a35e15d",
    "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/20260327111700.795099-56-peter.maydell@linaro.org/mbox/",
    "series": [
        {
            "id": 497750,
            "url": "http://patchwork.ozlabs.org/api/series/497750/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/list/?series=497750",
            "date": "2026-03-27T11:16:25",
            "name": "arm: Implement an emulation of GICv5 interrupt controller",
            "version": 2,
            "mbox": "http://patchwork.ozlabs.org/series/497750/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2216904/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2216904/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=tQ0U+vZk;\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 4fhytG116zz1yFx\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 27 Mar 2026 22:22:46 +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 1w65DJ-0000Cr-2O; Fri, 27 Mar 2026 07:18:53 -0400",
            "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 1w65CT-0007RZ-P7\n for qemu-devel@nongnu.org; Fri, 27 Mar 2026 07:18:03 -0400",
            "from mail-wr1-x431.google.com ([2a00:1450:4864:20::431])\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 1w65CO-00005M-CM\n for qemu-devel@nongnu.org; Fri, 27 Mar 2026 07:17:58 -0400",
            "by mail-wr1-x431.google.com with SMTP id\n ffacd0b85a97d-439bcec8613so1482460f8f.3\n for <qemu-devel@nongnu.org>; Fri, 27 Mar 2026 04:17:55 -0700 (PDT)",
            "from lanath.. (wildly.archaic.org.uk. [81.2.115.145])\n by smtp.gmail.com with ESMTPSA id\n ffacd0b85a97d-43b919cf2b2sm15484227f8f.18.2026.03.27.04.17.53\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Fri, 27 Mar 2026 04:17:53 -0700 (PDT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=linaro.org; s=google; t=1774610274; x=1775215074; 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=1a+4VgJGkwP3gKjTiIhrHr9y9Q94+K/thWEGPABWjoI=;\n b=tQ0U+vZkkrdFzQFVLB0RMBI1PpqQvChnbYcyX5ug+8eeaJqUuMwgI+meUH+ZNMa0f0\n IKlHVJfLYTC0J9AIIpMYp2YS+JMdBAOIbAOgTXUtkgTMHS+QzCw/iqfdGCWiJGebZgJi\n uUTE3LK9IIk/2s/nuo3EQ5zPiyhsRNtv3MnzEeQ2XEb+987HvtpJNFDkT+oLCc7sDie5\n fWk4q2mYnkMsvSWcM43COkWqQqq+I59twTkrrv4wGw3ivfnGgFJxIyhcn944FP6GFm3J\n QL/VvpeHTkR4IRfr4Z+gzXnUO2Av3oefjkbJizPTz63juh0P9Pbhaq1CsRDlDr1YkLTl\n UUZA==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1774610274; x=1775215074;\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=1a+4VgJGkwP3gKjTiIhrHr9y9Q94+K/thWEGPABWjoI=;\n b=bKLCCbVELZ19q5yidrEKxoM52gxc7rWLc4vsP0KUokQR3VlRnYb3Jqg3dmXrgFy4io\n e0plBR8L1bwXQ1o/ilY6bARVtRhlriaNvtSzke3/CA9LqzAX9jyJb5YnqVpc0av1XSNn\n ZK8IuB9qulkWTPVuND+9tfou+in9gW7zEY8SftSXcr7L+7SW2dcwE876ruUc0W6+LZI1\n ULXMUi4jnMUjvNJ4R3EZkoIBjiC7GvLLb1a07GTksQLBHPHibn17sTOAfkitGVdZ/9X/\n fVWvMppasXaRFrcXSQmtqtZYpU+vTCf9u/TehozaU3zANT5oY71KaSm1OaVTR/0ysWuv\n cLUg==",
        "X-Forwarded-Encrypted": "i=1;\n AJvYcCWIScXu2phII1Dl4Rl7NVHEEZaz4FASGSgb+pv3qmDK+vmmEWCfBREqfSxZ801AioPotuqgdrdaS8KN@nongnu.org",
        "X-Gm-Message-State": "AOJu0YxY/ButYJ5LxEGVgFTxofGa764ZiLjnS3C72hzio+tlH81t/M2a\n S9SQvPASqe9QcTRpPn09Y9AzRVj7Q9hutHU8kkTofCfveOYoT8dvHdH3da6ZHuWfdII=",
        "X-Gm-Gg": "ATEYQzzON+N4Leg3YVLmTZAUX1qJNBTG4wtx5IekE+Z9f758h/hNxT2Ylb2fYvNvsHA\n LDb/z58Czmbssf9EMtuFBOYKJXuM064P422XXBh46objq1dXxBvCykImwnc9EyV4V4l1m6Xjd93\n puoDBeqcn4hdpx1sr/HQvquV5pWLFBx/5nd5Zc5PGAYvRjU4U/n1f+5bNKuiQRJD79Z4BVYH7Fv\n aLb+e1scj7b4c5dKMOBEqOxkq+/piVycobungaQGS90wpmxdiiZaGxA9Oy58MxJ5mYruISG63zr\n lyVGiPG4CLKTACcFfseIpv8ZnZ/PMdj2G793EBjxKotOpwHhfSdXcnQ8H+0VNxj81UQAcm7SqbS\n cD4Uuf2umb/bvc9oKq/tVsGiZQAPdL/grLzP3TxweomNIuTcnDDgZs9mwvh+CzIFTmcDjUZ2srC\n sPStwtWyXDE1IInW2H+b8XmX4CNVHayVLfioM+15eJGMMaA8bPC3gXtidup7firjc5AnNcelDLv\n xU7mZKA9BDSK1GlPq/XIikjl/FJecI=",
        "X-Received": "by 2002:a05:6000:2dc3:b0:43b:9986:2fbe with SMTP id\n ffacd0b85a97d-43b9ea76342mr2999444f8f.49.1774610274349;\n Fri, 27 Mar 2026 04:17:54 -0700 (PDT)",
        "From": "Peter Maydell <peter.maydell@linaro.org>",
        "To": "qemu-arm@nongnu.org,\n\tqemu-devel@nongnu.org",
        "Cc": "Jonathan Cameron <jonathan.cameron@huawei.com>",
        "Subject": "[PATCH v2 55/65] hw/intc/arm_gicv3_cpuif: Don't allow GICv3 if CPU\n has GICv5 cpuif",
        "Date": "Fri, 27 Mar 2026 11:16:50 +0000",
        "Message-ID": "<20260327111700.795099-56-peter.maydell@linaro.org>",
        "X-Mailer": "git-send-email 2.43.0",
        "In-Reply-To": "<20260327111700.795099-1-peter.maydell@linaro.org>",
        "References": "<20260327111700.795099-1-peter.maydell@linaro.org>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Received-SPF": "pass client-ip=2a00:1450:4864:20::431;\n envelope-from=peter.maydell@linaro.org; helo=mail-wr1-x431.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 GICv3 and GICv5 CPU interfaces are not compatible, and a CPU will\nonly implement either one or the other.  If we find that we're trying\nto connect a GICv3 to a CPU that implements FEAT_GCIE, fail.  This\nwill only happen if the board code has a bug and doesn't configure\nits CPUs and its GIC consistently.\n\nSigned-off-by: Peter Maydell <peter.maydell@linaro.org>\nReviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com>\n---\n hw/intc/arm_gicv3.c       |  2 +-\n hw/intc/arm_gicv3_cpuif.c | 14 +++++++++++++-\n hw/intc/gicv3_internal.h  |  2 +-\n 3 files changed, 15 insertions(+), 3 deletions(-)",
    "diff": "diff --git a/hw/intc/arm_gicv3.c b/hw/intc/arm_gicv3.c\nindex 542f81ea49..e93c1df5b4 100644\n--- a/hw/intc/arm_gicv3.c\n+++ b/hw/intc/arm_gicv3.c\n@@ -449,7 +449,7 @@ static void arm_gic_realize(DeviceState *dev, Error **errp)\n \n     gicv3_init_irqs_and_mmio(s, gicv3_set_irq, gic_ops);\n \n-    gicv3_init_cpuif(s);\n+    gicv3_init_cpuif(s, errp);\n }\n \n static void arm_gicv3_class_init(ObjectClass *klass, const void *data)\ndiff --git a/hw/intc/arm_gicv3_cpuif.c b/hw/intc/arm_gicv3_cpuif.c\nindex eaf1e512ed..73e06f87d4 100644\n--- a/hw/intc/arm_gicv3_cpuif.c\n+++ b/hw/intc/arm_gicv3_cpuif.c\n@@ -16,6 +16,7 @@\n #include \"qemu/bitops.h\"\n #include \"qemu/log.h\"\n #include \"qemu/main-loop.h\"\n+#include \"qapi/error.h\"\n #include \"trace.h\"\n #include \"gicv3_internal.h\"\n #include \"hw/core/irq.h\"\n@@ -3016,7 +3017,7 @@ static void gicv3_cpuif_el_change_hook(ARMCPU *cpu, void *opaque)\n     gicv3_cpuif_virt_irq_fiq_update(cs);\n }\n \n-void gicv3_init_cpuif(GICv3State *s)\n+void gicv3_init_cpuif(GICv3State *s, Error **errp)\n {\n     /* Called from the GICv3 realize function; register our system\n      * registers with the CPU\n@@ -3027,6 +3028,17 @@ void gicv3_init_cpuif(GICv3State *s)\n         ARMCPU *cpu = ARM_CPU(qemu_get_cpu(s->first_cpu_idx + i));\n         GICv3CPUState *cs = &s->cpu[i];\n \n+        if (cpu_isar_feature(aa64_gcie, cpu)) {\n+            /*\n+             * Attempt to connect GICv3 to a CPU with GICv5 cpuif\n+             * (almost certainly a bug in the board code)\n+             */\n+            error_setg(errp,\n+                       \"Cannot connect GICv3 to CPU %d which has GICv5 cpuif\",\n+                       i);\n+            return;\n+        }\n+\n         /*\n          * If the CPU doesn't define a GICv3 configuration, probably because\n          * in real hardware it doesn't have one, then we use default values\ndiff --git a/hw/intc/gicv3_internal.h b/hw/intc/gicv3_internal.h\nindex 880dbe52d8..c01be70464 100644\n--- a/hw/intc/gicv3_internal.h\n+++ b/hw/intc/gicv3_internal.h\n@@ -722,7 +722,7 @@ void gicv3_redist_mov_vlpi(GICv3CPUState *src, uint64_t src_vptaddr,\n void gicv3_redist_vinvall(GICv3CPUState *cs, uint64_t vptaddr);\n \n void gicv3_redist_send_sgi(GICv3CPUState *cs, int grp, int irq, bool ns);\n-void gicv3_init_cpuif(GICv3State *s);\n+void gicv3_init_cpuif(GICv3State *s, Error **errp);\n \n /**\n  * gicv3_cpuif_update:\n",
    "prefixes": [
        "v2",
        "55/65"
    ]
}