From patchwork Tue May 18 20:11:22 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 441230 Delivered-To: patch@linaro.org Received: by 2002:a02:7a1b:0:0:0:0:0 with SMTP id a27csp580067jac; Tue, 18 May 2021 13:17:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyhA3eDQhOrrljTXCxgUhezyIu9MhiebRYLFY9k9239/cHPAympRXRK3bkkmdSRC0xbUHr5 X-Received: by 2002:a05:6e02:e10:: with SMTP id a16mr5880106ilk.56.1621369073135; Tue, 18 May 2021 13:17:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621369073; cv=none; d=google.com; s=arc-20160816; b=J16u2B6xD1548SLxi5dC+lX+If8AiIWJs6XSZ+CVBeFTRsm4E10GyYiIVctY5pqWLw iqnwkuxZcA//QmaJcqAlixs9nha0YPCCN71XdA2EcIW5/hvDEN6rA1LM2wr8zL2rEySV u4xqLp7a4hfC4j8icD6c2x8eRf3OsQkLOkR44EsReEbMBbnASnHEbN2oLfNpEUCNcDKi qakhDBb1aIVpYwaEHj+phtc+0PDdXVDmu+zerFnDAKs4L+Je2a3HlEUgjWNe+5iTttoK f77bzZB2zAip735geRccTChH1m9iW/XggEvEQz/SLHBiDfnpM3Nv/enYBLdTMCYVWBiu w6ZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:to:from:dkim-signature; bh=qPfzJb0rUax3UJP3k25AmhFKfk/NW8Mt2W62oGkhFmE=; b=pNVSl9hvAUpE8meA+oNv5wP3tpo9Mk+8Vl0YSxOGj2SozCpEDsgVIRolhFhBPg2Dch OXqtXtb1ut7Xuf7B/RI8UG0CklfxC+Q/p3mk4AXxMJE3CQ64Bdcog0u9Gi0QBRI4dyg5 uf/JMvOuH+ggImeLj9Gbmfncid9xPEYM6VN5e9hrUR2XRB9MdAcZtF6l2hEDmrzT2Nth dUH4KfZ+Ssr65j4/rulYXdCR2hl/9uO3gvM9MMK/O9tiMei1Jk5d15AYXqjfmsGPUItj 2WFzGN95cf71u2LjsGSdRntZIW2NgOX+2cfXrAI/Lr9mGZfcCwkJ+EkTIskoF9TWzy45 YvDQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=suOKldG+; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id v30si2252870jal.60.2021.05.18.13.17.53 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 18 May 2021 13:17:53 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=suOKldG+; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:45396 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lj6A4-0004sR-Go for patch@linaro.org; Tue, 18 May 2021 16:17:52 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42414) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lj64K-000071-Ah for qemu-devel@nongnu.org; Tue, 18 May 2021 16:11:56 -0400 Received: from mail-ot1-x330.google.com ([2607:f8b0:4864:20::330]:34417) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lj64D-0005zW-FJ for qemu-devel@nongnu.org; Tue, 18 May 2021 16:11:55 -0400 Received: by mail-ot1-x330.google.com with SMTP id u25-20020a0568302319b02902ac3d54c25eso9795063ote.1 for ; Tue, 18 May 2021 13:11:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=qPfzJb0rUax3UJP3k25AmhFKfk/NW8Mt2W62oGkhFmE=; b=suOKldG+qFrVpld3tSYxxLB/sopKgsukhg/r7Gx1FdXyO4tnFWYTBktA9FxeasbOWw qlLWR9QCFcjjWMoq+MGGf1n8MOeXYfV/Q4qaA6DHza8s2xqgOe163KfMiLHYsHej5HOr 8gvDSF7MsUZ2cQL2n8ArodyHOetyvhf15+4DRUNcopwEw11YKTO1nlHtQTaT9XWPVXsW 8sRjlhlxtydUjuRG6HoCDTg+LcLFldlwvva4uneQgQ/GXLYWnyNSPZEN3Fpdg2pU/DaF 14DnfZVWpRhXuEfbaL/eQmiWIewDyW3NTXgd1aPlKdCpTIMRq1HV1dtT9ZP21OMGpz0N liOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=qPfzJb0rUax3UJP3k25AmhFKfk/NW8Mt2W62oGkhFmE=; b=RggFPRIZhymxiG/4DXB2AN8aCjaCY3aVvJMnPqzbQ3kHvLaPYCFUnq5S5afx7oy6a6 3G54nw4CS27MjHEVD8cMY1FBssvlWnFe+SohYNAohy+CmOEkbnzf3w15aEEo1y4gcfwj pYsDmG8C8M4oUSn2YQnvCK1mU8qZED/o8qeai+XC9cwKfzqyyeRI7cqakD4l7HMe+W3q pD17U28yXMtVFFRd9XwMlvUh8F4mDy48ULRoBRDh4y3BhL84NRwnS2plT8ZNldm6OvX8 tr2WIfgYVdlGt2Ty1NhcZaPRxiqTcynix4gcEQ1OCknJf1epW8Cpj0mTm2VrTwvbKzt+ Kf2g== X-Gm-Message-State: AOAM532rrjn7WWDVUhQqiHLr0if1l2i9l2JUxVdbKIKyJbF4y5USGAqI fNHZ3iABRZ33eUqfTHEoScZEaZ20kQB2q5kC X-Received: by 2002:a9d:5e8c:: with SMTP id f12mr5595386otl.18.1621368708189; Tue, 18 May 2021 13:11:48 -0700 (PDT) Received: from localhost.localdomain ([45.235.253.15]) by smtp.gmail.com with ESMTPSA id u27sm3953204oof.38.2021.05.18.13.11.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 18 May 2021 13:11:47 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH 00/24] target/ppc: Clean up mmu translation Date: Tue, 18 May 2021 15:11:22 -0500 Message-Id: <20210518201146.794854-1-richard.henderson@linaro.org> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::330; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x330.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: bruno.larsen@eldorado.org.br, qemu-ppc@nongnu.org, david@gibson.dropbear.id.au Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" This attempts the cleanup I've been talking about with Bruno. On the way, there's a lot of MMUAccessType cleanup, to get the code into the form I wanted the interface to share. There's a lot more cleanup that could be done, particularly wrt the older mmu models. r~ Richard Henderson (24): target/ppc: Introduce prot_for_access_type target/ppc: Use MMUAccessType in mmu-radix64.c target/ppc: Use MMUAccessType in mmu-hash64.c target/ppc: Use MMUAccessType in mmu-hash32.c target/ppc: Rename access_type to type in mmu_helper.c target/ppc: Use MMUAccessType in mmu_helper.c target/ppc: Remove type argument from check_prot target/ppc: Remove type argument from ppc6xx_tlb_pte_check target/ppc: Remove type argument from ppc6xx_tlb_check target/ppc: Remove type argument from get_bat_6xx_tlb target/ppc: Remove type argument from mmu40x_get_physical_address target/ppc: Remove type argument from mmubooke_check_tlb target/ppc: Remove type argument from mmubooke_get_physical_address target/ppc: Remove type argument from mmubooke206_check_tlb target/ppc: Remove type argument for mmubooke206_get_physical_address target/ppc: Remove PowerPCCPUClass.handle_mmu_fault target/ppc: Use MMUAccessType with *_handle_mmu_fault target/ppc: Push real-mode handling into ppc_radix64_xlate target/ppc: Use bool success for ppc_radix64_xlate target/ppc: Split out ppc_hash64_xlate target/ppc: Split out ppc_hash32_xlate target/ppc: Split out ppc_jumbo_xlate target/ppc: Introduce ppc_xlate target/ppc: Restrict ppc_cpu_tlb_fill to TCG target/ppc/cpu-qom.h | 1 - target/ppc/internal.h | 19 ++ target/ppc/mmu-book3s-v3.h | 5 - target/ppc/mmu-hash32.h | 6 +- target/ppc/mmu-hash64.h | 6 +- target/ppc/mmu-radix64.h | 6 +- target/ppc/cpu_init.c | 45 ---- target/ppc/mmu-book3s-v3.c | 19 -- target/ppc/mmu-hash32.c | 244 ++++++++---------- target/ppc/mmu-hash64.c | 187 ++++++-------- target/ppc/mmu-radix64.c | 235 +++++++++--------- target/ppc/mmu_helper.c | 496 +++++++++++++++++-------------------- 12 files changed, 553 insertions(+), 716 deletions(-) -- 2.25.1