From patchwork Thu May 2 05:44:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 794100 Delivered-To: patch@linaro.org Received: by 2002:adf:a153:0:b0:34d:5089:5a9e with SMTP id r19csp78354wrr; Wed, 1 May 2024 22:47:34 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXze5QoOAXqyIFy4327BdFMKZu8mL4J3I4XEJOVWQlCoQ7teWWHjA9ZOcuIk2/wfbntxhBPuuGsUqPTw8FCS6tp X-Google-Smtp-Source: AGHT+IEdpo5T5x4U8ujy/LgMDr47zAhES0uNkuw/5Wgcjmt5YHhELa2xZqNAj6BTNiVnRLhqsoVf X-Received: by 2002:a05:6214:76e:b0:6a0:aac9:c56f with SMTP id f14-20020a056214076e00b006a0aac9c56fmr4744689qvz.33.1714628854412; Wed, 01 May 2024 22:47:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1714628854; cv=none; d=google.com; s=arc-20160816; b=DXVwBFrkGKRyi5tL6zMcLcVx9qlmhxSfjgol/j5Yu7nV6myF3B9VsmgDv7N5D3YO7W uRpXy97tJdaBdSc2jVC9dLHJYJ+YsrJyvuta/D/FGNesNTAOV8euUb0q4t8J6Bx0xEI6 7QPpCt1PhQiMxJVp4viSIk64TOPkUo48clsnpTudSM9p3mv7IuMge6nwCoIK9Tqsq9ZT m6M9qOC53oM8mGHxwffPjwtBrlINBd7YENqO3mTP8l2QXdjjRr18cyhubQwn/1wI9z13 ZsWRZBcdOjFmHYSy5NGRLXw+iEdrnjWDIbT3PHcyhNyqOWx+Z5s4ipR6fCQBa2peGqro JygA== 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:dkim-signature; bh=BO3Ii+A52/malNI8AUEcEUyt4enrdqxz3IH30eM+BG8=; fh=vvIHVEExtoxBacLa1w/xvEOdET6IjbTxlMJ0GExg4HQ=; b=a3IAY9rYyw5TcHqotazsImQpzsePKFyC5jURxHjc7oze1D5K/k17nVhQAz+WhtYD/J AbdZjl4jhPOlmz84LAKA3oIHj6xuGBeETJnZ/CLpselloxWM1VGa3k1kRd7qzvdiLqtU enVFwEBvwlqbxVOxwvbChCbmXfZdxOAGgapVpDZwagT6hJMxMuW6gSM3R9t+ynYkYTyQ jzSggEAQIQMYCv7uON3Q1Vn3K8E9XS7dAcskDcQ0R/NqtM4hTXOWzGGSRN8Jy6E3A2S9 n0gYX9sMMYKl4faxuZcxH73gpC0hZH8aNVjRPOScRzxv3u11cmsl4f3A5wiDSMpyqaRU Lwaw==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=d3znA4b4; 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"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id j2-20020a05621419c200b0069b3b6fd0cbsi228358qvc.347.2024.05.01.22.47.34 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 May 2024 22:47:34 -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; dkim=pass header.i=@linaro.org header.s=google header.b=d3znA4b4; 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"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s2PFL-0008Tv-2q; Thu, 02 May 2024 01:44:43 -0400 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 1s2PF8-0008Mh-5m for qemu-devel@nongnu.org; Thu, 02 May 2024 01:44:31 -0400 Received: from mail-ot1-x336.google.com ([2607:f8b0:4864:20::336]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1s2PF3-0002bv-Eb for qemu-devel@nongnu.org; Thu, 02 May 2024 01:44:29 -0400 Received: by mail-ot1-x336.google.com with SMTP id 46e09a7af769-6ee4dcc4567so2095731a34.3 for ; Wed, 01 May 2024 22:44:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1714628663; x=1715233463; 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=BO3Ii+A52/malNI8AUEcEUyt4enrdqxz3IH30eM+BG8=; b=d3znA4b4rneR6UEoy8iM1aiiZysVmHrtBuocz8IIg98yXERmf2njtvllYZC3K8J2mE Q/yKmAfHB20wRqbD7Ohb0+QLRvy21DOzWsR5fI+yeZNuicU9jaGFOIWnViEfW9ZH1ItR ZtSGMeRXz+krn154wJ4q1JXgEJ2ZPtB7oSuwj55fNuxIA1KzPPg2QkfD/H1rA7J08Xk9 K8A9hqIrVRVag6r6oQcHsePs4yoXJCREmxQbkrlKxP4O+NKiDYHNSKtRCuM1jMpS2Lv1 gKOGJrHon79RtQDQR2QA37VlCmqU/YK2msuH7zyzBA8Z/lNJE5jph/o3KkZwoV7bcBLv faRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714628663; x=1715233463; 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=BO3Ii+A52/malNI8AUEcEUyt4enrdqxz3IH30eM+BG8=; b=dCBWNfxXoqScnnzR6E1ybBNJbxdt7Zy48OmK/6jeiWNf1XqKDs19bNxsYrFl6DJrfl +weIKHmNi552/2fpZPCDmuJXlIFR5tF3uUIlstFLwNtmkIxe4pN6WmHUezGIh3/WaWvI pHiVlILHb/u0WCi2YrNJQbrbVrB9wm4NEUTERRqusNq9CD8WjYRpWuDeNdZvdK92dwqx cc5pDONHNbyQxWY76og8oSfrAST1DbdxK3jwBDSBXIISlFZN9eOytfAQtobHwUqnevff 2eeLsvee81VMknzsUHIM8MxQuF/Ab+ZTmXWKkMKE3esMyl3ASreBlTdUXDrI3awAfZeH z+qQ== X-Gm-Message-State: AOJu0YxIrp/ve6UXjPJ0YvYpUTYcQvc9YKOHN5e7cTrrxwfjuE0WVvtB ZVKKNM5knxQGoD6yxylKevuX8p3anao/mKTapVjRdcntk4Bc7LQbW0ORJ+tsrUOmhie6orh/7kv 4 X-Received: by 2002:a05:6870:9121:b0:233:276e:6bbf with SMTP id o33-20020a056870912100b00233276e6bbfmr5256272oae.15.1714628662898; Wed, 01 May 2024 22:44:22 -0700 (PDT) Received: from stoup.. (174-21-72-5.tukw.qwest.net. [174.21.72.5]) by smtp.gmail.com with ESMTPSA id e18-20020a656492000000b006089cf2cde5sm294401pgv.26.2024.05.01.22.44.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 May 2024 22:44:22 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: qemu-s390x@nongnu.org, iii@linux.ibm.com, david@redhat.com, thuth@redhat.com Subject: [PATCH 03/14] target/s390x: Update CR9 bits Date: Wed, 1 May 2024 22:44:06 -0700 Message-Id: <20240502054417.234340-4-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240502054417.234340-1-richard.henderson@linaro.org> References: <20240502054417.234340-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::336; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x336.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 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 Update from the PoO 14th edition. Signed-off-by: Richard Henderson Reviewed-by: Thomas Huth Reviewed-by: Ilya Leoshkevich --- target/s390x/cpu.h | 18 +++++++++++------- target/s390x/tcg/misc_helper.c | 2 +- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/target/s390x/cpu.h b/target/s390x/cpu.h index 950f84f316..1bb723a9d3 100644 --- a/target/s390x/cpu.h +++ b/target/s390x/cpu.h @@ -419,13 +419,17 @@ void cpu_get_tb_cpu_state(CPUS390XState *env, vaddr *pc, #endif /* CONFIG_TCG */ /* PER bits from control register 9 */ -#define PER_CR9_EVENT_BRANCH 0x80000000 -#define PER_CR9_EVENT_IFETCH 0x40000000 -#define PER_CR9_EVENT_STORE 0x20000000 -#define PER_CR9_EVENT_STORE_REAL 0x08000000 -#define PER_CR9_EVENT_NULLIFICATION 0x01000000 -#define PER_CR9_CONTROL_BRANCH_ADDRESS 0x00800000 -#define PER_CR9_CONTROL_ALTERATION 0x00200000 +#define PER_CR9_EVENT_BRANCH 0x80000000 +#define PER_CR9_EVENT_IFETCH 0x40000000 +#define PER_CR9_EVENT_STORE 0x20000000 +#define PER_CR9_EVENT_STORAGE_KEY_ALTERATION 0x10000000 +#define PER_CR9_EVENT_STORE_REAL 0x08000000 +#define PER_CR9_EVENT_ZERO_ADDRESS_DETECTION 0x04000000 +#define PER_CR9_EVENT_TRANSACTION_END 0x02000000 +#define PER_CR9_EVENT_IFETCH_NULLIFICATION 0x01000000 +#define PER_CR9_CONTROL_BRANCH_ADDRESS 0x00800000 +#define PER_CR9_CONTROL_TRANSACTION_SUPRESS 0x00400000 +#define PER_CR9_CONTROL_STORAGE_ALTERATION 0x00200000 /* PER bits from the PER CODE/ATMID/AI in lowcore */ #define PER_CODE_EVENT_BRANCH 0x8000 diff --git a/target/s390x/tcg/misc_helper.c b/target/s390x/tcg/misc_helper.c index 8c27998ab9..02215a7f18 100644 --- a/target/s390x/tcg/misc_helper.c +++ b/target/s390x/tcg/misc_helper.c @@ -644,7 +644,7 @@ void HELPER(per_ifetch)(CPUS390XState *env, uint64_t addr) /* If the instruction has to be nullified, trigger the exception immediately. */ - if (env->cregs[9] & PER_CR9_EVENT_NULLIFICATION) { + if (env->cregs[9] & PER_CR9_EVENT_IFETCH_NULLIFICATION) { CPUState *cs = env_cpu(env); env->per_perc_atmid |= PER_CODE_EVENT_NULLIFICATION;