From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544831; cv=none; d=zohomail.com; s=zohoarc; b=g835gx8V/GYrBDaWUvznchA2Fgl+9n5fJ3fSldiSXNZ20WWNWiRB4uYuFZhLNdrtGL/g6QCfJq12tS+6ecR8hUIuKZl9EEbQzPzbg+qi66X4KPZ1dkOhahY+KhgdySyUg8ztfKH4OHo/u7cOc2MTQYK0ytkrWtYXkgRw7Am04D4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544831; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=MH3PTa2rQEeojjP7It6N6X2oxiaoDUa4E4nRhBKXZH8=; b=OCdpfpiH6g2TgDBRhE5lyolmTwJSq916hjmA9xA7weWp/rsPnBNXrCtTxgsNPjUniUsn+rWZxhvBduTfvZA9PGQZQECVkCs0lecMeTomfOw1NNUqD01LDZDT/q6XRwhjPNah5PesWZOuREYPhcLwof+MOG4+imfbdKlmEAzm+k4= 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 1671544831976424.44858688460863; Tue, 20 Dec 2022 06:00:31 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3M-00047T-D2; Tue, 20 Dec 2022 08:53:08 -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 1p7d3K-00046s-Um; Tue, 20 Dec 2022 08:53:06 -0500 Received: from mail-oa1-x34.google.com ([2001:4860:4864:20::34]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3J-0000z0-Aa; Tue, 20 Dec 2022 08:53:06 -0500 Received: by mail-oa1-x34.google.com with SMTP id 586e51a60fabf-144bd860fdbso15500673fac.0; Tue, 20 Dec 2022 05:53:04 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=MH3PTa2rQEeojjP7It6N6X2oxiaoDUa4E4nRhBKXZH8=; b=XrfX2XL8mhO4XIBlmT2AQHZ6to3QXSgTqafi8OoZHeKyYpq+Vh2Z0QkLkuPSoetBf4 3BSG/AeVKAYb3QRvRtLocguHAeWpvO0V/u+pJ39evyDWK5ppCwuEYH78DcLPijb/0/iU U6qVMCL6jZHLGbWd3ybwj+s+ufXuHlos7XzxyHD0BGny4YSsTMdUMOiYjnjOJe4bNGkG b3mpXQCh5uvb/fD5oefD7MtGfvb7SRpTcrR1fCjC2TaJVK6+I0cvveSSy4STywjxxDWc LR9lRCEfTuliw4gYiY9/64owqBMjqkV95YOYuWfIA0bUL8TKCL4bxK0EuLhcO/hVAo0a GWrQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=MH3PTa2rQEeojjP7It6N6X2oxiaoDUa4E4nRhBKXZH8=; b=3LCB/UtP3h19Ws+ep3ulqMvGTvYU6tcS67msEJ1Oh9haXKqXYsX0zqSE4/e7HYOEO3 cMCaeX+jwZqWnaRWpkdwugVdWFC5y8tcGJu+Scr5MFmIPjinJogc+pDVO67Btrznncme GJpaRJ3hhIPcsekTjjcvi8ily/c64N2Lv/W4aN688m4VfbSQFxYFL/uVIZXoK901fbv2 DvR8BaAfVK9Z++8J84J/i7K5U19xJKZkH2y9q4QfeFw3d9rlk1qEwnOoGrT3lLfbiDc/ c7c8rJAXzm/eUVO8+7LXKa/aH7Ggnzn60ADXepDPNxFaUsE1CDh8bKh+bj5MsrFOLg7g Y6NQ== X-Gm-Message-State: ANoB5pkJ5VlRAWPT2aiBQ5iKOSSQzKQOA7naVhlpMamUVnvK0lY4edmp sbudfmSzlpCjEYintRhIjuSQHuWN0/U= X-Google-Smtp-Source: AA0mqf5Wp2uzKUjolFGVW3qTFLuVQtGVIUwgwWaKJsNQE+Ken6tK1f8gx9kWJnRGyot/LRP7mrA/5g== X-Received: by 2002:a05:6870:e8a:b0:144:87fc:f4b2 with SMTP id mm10-20020a0568700e8a00b0014487fcf4b2mr23453732oab.24.1671544383662; Tue, 20 Dec 2022 05:53:03 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= , David Gibson , Greg Kurz Subject: [PULL 01/15] MAINTAINERS: downgrade PPC KVM/TCG CPUs and pSeries to 'Odd Fixes' Date: Tue, 20 Dec 2022 10:52:37 -0300 Message-Id: <20221220135251.155176-2-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::34; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x34.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544836221100003 The maintainer is no longer being paid to maintain these components. All maintainership work is being done in his personal time since the middle of the 7.2 development cycle. Change the status of PPC KVM CPUs, PPC TCG CPUs and the pSeries machine to 'Odd Fixes', reflecting that the maintainer no longer has exclusive time to dedicate to them. It'll also (hopefully) keep expectations under check when/if these components are used in a customer product. Cc: C=C3=A9dric Le Goater Cc: David Gibson Cc: Greg Kurz Reviewed-by: C=C3=A9dric Le Goater Reviewed-by: Greg Kurz Reviewed-by: David Gibson Message-Id: <20221117153218.182835-1-danielhb413@gmail.com> Signed-off-by: Daniel Henrique Barboza --- MAINTAINERS | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index 716d5a24ad..9a8c40a1c5 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -276,7 +276,7 @@ R: C=C3=A9dric Le Goater R: David Gibson R: Greg Kurz L: qemu-ppc@nongnu.org -S: Maintained +S: Odd Fixes F: target/ppc/ F: hw/ppc/ppc.c F: hw/ppc/ppc_booke.c @@ -402,7 +402,7 @@ M: Daniel Henrique Barboza R: C=C3=A9dric Le Goater R: David Gibson R: Greg Kurz -S: Maintained +S: Odd Fixes F: target/ppc/kvm.c =20 S390 KVM CPUs @@ -1382,7 +1382,7 @@ R: C=C3=A9dric Le Goater R: David Gibson R: Greg Kurz L: qemu-ppc@nongnu.org -S: Maintained +S: Odd Fixes F: hw/*/spapr* F: include/hw/*/spapr* F: hw/*/xics* --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544536; cv=none; d=zohomail.com; s=zohoarc; b=KgyiGSk+4S3wX16HxJD5JBlYM5+EVPjlvhWcI0JeaSPxfYBhItem26MaeJ2R3YxPHQCjgqcLssrMbV70Ell2FZ9VDRGkrI8qBngniC6aRL8cqfo0jKbOlJri/J9YaBgUcvOjUti5UwbMKxHKY2aXmS3YNvdfdlXboCNgK9QPnGg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544536; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=mL0VJp39CttnSDlqO4/UNmgaMe23MKykdEDegdgvW5k=; b=DDj8jTef5JVhIPBnouFz+uChtoZcyLf9IbTyEPDdF+b2YHfY20LnsWKeErhwVE65ZhYISMOE463mQwwcnx3xliiwyAX1hBO3CCN76aIamVXuZltRnHAVhnCb8tpw3wFHQ4pwVo0WRaptdQh+bxzW32clkLui3iAxGJLJQd+ZLRk= 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 1671544536565535.7167289423631; Tue, 20 Dec 2022 05:55:36 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3Q-00048g-Tn; Tue, 20 Dec 2022 08:53:12 -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 1p7d3M-00047V-V7; Tue, 20 Dec 2022 08:53:08 -0500 Received: from mail-oa1-x29.google.com ([2001:4860:4864:20::29]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3L-0000zN-Eu; Tue, 20 Dec 2022 08:53:08 -0500 Received: by mail-oa1-x29.google.com with SMTP id 586e51a60fabf-144bd860fdbso15500759fac.0; Tue, 20 Dec 2022 05:53:06 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=mL0VJp39CttnSDlqO4/UNmgaMe23MKykdEDegdgvW5k=; b=f+0fei0YXG/T3YMpZJK6fXLbxkdn61adCL/c2WrZQ4NM9yxpaokblOwoFdklh45WJf jd1iLWpB9MKkukuI6pCR0u9Sq+ccoP9uBEZ6dbLnmQnVtjjMAd8jq0s9bA6pep5u8Rtf fuIms27aupOVhjuhZOQb5U+q/4TZhk9DmMgjn5NdQxWHler6GYCwIV3tCwMEbcqsnG1j xuqIXSyaMTzbYyiutxDBhI8IOnanBAhWs724qts5QI5J54oTbAJg+0d7y7i2BaRdMam7 c7D4kOo6X9/FPjEijkjQ2ZwWLoPCmncO4cqWRj2KcrTtuyTXoKUtoxqtS+T1W5CHuDz/ NcfQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=mL0VJp39CttnSDlqO4/UNmgaMe23MKykdEDegdgvW5k=; b=qH2xlTFTnhaDoeS5QCO0ujXzdQekM9q8O9GJDiuLEuxW3Ys90CWqqufuUxhaC5r2jw BVzakFCrkWjhsVNbuHhlY7/di2DPjfap+eppWFuCJhLico4jf5BdbO8cND4/lrUhsKkC kk0v7kpSlOO1nfbYMA6h8yASPwBx2S+SagzG+EzopFwqvQGLDeTpesUVoH9xZwACCKj8 Xc6iD7Z0PUk9kgP0Qs0FcSo4kImdWh2v6wNfLfQoYvptn1p9ZmlXv9CBIAKxhrg3ueRp +ezOO28/QTzLx1Tw5HMXy8ubhhju3gy6iykx3bA180bEP2JgZHCGLnYRqXm/zaJlodJF D3Dg== X-Gm-Message-State: ANoB5pljB53bMm5mzBaux2T4HOkUfXHb/ZfnAZvZXrKp6EE3hu6uWBsn IfMwx55/w+td+yJ7rC1vQgmFLtVsXgw= X-Google-Smtp-Source: AA0mqf6fZePHkvlwv9THkPSVdrijxVWObwO2fVILViQ7xnMvYpc6h8asXgzmECidj7vGLu9QJ+ptMw== X-Received: by 2002:a05:6870:4c8b:b0:14b:7e4f:f0ca with SMTP id pi11-20020a0568704c8b00b0014b7e4ff0camr11927825oab.31.1671544385746; Tue, 20 Dec 2022 05:53:05 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Bernhard Beschow Subject: [PULL 02/15] hw/sd/sdhci: MMIO region is implemented in 32-bit accesses Date: Tue, 20 Dec 2022 10:52:38 -0300 Message-Id: <20221220135251.155176-3-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::29; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x29.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544538438100003 From: Philippe Mathieu-Daud=C3=A9 Tested-by: Bernhard Beschow Reviewed-by: Bernhard Beschow Signed-off-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20221101222934.52444-2-philmd@linaro.org> Signed-off-by: Daniel Henrique Barboza --- hw/sd/sdhci.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hw/sd/sdhci.c b/hw/sd/sdhci.c index 306070c872..22c758ad91 100644 --- a/hw/sd/sdhci.c +++ b/hw/sd/sdhci.c @@ -1332,6 +1332,10 @@ sdhci_write(void *opaque, hwaddr offset, uint64_t va= l, unsigned size) static const MemoryRegionOps sdhci_mmio_ops =3D { .read =3D sdhci_read, .write =3D sdhci_write, + .impl =3D { + .min_access_size =3D 4, + .max_access_size =3D 4, + }, .valid =3D { .min_access_size =3D 1, .max_access_size =3D 4, --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544554; cv=none; d=zohomail.com; s=zohoarc; b=COSzmxtpuHwEuCKKr9YEm+H8EZlR8kVw4ZtBskelnXAybNh+9jx7Niti9YtJa8mDcPixCzhlmhHpvWtAUVLGb6uTAqHqY3rayL2cOnmA6DWQPeobSIeyBbp90JCF7kZ4z7Z891dbjiEAV0mSeubgWHJ/vTMgocYdqr8bbESayG0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544554; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=1VvlOM0ugm9Fr/4dQpsfYlJvQEM3Fz2babkbnBncbxQ=; b=Typ+SjrisrstnwpW3wbNzdYwFuNv2JxA9JM6VeWla4M+Z3+jU8cggGXz653FOeeqT3qZEdQDl9ix0iGmLAau6C94k4MJ4HZMriAwp+kHqxZbiSbBbuc8eKLbgzAXAK0DLSLrVP51H3hf+VDurMxaq5YAiQ8zdprsRAqfHyQeUuU= 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 1671544554119288.94319914235825; Tue, 20 Dec 2022 05:55:54 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3U-0004CF-Ro; Tue, 20 Dec 2022 08:53:16 -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 1p7d3P-00048h-8Y; Tue, 20 Dec 2022 08:53:11 -0500 Received: from mail-oa1-x32.google.com ([2001:4860:4864:20::32]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3N-000115-Ft; Tue, 20 Dec 2022 08:53:11 -0500 Received: by mail-oa1-x32.google.com with SMTP id 586e51a60fabf-1441d7d40c6so15416034fac.8; Tue, 20 Dec 2022 05:53:08 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=1VvlOM0ugm9Fr/4dQpsfYlJvQEM3Fz2babkbnBncbxQ=; b=T4N8ldIIS0QGxR6/WATrUp8TVmXONg/XOjmaXbJ5Y6pkdy+jnZOCmi24pzxwQ0JWDr ZNWMySnf2uCPHt8ErO9vYfJsw+1keZgFeE43MnFG8K9CYj+itLpbEYrewKw4+fJhaJrT ADYLvEWQleIxMREGihIqkTWRd0UeVb2nsu38799fFdh6ywii8DxrSj+NZqqQvGZyI57h AwQIh28LLwmRl/KdRzOghPPz8YNUkhhXxlWCJIlQZU85XnSUINxVuVWS/n4aDZ5la26P 0SNLtFbXqNfQVn2h/qRCzq+/2PWsELvxLAu3VL9GJU7bvZWjI9yTqo7r07z/ejAV/Uif U3vw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=1VvlOM0ugm9Fr/4dQpsfYlJvQEM3Fz2babkbnBncbxQ=; b=HUGMBadLOGWgwOBdv3CYks/z974jboLYsLjI33hShi7wt49YVLWgFK3LDm8XiuCfYi v4OkMN0XgW/n0ZdACguzQPnw+1GQlYWgh0NUUT+gmri5oX9Lgn0D7GeT1+Adl3dI9Lxz w5Acp8lCeusVa+qRJBQZCT7q//pcM6Y0elJ2q35Yz7FvvgjkVLpH6kKJLS4vK5vZ4e+h XlOhMejucxvF4iDuDxioZoJkLEXQgVJc+j+PHfjy64rhvEL/lw1GSDX3B28F/nC03xfJ wzvDqBhnOC4M1CLObSxLA4fgeVoue1TtqWkB7t4OD+SwUXhkQqgV7vpPtMJT5DyIxaIr ZwQg== X-Gm-Message-State: ANoB5pkse4Jxni4uc765KCWxUKJPf+fAySVk3tHtjxCHtri96zGbCJzP fPSaDrvmcUiMlcNWT3PPb/Gx0fWJ2I0= X-Google-Smtp-Source: AA0mqf652R1b55IKEcWRsRWSFt0dCMamRtLCQEZIMf4sKBuBpnwDz6hYI1ljOXOgczVrdI3/oEzvpA== X-Received: by 2002:a05:6870:c0cc:b0:144:8fee:3c4f with SMTP id e12-20020a056870c0cc00b001448fee3c4fmr24148415oad.36.1671544387992; Tue, 20 Dec 2022 05:53:07 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Bernhard Beschow Subject: [PULL 03/15] hw/sd/sdhci: Support big endian SD host controller interfaces Date: Tue, 20 Dec 2022 10:52:39 -0300 Message-Id: <20221220135251.155176-4-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::32; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x32.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544554576100005 From: Philippe Mathieu-Daud=C3=A9 Some SDHCI IP can be synthetized in various endianness: https://github.com/u-boot/u-boot/blob/v2021.04/doc/README.fsl-esdhc - CONFIG_SYS_FSL_ESDHC_BE ESDHC IP is in big-endian mode. Accessing ESDHC registers can be determined by ESDHC IP's endian mode or processor's endian mode. Our current implementation is little-endian. In order to support big endianness: - Rename current MemoryRegionOps as sdhci_mmio_le_ops ('le') - Add an 'endianness' property to SDHCIState (default little endian) - Set the 'io_ops' field in realize() after checking the property - Add the sdhci_mmio_be_ops (big-endian) MemoryRegionOps. Signed-off-by: Philippe Mathieu-Daud=C3=A9 Tested-by: Bernhard Beschow Reviewed-by: Bernhard Beschow Message-Id: <20221101222934.52444-3-philmd@linaro.org> Signed-off-by: Daniel Henrique Barboza --- hw/sd/sdhci-internal.h | 1 + hw/sd/sdhci.c | 32 +++++++++++++++++++++++++++++--- include/hw/sd/sdhci.h | 1 + 3 files changed, 31 insertions(+), 3 deletions(-) diff --git a/hw/sd/sdhci-internal.h b/hw/sd/sdhci-internal.h index 964570f8e8..5f3765f12d 100644 --- a/hw/sd/sdhci-internal.h +++ b/hw/sd/sdhci-internal.h @@ -308,6 +308,7 @@ extern const VMStateDescription sdhci_vmstate; #define SDHC_CAPAB_REG_DEFAULT 0x057834b4 =20 #define DEFINE_SDHCI_COMMON_PROPERTIES(_state) \ + DEFINE_PROP_UINT8("endianness", _state, endianness, DEVICE_LITTLE_ENDI= AN), \ DEFINE_PROP_UINT8("sd-spec-version", _state, sd_spec_version, 2), \ DEFINE_PROP_UINT8("uhs", _state, uhs_mode, UHS_NOT_SUPPORTED), \ DEFINE_PROP_UINT8("vendor", _state, vendor, SDHCI_VENDOR_NONE), \ diff --git a/hw/sd/sdhci.c b/hw/sd/sdhci.c index 22c758ad91..289baa879e 100644 --- a/hw/sd/sdhci.c +++ b/hw/sd/sdhci.c @@ -1329,7 +1329,7 @@ sdhci_write(void *opaque, hwaddr offset, uint64_t val= , unsigned size) value >> shift, value >> shift); } =20 -static const MemoryRegionOps sdhci_mmio_ops =3D { +static const MemoryRegionOps sdhci_mmio_le_ops =3D { .read =3D sdhci_read, .write =3D sdhci_write, .impl =3D { @@ -1344,6 +1344,21 @@ static const MemoryRegionOps sdhci_mmio_ops =3D { .endianness =3D DEVICE_LITTLE_ENDIAN, }; =20 +static const MemoryRegionOps sdhci_mmio_be_ops =3D { + .read =3D sdhci_read, + .write =3D sdhci_write, + .impl =3D { + .min_access_size =3D 4, + .max_access_size =3D 4, + }, + .valid =3D { + .min_access_size =3D 1, + .max_access_size =3D 4, + .unaligned =3D false + }, + .endianness =3D DEVICE_BIG_ENDIAN, +}; + static void sdhci_init_readonly_registers(SDHCIState *s, Error **errp) { ERRP_GUARD(); @@ -1371,8 +1386,6 @@ void sdhci_initfn(SDHCIState *s) =20 s->insert_timer =3D timer_new_ns(QEMU_CLOCK_VIRTUAL, sdhci_raise_inser= tion_irq, s); s->transfer_timer =3D timer_new_ns(QEMU_CLOCK_VIRTUAL, sdhci_data_tran= sfer, s); - - s->io_ops =3D &sdhci_mmio_ops; } =20 void sdhci_uninitfn(SDHCIState *s) @@ -1388,10 +1401,23 @@ void sdhci_common_realize(SDHCIState *s, Error **er= rp) { ERRP_GUARD(); =20 + switch (s->endianness) { + case DEVICE_LITTLE_ENDIAN: + s->io_ops =3D &sdhci_mmio_le_ops; + break; + case DEVICE_BIG_ENDIAN: + s->io_ops =3D &sdhci_mmio_be_ops; + break; + default: + error_setg(errp, "Incorrect endianness"); + return; + } + sdhci_init_readonly_registers(s, errp); if (*errp) { return; } + s->buf_maxsz =3D sdhci_get_fifolen(s); s->fifo_buffer =3D g_malloc0(s->buf_maxsz); =20 diff --git a/include/hw/sd/sdhci.h b/include/hw/sd/sdhci.h index 01a64c5442..a989fca3b2 100644 --- a/include/hw/sd/sdhci.h +++ b/include/hw/sd/sdhci.h @@ -96,6 +96,7 @@ struct SDHCIState { /* Configurable properties */ bool pending_insert_quirk; /* Quirk for Raspberry Pi card insert int */ uint32_t quirks; + uint8_t endianness; uint8_t sd_spec_version; uint8_t uhs_mode; uint8_t vendor; /* For vendor specific functionality */ --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544466; cv=none; d=zohomail.com; s=zohoarc; b=OpQC+VxIlIWjMR+RDIeQ3mi+oE7XeYoBUb7AvMT+4uBP9FyRbO8rsqRYcS5EmEyc2JckFZk9ML19XW7fQEqH4Qs2/4zmk1Wgk0mJton/dyJwzrTdkcGL4+vRV/ok7k+WnbmJq5qhTxuBM6Ls4PaTF+YZsU1U7saeki7XjFZOMI4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544466; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=UFsuVGzWOTY6d9VZpB1m6PqbK20uu92F5WdPXlu+u3A=; b=iz9MX9wWLy7AgRl7p+mjBQT48PUVV+9qT4vymGAltjKD3PfJV/JXcytpDqGv1ea2rF5W8X2WQbuHPQUJZ7DLxtZi7DXHF5I99pScCg3DpDu7U3UiDrQTO68ALmcsiQjaj/yexl1DAbJ+SBn2G3S9/E9MmuQqLezW5XxjQlxM2+Q= 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 1671544466749516.7215573657304; Tue, 20 Dec 2022 05:54:26 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3T-0004BK-Pq; Tue, 20 Dec 2022 08:53:15 -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 1p7d3R-00049A-3E; Tue, 20 Dec 2022 08:53:13 -0500 Received: from mail-oa1-x34.google.com ([2001:4860:4864:20::34]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3P-0000z0-7u; Tue, 20 Dec 2022 08:53:12 -0500 Received: by mail-oa1-x34.google.com with SMTP id 586e51a60fabf-144bd860fdbso15500995fac.0; Tue, 20 Dec 2022 05:53:10 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=UFsuVGzWOTY6d9VZpB1m6PqbK20uu92F5WdPXlu+u3A=; b=HHaVtmc/C7rEpCtmHV3bzrNQ9mrFtbVxMjhcHH0rn+LNT05JdeblMXWyzY/xp4V6Lj 4HRDPfZDmaGSyE0PpdGTUHpTcVq1JYSd/cs7/Ref/CPZeXEneyOMMaDeHD+y9pq2iKbX 9HZJOhSyQwZ1foYGqJDV5A1bfETjF6jOTQt5S1iUAocYwuDgki+0tU8FU/9+HKAFzkWk diysOICsF9N+RfVmcT5jXqJvtq2xh/ERIC/WxUDv8rP+8kfZTYqlbCuMlxXzOW3CtYhe uxrxonRKHMPqR7f7EqgU4ljX1uJaqAkOkUZkp9dMpDF/G4b7FLP8eEmRHuyeaGV68avy wFYg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=UFsuVGzWOTY6d9VZpB1m6PqbK20uu92F5WdPXlu+u3A=; b=QqqbpfrANzB15hvufZCWGA2bWxtnmzW1IUfLixwPIMGQXr5/DQaCHYkK6sAja0z7qL hGaFExOzSth6KvJq4TUPULO1Onc6cmZVTUC3DrueXpq9PVBWMcylTuklTKeMW+U/jPVb cw6gZsXiSbXyUdBJDrCPXCNjSEbyyNl3IF8F1oBX9hNL4hQhEj9fkdiklgiDg+4dqEBR Z42M3cKAkSTtFLRwcCHwwhHtDynPs/Nnx39O3sWgkEGW5zeUAgK2bnUC8akgUMPbr1z5 KGsx9/Ipd1EXQSkqNgwjsph8Ucy75hmQ0BqbXBfAlQPDRPcnzas9/Q0tYyv9C1WZdXq/ ny+A== X-Gm-Message-State: ANoB5pkUt06FWC6vDujVCElol8lbpaSDgaaAprn+Tyxkzh3vUy7eIIMk /LIR4c8u7mfXPTfy81fyp4ELFsDgXbA= X-Google-Smtp-Source: AA0mqf6n2mjsv1aYtoHHXh1G5dFyVF/oggi8SECpBzlFYG8597IlSUah/2b/BtF5vbfPtH4gsb6Pbg== X-Received: by 2002:a05:6870:a797:b0:144:7061:c0 with SMTP id x23-20020a056870a79700b00144706100c0mr22016851oao.39.1671544390126; Tue, 20 Dec 2022 05:53:10 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Bernhard Beschow Subject: [PULL 04/15] hw/ppc/e500: Add Freescale eSDHC to e500plat Date: Tue, 20 Dec 2022 10:52:40 -0300 Message-Id: <20221220135251.155176-5-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::34; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x34.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544467824100004 From: Philippe Mathieu-Daud=C3=A9 Adds missing functionality to e500plat machine which increases the chance of given "real" firmware images to access SD cards. Signed-off-by: Bernhard Beschow Message-Id: <20221018210146.193159-8-shentey@gmail.com> [PMD: Simplify using create_unimplemented_device("esdhc")] Signed-off-by: Philippe Mathieu-Daud=C3=A9 Tested-by: Bernhard Beschow Reviewed-by: Bernhard Beschow Message-Id: <20221101222934.52444-4-philmd@linaro.org> Signed-off-by: Daniel Henrique Barboza --- docs/system/ppc/ppce500.rst | 13 ++++++++++ hw/ppc/Kconfig | 2 ++ hw/ppc/e500.c | 48 ++++++++++++++++++++++++++++++++++++- hw/ppc/e500.h | 1 + hw/ppc/e500plat.c | 1 + 5 files changed, 64 insertions(+), 1 deletion(-) diff --git a/docs/system/ppc/ppce500.rst b/docs/system/ppc/ppce500.rst index fa40e57d18..c9fe0915dc 100644 --- a/docs/system/ppc/ppce500.rst +++ b/docs/system/ppc/ppce500.rst @@ -19,6 +19,7 @@ The ``ppce500`` machine supports the following devices: * Power-off functionality via one GPIO pin * 1 Freescale MPC8xxx PCI host controller * VirtIO devices via PCI bus +* 1 Freescale Enhanced Secure Digital Host controller (eSDHC) * 1 Freescale Enhanced Triple Speed Ethernet controller (eTSEC) =20 Hardware configuration information @@ -180,3 +181,15 @@ as follows: -kernel vmlinux \ -drive if=3Dpflash,file=3D/path/to/rootfs.ext2,format=3Draw \ -append "rootwait root=3D/dev/mtdblock0" + +Alternatively, the root file system can also reside on an emulated SD card +whose size must again be a power of two: + +.. code-block:: bash + + $ qemu-system-ppc64 -M ppce500 -cpu e500mc -smp 4 -m 2G \ + -display none -serial stdio \ + -kernel vmlinux \ + -device sd-card,drive=3Dmydrive \ + -drive id=3Dmydrive,if=3Dnone,file=3D/path/to/rootfs.ext2,format=3Dr= aw \ + -append "rootwait root=3D/dev/mmcblk0" diff --git a/hw/ppc/Kconfig b/hw/ppc/Kconfig index b8d2522f45..72a311edcb 100644 --- a/hw/ppc/Kconfig +++ b/hw/ppc/Kconfig @@ -128,10 +128,12 @@ config E500 select PFLASH_CFI01 select PLATFORM_BUS select PPCE500_PCI + select SDHCI select SERIAL select MPC_I2C select FDT_PPC select DS1338 + select UNIMP =20 config E500PLAT bool diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c index 2fe496677c..2bef2f01cb 100644 --- a/hw/ppc/e500.c +++ b/hw/ppc/e500.c @@ -48,6 +48,8 @@ #include "hw/net/fsl_etsec/etsec.h" #include "hw/i2c/i2c.h" #include "hw/irq.h" +#include "hw/sd/sdhci.h" +#include "hw/misc/unimp.h" =20 #define EPAPR_MAGIC (0x45504150) #define DTC_LOAD_PAD 0x1800000 @@ -66,11 +68,14 @@ #define MPC8544_SERIAL1_REGS_OFFSET 0x4600ULL #define MPC8544_PCI_REGS_OFFSET 0x8000ULL #define MPC8544_PCI_REGS_SIZE 0x1000ULL +#define MPC85XX_ESDHC_REGS_OFFSET 0x2e000ULL +#define MPC85XX_ESDHC_REGS_SIZE 0x1000ULL #define MPC8544_UTIL_OFFSET 0xe0000ULL #define MPC8XXX_GPIO_OFFSET 0x000FF000ULL #define MPC8544_I2C_REGS_OFFSET 0x3000ULL #define MPC8XXX_GPIO_IRQ 47 #define MPC8544_I2C_IRQ 43 +#define MPC85XX_ESDHC_IRQ 72 #define RTC_REGS_OFFSET 0x68 =20 #define PLATFORM_CLK_FREQ_HZ (400 * 1000 * 1000) @@ -203,6 +208,22 @@ static void dt_i2c_create(void *fdt, const char *soc, = const char *mpic, g_free(i2c); } =20 +static void dt_sdhc_create(void *fdt, const char *parent, const char *mpic) +{ + hwaddr mmio =3D MPC85XX_ESDHC_REGS_OFFSET; + hwaddr size =3D MPC85XX_ESDHC_REGS_SIZE; + int irq =3D MPC85XX_ESDHC_IRQ; + g_autofree char *name =3D NULL; + + name =3D g_strdup_printf("%s/sdhc@%" PRIx64, parent, mmio); + qemu_fdt_add_subnode(fdt, name); + qemu_fdt_setprop(fdt, name, "sdhci,auto-cmd12", NULL, 0); + qemu_fdt_setprop_phandle(fdt, name, "interrupt-parent", mpic); + qemu_fdt_setprop_cells(fdt, name, "bus-width", 4); + qemu_fdt_setprop_cells(fdt, name, "interrupts", irq, 0x2); + qemu_fdt_setprop_cells(fdt, name, "reg", mmio, size); + qemu_fdt_setprop_string(fdt, name, "compatible", "fsl,esdhc"); +} =20 typedef struct PlatformDevtreeData { void *fdt; @@ -553,6 +574,10 @@ static int ppce500_load_device_tree(PPCE500MachineStat= e *pms, =20 dt_rtc_create(fdt, "i2c", "rtc"); =20 + /* sdhc */ + if (pmc->has_esdhc) { + dt_sdhc_create(fdt, soc, mpic); + } =20 gutil =3D g_strdup_printf("%s/global-utilities@%llx", soc, MPC8544_UTIL_OFFSET); @@ -982,7 +1007,8 @@ void ppce500_init(MachineState *machine) 0, qdev_get_gpio_in(mpicdev, 42), 399193, serial_hd(1), DEVICE_BIG_ENDIAN); } - /* I2C */ + + /* I2C */ dev =3D qdev_new("mpc-i2c"); s =3D SYS_BUS_DEVICE(dev); sysbus_realize_and_unref(s, &error_fatal); @@ -992,6 +1018,26 @@ void ppce500_init(MachineState *machine) i2c =3D (I2CBus *)qdev_get_child_bus(dev, "i2c"); i2c_slave_create_simple(i2c, "ds1338", RTC_REGS_OFFSET); =20 + /* eSDHC */ + if (pmc->has_esdhc) { + create_unimplemented_device("esdhc", + pmc->ccsrbar_base + MPC85XX_ESDHC_REGS= _OFFSET, + MPC85XX_ESDHC_REGS_SIZE); + + /* + * Compatible with: + * - SD Host Controller Specification Version 2.0 Part A2 + * (See MPC8569E Reference Manual) + */ + dev =3D qdev_new(TYPE_SYSBUS_SDHCI); + qdev_prop_set_uint8(dev, "sd-spec-version", 2); + qdev_prop_set_uint8(dev, "endianness", DEVICE_BIG_ENDIAN); + s =3D SYS_BUS_DEVICE(dev); + sysbus_realize_and_unref(s, &error_fatal); + sysbus_connect_irq(s, 0, qdev_get_gpio_in(mpicdev, MPC85XX_ESDHC_I= RQ)); + memory_region_add_subregion(ccsr_addr_space, MPC85XX_ESDHC_REGS_OF= FSET, + sysbus_mmio_get_region(s, 0)); + } =20 /* General Utility device */ dev =3D qdev_new("mpc8544-guts"); diff --git a/hw/ppc/e500.h b/hw/ppc/e500.h index 68f754ce50..8c09ef92e4 100644 --- a/hw/ppc/e500.h +++ b/hw/ppc/e500.h @@ -27,6 +27,7 @@ struct PPCE500MachineClass { =20 int mpic_version; bool has_mpc8xxx_gpio; + bool has_esdhc; hwaddr platform_bus_base; hwaddr platform_bus_size; int platform_bus_first_irq; diff --git a/hw/ppc/e500plat.c b/hw/ppc/e500plat.c index 5bb1c603da..44bf874b0f 100644 --- a/hw/ppc/e500plat.c +++ b/hw/ppc/e500plat.c @@ -86,6 +86,7 @@ static void e500plat_machine_class_init(ObjectClass *oc, = void *data) pmc->fixup_devtree =3D e500plat_fixup_devtree; pmc->mpic_version =3D OPENPIC_MODEL_FSL_MPIC_42; pmc->has_mpc8xxx_gpio =3D true; + pmc->has_esdhc =3D true; pmc->platform_bus_base =3D 0xf00000000ULL; pmc->platform_bus_size =3D 128 * MiB; pmc->platform_bus_first_irq =3D 5; --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544702; cv=none; d=zohomail.com; s=zohoarc; b=Mi/aEUG78MxIw+1zLhPPFWpHRK9UUrV4TWVw/dXtXkzrg6ZWf6p36J8VPEJw5yk5D498AR99WTzbV3FXo8NzXhUX2fHuJhbhz3Jj2aYnaDclqXUgMUnLtudgrDOkFHBVWnjyoFLAiBVg5om3vX925SqsLQnQCfqrXK6ThdDqrIY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544702; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=Y26umyxYZIQKbffD6hLBebjrxc3lj3DIY2bESqX+yW8=; b=FHNJ5ZNt5o+zL4176NOOTdFM4sqnE1uHLDGqHJr9IQPML93T++XlWZRSY0YS6IB4PZw2gh+5N2pfCjtt6tTRmvBASuvbITh1htSRAxgmgzgjpZksn/oHnECWtAudPz199dQ4nyJYKr8gUZ/sAOwJ4ae5OaNJLGVEIPryXqITQSI= 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 1671544702092738.4126666547687; Tue, 20 Dec 2022 05:58:22 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3Y-0004GS-Ps; Tue, 20 Dec 2022 08:53:20 -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 1p7d3V-0004D3-Rn; Tue, 20 Dec 2022 08:53:18 -0500 Received: from mail-oa1-x30.google.com ([2001:4860:4864:20::30]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3T-00012L-D9; Tue, 20 Dec 2022 08:53:16 -0500 Received: by mail-oa1-x30.google.com with SMTP id 586e51a60fabf-1442977d77dso15419977fac.6; Tue, 20 Dec 2022 05:53:14 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=Y26umyxYZIQKbffD6hLBebjrxc3lj3DIY2bESqX+yW8=; b=N4X8/K/Bm9TSecU9vhuD2VVfE6LVb6VMRvVOWijsSRe8Z/N2hzMwTUI6GRAUdXv68G oq7333ThQd9FExBoH7r6rRLdYbx+gHkth9A2eqVwUeajiPCipj/WmgPpTWp7buVP5x05 34qaMlTzExlBIDXp9g1TaeR4iEKAwYlOcOdRmsAUmjIZFeNDrOsISx09xbaIR26g1p5V 5pMcWWfz5l0yeWBUmUvPSvOh7mioalzBzIo85wx71T9GCPdeah1i6Bspov6nopYTXRyQ 1Na+X+vSgWuZ+5AvCIDp/joUFOZfX0/aiqWw+q2kaLT77M8Tt8ejGB3ER7PnuucVj3Vd 9gIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=Y26umyxYZIQKbffD6hLBebjrxc3lj3DIY2bESqX+yW8=; b=oowBvXCv4nQX5we2ogpsp6zIf5mBZhKxHrhIis9GS2q0phtJKUZT7AUkqWa0ZeCC6/ rVAZ2H0KtkKXsiJnGzm2hDwKKnEpCDX17P3R4LUkyDLr2MZZ1RG9Hb9W6Ehnj1TUIMah AguQO843P5kmmjPAorqLnSqGj2wvQK5hfyh7mipMM7XWZqPKPaNZoog21W0tf9Ac8QoC vJny20Gi1k01HiZqi19uA4XRncYodXWIllENvEekx1yZZmd/eW3oO5TYb0Pv6LjUEnS/ ItUJLxBZyQVv5ARgGuBtzx+fVJwC5cHCxxxBEfIr7aBXEO1usA612wHeP0uc2fTOP1hr bUZQ== X-Gm-Message-State: ANoB5pkT3rcFBHgOiqMvLGqMOqXRGx+Uej98eJqTY31mdlpcjUZuiAYP Pv6EcJvZ04eIiaf0AbolCGr4FMErCJQ= X-Google-Smtp-Source: AA0mqf737xJGwsBuDZfYzMGlTCByYFtx9aQMjU/8l1ht6pBGBfrDwLdFd49vxEd/QRSrPd1I1f84Hw== X-Received: by 2002:a05:6870:a40a:b0:143:aebb:57d8 with SMTP id m10-20020a056870a40a00b00143aebb57d8mr23728428oal.49.1671544392212; Tue, 20 Dec 2022 05:53:12 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 05/15] target/ppc/kvm: Add missing "cpu.h" and "exec/hwaddr.h" Date: Tue, 20 Dec 2022 10:52:41 -0300 Message-Id: <20221220135251.155176-6-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::30; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x30.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544703234100001 From: Philippe Mathieu-Daud=C3=A9 kvm_ppc.h is missing various declarations from "cpu.h": target/ppc/kvm_ppc.h:128:40: error: unknown type name 'CPUPPCState'; did = you mean 'CPUState'? static inline int kvmppc_get_hypercall(CPUPPCState *env, ^~~~~~~~~~~ CPUState include/qemu/typedefs.h:45:25: note: 'CPUState' declared here typedef struct CPUState CPUState; ^ target/ppc/kvm_ppc.h:134:40: error: unknown type name 'PowerPCCPU' static inline int kvmppc_set_interrupt(PowerPCCPU *cpu, int irq, int leve= l) ^ target/ppc/kvm_ppc.h:285:38: error: unknown type name 'hwaddr' hwaddr ptex, int n) ^ target/ppc/kvm_ppc.h:220:15: error: unknown type name 'target_ulong' static inline target_ulong kvmppc_configure_v3_mmu(PowerPCCPU *cpu, ^ target/ppc/kvm_ppc.h:286:38: error: unknown type name 'ppc_hash_pte64_t' static inline void kvmppc_read_hptes(ppc_hash_pte64_t *hptes, ^ Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Daniel Henrique Barboza Message-Id: <20221213123550.39302-2-philmd@linaro.org> Signed-off-by: Daniel Henrique Barboza --- target/ppc/kvm_ppc.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/target/ppc/kvm_ppc.h b/target/ppc/kvm_ppc.h index ee9325bf9a..5fd9753953 100644 --- a/target/ppc/kvm_ppc.h +++ b/target/ppc/kvm_ppc.h @@ -9,6 +9,9 @@ #ifndef KVM_PPC_H #define KVM_PPC_H =20 +#include "exec/hwaddr.h" +#include "cpu.h" + #define TYPE_HOST_POWERPC_CPU POWERPC_CPU_TYPE_NAME("host") =20 #ifdef CONFIG_KVM --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544770; cv=none; d=zohomail.com; s=zohoarc; b=Y8JCC1CiuISXS4rMjvQY53ZURG+8FAsF6JGzdhVrnZhd/9n5qdYT2FKrZOxJVa8IPLzOteprop1JpFkArlRgk7an5P5De2iwTNb/o1QoLMbQ+D5ofXHIr8P1mskT0wQDyUACw95AhFhhvMhzbKVP8yYCiiLDUaDpVXQ9SqREbrU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544770; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=umE98gdRHDRDK4EVpp4UFfCVYlLLuK/yAYvtgaqx+tI=; b=e+ae9wx4/UDrFs7xL4bMm0vmgGI2O9sb+CfX0i2ZJk6su6J83m6wYiG/Irkj3N2I+9YmBSoEgIoRbnk5S/TxpPz46/bmIzGDCbgd+BGJ1KWRphzwj8XoT0J6Ya+eegdszrSMyUm/3dg3UV1OHfcxIuDQQPzllseheu8qFTKMgTY= 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 1671544770555553.7775350946121; Tue, 20 Dec 2022 05:59:30 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3Y-0004Ff-D7; Tue, 20 Dec 2022 08:53:20 -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 1p7d3V-0004D2-R4; Tue, 20 Dec 2022 08:53:18 -0500 Received: from mail-oa1-x30.google.com ([2001:4860:4864:20::30]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3T-00012P-MG; Tue, 20 Dec 2022 08:53:16 -0500 Received: by mail-oa1-x30.google.com with SMTP id 586e51a60fabf-1445ca00781so15457911fac.1; Tue, 20 Dec 2022 05:53:14 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=umE98gdRHDRDK4EVpp4UFfCVYlLLuK/yAYvtgaqx+tI=; b=JXaWnjf5mseHwm75UFOaxAmd1AoEgMMdZO/09DWwhFMKY9dfUUMNKOV5z3do0Y0A3w sK2i1sGUuT/CQLsF1VvIJKm+Jo100pXBneJlzAjH/wVEqOEfZRdnnaMj6M0TNx5A608P 4SUWCVv2HQkfZ7ojyn9UAB5rC9Su1Og+G44Tzhrf/t/HCxBX129jS/9Dj7V/FYyNra52 VL01emwNa1kEofV8keseO06WLlHMac/mdw7oFpfYRYoR5+w3C8SIYAhfS7K7tB1CUfeN PqwHN63wIjNCLO3UapiwVG22lwm5nZ87EZZQjVII5Iva5snIjXw7DeJHWsLk5O2pEGxy L7Zg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=umE98gdRHDRDK4EVpp4UFfCVYlLLuK/yAYvtgaqx+tI=; b=WcpZTLL/ET2O8YbgPIB05VMeVmwECzY+ZvUBBadOS5g9jKAEag00+c0Fiy13ufg+R5 n6AVZhOQQHI2RDNaVudEa/WlRnixaKOkuXJ9ObW5w7R90S+p7egh7fIGabkuKUuKx8zl 6EjLhMoLV0zvR0PE1wGvCQFRGjGSipvIqpz5iqvuI0lHzd1vV7GfmWw4tarTPyLSe+H+ 54qj8GvWCX1zF5XN35BGVt/m/YJfSD340ZLSJVDZTxyXRb0GRNzhuPknTilQal3CdphX N8gAgCnn27UFRZIb6KeOP+UtQu+lmSj5lFeSNelNoGIXnDfuTBNdWl2BftDQHap2YVpF SB6A== X-Gm-Message-State: AFqh2kr6waCKg5ccCKqGGmTjyA5M+NpbwJAS6XwsBaGC5/P16cG6sWOZ RSvrSmL3aNOAshVGy6ryjY8hSloTV0Y= X-Google-Smtp-Source: AMrXdXveQpOu7/Qj1jV5nX6lB1I3mVpPjntiVH5ZkLdYJZIq7DTuZwx7OfJTjCUBO41fdnFSOn4DpA== X-Received: by 2002:a05:6870:9f84:b0:14b:cdc5:870 with SMTP id xm4-20020a0568709f8400b0014bcdc50870mr7266500oab.10.1671544394266; Tue, 20 Dec 2022 05:53:14 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 06/15] hw/ppc/vof: Do not include the full "cpu.h" Date: Tue, 20 Dec 2022 10:52:42 -0300 Message-Id: <20221220135251.155176-7-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::30; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x30.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544771779100001 From: Philippe Mathieu-Daud=C3=A9 "vof.h" doesn't need the full "cpu.h" to get the target_ulong definition, including "exec/cpu-defs.h" is enough. Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Daniel Henrique Barboza Message-Id: <20221213123550.39302-3-philmd@linaro.org> Signed-off-by: Daniel Henrique Barboza --- include/hw/ppc/vof.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/hw/ppc/vof.h b/include/hw/ppc/vof.h index f8c0effcaf..d3f293da8b 100644 --- a/include/hw/ppc/vof.h +++ b/include/hw/ppc/vof.h @@ -9,7 +9,7 @@ #include "qom/object.h" #include "exec/address-spaces.h" #include "exec/memory.h" -#include "cpu.h" +#include "exec/cpu-defs.h" =20 typedef struct Vof { uint64_t top_addr; /* copied from rma_size */ --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544678; cv=none; d=zohomail.com; s=zohoarc; b=l3Vi8VmF/ISn1cyJcyYohuhbt/FAC9/JLSOaizmtMq4ci/H6tVMsOF3ydHUnDTssgpRezFjaHIXnGAVuXVympKVjSNe3VbL9+LegoS2Ig4c3s6MVkIhTdkZyaNdkv2/psEmYP46gcdPW9Zkio2A4fvQ/SBjNjd0THhMZpHi4jOk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544678; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=G4SPXsEIXY0CS0seSoT5oNuwNukYT1XRaSgA4LvShkM=; b=Tlcz6LyuI3GWMWo7AyGUDHlxh/ezHtmzBPGHOzfTJsmYscA/A/EkaXrpLOqQ5ffgr74d04INrRC22efdvfUaiITgJArfO4JHudq7NEtYFXbr3dMvfwkSnoFEJzjHh+jdvJr3sJjGEDWduoppae3dxdDqxiv/GcclZ1DZO6SAXG0= 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 1671544678974657.6640418443408; Tue, 20 Dec 2022 05:57:58 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3c-0004J1-Kw; Tue, 20 Dec 2022 08:53:24 -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 1p7d3X-0004Fh-LK; Tue, 20 Dec 2022 08:53:19 -0500 Received: from mail-oa1-x2e.google.com ([2001:4860:4864:20::2e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3W-00012h-3b; Tue, 20 Dec 2022 08:53:19 -0500 Received: by mail-oa1-x2e.google.com with SMTP id 586e51a60fabf-14455716674so15426337fac.7; Tue, 20 Dec 2022 05:53:17 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=G4SPXsEIXY0CS0seSoT5oNuwNukYT1XRaSgA4LvShkM=; b=IriBOeyzQh+gc7CJrYrqJYzKz/ZwPF5IV4/W1M1SEc1JZvKcLJpU2CU/rQ71D5LkvB x4yESWh1RI+VdQLDgnM0jK7PhunH6xEXnzZK559bIbvGrXPuSUbRYSvY2UxGqV1Bwa7g z3fO0WC7m60rydHr0B4lEb9uHnAbmKyXdcWfy6suBPz77bbo1EhL/neB8O81TSS94Lhn Z3vrzaL7uVN+0uMCkJfZu7v7yXpeTSTDjk2zZnO3tvgzJVMEazSTOdnuDr5hj5XoDFff 8p4Ee0Wp4rWsuwfmlw/Ew2gSQrDRqJHkfXP3+Rch2KAU5opS+gWC+73nsilhapwPlmUY 96QA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=G4SPXsEIXY0CS0seSoT5oNuwNukYT1XRaSgA4LvShkM=; b=499ZZ0YJ5+duDqjjo/G92oLvJvCa0GyP9zWugcj2dGBxuXTb/als6sfL1bj352x1Zk YD9JUrzg1ucFYL3aJr28RvKPYY5i+ybOI3neWYvK4d191s1gGytUACY/8Z9X7jChsXUq eIsHWSRzjikZ35sKfZNx8eDVkevowRVaQNvHGopQReViusEZ5zk8z1pFlEOXfsWvwHA3 P8VbTtaBlqDWp+hk9kNBzC9BmCRpAlvxgrbIlhiDeS+xcnBMM0e0iUX41+N9xZ/rA2hF mM5OgRqxpu1UaIA/yVSfgyS2oOti0NYzIkQLRTjwAI8O6gzE1G1+dsAMKogeKZa+NhMt FrMg== X-Gm-Message-State: AFqh2koNu74+gYYSsfqoT5LzOW2SzLrM7Adae7TTcXPuNFTQEnU6rFp7 gzej4Ni+Psuskcf4rqgAEnldaZe9PHk= X-Google-Smtp-Source: AMrXdXsddvA5T4K1p8Jdy9XxctipH4P9BGHGi0FoytEXqnp68Xb0Sr+NdUM0JQ/MiGtpBWZWH7+eIw== X-Received: by 2002:a05:6870:c5a8:b0:144:c2e7:3a98 with SMTP id ba40-20020a056870c5a800b00144c2e73a98mr8424227oab.31.1671544396235; Tue, 20 Dec 2022 05:53:16 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 07/15] hw/ppc/spapr: Reduce "vof.h" inclusion Date: Tue, 20 Dec 2022 10:52:43 -0300 Message-Id: <20221220135251.155176-8-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::2e; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x2e.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544681150100007 From: Philippe Mathieu-Daud=C3=A9 Currently objects including "hw/ppc/spapr.h" are forced to be target specific due to the inclusion of "vof.h" in "spapr.h". "spapr.h" only uses a Vof pointer, so doesn't require the structure declaration. The only place where Vof structure is accessed is in spapr.c, so include "vof.h" there, and forward declare the structure in "spapr.h". Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Daniel Henrique Barboza Message-Id: <20221213123550.39302-4-philmd@linaro.org> Signed-off-by: Daniel Henrique Barboza --- hw/ppc/spapr.c | 1 + include/hw/ppc/spapr.h | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index dc850032ae..59641adaec 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -62,6 +62,7 @@ #include "hw/ppc/fdt.h" #include "hw/ppc/spapr.h" #include "hw/ppc/spapr_vio.h" +#include "hw/ppc/vof.h" #include "hw/qdev-properties.h" #include "hw/pci-host/spapr.h" #include "hw/pci/msi.h" diff --git a/include/hw/ppc/spapr.h b/include/hw/ppc/spapr.h index 04a95669ab..5c8aabd444 100644 --- a/include/hw/ppc/spapr.h +++ b/include/hw/ppc/spapr.h @@ -12,7 +12,6 @@ #include "hw/ppc/spapr_xive.h" /* For SpaprXive */ #include "hw/ppc/xics.h" /* For ICSState */ #include "hw/ppc/spapr_tpm_proxy.h" -#include "hw/ppc/vof.h" =20 struct SpaprVioBus; struct SpaprPhbState; @@ -22,6 +21,8 @@ typedef struct SpaprEventLogEntry SpaprEventLogEntry; typedef struct SpaprEventSource SpaprEventSource; typedef struct SpaprPendingHpt SpaprPendingHpt; =20 +typedef struct Vof Vof; + #define HPTE64_V_HPTE_DIRTY 0x0000000000000040ULL #define SPAPR_ENTRY_POINT 0x100 =20 --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671545081; cv=none; d=zohomail.com; s=zohoarc; b=RoxfT2SAvXdCC7cT29Q/9mqXONMkww0PJbUbYI+m1XYT1emNYUPXlw43bavApBMR68hrK3BAusp+TjFdLJru25aIrOFmdD66flZIXsU+bSvc/bwGnXVKAcxI7BXKGg+KYb14kytupImj8pCMTbuptMdk3UkY0xWPTCBnoXJsAvw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671545081; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=B+IR5HLmiOCztNIy21koqL5hnkPQKWK0yl/szVYQr7o=; b=epInH20sjUOkcwnimfnlBq5q6YcrR8zhIa2zPwTUeL2zWgChS00yE5mr3+axiIukbXbioKOpH8O3d2H6JSwQjE0fTBQzys0cb456Vk0N/Mu8Z43/RtElCMDWkM/gayFMwHUnAY3tzATYGduKwl3hj087vD7b6BDzKpNBrTHvPTE= 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 1671545081725788.0825415591462; Tue, 20 Dec 2022 06:04:41 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3d-0004JL-21; Tue, 20 Dec 2022 08:53:25 -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 1p7d3Z-0004Go-TA; Tue, 20 Dec 2022 08:53:22 -0500 Received: from mail-oa1-x2a.google.com ([2001:4860:4864:20::2a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3Y-000137-Cs; Tue, 20 Dec 2022 08:53:21 -0500 Received: by mail-oa1-x2a.google.com with SMTP id 586e51a60fabf-1322d768ba7so15438632fac.5; Tue, 20 Dec 2022 05:53:19 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=B+IR5HLmiOCztNIy21koqL5hnkPQKWK0yl/szVYQr7o=; b=E7Z/bh40O8V+Fkg8YwKn7+GAmeyc0hw5PkBn6PpCyPObskjOEDLJ1iQx3NWIrFas3B 1sUN8KytDgmrzSGmIOzC6wTqGtoFbz6Rvj7FNhpGuhOxZxXxpzu8Yq3uxuYHlgVZwK+b Gh2oPy9Dv0pUQQ8RFFQISp/Dfk8oz7YyNHEOEhO0JAKNCcT9uK77qxMyV3oPkzleCpTF /uMiyn0UoaHuCwzhwDupQ+QB7J3n7Y3+la1JckOHLTqCheAZ3YCfBk/LFxyEx8koIm6T 0ZJ22ZU+/KB/OkJMjxqHtIDh+YS33C+kXRpFkNt7nf2dP5kLvndTM/3JPjnKUEpz4Mxb mcLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=B+IR5HLmiOCztNIy21koqL5hnkPQKWK0yl/szVYQr7o=; b=Rj/IRkU3WJ5UeCY5l7GokVWirKBvxI6qcTJHkKGQibH5DYvR1lbg/uAguGRIxOAGHj WtUFZGELqqFkJIBpvyZR6LokVWBSJeI9/VGMDGqr/XNuQ87F9/2rrW0gRacFneDAF4gG mUYPfhm7gnjbJRt6FXwFzL+ask+ocAjZdQW4HTCc1D4CoA+e1JYHY2E/ol72x528QbhU hQWKkEb3OmlIJezxuMkOONGHNU13UohAPKgY0DUP7CKwTxqpZOerbOeYJ2mzJIEZR7jR ltOiMEJH/e+ImuBYN7n3SU/iV5GfZ3OsSyfB86Jr1F8TEObphN/e+n/21qbqEXEGvlzA CsKg== X-Gm-Message-State: AFqh2krc1zSoGb2tft9SG1pqLaC/eng7rlYBpoFTVHyiRW4Mcgxqt8GZ 7UEgpqD1Qx4bx0GLDdaOFWeaSqlZQts= X-Google-Smtp-Source: AMrXdXv1m6abus4gQxHCU2DbxQKbIqim1COXhpgxT80tqTMXb8xNIg77DqUVh+9vICqDD7ABlzy4gw== X-Received: by 2002:a05:6870:e88f:b0:144:40d0:85a9 with SMTP id q15-20020a056870e88f00b0014440d085a9mr7045804oan.32.1671544398921; Tue, 20 Dec 2022 05:53:18 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, Bernhard Beschow , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 08/15] target/ppc/mmu_common: Log which effective address had no TLB entry found Date: Tue, 20 Dec 2022 10:52:44 -0300 Message-Id: <20221220135251.155176-9-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::2a; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x2a.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671545083870100001 From: Bernhard Beschow Let's not leave developers in the dark where this log message comes from. Signed-off-by: Bernhard Beschow Reviewed-by: C=C3=A9dric Le Goater Reviewed-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20221216145709.271940-2-shentey@gmail.com> Signed-off-by: Daniel Henrique Barboza --- target/ppc/mmu_common.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/target/ppc/mmu_common.c b/target/ppc/mmu_common.c index 89107a6af2..49067c05e6 100644 --- a/target/ppc/mmu_common.c +++ b/target/ppc/mmu_common.c @@ -811,7 +811,8 @@ static int mmubooke206_check_tlb(CPUPPCState *env, ppcm= as_tlb_t *tlb, } } =20 - qemu_log_mask(CPU_LOG_MMU, "%s: TLB entry not found\n", __func__); + qemu_log_mask(CPU_LOG_MMU, "%s: No TLB entry found for effective addre= ss " + "0x" TARGET_FMT_lx "\n", __func__, address); return -1; =20 found_tlb: --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544776; cv=none; d=zohomail.com; s=zohoarc; b=Db4cBirfvUczoAG7fBNzSAhyYVBmLhtiawyrxWcJsCPVoDSYcgr+/LiOZviq3ieaIuAbLxx4h+v28Z9t2g7wAr4bTWUKZV39C6Fjwm1gyLQL/NRp9XLWgwADgvsb+Mk9/eIiEWLnU86WKUwcrBYGBtDsgn1L29PtMe4dG9dYhKw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544776; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=UolbehPZVT4MZJ701HApHrkweA0x+o6XOjYoy2v+Dhg=; b=SqS5l3SPb4L2UEJ24zW1J/WGL0dl70rjoYUU7463OV5NapsrrDGFYuHrJTwt9mPT7l3npnlwnZ6z/eWditYHINy8VhjscmHMab+UCiKjKf2rsQ+dRcBfJgrq/NGlxu2H56udPxEojVyTRq+4iCQ2K/I8ybXsddXREhUFgOi872s= 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 1671544776361855.2414914857992; Tue, 20 Dec 2022 05:59:36 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3d-0004Jo-FA; Tue, 20 Dec 2022 08:53:25 -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 1p7d3b-0004HU-W5; Tue, 20 Dec 2022 08:53:24 -0500 Received: from mail-oa1-x2e.google.com ([2001:4860:4864:20::2e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3a-00012h-GC; Tue, 20 Dec 2022 08:53:23 -0500 Received: by mail-oa1-x2e.google.com with SMTP id 586e51a60fabf-14455716674so15426602fac.7; Tue, 20 Dec 2022 05:53:21 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=UolbehPZVT4MZJ701HApHrkweA0x+o6XOjYoy2v+Dhg=; b=JzUqyHAo2YRzzPqxPI+SVuBmbE5WFzEo/u1ysBN6xroPV/5z2K4cwHzAaYSN412Hlj qdPTRtLThUGssf6GNDt2gZycGcHy70ogB43IvxeQ8rl6E8WIRCNIjmOkiBcbIE1QncfE 8mV7RGUSQWqOcfMhuFDeYOaX3hbXvJsn0CpyYYQTZSEi6DHJ/4Xqf7eqU6DL+RshbwDg xXY749u/3C2W/HWzG1X9twbYE8RXC/YBB8LXXvoWKB2dp+wqIiFFsq0RL+SuLwirmSUP bXid5b+dqOnwX6MzkqeNGsgZAaCy4lL14/bzHlUFhv/FdNG1LfYdKtNxjosmzAXg74BA Ja0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=UolbehPZVT4MZJ701HApHrkweA0x+o6XOjYoy2v+Dhg=; b=5ejFvtj3lhsOWKx3josM7dmwmI8/2BakUUi10Chfr62+dtasL3YP8gneE8biwItm4O PdtoqHHZky6OU3F4JlILgu4ZbxP1twoyPCIXqzkJqW4+JCrXxIiIYAGgk4YBpOgMI13c rcShHDe9xRRu4OCQHKtjmlH+rmwkvDHe7XVl2S6qevzQZ+RBY/WpJoYrLlYJZ7Vnu2XY M31hQcHc6JCjjPlvAmFfAcpPNlzPq4A6/1GcGLIZ77vc30kJqUBreAQi1CUJB0jLk1lr 50D0BmC9y/RtH3Fk17neHKqQrTOfkUrPvxLueh00wmp3qyjfbJK5V3OXbkdUEbXqJz6r BAfA== X-Gm-Message-State: ANoB5pniO/Sa9F5Og9BkhCaBKTc+Hutyc2lD/5u1T0mjadTVZlJnDlr0 plI/kj4Z9fs2WS6ukmzyN2E+VIBF3DE= X-Google-Smtp-Source: AA0mqf7k0z1/kW1AoSF41ON+KJ/emKLZOA5FEqAfRadAPLKSJPMDvnpr22NsrHPeBMUG3Qx+ZWFYZw== X-Received: by 2002:a05:6870:cc88:b0:143:9b6b:a871 with SMTP id ot8-20020a056870cc8800b001439b6ba871mr20208896oab.23.1671544401402; Tue, 20 Dec 2022 05:53:21 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, Bernhard Beschow , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 09/15] target/ppc/mmu_common: Fix table layout of "info tlb" HMP command Date: Tue, 20 Dec 2022 10:52:45 -0300 Message-Id: <20221220135251.155176-10-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::2e; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x2e.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544777626100003 From: Bernhard Beschow Starting with the URWX columns the columns didn't line up. Before: QEMU 7.2.50 monitor - type 'help' for more information (qemu) info tlb TLB0: Effective Physical Size TID TS SRWX URWX WIMGE U0123 0x0000000000a80000 0x000000000105d000 4K 117 0 SR--UR-- --M-- U---- 0x0000000000100000 0x000000000114e000 4K 117 0 SR--UR-- --M-- U---- (qemu) After: QEMU 7.2.50 monitor - type 'help' for more information (qemu) info tlb TLB0: Effective Physical Size TID TS SRWX URWX WIMGE U0123 0x00000000b7a00000 0x000000000fcf5000 4K 18 0 SR-- UR-- --M-- U---- 0x0000000000800000 0x000000000fd73000 4K 18 0 SR-- UR-X --M-- U---- TLB1: Effective Physical Size TID TS SRWX URWX WIMGE U0123 0x00000000c0000000 0x0000000000000000 16M 0 0 SR-X U--- --M-- U---- 0x00000000c1000000 0x0000000001000000 16M 0 0 SRW- U--- --M-- U---- (qemu) Signed-off-by: Bernhard Beschow Reviewed-by: C=C3=A9dric Le Goater Reviewed-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20221216145709.271940-3-shentey@gmail.com> Signed-off-by: Daniel Henrique Barboza --- target/ppc/mmu_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/ppc/mmu_common.c b/target/ppc/mmu_common.c index 49067c05e6..8901f4d134 100644 --- a/target/ppc/mmu_common.c +++ b/target/ppc/mmu_common.c @@ -980,7 +980,7 @@ static void mmubooke206_dump_one_tlb(CPUPPCState *env, = int tlbn, int offset, pa =3D entry->mas7_3 & ~(size - 1); =20 qemu_printf("0x%016" PRIx64 " 0x%016" PRIx64 " %4s %-5u %1u S%c%c= %c" - "U%c%c%c %c%c%c%c%c U%c%c%c%c\n", + " U%c%c%c %c%c%c%c%c U%c%c%c%c\n", (uint64_t)ea, (uint64_t)pa, book3e_tsize_to_str[tsize], (entry->mas1 & MAS1_TID_MASK) >> MAS1_TID_SHIFT, --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544967; cv=none; d=zohomail.com; s=zohoarc; b=acZD0HcY0RsLHx3cbyOzY2iXpAQOGP9rxJAFgU1oREPjtgKvrn+a34FSiBmoalXu0+xNyUA6y4MM6+tfgw/yvi2YId89Gg5vd0cHwomZV1o0ukbTDXvF/pJ2Vl1BKAZW0t4ub6zmxCQBABnlqwdxFRRD3nDpy9F+rlcTNeJwEb4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544967; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=37wcK39IH790uEINkU4OGea3CBZ8gkITTYDDBIzhz9g=; b=M9VtZyowwloNHOBT5MAJ0rWAqh/YDnWz+8WMHUnWd+UVHMoi0j7LUHqjjBKLdG6xNGQRWRUfj4QirH23GKmzqiWFQh02g9jDBeW1xCizSmfTdQ7MRRyU9/W9TtrT1DQ5KoneepX3zgmY4AGZzO1imv0+2YYbDX2ok+Z7vKmGK+A= 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 1671544967872983.8302588828677; Tue, 20 Dec 2022 06:02:47 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3i-0004Lt-Bb; Tue, 20 Dec 2022 08:53:30 -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 1p7d3g-0004Ki-06; Tue, 20 Dec 2022 08:53:28 -0500 Received: from mail-oa1-x29.google.com ([2001:4860:4864:20::29]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3e-00013o-Gq; Tue, 20 Dec 2022 08:53:27 -0500 Received: by mail-oa1-x29.google.com with SMTP id 586e51a60fabf-142b72a728fso15415440fac.9; Tue, 20 Dec 2022 05:53:25 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=37wcK39IH790uEINkU4OGea3CBZ8gkITTYDDBIzhz9g=; b=gc6iJ5jUzgAS+XcXkgUh8Srbb0xWFs8a+g6gHq0hdCJdxHJt1UQNtR2qUV3BIjEHjF h1GImluEKvL00bwc30oB14zoGmh26zB0+rPJvgOOvOkE46A+G/hzzrVht4ViMnYklmap 3xjTMSPXrZd4zW6GX0Qo0yCoGIE3O2x2lOubP1LOOLnur/GQkLnLh0daKFicmn0Tn5rF FBxfaEtmldCuO5fDGoVgRRdoRkdKfrb06wnL+e9/AY/BgHx6FvDTXcNLewpnh2Tabz3N 3CZv6oez2XLHG85TNR21J3kgzjc2oC0LEHXprmk44ek2N2kieFsg6OO3UBdcqNsV1a+K Eabw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=37wcK39IH790uEINkU4OGea3CBZ8gkITTYDDBIzhz9g=; b=MiwhutnXDMdV6SbI4IXn6v1I8fUZdxl5XrOjlbB1OO6xmB6ZenDompg/REm0tinjtK IYQ3jV64SOTWHy0z4o8+dPVcfWweqsIl+PBIhYS+k7njwPUlamoDEytBXEOEnuZdZdaz 3LDuK85fCaoEN7GlUbLju1zo0VXbH+2MqhoI16wwAx6Xsn8n17eXkpqTbxyf4brauJbP JvQMxRMvTm4NlWEkywu1Gs87EpXGoyoosEaExsKNaIKYdqfw0uf/CNBmRIrO1wC7mqVg Zh5SBtKC5g8dfu/Gcve6PjYybnG/DnGya6zM/yJ+PAUIzVuYt6aCHnOMQHhhrR31LCqm IHmA== X-Gm-Message-State: ANoB5pkFJy5r1xAaNnquDVoaKaInGesjyyCO38x1yqq3LikJX8/KGtJq e6/DAcWxP/ZrEQn5/b48587Y9Fl58Xo= X-Google-Smtp-Source: AA0mqf5XE8B778Ka0JnubHub5+yzu41WAagtICRiaud9fE54J1BfuTrFIZ+IcP9XuigQ9z0zFj75JA== X-Received: by 2002:a05:6871:4209:b0:14b:7e0a:eef1 with SMTP id li9-20020a056871420900b0014b7e0aeef1mr13481777oab.44.1671544404097; Tue, 20 Dec 2022 05:53:24 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, Bernhard Beschow , "Edgar E . Iglesias" , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 10/15] hw/ppc/virtex_ml507: Prefer local over global variable Date: Tue, 20 Dec 2022 10:52:46 -0300 Message-Id: <20221220135251.155176-11-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::29; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x29.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544970131100001 From: Bernhard Beschow Signed-off-by: Bernhard Beschow Reviewed-by: Edgar E. Iglesias Reviewed-by: C=C3=A9dric Le Goater Reviewed-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20221216145709.271940-4-shentey@gmail.com> Signed-off-by: Daniel Henrique Barboza --- hw/ppc/virtex_ml507.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/ppc/virtex_ml507.c b/hw/ppc/virtex_ml507.c index 13cace229b..f2f81bd425 100644 --- a/hw/ppc/virtex_ml507.c +++ b/hw/ppc/virtex_ml507.c @@ -157,7 +157,7 @@ static int xilinx_load_device_tree(MachineState *machin= e, int r; const char *dtb_filename; =20 - dtb_filename =3D current_machine->dtb; + dtb_filename =3D machine->dtb; if (dtb_filename) { fdt =3D load_device_tree(dtb_filename, &fdt_size); if (!fdt) { --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544689; cv=none; d=zohomail.com; s=zohoarc; b=DGufqSRQL4SGJm1UvazdxEmZBXCVj2Cv6wMbavkQJOKiCSjKVUaX/QYNcmy/1nZ2+84ltHYXy39Mk+/tqVvI+qGceI2xBIImnqNsukpPFyCor+2bXReSzTjM3eFbPblX5LK6QIsmyLsxyUvXUKT/S0fZ3oR3RHDB0c3+RcFHsqI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544689; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=CZFbcD/D1dbm66qHXSpBmJgzXHTUS+Jktmxwhei7GmI=; b=KwrNfxy+44lrULn60ZsJdHLP3KqatJKPMjB7nZYUkcNkTrdrsFGUWxKIy1EOlttKxeIiidU6CosgD1fNVbQiclu1cHw1PFHI7Tq6doccuF5Ru+dg5mjKIDAZU6+92rfBDkTJZdHwLdL5Srs4mXI3y1m/CRp7ZXpKDxkMGFWLhtM= 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 167154468934760.33650485153237; Tue, 20 Dec 2022 05:58:09 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3j-0004MQ-0R; Tue, 20 Dec 2022 08:53:31 -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 1p7d3h-0004Lc-MM; Tue, 20 Dec 2022 08:53:29 -0500 Received: from mail-oa1-x2d.google.com ([2001:4860:4864:20::2d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3g-000142-6v; Tue, 20 Dec 2022 08:53:29 -0500 Received: by mail-oa1-x2d.google.com with SMTP id 586e51a60fabf-1447c7aa004so15403314fac.11; Tue, 20 Dec 2022 05:53:27 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=CZFbcD/D1dbm66qHXSpBmJgzXHTUS+Jktmxwhei7GmI=; b=K3NgEeOJcYXUa3a5+kLYhkwGK2jWNXz9KL+Yj+uX3dXI+Hx0dfjQQijy1PcA4W2YNa 2WkUQO3Dvkp8g9my9bBtOGdQDjd1bxH3QYfW2iNoTMGDUjNRcevXJXihymNeKjeoVOpq mk5jIExgei6XMAPdX/iiFfmZSqwm+ypDiFh4WYxVH9w97iJOtakQFT4f14GcsHvEJl72 R0q6aZbeG3bSiSUrQrtENeYY7Ku4FRB44m0UAW3B1pb5COFv+WTH4rz55KVlVNxZbA1M hc40BL7yaxN72oYyUp07ODiY9fmSif0Ew+1ff06XfTayOecFhwH3IvA8/xxksBo91Q17 jGfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=CZFbcD/D1dbm66qHXSpBmJgzXHTUS+Jktmxwhei7GmI=; b=MEhUkwfRuFD3ihat9DerxC+XpdKTK4kG3agRIOmf0Zu3JNtStsccb/dfAvlJUbCzZt y+jcDP/NtVacCOKLXLALYtDbMGpBwMD9THPY1ywOgR6Lclak8ok6OIsWPCM9bilTo1ol 6eykzHP1J6TmxOJZQ8IR97Fq/UHl078uBirWK9gL2m7xFfskKuPpz/nKeGrO06uvvJ7F Gzrm2Ct7KcgHMUbp3SWGx+xQF4TZiLT3dnD4zIKhxhJUKn9XUB/jKbHaf7a/uY8+kJUM 5wuSSE0oUKMzZM0gduJSGnDLo8hoSruqvACOsdwQTlo3Pt/m0jxEoa9rhif0jhjrgTc1 bFXQ== X-Gm-Message-State: AFqh2krGTlSPwfuRPkFle7a/BPcaNmT5Q+sG3hhx/UdfeHWiW+crJbeM FMR6uO9sW2we5vrb++thlPh4E6cWoh0= X-Google-Smtp-Source: AMrXdXtZaVHDB16B9UhhZ3+jKQDZ6O0tWnvxGES71icRqzMl3LOvrbLIFtt9DLL8S+E+qgsSsm+tag== X-Received: by 2002:a05:6870:7889:b0:144:c5e3:643a with SMTP id hc9-20020a056870788900b00144c5e3643amr6986359oab.4.1671544406358; Tue, 20 Dec 2022 05:53:26 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, Bernhard Beschow , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 11/15] hw/ppc/e500: Prefer local variable over qdev_get_machine() Date: Tue, 20 Dec 2022 10:52:47 -0300 Message-Id: <20221220135251.155176-12-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::2d; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x2d.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544691207100003 From: Bernhard Beschow Signed-off-by: Bernhard Beschow Reviewed-by: C=C3=A9dric Le Goater Reviewed-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20221216145709.271940-5-shentey@gmail.com> Signed-off-by: Daniel Henrique Barboza --- hw/ppc/e500.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c index 2bef2f01cb..53876af866 100644 --- a/hw/ppc/e500.c +++ b/hw/ppc/e500.c @@ -984,7 +984,7 @@ void ppce500_init(MachineState *machine) memory_region_add_subregion(address_space_mem, 0, machine->ram); =20 dev =3D qdev_new("e500-ccsr"); - object_property_add_child(qdev_get_machine(), "e500-ccsr", + object_property_add_child(OBJECT(machine), "e500-ccsr", OBJECT(dev)); sysbus_realize_and_unref(SYS_BUS_DEVICE(dev), &error_fatal); ccsr =3D CCSR(dev); @@ -1048,7 +1048,7 @@ void ppce500_init(MachineState *machine) =20 /* PCI */ dev =3D qdev_new("e500-pcihost"); - object_property_add_child(qdev_get_machine(), "pci-host", OBJECT(dev)); + object_property_add_child(OBJECT(machine), "pci-host", OBJECT(dev)); qdev_prop_set_uint32(dev, "first_slot", pmc->pci_first_slot); qdev_prop_set_uint32(dev, "first_pin_irq", pci_irq_nrs[0]); s =3D SYS_BUS_DEVICE(dev); --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544466; cv=none; d=zohomail.com; s=zohoarc; b=mWj6b2rxqe7OUgXds6Blu6wN1uHEP/R/DO4yRelm7nSfVQJYlH+M32FgONteJqTDTTcqZv0FQwGxW0Or+AH14qVVXw3gi3/fXGK32mYD9b7j2KRlYY/PXM8nBbGInybv504kkPyvU6gVSOaI97kB+UYR9PmRCzR7FHMde+rXsFo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544466; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=JLfYbjnmnlceFRofKnXzhe3GkaQmrAEnrSg6xJoLQ44=; b=XVDxHCwKgnJ+Ybhwb0BA/jSWSruAEnUTMzpB0+6904ljSYTXYk8C6FiJzpp5y0DBCNy9HajGEtWY8eTcpZwuIilHSlUK3sxI1qrN438qkDMjem3EeVkltl1j2sjBBS6iVKL8LqVBX4g/q8Z2cDrOdDa7ytQJLK3d/LnfO1w7oJM= 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 1671544466075591.2909462086717; Tue, 20 Dec 2022 05:54:26 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3k-0004Mx-ID; Tue, 20 Dec 2022 08:53:32 -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 1p7d3j-0004MV-Kv; Tue, 20 Dec 2022 08:53:31 -0500 Received: from mail-oa1-x35.google.com ([2001:4860:4864:20::35]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3i-00014U-5b; Tue, 20 Dec 2022 08:53:31 -0500 Received: by mail-oa1-x35.google.com with SMTP id 586e51a60fabf-12c8312131fso15439943fac.4; Tue, 20 Dec 2022 05:53:29 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=JLfYbjnmnlceFRofKnXzhe3GkaQmrAEnrSg6xJoLQ44=; b=kf8xTQeMNJL/KIz6suYK8IU/tbz41IXXgEg+59up9Jduql92JlQv3rRACukIXHVG21 O/ZIVESfyyifYHULj0/VNKNwY9kHq8AmrQeawGFc2Qz9LAIUvMcMS2mf80Z2pLzUDrjQ HiEVs2xx+kPz+/PtuaF4EzMCaLfmj5+EHAI//FjOKv6icGBDNK0ZFwyyu0Ihbt7qEuX8 acDq3mLqDFFFPQLeO5u4yHYlIkk6i9sheFdbzIZrIktRg1fHgf6g/DLRVU/MAyS6qLnY YlYLBwc8spaiHjzUqkBxjraqgFvB4AyRa4h1KaSAtmt74tlVUH7oBGKgo8QLcx9MNj80 zg2Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=JLfYbjnmnlceFRofKnXzhe3GkaQmrAEnrSg6xJoLQ44=; b=cBHex87hYGk6OKe2CkZUxLDv0zn/u79WPn61NtHGrUI3snB6vzstWA56C+fd/nSRKu 3IP3gYbTf9jip8ovZgEdSnP8X47JVGXgsnikyvFzSDGYj8lOvI9GsEo5DDLHdZRU1KOQ XjJFwfDPsTyqOFqhmpD6QRNPNOHdj1VyiGDTWh0ruV695+QPtGAvEvtPZhPFC4t4d8O3 xMLwEK5l9GqpWaVKUTkfY8olBc09hLAp5D6iKi4sOk4AX8dSFAwPWlEzzcbqcbv51OGV ZBUKzVXN+2k+Cx5O/IeGL6VNhZ0BBXIr54iIdDrGnQsMBiwOUGtfd8eZhSo1t39qqAEU aosA== X-Gm-Message-State: ANoB5pkhfGiWz2SPAOtvOWQoBdIL+PkGaxMq4mUC+XIZWTpuLZT8OObk 3y9RXJY5LBM0cMtBmo3LjzFRM77pntQ= X-Google-Smtp-Source: AA0mqf5eL2O7k5jOWq0xGA4KcVXAP1wGDm408s2eWmm7jAdfC1FlItCn6fkSxeVlNtUWMF3WCDYpKA== X-Received: by 2002:a05:6870:2886:b0:144:b157:ddb3 with SMTP id gy6-20020a056870288600b00144b157ddb3mr21047339oab.51.1671544408444; Tue, 20 Dec 2022 05:53:28 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, Bernhard Beschow , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= Subject: [PULL 12/15] hw/ppc/e500: Resolve variable shadowing Date: Tue, 20 Dec 2022 10:52:48 -0300 Message-Id: <20221220135251.155176-13-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::35; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x35.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544467799100003 From: Bernhard Beschow Assign to the outer variable instead which even saves some code. Signed-off-by: Bernhard Beschow Reviewed-by: C=C3=A9dric Le Goater Message-Id: <20221216145709.271940-6-shentey@gmail.com> Signed-off-by: Daniel Henrique Barboza --- hw/ppc/e500.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c index 53876af866..fee14ff8b3 100644 --- a/hw/ppc/e500.c +++ b/hw/ppc/e500.c @@ -908,7 +908,7 @@ void ppce500_init(MachineState *machine) bool kernel_as_payload; hwaddr bios_entry =3D 0; target_long payload_size; - struct boot_info *boot_info; + struct boot_info *boot_info =3D NULL; int dt_size; int i; unsigned int smp_cpus =3D machine->smp.cpus; @@ -963,7 +963,6 @@ void ppce500_init(MachineState *machine) /* Register reset handler */ if (!i) { /* Primary CPU */ - struct boot_info *boot_info; boot_info =3D g_new0(struct boot_info, 1); qemu_register_reset(ppce500_cpu_reset, cpu); env->load_info =3D boot_info; @@ -1263,7 +1262,6 @@ void ppce500_init(MachineState *machine) } assert(dt_size < DTB_MAX_SIZE); =20 - boot_info =3D env->load_info; boot_info->entry =3D bios_entry; boot_info->dt_base =3D dt_base; boot_info->dt_size =3D dt_size; --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544499; cv=none; d=zohomail.com; s=zohoarc; b=SmV4K81zl7K9M57+M7MXZa4fFEZuss6eIgskBLruCfUxBGq95mLGOv2NSQn01KOkTENiGI9TkRFOcUGkrXt7RqmDQJ9e96TVRkbFocWMwOc8K5B0VLnqIQBhJmz77NrffPyWNVEahA4X92YDbTpulUuFPKVQFQGCtSdjmYDnL/E= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544499; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=kaZTRCWB3+vNJHSy/PbrNyDQSIagPPPMiaqor4aGfWQ=; b=IcZ7JfHK+iiGY/6vu1E6OHfpoC/kFAUBFvAJS4slT8Xw0BkfEY1oRI/m1oKwcHiSErNhB4Zb4HCLYo1j1lyN0lXSX7VE0Jvnyw2HAMC9z0J5eYQLBXdQpfpfnZHUJmgDseLwwMi/Fe58bs4Uc/ukhZB09AXL4sajizqipNlXbYs= 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 167154449972179.37437714639339; Tue, 20 Dec 2022 05:54:59 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3m-0004Ns-6A; Tue, 20 Dec 2022 08:53:34 -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 1p7d3l-0004NT-Bf; Tue, 20 Dec 2022 08:53:33 -0500 Received: from mail-oa1-x2e.google.com ([2001:4860:4864:20::2e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3j-00012h-SM; Tue, 20 Dec 2022 08:53:33 -0500 Received: by mail-oa1-x2e.google.com with SMTP id 586e51a60fabf-14455716674so15427099fac.7; Tue, 20 Dec 2022 05:53:31 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=kaZTRCWB3+vNJHSy/PbrNyDQSIagPPPMiaqor4aGfWQ=; b=AWXO9NPWFHslD+5dwAOde1z7o8seFZI0rGW6xxJIzYSF4F+6WAaSPpCYxAUHkygUgM ZNhBnvcayvXDCq27bIKkoj1JTWVSLRaeugJZdqc3WHMZrFHRqT1RUrhdMXgeUSG04+GO 84St2WeM/Ph9kmmfdd7KI3nnyNQn+vDeh+el3Vmk9TP8TakysuMXBvCB1toWU5JvDl86 TW7tgzrWc8DogqFqIFXQMh2FJ7vZeKtJiEuKlBZA5Yt+iM92RvnpMgh90FiCNZ4A6ndw XEXgDiIiHTZTZ3+WJ0jPc7IjPAW5RbA32l+GfbveInq1DrL9a7ZEx5DJ/GAdYTabmWVR 6Oww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=kaZTRCWB3+vNJHSy/PbrNyDQSIagPPPMiaqor4aGfWQ=; b=WXDeij0HqJ5ThBD31etVIhcDadMmLPJIUz0ScA7QPHtQnrOahjYmvnMSvmal01oPUS l1h1pOtNPnvNX+T9JH7ScxY+Q0WkL2EDABR6tyD0758+vWPh7HSkVC85sle0l8Q9yEFt oORW2mz+WBXPk4elx3B6KGBA6R+OEvWiCYR26KA/7uEOaWkAhliW/aSG29eh22rOk7yo pLXB62A2a0zaa7XJKD4+U2A5xwH7tbpu7r0xhXN7O33BWR6xCYnh41/w6OffafRE5Wh4 1UvlqIh/AaEHte6VDhZSv4IQr5u5ttzdUh9WFTm/UmECx64DwiZsFCFz2XUSFwqxh8hF Vp0g== X-Gm-Message-State: ANoB5pkcneLuMdGB4d+On2b+2M7oh7YpraYNLvEo8E9MgOUgV7aBY6K6 JhxUCVmq63flN8VCAkSw8u9KGrMpqaE= X-Google-Smtp-Source: AA0mqf5B9ckP1ZEYJFBnnWRL4vZOHwBVzL2WXgAZt9mE7heiQ2Cuc6dKu1jR/WIU3IxO/FWV0jaytA== X-Received: by 2002:a05:6870:9e84:b0:144:95ca:c5cb with SMTP id pu4-20020a0568709e8400b0014495cac5cbmr23247262oab.37.1671544410751; Tue, 20 Dec 2022 05:53:30 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, Bernhard Beschow , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= Subject: [PULL 13/15] hw/ppc/e500: Move comment to more appropriate place Date: Tue, 20 Dec 2022 10:52:49 -0300 Message-Id: <20221220135251.155176-14-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=2001:4860:4864:20::2e; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x2e.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544500210100001 From: Bernhard Beschow The TLB entries are set up in mmubooke_create_initial_mapping(), not in booke206_page_size_to_tlb(). Signed-off-by: Bernhard Beschow Reviewed-by: C=C3=A9dric Le Goater Message-Id: <20221216145709.271940-7-shentey@gmail.com> Signed-off-by: Daniel Henrique Barboza --- hw/ppc/e500.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c index fee14ff8b3..cff2acbb34 100644 --- a/hw/ppc/e500.c +++ b/hw/ppc/e500.c @@ -717,7 +717,6 @@ static int ppce500_prep_device_tree(PPCE500MachineState= *machine, kernel_base, kernel_size, true); } =20 -/* Create -kernel TLB entries for BookE. */ hwaddr booke206_page_size_to_tlb(uint64_t size) { return 63 - clz64(size / KiB); @@ -748,6 +747,7 @@ static uint64_t mmubooke_initial_mapsize(CPUPPCState *e= nv) return (1ULL << 10 << tsize); } =20 +/* Create -kernel TLB entries for BookE. */ static void mmubooke_create_initial_mapping(CPUPPCState *env) { ppcmas_tlb_t *tlb =3D booke206_get_tlbm(env, 1, 0, 0); --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544668; cv=none; d=zohomail.com; s=zohoarc; b=cNM+1+OMUmRO+a6Hix9nOKMKa7ov95UQ2rxCTOYdUZRrTuFYeIYzuXCUoYSQBASOHJsDAb0MNCqOFVoiLUf2epc4kAB5lvPPH97BhBkgvsWKYaedDi2+tbno7DQjpmBzpmYnEDxjHGOAA1bkVh/3T4rUoZzOo2E00Hok6Gr2Zek= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544668; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=m/S6uVqxcXUPFL/hsj37bNmOIw6RVrsWs4dBLs+Xikw=; b=BZW7kze5ZCdexQn1iDphVHJRV/o1nhfFvMv5zz9dVcwZ3wafnPHDSYoJatez02AvJLGBinhQlU0dlziM2g+pjzifNrKRi0Tlr2cyiPw9L1BtLwSVkKIIpvOKvBjLEKOxdiq/qGHnxOnvnJyCGdaogcjVCPeEwwl5OSsXJvc98xY= 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 1671544668090464.6393866393639; Tue, 20 Dec 2022 05:57:48 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3q-0004QX-KX; Tue, 20 Dec 2022 08:53:38 -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 1p7d3n-0004OW-Uk; Tue, 20 Dec 2022 08:53:36 -0500 Received: from mail-oa1-x30.google.com ([2001:4860:4864:20::30]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3m-00012L-4X; Tue, 20 Dec 2022 08:53:35 -0500 Received: by mail-oa1-x30.google.com with SMTP id 586e51a60fabf-1442977d77dso15420980fac.6; Tue, 20 Dec 2022 05:53:33 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=m/S6uVqxcXUPFL/hsj37bNmOIw6RVrsWs4dBLs+Xikw=; b=DX3NngfoCIpEmJ58EFN2sL7mQnnU6NB7/6rH/mAr4ISCGBB+lw73LUmQ7GMcf/hG8e c+4QBRsCL9YlF89mNzWiG7bSN2mNdayhvZKoIySHMP/3bxMZnlWE+uxYcsp3qQOXHgZz f0H0x/6ZsXIysEOYb2nMnwUD60uaEBZLvuXOWSCUg5UobkEB776+j2OTIp+ttxz1f7p8 tfucKl6hzGBcJFFCwwUTdELXAaO03XqTGGVzFFUbXEVF8n0FxQ9RRzpSH8tt9KHIvIzY RStRFOzcU4c62s/Pn5y0q9C20Ljh+tMbdNbY5O8Dsy220qIFhuQftGtEiIPlzKcMtmnC Buxg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=m/S6uVqxcXUPFL/hsj37bNmOIw6RVrsWs4dBLs+Xikw=; b=jOt329phXkrvqqebZNMn6itSGlxMF1V4O9m77Us7AU79LZ3Sxtxd3hkcTUlkPLHo2N mS/cHYVhlj4/x4sv3SAnV1sGkos4qCEoyOk1q6cbNdBIPlorHTACjtqk7b6zBwvdXT6n rRlYrby7ABDhTRhaHbA8K4VxvrEYU2yA1FV+fYINYNvDxUTLHYOpMcxbOnglCKAcgknp 9Q6+F9bB4eADl3lDx7YZBjvB2fW4Wi6YoUs1wB0xqY3aeOcWCLG1pMXEfi7RTgovdJzd Cif6l+0afOh4RfyrPCUhWc+mOE4bIxqIMNPzyWGHVu3qVgKyAXzbf6T3JKPEA4iAER6F 6jFQ== X-Gm-Message-State: ANoB5plRYkA3UEE67gHSAOysYZESP1kPZuSzR+4VrS7zzjVQsir5Hv19 /LzRSGzrBHr5ZfnXxiqojJYxCuILMUQ= X-Google-Smtp-Source: AA0mqf7UX42hFs4VJCYrK3Ucbgvc7wsTnV6htyKIGH6R7raWQpCH1XJi6qw+RPho0qjZXNMUw86Ocg== X-Received: by 2002:a05:6870:ec87:b0:144:6a45:bafb with SMTP id eo7-20020a056870ec8700b001446a45bafbmr25130059oab.42.1671544412701; Tue, 20 Dec 2022 05:53:32 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, Nicholas Miehlbradt Subject: [PULL 14/15] target/ppc: Implement the DEXCR and HDEXCR Date: Tue, 20 Dec 2022 10:52:50 -0300 Message-Id: <20221220135251.155176-15-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=lists.gnu.org; Received-SPF: pass client-ip=2001:4860:4864:20::30; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x30.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544669383100001 Content-Type: text/plain; charset="utf-8" From: Nicholas Miehlbradt Define the DEXCR and HDEXCR as special purpose registers. Each register occupies two SPR indicies, one which can be read in an unprivileged state and one which can be modified in the appropriate priviliged state, however both indicies refer to the same underlying value. Note that the ISA uses the abbreviation UDEXCR in two different contexts: the userspace DEXCR, the SPR index which can be read from userspace (implemented in this patch), and the ultravisor DEXCR, the equivalent register for the ultravisor state (not implemented). Signed-off-by: Nicholas Miehlbradt Reviewed-by: Daniel Henrique Barboza Message-Id: <20221220042330.2387944-2-nicholas@linux.ibm.com> Signed-off-by: Daniel Henrique Barboza --- target/ppc/cpu.h | 19 +++++++++++++++++++ target/ppc/cpu_init.c | 25 +++++++++++++++++++++++++ target/ppc/spr_common.h | 1 + target/ppc/translate.c | 19 +++++++++++++++++++ 4 files changed, 64 insertions(+) diff --git a/target/ppc/cpu.h b/target/ppc/cpu.h index 81d4263a07..3923f174f8 100644 --- a/target/ppc/cpu.h +++ b/target/ppc/cpu.h @@ -1068,6 +1068,21 @@ struct ppc_radix_page_info { uint32_t entries[PPC_PAGE_SIZES_MAX_SZ]; }; =20 +/*************************************************************************= ****/ +/* Dynamic Execution Control Register */ + +#define DEXCR_ASPECT(name, num) \ +FIELD(DEXCR, PNH_##name, PPC_BIT_NR(num), 1) \ +FIELD(DEXCR, PRO_##name, PPC_BIT_NR(num + 32), 1) \ +FIELD(HDEXCR, HNU_##name, PPC_BIT_NR(num), 1) \ +FIELD(HDEXCR, ENF_##name, PPC_BIT_NR(num + 32), 1) \ + +DEXCR_ASPECT(SBHE, 0) +DEXCR_ASPECT(IBRTPD, 1) +DEXCR_ASPECT(SRAPD, 4) +DEXCR_ASPECT(NPHIE, 5) +DEXCR_ASPECT(PHIE, 6) + /*************************************************************************= ****/ /* The whole PowerPC CPU context */ =20 @@ -1674,9 +1689,11 @@ void ppc_compat_add_property(Object *obj, const char= *name, #define SPR_BOOKE_GIVOR13 (0x1BC) #define SPR_BOOKE_GIVOR14 (0x1BD) #define SPR_TIR (0x1BE) +#define SPR_UHDEXCR (0x1C7) #define SPR_PTCR (0x1D0) #define SPR_HASHKEYR (0x1D4) #define SPR_HASHPKEYR (0x1D5) +#define SPR_HDEXCR (0x1D7) #define SPR_BOOKE_SPEFSCR (0x200) #define SPR_Exxx_BBEAR (0x201) #define SPR_Exxx_BBTAR (0x202) @@ -1865,8 +1882,10 @@ void ppc_compat_add_property(Object *obj, const char= *name, #define SPR_RCPU_L2U_RA2 (0x32A) #define SPR_MPC_MD_DBRAM1 (0x32A) #define SPR_RCPU_L2U_RA3 (0x32B) +#define SPR_UDEXCR (0x32C) #define SPR_TAR (0x32F) #define SPR_ASDR (0x330) +#define SPR_DEXCR (0x33C) #define SPR_IC (0x350) #define SPR_VTB (0x351) #define SPR_MMCRC (0x353) diff --git a/target/ppc/cpu_init.c b/target/ppc/cpu_init.c index 95d25856a0..abee71d407 100644 --- a/target/ppc/cpu_init.c +++ b/target/ppc/cpu_init.c @@ -5727,6 +5727,30 @@ static void register_power10_hash_sprs(CPUPPCState *= env) hashpkeyr_initial_value); } =20 +static void register_power10_dexcr_sprs(CPUPPCState *env) +{ + spr_register(env, SPR_DEXCR, "DEXCR", + SPR_NOACCESS, SPR_NOACCESS, + &spr_read_generic, &spr_write_generic, + 0); + + spr_register(env, SPR_UDEXCR, "DEXCR", + &spr_read_dexcr_ureg, SPR_NOACCESS, + &spr_read_dexcr_ureg, SPR_NOACCESS, + 0); + + spr_register_hv(env, SPR_HDEXCR, "HDEXCR", + SPR_NOACCESS, SPR_NOACCESS, + SPR_NOACCESS, SPR_NOACCESS, + &spr_read_generic, &spr_write_generic, + 0); + + spr_register(env, SPR_UHDEXCR, "HDEXCR", + &spr_read_dexcr_ureg, SPR_NOACCESS, + &spr_read_dexcr_ureg, SPR_NOACCESS, + 0); +} + /* * Initialize PMU counter overflow timers for Power8 and * newer Power chips when using TCG. @@ -6402,6 +6426,7 @@ static void init_proc_POWER10(CPUPPCState *env) register_power8_rpr_sprs(env); register_power9_mmu_sprs(env); register_power10_hash_sprs(env); + register_power10_dexcr_sprs(env); =20 /* FIXME: Filter fields properly based on privilege level */ spr_register_kvm_hv(env, SPR_PSSCR, "PSSCR", NULL, NULL, NULL, NULL, diff --git a/target/ppc/spr_common.h b/target/ppc/spr_common.h index b5a5bc6895..8437eb0340 100644 --- a/target/ppc/spr_common.h +++ b/target/ppc/spr_common.h @@ -195,6 +195,7 @@ void spr_read_ebb_upper32(DisasContext *ctx, int gprn, = int sprn); void spr_write_ebb_upper32(DisasContext *ctx, int sprn, int gprn); void spr_write_hmer(DisasContext *ctx, int sprn, int gprn); void spr_write_lpcr(DisasContext *ctx, int sprn, int gprn); +void spr_read_dexcr_ureg(DisasContext *ctx, int gprn, int sprn); #endif =20 void register_low_BATs(CPUPPCState *env); diff --git a/target/ppc/translate.c b/target/ppc/translate.c index 19c1d17cb0..edb3daa9b5 100644 --- a/target/ppc/translate.c +++ b/target/ppc/translate.c @@ -1249,6 +1249,25 @@ void spr_write_ebb_upper32(DisasContext *ctx, int sp= rn, int gprn) gen_fscr_facility_check(ctx, SPR_FSCR, FSCR_EBB, sprn, FSCR_IC_EBB); spr_write_prev_upper32(ctx, sprn, gprn); } + +void spr_read_dexcr_ureg(DisasContext *ctx, int gprn, int sprn) +{ + TCGv t0 =3D tcg_temp_new(); + + /* + * Access to the (H)DEXCR in problem state is done using separated + * SPR indexes which are 16 below the SPR indexes which have full + * access to the (H)DEXCR in privileged state. Problem state can + * only read bits 32:63, bits 0:31 return 0. + * + * See section 9.3.1-9.3.2 of PowerISA v3.1B + */ + + gen_load_spr(t0, sprn + 16); + tcg_gen_ext32u_tl(cpu_gpr[gprn], t0); + + tcg_temp_free(t0); +} #endif =20 #define GEN_HANDLER(name, opc1, opc2, opc3, inval, type) = \ --=20 2.38.1 From nobody Wed May 15 14:03:44 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=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1671544511; cv=none; d=zohomail.com; s=zohoarc; b=bKr+u4YpQMUL8zO//g9Oxjp8VF25HBV7y0u619J3qDA2uQnWc3TxhLzelq8oglp4VqzCXwyY3KV2RYkUVMRuqf8iOu9cBVKiqSOZlI04hgvJM/3IG9XJW392vCfXupzHqJ4Jjt8VUALj2y4CWUGW/VkCqJhq/4jGopIf+HbQZ2w= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1671544511; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=duf0nNtYaItwYDzbhKlns2RnaTPeDICDvkZSxpPsxPw=; b=bH0wnzvJv92uzaYGG4sD/wxGzMFtoTIu36Hazf0fM1OZrZThRopp31H0Ww4pGoPLf1OtNFsQuwikDsNIataqDOBslSNjNyMe9q6VBDtARFcaEBhEPTGNDKLG12EjmrxdY6STKYsj4/GnxZQVlCNoSqCJrr0pK27h2fEaW+lGpyQ= 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 1671544511623778.4266219009023; Tue, 20 Dec 2022 05:55:11 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7d3r-0004Qx-IA; Tue, 20 Dec 2022 08:53:39 -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 1p7d3p-0004Pi-LB; Tue, 20 Dec 2022 08:53:38 -0500 Received: from mail-oa1-x2a.google.com ([2001:4860:4864:20::2a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p7d3o-000137-0g; Tue, 20 Dec 2022 08:53:37 -0500 Received: by mail-oa1-x2a.google.com with SMTP id 586e51a60fabf-1322d768ba7so15439418fac.5; Tue, 20 Dec 2022 05:53:35 -0800 (PST) Received: from fedora.dc1.ventanamicro.com (201-43-103-101.dsl.telesp.net.br. [201.43.103.101]) by smtp.gmail.com with ESMTPSA id f14-20020a056870898e00b0014474019e50sm5994933oaq.24.2022.12.20.05.53.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 05:53:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=duf0nNtYaItwYDzbhKlns2RnaTPeDICDvkZSxpPsxPw=; b=H5Bj34WVN0IK4ap+gPD3d2RITnqfbK+tgwsj1kOAhYAl0KPa8Jvv+vYIu4PeGO7tsV mXa9zBgmGAqKurWiBtp/mmjXo5A/m3cIrCf9wJ1H7tuZ6BF7XHHg0fjHOOaBkIF4bTba ygHdLiKSsvVS/9+v1B8ZMxN6e4Gjkm7L1e++jPFOUvrqXQlvOjs9a/PavFjxM+rkQBYQ ZsXdaiHTUggwbX2gIxGt/SjBqq9DepI2qFeYI3rWdz5pU3DjojQSWmb9zDXdmAnJV2A/ Jnx2GdGCzdxB89Ii88Gu4nTdRGprgrlNcNMWXTVfpK/d8aoPPm5sV9N0iEE6T3v1YGvN NYWg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=duf0nNtYaItwYDzbhKlns2RnaTPeDICDvkZSxpPsxPw=; b=Ous4c6dxkBpuHTbM1ImXTkUCFN78fC58eDFSs86//sdaSiqrIzQEwVCyy1QC4uf7ud h+wPe0xOv3inWIS4AvykbRP19B7MyNBfIEY2SvtfgY9QUFeAy0Bb/PsjLeb/Lg3Mgakw lgTHwkBQ9tCmxA+qRORUBoTnce3Vk67Yc9GgvJFKxLXIvXbfc+KbLcZiT9az4vemgVrj 7iMLSGXGAZ8SzbwVDMfSn+zmJQuhDGsmHG2aTBfYnnXFxScDukpqyNiS6MfdBw2GNPWD dKGJW04C+4m62EGUOrOBAxBCiyB/F8kXjoy1NvuUGxFLsv8X/ozt7STrUOudZhEV+acc ztPA== X-Gm-Message-State: ANoB5pmmOzum6N1+FQlcnFGtdB2GEC9fgzkvUSOGK6V9xef8BuGdVnu1 QO/AGBJFTmFXSvlwzATRyzx7eg1X6gg= X-Google-Smtp-Source: AA0mqf7+L/fQKkltfhD8zvlZpD6kRoLBdd5TJaeGa2q770klwQzO9nYOdA9DRg6r8DzVMNnjxpZ3Xw== X-Received: by 2002:a05:6870:1d0f:b0:144:8c76:636 with SMTP id pa15-20020a0568701d0f00b001448c760636mr21134753oab.39.1671544414916; Tue, 20 Dec 2022 05:53:34 -0800 (PST) From: Daniel Henrique Barboza To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, peter.maydell@linaro.org, Nicholas Miehlbradt Subject: [PULL 15/15] target/ppc: Check DEXCR on hash{st, chk} instructions Date: Tue, 20 Dec 2022 10:52:51 -0300 Message-Id: <20221220135251.155176-16-danielhb413@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221220135251.155176-1-danielhb413@gmail.com> References: <20221220135251.155176-1-danielhb413@gmail.com> 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=lists.gnu.org; Received-SPF: pass client-ip=2001:4860:4864:20::2a; envelope-from=danielhb413@gmail.com; helo=mail-oa1-x2a.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1671544512120100001 Content-Type: text/plain; charset="utf-8" From: Nicholas Miehlbradt Adds checks to the hashst and hashchk instructions to only execute if enabled by the relevant aspect in the DEXCR and HDEXCR. This behaviour is guarded behind TARGET_PPC64 since Power10 is currently the only implementation which has the DEXCR. Reviewed-by: Daniel Henrique Barboza Signed-off-by: Nicholas Miehlbradt Message-Id: <20221220042330.2387944-3-nicholas@linux.ibm.com> Signed-off-by: Daniel Henrique Barboza --- target/ppc/excp_helper.c | 58 +++++++++++++++++++++++++++++----------- 1 file changed, 43 insertions(+), 15 deletions(-) diff --git a/target/ppc/excp_helper.c b/target/ppc/excp_helper.c index 94adcb766b..add4d54ae7 100644 --- a/target/ppc/excp_helper.c +++ b/target/ppc/excp_helper.c @@ -2902,29 +2902,57 @@ static uint64_t hash_digest(uint64_t ra, uint64_t r= b, uint64_t key) return stage1_h ^ stage1_l; } =20 +static void do_hash(CPUPPCState *env, target_ulong ea, target_ulong ra, + target_ulong rb, uint64_t key, bool store) +{ + uint64_t calculated_hash =3D hash_digest(ra, rb, key), loaded_hash; + + if (store) { + cpu_stq_data_ra(env, ea, calculated_hash, GETPC()); + } else { + loaded_hash =3D cpu_ldq_data_ra(env, ea, GETPC()); + if (loaded_hash !=3D calculated_hash) { + raise_exception_err_ra(env, POWERPC_EXCP_PROGRAM, + POWERPC_EXCP_TRAP, GETPC()); + } + } +} + #include "qemu/guest-random.h" =20 -#define HELPER_HASH(op, key, store) = \ +#ifdef TARGET_PPC64 +#define HELPER_HASH(op, key, store, dexcr_aspect) = \ void helper_##op(CPUPPCState *env, target_ulong ea, target_ulong ra, = \ target_ulong rb) = \ { = \ - uint64_t calculated_hash =3D hash_digest(ra, rb, key), loaded_hash; = \ - = \ - if (store) { = \ - cpu_stq_data_ra(env, ea, calculated_hash, GETPC()); = \ - } else { = \ - loaded_hash =3D cpu_ldq_data_ra(env, ea, GETPC()); = \ - if (loaded_hash !=3D calculated_hash) { = \ - raise_exception_err_ra(env, POWERPC_EXCP_PROGRAM, = \ - POWERPC_EXCP_TRAP, GETPC()); = \ - } = \ + if (env->msr & R_MSR_PR_MASK) { = \ + if (!(env->spr[SPR_DEXCR] & R_DEXCR_PRO_##dexcr_aspect##_MASK || = \ + env->spr[SPR_HDEXCR] & R_HDEXCR_ENF_##dexcr_aspect##_MASK)) = \ + return; = \ + } else if (!(env->msr & R_MSR_HV_MASK)) { = \ + if (!(env->spr[SPR_DEXCR] & R_DEXCR_PNH_##dexcr_aspect##_MASK || = \ + env->spr[SPR_HDEXCR] & R_HDEXCR_ENF_##dexcr_aspect##_MASK)) = \ + return; = \ + } else if (!(env->msr & R_MSR_S_MASK)) { = \ + if (!(env->spr[SPR_HDEXCR] & R_HDEXCR_HNU_##dexcr_aspect##_MASK)) = \ + return; = \ } = \ + = \ + do_hash(env, ea, ra, rb, key, store); = \ +} +#else +#define HELPER_HASH(op, key, store, dexcr_aspect) = \ +void helper_##op(CPUPPCState *env, target_ulong ea, target_ulong ra, = \ + target_ulong rb) = \ +{ = \ + do_hash(env, ea, ra, rb, key, store); = \ } +#endif /* TARGET_PPC64 */ =20 -HELPER_HASH(HASHST, env->spr[SPR_HASHKEYR], true) -HELPER_HASH(HASHCHK, env->spr[SPR_HASHKEYR], false) -HELPER_HASH(HASHSTP, env->spr[SPR_HASHPKEYR], true) -HELPER_HASH(HASHCHKP, env->spr[SPR_HASHPKEYR], false) +HELPER_HASH(HASHST, env->spr[SPR_HASHKEYR], true, NPHIE) +HELPER_HASH(HASHCHK, env->spr[SPR_HASHKEYR], false, NPHIE) +HELPER_HASH(HASHSTP, env->spr[SPR_HASHPKEYR], true, PHIE) +HELPER_HASH(HASHCHKP, env->spr[SPR_HASHPKEYR], false, PHIE) #endif /* CONFIG_TCG */ =20 #if !defined(CONFIG_USER_ONLY) --=20 2.38.1