From nobody Mon Nov 23 04:44:10 2026 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=1792499294; cv=none; d=zohomail.com; s=zohoarc; b=OOuxyFLnaX9PvE+wzuOx0wrOwjezj+4LvDDvUMBTgKfGH8RYLXp4ZUJpdJMXfVoc/FwTM8WAZ5mLYTtB1xkGG8QQkFkxFyphNEN9rOzownuEikTiOhUUfNh7aVCbLpAXQyISxiHmuTVezEMxw3T6o7Q0D+AXL/k3oiPTmKb25C0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1792499294; h=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:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=NNPAVebBgE86yGS589DuMeccMx56+d9+OJ/1mfKNNsY=; b=moRSKYIQS47P5uOOhYrzMcKDfpXqkWRJD9b/aRfgoVaOISEaFANWRn0bTcQPn9XKhRD3pBxj61gQaDOArw8pH7nnfIYAuUCKbEr/nMph4Eh/zAeRNVaMcVsG809QqyHhSZpzO7enTLXlXeqEiJ8M9B59FTRt0G2RjAc5PowqpI8= 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 lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1792499294211475.8344809990541; Tue, 20 Oct 2026 05:28:14 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xJ8wl-0008S8-Br; Tue, 20 Oct 2026 08:28:03 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xJ8wj-0008Rt-DG for qemu-devel@nongnu.org; Tue, 20 Oct 2026 08:28:01 -0400 Received: from mail-wr1-x430.google.com ([2a00:1450:4864:20::430]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1xJ8wh-0004Me-NQ for qemu-devel@nongnu.org; Tue, 20 Oct 2026 08:28:01 -0400 Received: by mail-wr1-x430.google.com with SMTP id ffacd0b85a97d-48e00eee27dso1854241f8f.0 for ; Tue, 20 Oct 2026 05:27:59 -0700 (PDT) Received: from lanath.. (wildly.archaic.org.uk. [81.2.115.145]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4a1f2cd482bsm68899315e9.12.2026.10.20.05.27.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2026 05:27:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1792499278; x=1793104078; 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:content-type; bh=NNPAVebBgE86yGS589DuMeccMx56+d9+OJ/1mfKNNsY=; b=Mxqd+Z/NC+aAKjmmbYdr8LkFKNsmXKJll53awecn2j4vWwD5l/3UehdI5QtrtPBS7E a0ZkOvA1uRvJtH5eYQnilOznamklxxJXrXM+t4fkopcmGitgUt533ePSfDoWC8j9vn8K iOUtzN7E3rN6R8UmgW17X1BtyOZoCFqO+4s1b8HyVagmrp2ZtjgkBgbAnTDd0oSGtqVT IQJkMVBsheC9NoTBgXSG/3r46HXaoV450BLqzpW7vmT0URa8OSw1GQuuQ/8M7Rp9PmZM ARpZ+VSLNXe9O0Zjt+dUdatZ8NcyObCst31A/GUbJEnEkAEjGmySyvlW8nUIwghiE9e1 daPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1792499278; x=1793104078; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=NNPAVebBgE86yGS589DuMeccMx56+d9+OJ/1mfKNNsY=; b=iIEKp/XNe1GZMUISNY2Pn8DilCEr1VafSTkqCreMh5AlUwO/H7L6U+8kN1e80F+F6u 9pW0B02RwC2XdQEOcJFJJJKZDfsU9Re0rBXDZlVkLWhphw0w9EwUaaEAE8jI/TbrbziZ qS6yYVdzJT9WWhPFQhqMOO+empoWdZOxF+yvQZ6R11LKrdpzTOtsfpp/XzbpndtADC+m Ldd76lNWAnhz3jEwCtvXyPzYS6ZmwCbhB7qxwHnF6S0At2wLHN001/IcM1VuQnN9al3C t5/CePhZ8IybjRaDJ4ICTj/k59QMHp5psh6wblRI5u+Xc2FP2KG2VgxAWtc0V4oQ0Ugx Gvng== X-Gm-Message-State: AFq9FYIUpLxytOXMrGjOqxjvbLvTlD+jYxoeWBDFM3nhxp6vNI5XKem9 qn/uwOLz8jjXurrMZGSZzRdv4S6OSEiwShVVNlxeyo617LgtshQn6l7vAOJsBGMgP52Vof+FhGq lumN2/sw= X-Gm-Gg: AYBFou1B1zfFd9CWltrrW9LVBvGv/HgUuHGEOJ5mGlM+ScT0TKp6Sl8BZw1c0BPcIsd PV2vxN9RPpSdaI0D5VVANuqtFAeC2Q06+QxpVkIq+SevZQDqbrKvGXG2WN0MkzOcYbUnUul2s+q JoCRJLAZphL/NsZr2E2miuOLHyZJPg3d9SuAjjnzNwfGq9p6sBb2YRswgWnyGUiYMl92Cy8frRL ikit6L38LBB00Rlky9ww0VTUOUOguEryxGeerImW+MyYbjxtofXVDoPf9fYe2JOPFjYN3xNrfwQ yeWaCtALHeDun/O2qEzrZ+0cqYONLDNL75lycX3E6IhJqySILuYhabjQowmdhZ13crM+vR1UOA4 ZwPAMuDNboA9jUZqgfdMq3Cdu1/IdHYwz3IAgDC3i/pUj3ztuCJZB94D1R8A4HPOiyFlkudx0Wd fMTT9bf11i9EpIg0nW03c3ocPfV69nKH8OGB9oyJXr9mcQ3T/Gbx9r4uSiTo5JbfTbTP2XH2mL1 9cWyVOLrm9l47R09EKdIL9F6Ur4ChGO5I/sjthqiVYMBYpjB7aZ28nj5kPs5WGCAYdi7EZjtNDA u6k= X-Received: by 2002:a05:600c:a4b:b0:4a0:eae0:b30e with SMTP id 5b1f17b1804b1-4a1d7604051mr246946115e9.22.1792499278182; Tue, 20 Oct 2026 05:27:58 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Cc: Richard Henderson , Michael Rolnik , Stafford Horne , Yoshinori Sato Subject: [PATCH 1/5] target/alpha: Convert to translate_for_debug Date: Tue, 20 Oct 2026 13:27:48 +0100 Message-ID: <20261020122752.3651914-2-peter.maydell@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20261020122752.3651914-1-peter.maydell@linaro.org> References: <20261020122752.3651914-1-peter.maydell@linaro.org> MIME-Version: 1.0 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=lists1p.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::430; envelope-from=peter.maydell@linaro.org; helo=mail-wr1-x430.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: qemu development 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: 1792499296592158500 Content-Type: text/plain; charset="utf-8" Convert alpha to providing the translate_for_debug method rather than the deprecated get_phys_addr_debug method. Signed-off-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Richard Henderson --- target/alpha/cpu.h | 3 ++- target/alpha/cpu.c | 2 +- target/alpha/helper.c | 15 +++++++++++++-- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/target/alpha/cpu.h b/target/alpha/cpu.h index 378bd96d941..32f53453d72 100644 --- a/target/alpha/cpu.h +++ b/target/alpha/cpu.h @@ -282,7 +282,8 @@ extern const VMStateDescription vmstate_alpha_cpu; =20 void alpha_cpu_do_interrupt(CPUState *cpu); bool alpha_cpu_exec_interrupt(CPUState *cpu, int int_req); -hwaddr alpha_cpu_get_phys_addr_debug(CPUState *cpu, vaddr addr); +bool alpha_cpu_translate_for_debug(CPUState *cpu, vaddr addr, + TranslateForDebugResult *result); #endif /* !CONFIG_USER_ONLY */ void alpha_cpu_dump_state(CPUState *cs, FILE *f, int flags); int alpha_cpu_gdb_read_register(CPUState *cpu, GByteArray *buf, int reg); diff --git a/target/alpha/cpu.c b/target/alpha/cpu.c index 12e86021663..dca25456e78 100644 --- a/target/alpha/cpu.c +++ b/target/alpha/cpu.c @@ -242,7 +242,7 @@ static void alpha_cpu_initfn(Object *obj) =20 static const struct SysemuCPUOps alpha_sysemu_ops =3D { .has_work =3D alpha_cpu_has_work, - .get_phys_addr_debug =3D alpha_cpu_get_phys_addr_debug, + .translate_for_debug =3D alpha_cpu_translate_for_debug, }; #endif =20 diff --git a/target/alpha/helper.c b/target/alpha/helper.c index c3614ecafda..ccf1994b31b 100644 --- a/target/alpha/helper.c +++ b/target/alpha/helper.c @@ -297,14 +297,25 @@ static int get_physical_address(CPUAlphaState *env, v= addr addr, return ret; } =20 -hwaddr alpha_cpu_get_phys_addr_debug(CPUState *cs, vaddr addr) +bool alpha_cpu_translate_for_debug(CPUState *cs, vaddr addr, + TranslateForDebugResult *result) { hwaddr phys; int prot, fail; =20 fail =3D get_physical_address(cpu_env(cs), addr, 0, 0, &phys, &prot); + if (fail >=3D 0) { + return false; + } + phys |=3D addr & ~TARGET_PAGE_MASK; - return (fail >=3D 0 ? -1 : phys); + + *result =3D (TranslateForDebugResult) { + .physaddr =3D phys, + .lg_page_size =3D TARGET_PAGE_BITS, + .attrs.debug =3D 1, + }; + return true; } =20 bool alpha_cpu_tlb_fill(CPUState *cs, vaddr addr, int size, --=20 2.43.0 From nobody Mon Nov 23 04:44:10 2026 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=1792499338; cv=none; d=zohomail.com; s=zohoarc; b=iJic2DV+4ll6fWIgWVOKr0vC3bGnEx6M2yY0lLbQRSaKX8A8wDDdS4p9D1CCySCEuGxRfrL0d07YNLTSkc9HXAIkM+Wwa9/vkSHauEFteTydfxpjLNo4MMUtE/iYcpb2I0aSTBZm5rriEZrrYt+u3c8Vd5TSjzrHBzULfC+b05k= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1792499338; h=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:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=Zhp3G2DCG5w/xJJN4I2L5thmUqX44nmG1wWLXQD3W6g=; b=fcvdovK09Ryspqg+iVBcIFBqvdbAQ2lTMVUXdNi/WN8iwvIBtOdZPe4ITjfhG0CE6v7cENu/fKCakP0veVGbPUjfNI5QduTGu3uVS6D54pewydkZ0RYOi1mq3qCYA8bsSynM2kLjl3JqkW5aIvPn4xdA7cPogkj1nRJwDGJpQJw= 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 lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1792499338114148.4036307728635; Tue, 20 Oct 2026 05:28:58 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xJ8wn-0008Sb-A1; Tue, 20 Oct 2026 08:28:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xJ8wl-0008SL-Rl for qemu-devel@nongnu.org; Tue, 20 Oct 2026 08:28:03 -0400 Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1xJ8wk-0004Mr-7j for qemu-devel@nongnu.org; Tue, 20 Oct 2026 08:28:03 -0400 Received: by mail-wm1-x32b.google.com with SMTP id 5b1f17b1804b1-4a1df146015so19006535e9.0 for ; Tue, 20 Oct 2026 05:28:01 -0700 (PDT) Received: from lanath.. (wildly.archaic.org.uk. [81.2.115.145]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4a1f2cd482bsm68899315e9.12.2026.10.20.05.27.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2026 05:27:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1792499280; x=1793104080; 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:content-type; bh=Zhp3G2DCG5w/xJJN4I2L5thmUqX44nmG1wWLXQD3W6g=; b=WN7TfbVa6YN/9g/VqTHJUbJSOBAb7k+HOriEPyvhTvuvzWp9F4FvHGSKgIlxX4gqLP MJPdyMQD8IQF5swKIvl9lNE6E41VjsO7Ey42SZCD4FJIxAh1BiTTKncYbGeFhl2O7t6r g4Wg5ZHVsK5jg5Es374HJd8PQUW5TnBHIVBqeWFSdiw9yL8r7Cm/WO/zkkgXcuX/Ww2p 7CdXwsdifz5W1YMKUxuhKC+VrmbheKo0AI0Qg+zsHbFY92gq7siah8blfXfVrORWOIBz JsH/v8+B4Rgq65rfFZzpOvq/l1AXdmQpYsPXlE8fuSrMNd8tNe7AqiKHg8Nz0FhGSzSd C66Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1792499280; x=1793104080; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=Zhp3G2DCG5w/xJJN4I2L5thmUqX44nmG1wWLXQD3W6g=; b=vs2uAQ5AKzz0qkf1x9d4kq+QTH/nuV6hQ0hLdJsi+xiRhBTY7Hy2/gLnobuiO5NWWz Smps6E24bQttK5c+0/YD3ZeyrQBC0mWPPRnLbunwOSUEm/kQ1wq49OGZA35/xQbVYKMJ DPl9fUJINnYVh0eTdhgReAXx6SnERp1i30I9QrujM49Byms3TuOB+4GIfVPIhem51wUO n235h24H31zmVrEJKbZhdgL1vAy1Jf61jL3QcY/aAK7vCf3ZT4YZMh1qr5tGLQ1Lrru8 rCb6+vViOY5s2tmo0zDGL3BZF+Vw2UD6OCDqnBmSIwBseoObyMduFbBL8rH2uDXxotlm +nSw== X-Gm-Message-State: AFq9FYIb/b1kkqGjnXxbfoLv0wKZTzqXSBG65lJx8h1a42aMc4lf+SkY yb0CaBnT/G0u3SxwZftF3QMNWjhXe/HRETE0IB09z1HnNy5r4RHoiLIYwBw8rwriyEKj5lWr8+/ jNNZmEuA= X-Gm-Gg: AYBFou1Bp6j9MDT7EeT/BlAuSmH+7FrIyLPkP01bziJFowFDr4EjnZN/2+8UVxTBb3N hODJVxrD+wBYB/BDmy3dbAhX+nyHkof4pmjINSzR75LiPwx3m+cVTI/bYz+znsadavZ/LOVAjoP wpj3eWCf3R45Q/QxzCwB/WOLX+6GUNv5wHcb65/H7wJx6uzj3QvH8kVsWt7gnYbxqyu/dBtSbq1 yHVaasf/LFUkonuY7xh6kvE6HHn2VxMSsh35eG2/nrt8q7c2EnLKT1q/TTTA8r+mOhShLUy4MVj Se0v3nO78cEPDT3CWzxVhE76ZAySlX+YHcjd6s+fHLnOwG+9OrYYERZbiyGi/bZ/nl1hs5UBXM/ XOFdd8eWvhr0j9Z1hzYf4lsof6ciI/djJLHyKWOt/9GJobpedfrCPUiWZy0U/KRZkabsJS1dwPU r9XC4gvyjLNOZXDOcuzBh70/b67ZFTIwU/mkIH0U1YWHpLIIlvxehwTrjW0VpxJFAyX8MJuF+QY CBiqemdv6FD0gvRyUVQictMpUbkhOzDlY6sRnMOqLH+Wa7lEeBJHIZIhOBF9G+CJiuoEOXaDnDn /Fc= X-Received: by 2002:a05:600c:468e:b0:4a0:12d7:4c88 with SMTP id 5b1f17b1804b1-4a1d7625f71mr242544745e9.30.1792499279880; Tue, 20 Oct 2026 05:27:59 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Cc: Richard Henderson , Michael Rolnik , Stafford Horne , Yoshinori Sato Subject: [PATCH 2/5] target/avr: Convert to translate_for_debug Date: Tue, 20 Oct 2026 13:27:49 +0100 Message-ID: <20261020122752.3651914-3-peter.maydell@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20261020122752.3651914-1-peter.maydell@linaro.org> References: <20261020122752.3651914-1-peter.maydell@linaro.org> MIME-Version: 1.0 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=lists1p.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32b; envelope-from=peter.maydell@linaro.org; helo=mail-wm1-x32b.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: qemu development 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: 1792499339266158500 Content-Type: text/plain; charset="utf-8" Convert avr to providing the translate_for_debug method rather than the deprecated get_phys_addr_debug method. Signed-off-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Richard Henderson --- target/avr/cpu.h | 3 ++- target/avr/cpu.c | 2 +- target/avr/helper.c | 11 +++++++++-- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/target/avr/cpu.h b/target/avr/cpu.h index 1e4e839bd83..4e2372a6801 100644 --- a/target/avr/cpu.h +++ b/target/avr/cpu.h @@ -177,7 +177,8 @@ extern const struct VMStateDescription vms_avr_cpu; =20 void avr_cpu_do_interrupt(CPUState *cpu); bool avr_cpu_exec_interrupt(CPUState *cpu, int int_req); -hwaddr avr_cpu_get_phys_addr_debug(CPUState *cpu, vaddr addr); +bool avr_cpu_translate_for_debug(CPUState *cpu, vaddr addr, + TranslateForDebugResult *result); int avr_cpu_gdb_read_register(CPUState *cpu, GByteArray *buf, int reg); int avr_cpu_gdb_write_register(CPUState *cpu, uint8_t *buf, int reg); int avr_print_insn(bfd_vma addr, disassemble_info *info); diff --git a/target/avr/cpu.c b/target/avr/cpu.c index f8409f32ab9..9476bd87276 100644 --- a/target/avr/cpu.c +++ b/target/avr/cpu.c @@ -233,7 +233,7 @@ static void avr_cpu_dump_state(CPUState *cs, FILE *f, i= nt flags) =20 static const struct SysemuCPUOps avr_sysemu_ops =3D { .has_work =3D avr_cpu_has_work, - .get_phys_addr_debug =3D avr_cpu_get_phys_addr_debug, + .translate_for_debug =3D avr_cpu_translate_for_debug, }; =20 static const TCGCPUOps avr_tcg_ops =3D { diff --git a/target/avr/helper.c b/target/avr/helper.c index f452c9d9040..8f90b8d9a45 100644 --- a/target/avr/helper.c +++ b/target/avr/helper.c @@ -108,9 +108,16 @@ void avr_cpu_do_interrupt(CPUState *cs) qemu_plugin_vcpu_interrupt_cb(cs, ret); } =20 -hwaddr avr_cpu_get_phys_addr_debug(CPUState *cs, vaddr addr) +bool avr_cpu_translate_for_debug(CPUState *cs, vaddr addr, + TranslateForDebugResult *result) { - return addr; /* I assume 1:1 address correspondence */ + /* I assume 1:1 address correspondence */ + *result =3D (TranslateForDebugResult) { + .physaddr =3D addr, + .lg_page_size =3D TARGET_PAGE_BITS, + .attrs.debug =3D 1, + }; + return true; } =20 bool avr_cpu_tlb_fill(CPUState *cs, vaddr address, int size, --=20 2.43.0 From nobody Mon Nov 23 04:44:10 2026 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=1792499333; cv=none; d=zohomail.com; s=zohoarc; b=WXtOKUmcMQx35CnjPG6NcdhoWUyzARgJFCD1xT5uUEA3wI3G2NYhU2zB+BGVg7/4ocapOCHTW4xJZCRiymBHVl7rRmgcpX+APi1odszSZVlF27XXgKh56q18aJeclMonwNAD2NDkqYm+kPoAM+LyR1QxyF17vJu6jk9kpeahwmE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1792499333; h=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:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=dT6MVmsVPa33xYsB4R9hl3VCTg+ecJ2i/jON0dmG+pI=; b=Z812AiTsFgZvEUrEU5OdmPWn0gkCRclJvnEulvOlSRPE1UWItOqClWjgBs+PI1fsS6ra78UbsWEYRMmvJT8bqir8PIMUcxKJiemER5g8LkV1A8z9lls1BJ60nAotsPQZN4B66pTVhKs7eRndSetFnr+OTUOOVX2HmW4nLh51RQY= 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 lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1792499333837855.4439989581088; Tue, 20 Oct 2026 05:28:53 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xJ8wo-0008T7-FH; Tue, 20 Oct 2026 08:28:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xJ8wm-0008SS-6r for qemu-devel@nongnu.org; Tue, 20 Oct 2026 08:28:04 -0400 Received: from mail-wm1-x32f.google.com ([2a00:1450:4864:20::32f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1xJ8wk-0004My-LG for qemu-devel@nongnu.org; Tue, 20 Oct 2026 08:28:03 -0400 Received: by mail-wm1-x32f.google.com with SMTP id 5b1f17b1804b1-4a1e3098ee2so26621255e9.3 for ; Tue, 20 Oct 2026 05:28:02 -0700 (PDT) Received: from lanath.. (wildly.archaic.org.uk. [81.2.115.145]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4a1f2cd482bsm68899315e9.12.2026.10.20.05.27.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2026 05:28:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1792499281; x=1793104081; 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:content-type; bh=dT6MVmsVPa33xYsB4R9hl3VCTg+ecJ2i/jON0dmG+pI=; b=GvkvLZkSpnwsDL6EVoKyewZDL3XisupkUN4oqAYMRay4MwDtb62ZEm40qkV0y3Hdgc CnTgRadScHUGibqztSvTS/LKwWc6QvztudAHed5EMbU4oC7v+VIj5Sp0kqbjcE/5Li21 p1QClyx1u1A8TCm0ov1DzTD7LD3WUVxwSfB2SCcyhAr0Dq6okapBdO/1XEEgrZov/L8O V7SxJu1IxDiLmmgIZ7WA0o5OWWYfmY7OKP8uayI6NmxgfdgI/bi5A0Hb3D0Wz3CcM3jD usRElekI4dpLxWmiQoy2JEvBB0SHl/sHhAccqiRpdzW8lre41g10Z6keZr+oVmgo6X5s l/sw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1792499281; x=1793104081; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=dT6MVmsVPa33xYsB4R9hl3VCTg+ecJ2i/jON0dmG+pI=; b=OxQF0iQGR6Mr7v7uyjSY/mnJe3Q8fUxZounT3zJYf5+meu50+pQZn0FK1GdCYRtX9V BBlq4j5hX5ov6xp273SWH53FqHsUhIrZzT7AG4FyUOfZmfOPCMkshsv6HZKmrddMb1NI iV0vHP7sLnBIiJbzHcgLixVJW51K8jAtGhp4lI2BMOZ/0DqNpOg3eIpxGwUrIlZpSIV3 WDAmotcmJjezvYxD/LIQ+WeeZkj4nnifKovo9v+Ne6EpEW+8rmcVznyy/q/UgWBG3fqD 40OPS00E83qW5TRi0mP/+p77NtDxCpIM1oQGJcxb/2TsQeWsYSh/luDpAIlJq4EU933N TbKQ== X-Gm-Message-State: AFq9FYKAy6r2L7WWW5l6MqCw/vYQXdiK3SQ9I/uIJVzoshyw+9pQCchE S2ZP1Zlp/u3eQKnu2c3+4gygqYJAXXlzfmJMPtjZGbhPndMOtZwnrQXHZrki8OHu+n+ffjZXsxk 0xbp3eRw= X-Gm-Gg: AYBFou0XqacgRWZRyfuhmLpzzEKlWwspPHKOpMAk8DW1dAxcnCxWICoPwzr/6u1wUje 3bHSO/E9EbnLfuEOrbCNE0s389IxtNRelBLbHjMZHqJyij13rk69wIduT/uvS9tJXR0kIkakCvf lwac7a9+CstAHdg/gi6ue+5jOvlY6GOWQckoqej63fd+hgFwbddnexNJYCK5oH66retLNr42CUI XuxRDrp0dM+hT3cidCGFwPsV4pJfsb0OD8B7dDvmap79cZYC3Op8iLR1fF8BvsOU0KIw/U0QKJJ F4aovLrYj07B6wwz20nbmvHCzLNTJD1afElON0uQKFgtUcwusGlk6KO18DFKnrjkKJCPH56a7BF EOZroDeCQeOn4kcpBzzuNFM/rNgvMfX60iSxRy2buuHTxMTJE9SdLX8ay9uO8rZS6NAEJJNlBKe rJ6OmxNwX9CjLhDr9uulI/hZzB/BuuSiWQmhi8QQUbFUG/tiCSKtUW0tl61B9WzIQeyIg9/hC6m 39cbhfjcsnstdAEzkWuqD0Zq3Mf8cjWZkEKg21dKU4QBiRxJH3MT8lughzVigmOD3c1LbmKKUI3 NYdOqvVP3C1Z3w== X-Received: by 2002:a05:600c:4e0d:b0:4a1:e7ce:107b with SMTP id 5b1f17b1804b1-4a1e7ce1570mr122591455e9.2.1792499281003; Tue, 20 Oct 2026 05:28:01 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Cc: Richard Henderson , Michael Rolnik , Stafford Horne , Yoshinori Sato Subject: [PATCH 3/5] target/or1k: Convert to translate_for_debug Date: Tue, 20 Oct 2026 13:27:50 +0100 Message-ID: <20261020122752.3651914-4-peter.maydell@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20261020122752.3651914-1-peter.maydell@linaro.org> References: <20261020122752.3651914-1-peter.maydell@linaro.org> MIME-Version: 1.0 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=lists1p.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32f; envelope-from=peter.maydell@linaro.org; helo=mail-wm1-x32f.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: qemu development 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: 1792499335097158500 Content-Type: text/plain; charset="utf-8" Convert or1k to providing the translate_for_debug method rather than the deprecated get_phys_addr_debug method. Signed-off-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Richard Henderson --- target/or1k/cpu.h | 3 ++- target/or1k/cpu.c | 2 +- target/or1k/mmu.c | 21 ++++++++++++++++----- 3 files changed, 19 insertions(+), 7 deletions(-) diff --git a/target/or1k/cpu.h b/target/or1k/cpu.h index fc4387ce7ae..99b65ae4b97 100644 --- a/target/or1k/cpu.h +++ b/target/or1k/cpu.h @@ -296,7 +296,8 @@ void openrisc_translate_code(CPUState *cs, TranslationB= lock *tb, int print_insn_or1k(bfd_vma addr, disassemble_info *info); =20 #ifndef CONFIG_USER_ONLY -hwaddr openrisc_cpu_get_phys_addr_debug(CPUState *cpu, vaddr addr); +bool openrisc_cpu_translate_for_debug(CPUState *cpu, vaddr addr, + TranslateForDebugResult *result); =20 bool openrisc_cpu_tlb_fill(CPUState *cs, vaddr address, int size, MMUAccessType access_type, int mmu_idx, diff --git a/target/or1k/cpu.c b/target/or1k/cpu.c index 66c00c0930c..d5415f0e567 100644 --- a/target/or1k/cpu.c +++ b/target/or1k/cpu.c @@ -247,7 +247,7 @@ static void openrisc_any_initfn(Object *obj) =20 static const struct SysemuCPUOps openrisc_sysemu_ops =3D { .has_work =3D openrisc_cpu_has_work, - .get_phys_addr_debug =3D openrisc_cpu_get_phys_addr_debug, + .translate_for_debug =3D openrisc_cpu_translate_for_debug, }; #endif =20 diff --git a/target/or1k/mmu.c b/target/or1k/mmu.c index 3fc56e1b771..a78e8c8ca2e 100644 --- a/target/or1k/mmu.c +++ b/target/or1k/mmu.c @@ -139,7 +139,8 @@ bool openrisc_cpu_tlb_fill(CPUState *cs, vaddr addr, in= t size, cpu_loop_exit_restore(cs, retaddr); } =20 -hwaddr openrisc_cpu_get_phys_addr_debug(CPUState *cs, vaddr addr) +bool openrisc_cpu_translate_for_debug(CPUState *cs, vaddr addr, + TranslateForDebugResult *result) { OpenRISCCPU *cpu =3D OPENRISC_CPU(cs); int prot, excp, sr =3D cpu->env.sr; @@ -152,12 +153,15 @@ hwaddr openrisc_cpu_get_phys_addr_debug(CPUState *cs,= vaddr addr) PAGE_READ, (sr & SR_SM) !=3D 0); if (!excp) { - return phys_addr; + break; } excp =3D get_phys_mmu(cpu, &phys_addr, &prot, addr, PAGE_EXEC, (sr & SR_SM) !=3D 0); - return excp ? -1 : phys_addr; + if (excp) { + return false; + } + break; =20 default: /* The mmu is partially enabled, and we don't really have @@ -167,13 +171,20 @@ hwaddr openrisc_cpu_get_phys_addr_debug(CPUState *cs,= vaddr addr) PAGE_EXEC | PAGE_READ | PAGE_WRITE, (sr & SR_SM) !=3D 0); if (!excp) { - return phys_addr; + break; } /* fallthru */ =20 case 0: /* The mmu is definitely disabled; lookups never fail. */ get_phys_nommu(&phys_addr, &prot, addr); - return phys_addr; + break; } + + *result =3D (TranslateForDebugResult) { + .physaddr =3D phys_addr, + .lg_page_size =3D TARGET_PAGE_BITS, + .attrs.debug =3D 1, + }; + return true; } --=20 2.43.0 From nobody Mon Nov 23 04:44:10 2026 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=1792499327; cv=none; d=zohomail.com; s=zohoarc; b=Pz9slR0WDHq8nFCaHo7+1WLHk0mSYkoMrRjpVcTjsmZRXjXivPoAsfVQFXVR9tsqMXCADcAd+UCNWmmwFxdMAY2u1OIHF7BM4sBWYALgsefQeneJ+Xb94KiihP0WS6slBNjEl5UNrg9Hpd14pFpaROoPnkDRinXjWzH19sloB0Q= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1792499327; h=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:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=UeL+8vC6aQ3VQwZWZxW58agudbTa7NuDqzjt9yofRd4=; b=fvtZFuMfhgDH5Hw6EdhcBFcdDIHRAYOb/lcXJJQ/asz33a5+WpqlNR8EqR+OyYuY5aTd25o1PFvxc4cA+8zIz6OyjV2N9lDwaiBJouUuUx4ibBb8l/e08RJo/sVcCKrAVKTekQwReRjsx9cS5Egt89CzKVydZjRh4dkWkyxd+NA= 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 lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 179249932759937.50494803186825; Tue, 20 Oct 2026 05:28:47 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xJ8wp-0008TZ-HV; Tue, 20 Oct 2026 08:28:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xJ8wn-0008Sc-B1 for qemu-devel@nongnu.org; Tue, 20 Oct 2026 08:28:05 -0400 Received: from mail-wm1-x332.google.com ([2a00:1450:4864:20::332]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1xJ8wl-0004N5-Q2 for qemu-devel@nongnu.org; Tue, 20 Oct 2026 08:28:05 -0400 Received: by mail-wm1-x332.google.com with SMTP id 5b1f17b1804b1-4a1d484b4a9so40629475e9.0 for ; Tue, 20 Oct 2026 05:28:03 -0700 (PDT) Received: from lanath.. (wildly.archaic.org.uk. [81.2.115.145]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4a1f2cd482bsm68899315e9.12.2026.10.20.05.28.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2026 05:28:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1792499282; x=1793104082; 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:content-type; bh=UeL+8vC6aQ3VQwZWZxW58agudbTa7NuDqzjt9yofRd4=; b=h3sLf/rf71u9cPs1k64kTqm/Mq3k3pLh/U3UQOI3HS0Xb8z6XuXmTt4FwsD4GahdIZ m1AVpoLlXIYdqJpF//mZZ/XStFY06vTpxYnDtbGuHYp2W5VMwjBi/dn+EZlZfBKRwLQE 62Gbg/uJrOBTHBG1rvHFAHVUspn+H62ovXpEbprCiA9nEQAfnbAqcXz0VvIqnPvl6Wcy C8xK81colyWpBpIj6IWl722t6hopnhNWqJBY/2tWPq1C7LwN12oLICZKYxrWZiUK4r+P vxjCpoz65qazQ3UxGPJwJjpJtjbd2j9/whbbW/KWJfIOFs88hAKcOhjRLPDdwxdyd+xj ZLWA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1792499282; x=1793104082; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=UeL+8vC6aQ3VQwZWZxW58agudbTa7NuDqzjt9yofRd4=; b=q8A9yWm97MH8huIECt3BHTfihXPqs/rPKCQeeTCEDvahXPIWGKtlp3O0NunDlxFA4x jeoJkpjm3q42N+NAEzYxF6lSK6Cmb/i6Ipfn7UCH1LhHK6aDl1MblZbHRfblOeW0xMMF pEfrankqmX/0nohJjYc7/iSMaEYV0LpZQyss+a3m31YGqrGAmeNXZkHSuinDo+gehXbx 1ahZOJw8iomqKes8femfs55ku38Ch8G5wJ5I34EJtPX0ax7M3CckHzfR2l1ve1EGdlU1 N4aJvdeDJwFyKI2n7V6PXZhU9lfAT/cMYBcKontdxnJOtJKlqH1cjBw1AenQI6fFzn+Z BviA== X-Gm-Message-State: AFq9FYLvhcarpqWlUe9QL1yfJSVuTvJjFZCWMpNjoR4Ay0ChgaPyHzDY 0oZjf5UPalZ8VKIBI9zmvf3qKajpz4+rZh/JgLZbAEFdu3lTUJRNcMNCZXXZ8pJfNkLKDhfqSyP +NG9f/28= X-Gm-Gg: AYBFou3EdbHmuUqGK1eDyWhFkm/aHEjxDrSgTEzNRnIQT5wsN2dkVbIFGDtjm0p0rER ascWNh6vbPNE27sb2sDSFu3Yj7C1fd/fdLj+DA4+PRNejvQO6yQXWTvLj7rICZcwMzi+eXcBjWr +ZdJkng3P5MTjG8geh+KHstEDYAqVP86nwWfATGtcCLUFZ2LMtT44FddiF30GPayBUdgXdQY+9D KD42oS4wNpVOT697UT0ha9R9RfXgLAI3IAPgUJRJrVdpkIgaMs6lKlF9JlGLw9gSKk0iUns/qep zla/J89Vdsk+xnQgyNJ80cIC6/8xTyLNNX86RKAvYsKri578o9Kd63Soo/ddvEFaz+iXDBnJ3le LNjD27yKRzntLV1KclFIjL5o6HHegQr7fjjDCPpmdRaCkHl0CKY19K/bSoWyfwKZosPLl5UTteo pb7s1rskCMc4tMKkWcwwagI9M59iD9zjuL8FFBxE3l63hTSKwnk42MEY29RFkQiGYRAZB0F6+qX UFgnRvCeJou4lVO/qpa1G09+XvO8vxVI+co8Kqggs+ozmRVWtbDhiM3AFJ0YDZC2KghOACvztdH ARU= X-Received: by 2002:a05:600c:46c7:b0:4a1:f9e6:f418 with SMTP id 5b1f17b1804b1-4a1f9e6f45amr15744215e9.34.1792499282222; Tue, 20 Oct 2026 05:28:02 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Cc: Richard Henderson , Michael Rolnik , Stafford Horne , Yoshinori Sato Subject: [PATCH 4/5] target/rx: Convert to translate_for_debug Date: Tue, 20 Oct 2026 13:27:51 +0100 Message-ID: <20261020122752.3651914-5-peter.maydell@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20261020122752.3651914-1-peter.maydell@linaro.org> References: <20261020122752.3651914-1-peter.maydell@linaro.org> MIME-Version: 1.0 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=lists1p.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::332; envelope-from=peter.maydell@linaro.org; helo=mail-wm1-x332.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: qemu development 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: 1792499328969158500 Content-Type: text/plain; charset="utf-8" Convert rx to providing the translate_for_debug method rather than the deprecated get_phys_addr_debug method. Signed-off-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Richard Henderson Reviewed-by: Yoshinori Sato --- target/rx/cpu.h | 3 ++- target/rx/cpu.c | 2 +- target/rx/helper.c | 10 ++++++++-- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/target/rx/cpu.h b/target/rx/cpu.h index 64ba48a7329..8ec704a9f72 100644 --- a/target/rx/cpu.h +++ b/target/rx/cpu.h @@ -136,7 +136,8 @@ struct RXCPUClass { const char *rx_crname(uint8_t cr); void rx_cpu_do_interrupt(CPUState *cpu); bool rx_cpu_exec_interrupt(CPUState *cpu, int int_req); -hwaddr rx_cpu_get_phys_addr_debug(CPUState *cpu, vaddr addr); +bool rx_cpu_translate_for_debug(CPUState *cpu, vaddr addr, + TranslateForDebugResult *result); void rx_cpu_dump_state(CPUState *cpu, FILE *f, int flags); int rx_cpu_gdb_read_register(CPUState *cpu, GByteArray *buf, int reg); int rx_cpu_gdb_write_register(CPUState *cpu, uint8_t *buf, int reg); diff --git a/target/rx/cpu.c b/target/rx/cpu.c index 9b8473d71cf..0bcfec1d7c0 100644 --- a/target/rx/cpu.c +++ b/target/rx/cpu.c @@ -209,7 +209,7 @@ static void rx_cpu_init(Object *obj) =20 static const struct SysemuCPUOps rx_sysemu_ops =3D { .has_work =3D rx_cpu_has_work, - .get_phys_addr_debug =3D rx_cpu_get_phys_addr_debug, + .translate_for_debug =3D rx_cpu_translate_for_debug, }; =20 static const TCGCPUOps rx_tcg_ops =3D { diff --git a/target/rx/helper.c b/target/rx/helper.c index 0f99279bbaa..1f73fed6efd 100644 --- a/target/rx/helper.c +++ b/target/rx/helper.c @@ -147,7 +147,13 @@ bool rx_cpu_exec_interrupt(CPUState *cs, int interrupt= _request) return false; } =20 -hwaddr rx_cpu_get_phys_addr_debug(CPUState *cs, vaddr addr) +bool rx_cpu_translate_for_debug(CPUState *cs, vaddr addr, + TranslateForDebugResult *result) { - return addr; + *result =3D (TranslateForDebugResult) { + .physaddr =3D addr, + .lg_page_size =3D TARGET_PAGE_BITS, + .attrs.debug =3D 1, + }; + return true; } --=20 2.43.0 From nobody Mon Nov 23 04:44:10 2026 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=1792499303; cv=none; d=zohomail.com; s=zohoarc; b=dEMWv55SEpjjWL1DtkKLjvKSxFAmuQ+VI0IoB9gjsgrPislqc8hLgEr5BCktG5FNLLp+5NdigNQ+Gr1CLZteD6CWpf+p/7GnhollPOSVg7m7Yb22y1addH6/Mpha7XjjX5rYwhVKbYOUTpjllWKMHi1VXDudPqbYESWMOl0boN0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1792499303; h=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:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=vIJbdNAXRzY/n52qxKNec3ew+2nR5MYFb3y4fJM4Cfs=; b=Jagf2IlDz6lID5g+Py3rRmVttpWMITI4xwOC71M27svJRGIldmTl+z5qgOr/l6Aa1JUFA4Gy2cqEqPnmG6QMkQ35tSe+d46K5Un33ZZ1W3W4BAnxfA6DhnAtob5zW43CS33rFtW3BWu+mKnAcpPUP73RSLqiFCxfV0pYQ/kjIcc= 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 lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1792499303121343.30608781676926; Tue, 20 Oct 2026 05:28:23 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xJ8wp-0008Te-T8; Tue, 20 Oct 2026 08:28:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xJ8wo-0008TD-Ju for qemu-devel@nongnu.org; Tue, 20 Oct 2026 08:28:06 -0400 Received: from mail-wm1-x335.google.com ([2a00:1450:4864:20::335]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1xJ8wm-0004NH-Vl for qemu-devel@nongnu.org; Tue, 20 Oct 2026 08:28:06 -0400 Received: by mail-wm1-x335.google.com with SMTP id 5b1f17b1804b1-4a19cba5c14so32415425e9.3 for ; Tue, 20 Oct 2026 05:28:04 -0700 (PDT) Received: from lanath.. (wildly.archaic.org.uk. [81.2.115.145]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4a1f2cd482bsm68899315e9.12.2026.10.20.05.28.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2026 05:28:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1792499283; x=1793104083; 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:content-type; bh=vIJbdNAXRzY/n52qxKNec3ew+2nR5MYFb3y4fJM4Cfs=; b=Xj4h1Qspg4FZXe4qkcJ+zDbGC2AIzynpB8iuR45KjBtz3xSdaFDp1PQh3Q8qP2Z2xw epW8xtG9Ydzur4rKMsRRcfHdtmL2GSNHeFCcfK5Ctta+9pSL1E13H7xdo3UV+Fzci4qg oWJDyjteTrzDI9Wp5TK+4EYGhSRn/qxrW0k3hmdvjliL2m+QdNNCrk6kYMeOqHaHJXH5 XUmEpu5BDe+ODBbXZBVyZmgNT9Ul+iE/BZiQBPg0A5hqJhLSE/vsrGOZNyHSpLmOYCjB aaP/Ky2PdEycx/WVQcwr+dkFv1jxr+6BAeQ8nZKM4na1SSN88M+376k7/HeEDAMiVQ1K 7C9g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1792499283; x=1793104083; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=vIJbdNAXRzY/n52qxKNec3ew+2nR5MYFb3y4fJM4Cfs=; b=kEq32bCmKyoqdU/V+Hm5P0ktmlvpSZpEjK/cjsbBkKYgfhO1Pm+LGtJ15LIi3cCcZk m0kkcOFej5QP/9pbaXqPUh9EhnggBZERYeL0HT9g69tUvZ0wyu4OPPfAGH5W1l4SWfX1 xyfc1KiT8o3r3XQaUXKILWLkMJc/wkAXFVF0erv5K/A1Msrriln78ic7sXUwg0ClKDtH zjUn37TlPuBl7OPw4UdOBQsyho8tTXs7Pjl/irySLxoP05+tZ4IfHQenASeT7h4Oio34 AQQou1kBKWrO3ZXSg8aTBiDxBamcvuoEiHDuPBGal+MxvYX5YPon6P8KgdJnPpH4ZP0z W1KA== X-Gm-Message-State: AFq9FYI2K21mLJDOw4+Wft8DxnEVHWHhjwgYngkTpm9zPvhQgJbMXskf rklQsAabIMCNUzQrLbxHxFYbzxN11WpUaQFQp4XA1GrD2WBc2re3+G98gAPVvh7JdVIGVu4Lx0e 8disKZiI= X-Gm-Gg: AYBFou0ZllyOBvwg4gjQzZKBDMhdhhIbhNgWL3DtiKesvcscATju4raBicO5gAXw0N5 aexRd3rQ7OesZfXD3UmVDxWMwmgIZFtmwnLKDOU7kAfaJ4jzRrQWN0HhHhdJYZ5BJIGvBBa7HOu Q2Ljqc4lnhHMiiHCuAXHkgj/rnsErShLmzC38IvGY8gMV9b7Cp+2tOPvxFPLDTKk3A8YFCO+TtY DyiLZA+xaUYz9WuFvCiz//+xeEZO8bUaBL8ZyOhCcnuBYQAA2iJtZm1r3us+IDk1HFzKUD0DmRP j990n2G8Mrp5WsC7PLMc4wp6Yw4mrPTWNX2axsgY3Qmiv/8g5hI6/8QPuQjRcx60gxc6mxDmhzO e1/dUftjMm13NRWu9jQURhilwYdWTYak5g6xO/2VsDYaW7sVXh/6+YINrdOSNTfHf6vYQ2XbROX X0+2/GNMVhTPVjgz9iLoNEGa2FoyIGXYrdoZHvL0BFhwTGsamQjA5DCbO0o/5tejNEl7Hu7KxEk 5CAiErSXrGhKRvK+A8RUedYXzixfIaU/MD6DhDQ013RIQGFCmKh4fOTXWJ72KLaSRc7vYXrYZuQ mXY= X-Received: by 2002:a05:600c:3b22:b0:4a1:7690:d878 with SMTP id 5b1f17b1804b1-4a1d7615cb9mr230307795e9.17.1792499283517; Tue, 20 Oct 2026 05:28:03 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Cc: Richard Henderson , Michael Rolnik , Stafford Horne , Yoshinori Sato Subject: [PATCH 5/5] target/tricore: Convert to translate_for_debug Date: Tue, 20 Oct 2026 13:27:52 +0100 Message-ID: <20261020122752.3651914-6-peter.maydell@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20261020122752.3651914-1-peter.maydell@linaro.org> References: <20261020122752.3651914-1-peter.maydell@linaro.org> MIME-Version: 1.0 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=lists1p.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::335; envelope-from=peter.maydell@linaro.org; helo=mail-wm1-x335.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: qemu development 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: 1792499304625158500 Content-Type: text/plain; charset="utf-8" Convert tricore to providing the translate_for_debug method rather than the deprecated get_phys_addr_debug method. Signed-off-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Richard Henderson --- target/tricore/cpu.h | 3 ++- target/tricore/cpu.c | 2 +- target/tricore/helper.c | 13 ++++++++++--- 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h index 12e497d2a7a..17e3d1fe804 100644 --- a/target/tricore/cpu.h +++ b/target/tricore/cpu.h @@ -79,7 +79,8 @@ struct TriCoreCPUClass { ResettablePhases parent_phases; }; =20 -hwaddr tricore_cpu_get_phys_addr_debug(CPUState *cpu, vaddr addr); +bool tricore_cpu_translate_for_debug(CPUState *cpu, vaddr addr, + TranslateForDebugResult *result); void tricore_cpu_dump_state(CPUState *cpu, FILE *f, int flags); =20 FIELD(PCXI, PCPN_13, 24, 8) diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c index 84a05e3d363..deca702cc6d 100644 --- a/target/tricore/cpu.c +++ b/target/tricore/cpu.c @@ -207,7 +207,7 @@ static bool tricore_cpu_exec_interrupt(CPUState *cs, in= t interrupt_request) =20 static const struct SysemuCPUOps tricore_sysemu_ops =3D { .has_work =3D tricore_cpu_has_work, - .get_phys_addr_debug =3D tricore_cpu_get_phys_addr_debug, + .translate_for_debug =3D tricore_cpu_translate_for_debug, }; =20 static const TCGCPUOps tricore_tcg_ops =3D { diff --git a/target/tricore/helper.c b/target/tricore/helper.c index 273713a1473..9cc80b14c8c 100644 --- a/target/tricore/helper.c +++ b/target/tricore/helper.c @@ -47,7 +47,8 @@ static int get_physical_address(CPUTriCoreState *env, hwa= ddr *physical, return ret; } =20 -hwaddr tricore_cpu_get_phys_addr_debug(CPUState *cs, vaddr addr) +bool tricore_cpu_translate_for_debug(CPUState *cs, vaddr addr, + TranslateForDebugResult *result) { TriCoreCPU *cpu =3D TRICORE_CPU(cs); hwaddr phys_addr; @@ -56,9 +57,15 @@ hwaddr tricore_cpu_get_phys_addr_debug(CPUState *cs, vad= dr addr) =20 if (get_physical_address(&cpu->env, &phys_addr, &prot, addr, MMU_DATA_LOAD, mmu_idx)) { - return -1; + return false; } - return phys_addr; + + *result =3D (TranslateForDebugResult) { + .physaddr =3D phys_addr, + .lg_page_size =3D TARGET_PAGE_BITS, + .attrs.debug =3D 1, + }; + return true; } =20 /* TODO: Add exception support */ --=20 2.43.0