From patchwork Wed Mar 8 16:57:17 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Tokarev X-Patchwork-Id: 660451 Delivered-To: patch@linaro.org Received: by 2002:adf:a3c6:0:0:0:0:0 with SMTP id m6csp433352wrb; Wed, 8 Mar 2023 09:03:24 -0800 (PST) X-Google-Smtp-Source: AK7set+CCEnagSRzleaPMDnhHjK/1aFFaB1sAKvNfE+xbOz5ROyEt/i6FqsfJQ64wV0F0YpeYKSy X-Received: by 2002:a05:6214:250d:b0:56e:ab08:670d with SMTP id gf13-20020a056214250d00b0056eab08670dmr33310775qvb.42.1678295003940; Wed, 08 Mar 2023 09:03:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1678295003; cv=none; d=google.com; s=arc-20160816; b=HujQpc8w6+2D70pgMGTkINlFJuCQRfTL4kZm1zGcReFLydqKWxRjsI5iZhxwth88Zz PpRSEAOtZ+ki6vJqTuNDzBMvbctzN74D+TEf/7A4kIp4f3W04wuMLNSQtbVsLxx5Zqc+ eu4smWLNm2sCeoyEWIMcTifPChfypYwo0jaxim3VLh8M4MaXt6/L7pW9d2aUyK3+0BMW L1xIqm7iodGv99krdKEJ/ZUwbGqHixVfBiW1xSP6MyH/8IvIJgn/OWOXGuz/bMAMYjJB 9Ol0GqKpkWzgSOEf1KGER/VzmLw39M8OHRmwcy4OIO/eS2aQF0I42YpqM4rey+Va59do aSlg== 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=lbzES6mGCRThb4h6Y0Cch8tyH+03d9cif9zcxoTryEs=; b=gIyHthdDdRtyEeSAYcCaIhcwan2+ANzq1R292xMz5YZ/kf/Jo0M81AAXeRwzDvAKfU bPXywguqlMOG8EiQLToram9O5PAAm+Y660ZfS8TdQPsA7vsY1Rmhbqt4aHbRKQ/+AftI 8r2k/TQDHEcEYG7H4OxB2yVsP8IbGQak8vZEGh5FG4SD1nsDbY5hHofTvUJYyp5E6hVP Q7UEeR57AE+D4A4ohjoycFdUQmAtt+NiTaCdnKr9uerk6xr+ywOzj7lzPi2U9/wibDph qC/OcQWsYuHOaJNa9aikXV1Gcuf0ffXH1d812F7sGrRJG2HhCeSaXRIYCJcLk59CuZKP 3FMA== 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 w24-20020a05620a0e9800b006fa1585a6absi12077995qkm.186.2023.03.08.09.03.23 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 08 Mar 2023 09:03:23 -0800 (PST) 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 localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pZx7v-0004CU-5w; Wed, 08 Mar 2023 11:58:55 -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 1pZx7s-0004AC-LS; Wed, 08 Mar 2023 11:58:52 -0500 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 1pZx7p-0003yC-Rq; Wed, 08 Mar 2023 11:58:52 -0500 Received: from tsrv.corpit.ru (tsrv.tls.msk.ru [192.168.177.2]) by isrv.corpit.ru (Postfix) with ESMTP id 7AAA4400EB; Wed, 8 Mar 2023 19:58:20 +0300 (MSK) Received: from tls.msk.ru (mjt.wg.tls.msk.ru [192.168.177.130]) by tsrv.corpit.ru (Postfix) with SMTP id 3048E1FD; Wed, 8 Mar 2023 19:58:19 +0300 (MSK) Received: (nullmailer pid 2098280 invoked by uid 1000); Wed, 08 Mar 2023 16:58:15 -0000 From: Michael Tokarev To: qemu-devel@nongnu.org Cc: qemu-stable@nongnu.org, Richard Henderson , Peter Maydell , Michael Tokarev Subject: [PATCH 14/47] target/arm: Fix in_debug path in S1_ptw_translate Date: Wed, 8 Mar 2023 19:57:17 +0300 Message-Id: <20230308165815.2098148-14-mjt@msgid.tls.msk.ru> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230308165035.2097594-1-mjt@msgid.tls.msk.ru> References: <20230308165035.2097594-1-mjt@msgid.tls.msk.ru> 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 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: Richard Henderson During the conversion, the test against get_phys_addr_lpae got inverted, meaning that successful translations went to the 'failed' label. Cc: qemu-stable@nongnu.org Fixes: f3639a64f60 ("target/arm: Use softmmu tlbs for page table walking") Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1417 Signed-off-by: Richard Henderson Message-id: 20230114054605.2977022-1-richard.henderson@linaro.org Reviewed-by: Peter Maydell Signed-off-by: Peter Maydell (cherry picked from commit 4a1103afb16efa64600ef0c2b03afe60f689fdc9) Signed-off-by: Michael Tokarev --- target/arm/ptw.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/arm/ptw.c b/target/arm/ptw.c index f812734bfb..bb22271a1d 100644 --- a/target/arm/ptw.c +++ b/target/arm/ptw.c @@ -238,8 +238,8 @@ static bool S1_ptw_translate(CPUARMState *env, S1Translate *ptw, }; GetPhysAddrResult s2 = { }; - if (!get_phys_addr_lpae(env, &s2ptw, addr, MMU_DATA_LOAD, - false, &s2, fi)) { + if (get_phys_addr_lpae(env, &s2ptw, addr, MMU_DATA_LOAD, + false, &s2, fi)) { goto fail; } ptw->out_phys = s2.f.phys_addr;