From nobody Wed Nov 27 11:51:23 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1699269295; cv=none; d=zohomail.com; s=zohoarc; b=oDh1lAJ6q9e5Tf/xAWi05r0q03fT7SY8sQbTomj979JH/S4ZS3qkdwaWSUQvQV/iBDDSdd7rcmXexo3AD6K3bIZfZN3VJiht9UuP4dwI+zEUHXlrtmJo9SKK4qOU0WDBKzQe2mKIdSsM8T4FM6KTdqJKx10t27CR94i+OYJ3PD4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1699269295; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=R87QIdTSbuBFqtOuBBqCdN1J8XfSkpLJYhBFwzXT2iA=; b=RMKQmLmzoHS2EErxpoK9ODqcVqJ7k6jN5dnohvZHYnZP+yJ0QFrlpi79ecZHlKafqsMoNxAK/JDpl3TuSGa8gtwCNr7i++FrA9pl7tEjOVaJ6LyxoEYQns2cK8ATZRc4XZYL3t50ISaRPBAPGK88JzZ0rJwBUchGivOzr/8RZRk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1699269295405783.5255199405849; Mon, 6 Nov 2023 03:14:55 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qzxRW-0002Vi-8b; Mon, 06 Nov 2023 06:06:54 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qzxQz-0001ei-JZ for qemu-devel@nongnu.org; Mon, 06 Nov 2023 06:06:26 -0500 Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qzxQw-0004O5-Jx for qemu-devel@nongnu.org; Mon, 06 Nov 2023 06:06:21 -0500 Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-4079ed65582so32860215e9.1 for ; Mon, 06 Nov 2023 03:06:06 -0800 (PST) Received: from m1x-phil.lan (176-131-220-199.abo.bbox.fr. [176.131.220.199]) by smtp.gmail.com with ESMTPSA id i20-20020a05600c355400b0040839fcb217sm11896421wmq.8.2023.11.06.03.06.03 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Mon, 06 Nov 2023 03:06:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1699268766; x=1699873566; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=R87QIdTSbuBFqtOuBBqCdN1J8XfSkpLJYhBFwzXT2iA=; b=Kj/1LaOCc8ohvfAmi8Yz10wI2m4KbFPHjnDS4xi3yvwiMQPOAWM88ygVYIxCv7WE6o igHycHZ1IARjealLc8DwDef/bsE6vWViPkuyzYcmuWVNarBlrOx7JnHX99TgWu4oSYd0 TXpckHGQTlrzg2IMJASV/+1uF+j2jqlMRGaxVcxpfsxZbxWXwlqZDWeH+iYuPiZjHhtg o7fYOJTNTVFip8+civVvL77jpFN8ws/y37wyNxzxSLnelktqSKQzz+ph0NlJ1gpyHzyD vdaPi1M2MBgBwbYNPaIzXZVaFh0oq08rVJaGb3L/eHoLhyvou3bbwRrksAPCONXIiqT4 yt+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1699268766; x=1699873566; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=R87QIdTSbuBFqtOuBBqCdN1J8XfSkpLJYhBFwzXT2iA=; b=hDpq2HDUZw1F6P0OcN0RSchzZYK5N048TTKEhhsyzTQrE1tDxn5E4VnTIEPasxyc8/ 0SUmQEma63WKTobQtGRBQImOARWhClyAlhwP9baiZUgQf6hBT7MOKhqm05diTN3RHOmm EtLTLjaoFvBiiCUC3Sq8p+N9TRAQFhzI3DDvtpc8ntRcb2jFHHfQBSUIZbP6QTI8dudj zTHddzer3OVwT9XJkJ0kVhVNlhPICDsyT4LlqX0vNWHTmxL0TT+ec88xUm8zIAg/vXaM JKGghEx8gjK2n+EYEi+ubp0eX0A8OFDm9biE03CdZVmOWHksRgn/BXSlr703Dfisrix0 sAqA== X-Gm-Message-State: AOJu0Yx24lytU/jkrNHlUh+zqhKw8M3pVFJ3e7w0/Bp2REkRYGUM36qf 98cpLwMi27WK+OseY8cckyyv3ym7gBUh6Ky39xA= X-Google-Smtp-Source: AGHT+IEAb7mlXjiV+t8xOiAWlZzqIbRP1ddqvYwThww0DxTtH+DpaAZtlEj/6Pj1UY+lnDvwGergOA== X-Received: by 2002:a05:600c:3148:b0:405:1c19:b747 with SMTP id h8-20020a05600c314800b004051c19b747mr24127659wmo.15.1699268765817; Mon, 06 Nov 2023 03:06:05 -0800 (PST) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: kvm@vger.kernel.org, qemu-s390x@nongnu.org, qemu-block@nongnu.org, qemu-riscv@nongnu.org, qemu-ppc@nongnu.org, qemu-arm@nongnu.org, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Richard Henderson , Alistair Francis , David Hildenbrand , Ilya Leoshkevich , Thomas Huth Subject: [PULL 21/60] target/s390x: Use env_archcpu() in handle_diag_308() Date: Mon, 6 Nov 2023 12:02:53 +0100 Message-ID: <20231106110336.358-22-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20231106110336.358-1-philmd@linaro.org> References: <20231106110336.358-1-philmd@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::330; envelope-from=philmd@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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1699269297411100003 When CPUArchState* is available (here CPUS390XState*), we can use the fast env_archcpu() macro to get ArchCPU* (here S390CPU*). The QOM cast S390_CPU() macro will be slower when building with --enable-qom-cast-debug. Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Richard Henderson Acked-by: Alistair Francis Message-Id: <20231009110239.66778-4-philmd@linaro.org> --- target/s390x/diag.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/s390x/diag.c b/target/s390x/diag.c index 8ce18e08f3..27ffd48576 100644 --- a/target/s390x/diag.c +++ b/target/s390x/diag.c @@ -77,7 +77,7 @@ void handle_diag_308(CPUS390XState *env, uint64_t r1, uin= t64_t r3, uintptr_t ra) { bool valid; CPUState *cs =3D env_cpu(env); - S390CPU *cpu =3D S390_CPU(cs); + S390CPU *cpu =3D env_archcpu(env); uint64_t addr =3D env->regs[r1]; uint64_t subcode =3D env->regs[r3]; IplParameterBlock *iplb; --=20 2.41.0