From patchwork Fri Jun 7 19:12:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Tokarev X-Patchwork-Id: 802350 Delivered-To: patch@linaro.org Received: by 2002:adf:f147:0:b0:35b:5a80:51b4 with SMTP id y7csp1035693wro; Fri, 7 Jun 2024 16:42:32 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWDrYBqgrTOogP+0JXfErMURSJ5pVcXNJ+8Frs5xXMacuiUTQ9XbyHlbgUkfAFJwdc3NgDCfmqppv8MQRdXO9Ha X-Google-Smtp-Source: AGHT+IFZNIUr0i61hgL89szWRE14hUQH/1zH73chP1D1iHvor+vrYK45mZmBX3KRu6s3kLZ6Sp4X X-Received: by 2002:a05:620a:b41:b0:793:822:d737 with SMTP id af79cd13be357-7953c4d04c2mr365407085a.69.1717803751936; Fri, 07 Jun 2024 16:42:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1717803751; cv=none; d=google.com; s=arc-20160816; b=vJNklh7v5zMwTrMKkflhbf5EUo88Ajo4dTZ8BPCIzOHLGM6I0HD69D3L+LsSQSLx3G tVmdYQGjhxjfTE/tf8Ptxg8I7svakVxrqYEmi9AmoDNR4ZhnSrRyF4hU3TV5vAW7wFN5 2LmoNrDjsbd25g/QiV33EeFbUb5G2vmDRIaggTXR8ZL3jOhrE/Wlq+u88G6P5hQ+NNTi 12vh4QpW1TLoeEYO0o9D4bBuMWyyndS1iG2Vh3+kcWOKrYRcGE0Rcl4DepHgI4b6gyU1 UkSaV3/fjFq5N7x2I9HAQJY5vXRjU8DVJADwLN/2DrjxA83j2/sPtNW/OQhsokcFoQD8 qXCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from; bh=FmWxV7urJfQgDw9+FotgNqpFu+GvKtA9SQIwTsarLfs=; fh=aqdVPOO5/ewHx85jjyvtU77FupVJMtNmzkZraoCtO0Q=; b=s2GobVR+BUlNTGl0ESwpQoD+f1aZ/J0IyggBwWz+9D4FU6lyT2b1vH9AqAvKo5t22d L82WJJWw2QQAf4mzE1Zn6wAXojUvtB9R2QYP6N1nJumkuG+ZIg/N9oCzUKA5Zqg9NiVk dGLZm9xqLh9j6yBdhjXOleSu30S7ymPNjMMoLmGj+ywrLSZji6AqANEFBKOr5q3ZATP9 sUzC+8Wa6DeG0v0yQofkyVL0B+Up5FyBaUQ/LHJ0YT+IM/iyBLrGMhjwFCMpHBcXI2gd wyP8p8Nagimg2Cbxyk44ZVaywjo/h8LcIw22HU8rRHrEG1C9+pT2vl4dLHUqaOCX4aFr LG1w==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org" Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id af79cd13be357-79532850a92si396609985a.98.2024.06.07.16.42.31 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 07 Jun 2024 16:42:31 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org" Received: from [::1] (helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sFf15-0004ve-Tt; Fri, 07 Jun 2024 15:12:47 -0400 Received: from [2001:470:142:3::10] (helo=eggs.gnu.org) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sFf0z-0004Q5-5B; Fri, 07 Jun 2024 15:12:41 -0400 Received: from isrv.corpit.ru ([86.62.121.231]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sFf0x-0001gX-JC; Fri, 07 Jun 2024 15:12:40 -0400 Received: from tsrv.corpit.ru (tsrv.tls.msk.ru [192.168.177.2]) by isrv.corpit.ru (Postfix) with ESMTP id CBBFD6E531; Fri, 7 Jun 2024 22:13:15 +0300 (MSK) Received: from tls.msk.ru (mjt.wg.tls.msk.ru [192.168.177.130]) by tsrv.corpit.ru (Postfix) with SMTP id 10BEBE2731; Fri, 7 Jun 2024 22:12:21 +0300 (MSK) Received: (nullmailer pid 528243 invoked by uid 1000); Fri, 07 Jun 2024 19:12:20 -0000 From: Michael Tokarev To: qemu-devel@nongnu.org Cc: qemu-stable@nongnu.org, Marcin Juszkiewicz , Richard Henderson , Peter Maydell , Michael Tokarev Subject: [Stable-7.2.12 23/29] target/arm: Disable SVE extensions when SVE is disabled Date: Fri, 7 Jun 2024 22:12:06 +0300 Message-Id: <20240607191219.528194-4-mjt@tls.msk.ru> X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Received-SPF: pass client-ip=86.62.121.231; envelope-from=mjt@tls.msk.ru; helo=isrv.corpit.ru X-Spam_score_int: -68 X-Spam_score: -6.9 X-Spam_bar: ------ X-Spam_report: (-6.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_HI=-5, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org From: Marcin Juszkiewicz Cc: qemu-stable@nongnu.org Resolves: https://gitlab.com/qemu-project/qemu/-/issues/2304 Reported-by: Marcin Juszkiewicz Signed-off-by: Richard Henderson Signed-off-by: Marcin Juszkiewicz Message-id: 20240526204551.553282-1-richard.henderson@linaro.org Reviewed-by: Peter Maydell Signed-off-by: Peter Maydell (cherry picked from commit daf9748ac002ec35258e5986b6257961fd04b565) Signed-off-by: Michael Tokarev diff --git a/target/arm/cpu64.c b/target/arm/cpu64.c index 3d74f134f5..037e9d9feb 100644 --- a/target/arm/cpu64.c +++ b/target/arm/cpu64.c @@ -190,7 +190,11 @@ void arm_cpu_sve_finalize(ARMCPU *cpu, Error **errp) * No explicit bits enabled, and no implicit bits from sve-max-vq. */ if (!cpu_isar_feature(aa64_sve, cpu)) { - /* SVE is disabled and so are all vector lengths. Good. */ + /* + * SVE is disabled and so are all vector lengths. Good. + * Disable all SVE extensions as well. + */ + cpu->isar.id_aa64zfr0 = 0; return; }