{"id":2224043,"url":"http://patchwork.ozlabs.org/api/covers/2224043/?format=json","web_url":"http://patchwork.ozlabs.org/project/qemu-devel/cover/20260416165353.589569-1-peter.maydell@linaro.org/","project":{"id":14,"url":"http://patchwork.ozlabs.org/api/projects/14/?format=json","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":"<20260416165353.589569-1-peter.maydell@linaro.org>","list_archive_url":null,"date":"2026-04-16T16:53:50","name":"[v2,0/3] target/arm: Allow aarch64=off for TCG","submitter":{"id":5111,"url":"http://patchwork.ozlabs.org/api/people/5111/?format=json","name":"Peter Maydell","email":"peter.maydell@linaro.org"},"mbox":"http://patchwork.ozlabs.org/project/qemu-devel/cover/20260416165353.589569-1-peter.maydell@linaro.org/mbox/","series":[{"id":500185,"url":"http://patchwork.ozlabs.org/api/series/500185/?format=json","web_url":"http://patchwork.ozlabs.org/project/qemu-devel/list/?series=500185","date":"2026-04-16T16:53:50","name":"target/arm: Allow aarch64=off for TCG","version":2,"mbox":"http://patchwork.ozlabs.org/series/500185/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/covers/2224043/comments/","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=efo5zqTF;\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 4fxPJP48P9z1yG9\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 17 Apr 2026 02:55: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 1wDPye-00068W-Eg; Thu, 16 Apr 2026 12:54:04 -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 <peter.maydell@linaro.org>)\n id 1wDPyc-000681-5o\n for qemu-devel@nongnu.org; Thu, 16 Apr 2026 12:54:03 -0400","from mail-wm1-x330.google.com ([2a00:1450:4864:20::330])\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 1wDPyZ-0007Wc-LS\n for qemu-devel@nongnu.org; Thu, 16 Apr 2026 12:54:01 -0400","by mail-wm1-x330.google.com with SMTP id\n 5b1f17b1804b1-4852a9c6309so75965655e9.0\n for <qemu-devel@nongnu.org>; Thu, 16 Apr 2026 09:53:59 -0700 (PDT)","from lanath.. (wildly.archaic.org.uk. [81.2.115.145])\n by smtp.gmail.com with ESMTPSA id\n 5b1f17b1804b1-488fa79d476sm473035e9.1.2026.04.16.09.53.54\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Thu, 16 Apr 2026 09:53:55 -0700 (PDT)"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=linaro.org; s=google; t=1776358438; x=1776963238; darn=nongnu.org;\n h=content-transfer-encoding:mime-version:message-id:date:subject:cc\n :to:from:from:to:cc:subject:date:message-id:reply-to;\n bh=Prv6XnWS1b0WHiNYlODggkmm/Lh0xfjDgprbZpOCctA=;\n b=efo5zqTFe4+GAMqTgiPN4xWErg3uxbTaCOCBHnXwuLSle5nT+pXHj3o6vCeAlMSUWC\n +2is3pHEK9Qz0cba94qNfCLTmckn2hJHWw5f74LUfZUzyBaS6xBXv9ctzkjBbb3m9bAy\n aHAtiLQLxGShnfWFYJPLlomFKY2zZm+mRXkKCDp63MTcAxU853hdCLD9KOnn1rvIg1Sq\n hLebaSWqPEqPE+S3is0bEUo+HPOjP6lRLNe3BpisxpaAMx4w3vmSgPb9KBHd5oBknu/1\n /X8iMHbN3c37HW+dOP2qZ5uI6QZlPlwkNKEUCqYX+rSE4I6LLWW8ybOXBpqdSRBkqHZk\n Nxuw==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1776358438; x=1776963238;\n h=content-transfer-encoding:mime-version:message-id:date:subject:cc\n :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date\n :message-id:reply-to;\n bh=Prv6XnWS1b0WHiNYlODggkmm/Lh0xfjDgprbZpOCctA=;\n b=GrCx6eM0LgNFARuT7aLZO8E50w4Lnuvvu+4XHgKqoooqk6lmJrpXdwtEf8OBtp3jvw\n PKpECwyJmJr7ce0oy2p3dHMG/Rok4OHG0rAmBeG/xCTIC61hmO/6GiKV0fdGK+0migIY\n DXn+jjS0FdBvrsueR/hQZBYS+/9ApKZ4Kfit2FwQMDOxUY9HDiRSPlLpef6IeUzHwl6i\n +C7vre1Fsq6cSZKnVeO1Kg6WspUb4Sh/gEjLHJU/nD5IBgp1Bje0SoD9J1Ty4Q9b+7Ti\n Vu7UHX7UkA50dCYasccSbby/yfVLvhA6zwWJZjcQxMFwH9w2KtPXL2w/RGpCYvPQhzJF\n lezw==","X-Forwarded-Encrypted":"i=1;\n AFNElJ9vefz7veN/9Q7USsDsOah+f7X60qSY/7oUQfE73V/vy7mCgxLfpKtIgCsQlC0IBFjv7NAe/rYdOmoD@nongnu.org","X-Gm-Message-State":"AOJu0YyaUOmNPOkH4loOlY+dChwBeHWFg8g6Z5+b9V9hhflS/aiYvtCk\n P5zql2qCm3hwl6nWxU6ZNbMKczso957E+G0ZrrKGgsQy+5BdZPj8dkERY8ySW16EBoQ=","X-Gm-Gg":"AeBDietOt9hmHGcfh6dEV3KExmWVP9s6sd8FNscTheHPzCpMXGV6vuZ+wK9x9i4VcBq\n WLx5BLDKCPO6vZrH38BGFQp6ETfaA6iHLb6L5YFh8ErcahnOs1Xk8stg3cGE5EAnuMqKPRtBBt1\n pjXppIfH+23ZoFE8i1n3zcoHyEiibgZxoHFvU8qnWh2q/+aMgnUvBiAkCgEsEaWesZJ1HW1aW6e\n 5cdrgh474DDP/S3Y1G8aZi61oP9Xx/GhCNQAgK3KDmiR4DI78dIaQMea8UclMDL2t8wgcAzC/3t\n BY5dYken2II0VK/ZOL1LLhEpZaBx47JDaz0zhMauPVT/sw8LyA4b5uJYGfjKMTd1pwqhfAyEbVs\n EMzxWnLlv4D232gMuDBTrGbPgMqexglsCx/ezF9L/NxC7MDFIlFBe3TUzV0E9Ax6ssSw38Qkhly\n pMwgovP466IBfu6gf2+mufSVjPj9sSh4wvguYc/uxh886LpeoVY5XCgorORwPOLQAV86kW+Un39\n bYJ3dsvinhZkD1g0jpsl8j2ei/jRKF2H/OpFJcdkLdOtm9X+mRu","X-Received":"by 2002:a05:600c:a404:b0:487:1108:48b8 with SMTP id\n 5b1f17b1804b1-488d67b8d97mr321520695e9.2.1776358437763;\n Thu, 16 Apr 2026 09:53:57 -0700 (PDT)","From":"Peter Maydell <peter.maydell@linaro.org>","To":"qemu-arm@nongnu.org,\n\tqemu-devel@nongnu.org","Cc":"Richard Henderson <richard.henderson@linaro.org>, =?utf-8?q?Cl=C3=A9ment?=\n\t=?utf-8?q?_Chigot?= <chigot@adacore.com>","Subject":"[PATCH v2 0/3] target/arm: Allow aarch64=off for TCG","Date":"Thu, 16 Apr 2026 17:53:50 +0100","Message-ID":"<20260416165353.589569-1-peter.maydell@linaro.org>","X-Mailer":"git-send-email 2.43.0","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Received-SPF":"pass client-ip=2a00:1450:4864:20::330;\n envelope-from=peter.maydell@linaro.org; helo=mail-wm1-x330.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":"This patchset relaxes our current constraint that we only permit\n-cpu foo,aarch64=off on KVM CPUs, so that you can also use this\nto run a TCG CPU with aarch64 disabled. This is useful because\ncurrently if you want a 32-bit TCG CPU you're limited to either\n'max' in qemu-system-arm or else the old v7-only CPUs like a15.\n\nI sent out v1 back in October last year. The main changes\nhere are:\n - as I said we ought to do in a follow up to those patches\n   https://lore.kernel.org/qemu-devel/CAFEAcA9KeO2r+jNont_2Jpvi5MgViH3nXO7TcbANe+3nS_PF-A@mail.gmail.com/\n   I've switched to only clearing the AArch64 ID regs with\n   TCG; we leave the KVM aarch64=off behaviour alone. (Clearing\n   the regs didn't break KVM, but did leave us in the odd\n   situation that QEMU and KVM didn't have the same idea about\n   what the ID reg values were, which seems like it might lead\n   to subtle problems later.)\n - I've added a simple functional test which boots one of\n   the kernels we use for a 32-bit functional test using\n   qemu-system-aarch64 and -cpu max,aarch64=off\n\nI also made a tiny tweak to the docs wording.\n\nPatches 1 and 3 need review.\n\nthanks\n-- PMM\n\nPeter Maydell (3):\n  target/arm: Clear AArch64 ID regs from ARMISARegisters if AArch64\n    disabled\n  target/arm: Allow 'aarch64=off' to be set for TCG CPUs\n  tests/functional/aarch64: Add basic test of TCG aarch64=off\n\n docs/system/arm/cpu-features.rst              | 10 +--\n target/arm/cpu-features.h                     |  5 ++\n target/arm/cpu.c                              | 71 +++++++++++++++++--\n target/arm/cpu.h                              |  3 +-\n tests/functional/aarch64/meson.build          |  1 +\n .../aarch64/test_virt_aarch64_off.py          | 37 ++++++++++\n tests/qtest/arm-cpu-features.c                |  8 +--\n 7 files changed, 120 insertions(+), 15 deletions(-)\n create mode 100755 tests/functional/aarch64/test_virt_aarch64_off.py"}