From patchwork Thu Oct 17 11:20:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Adamczyk X-Patchwork-Id: 13839871 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5982DD2127D for ; Thu, 17 Oct 2024 11:22:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:Cc:To:From: Subject:Message-ID:Mime-Version:Date:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=n8lX1GmEtOr6LjU6fqL4HANwkfAPHfX1qh42rxSH5WY=; b=nUQBGMSarl7UFplpAboY7dH8HV o8JL3Gu4N2of5a4a5w5VY0eiTKME62Q/c6db1kpnWS3OtFh1XrZeCdBa7uTkNJDZOMjjAgfUEXr23 u4yykV57QPNVFwhynNLFZE4lbQhWH6F8tAj9EZYePWZ5MDjawHPZunPMF5Y2Z9D4dTEBCklclKgi9 Zrvro+ip8g1Hk7I/OvPucb3A5idbUMEhSEfqP35Nib7biViZaSvzb05AQlLiTSgEu6UVeHs0kNO6C fkNwh0d3ssLf8hnw/FZIVUSQgBhYkDFdtxev4c3pDibcUKbqmhkdfmcu0QKcXnjJjrOSrMBsAEJ1R dfEvSy2w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1t1Oa7-0000000Ed1C-2yMT; Thu, 17 Oct 2024 11:22:15 +0000 Received: from mail-ej1-x649.google.com ([2a00:1450:4864:20::649]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1t1OYd-0000000EcrR-2OUK for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2024 11:20:46 +0000 Received: by mail-ej1-x649.google.com with SMTP id a640c23a62f3a-a9a273e4251so52505166b.1 for ; Thu, 17 Oct 2024 04:20:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1729164041; x=1729768841; darn=lists.infradead.org; h=cc:to:from:subject:message-id:mime-version:date:from:to:cc:subject :date:message-id:reply-to; bh=n8lX1GmEtOr6LjU6fqL4HANwkfAPHfX1qh42rxSH5WY=; b=O8aBiZP8rslhjCL84Q+aTAS9L76PjuZwpRpND75lgtNqEkcJmb9Lkn6qS4BkPI9ftd 2mvqQwJHB2hvpIn2XV3JdtYB+x+Tyw2okVXoGuWEiqoZDc7kA+Rqe6JQ2OLbEuJuHQTa H/7970IMLqst1ZBmgTIaDXzbDabi8IvovQ7sbWJi4pdnAhggLNoDRioaFKW3WczQGQS8 JPUtjAaBUGpJ2HV8toXZ8m6HNH02jw3ShU865v2tLA7krRqgEXoEUjSZvbXXIaUHOIto vBLoArnlUiWhryOU/DjPb5+y/zaSaR1ed13oIAvpa2E2fdPzWawMVySVthFNJ0BK9jDf UN4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729164041; x=1729768841; h=cc:to:from:subject:message-id:mime-version:date:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=n8lX1GmEtOr6LjU6fqL4HANwkfAPHfX1qh42rxSH5WY=; b=TAe0w1yEdtGERFAZp+1OvbymlFBH5FOvzCXk4KzGF261vIH/2eHwoU0RIW0I99q5oR d/UomasuBCzhZuGztpArONUh0WZ56cZhZgI0b+rY7Tt7E3WLRvMsXV82pgzcnflsILJO 5SfKT/fOgiaufhluHtqNxxldOqcn1ZsHe9PHskXtmz3jJG3aGLlPTE6cifxzIck9YmuG RHggzY3c2F8O7qV64uB0itR4+XODpOKOlT2eqTkg6B5jiw4/4iTbhk9WByfPAYNU4Iiy ZtJrgLqaSbWKkNZRtT9Ta5LS5fPDL/Mf03QNqUdk+iL/OgoXxMGbrab7dWoMVOcgYu98 4VZQ== X-Forwarded-Encrypted: i=1; AJvYcCWDhH8c1LxS1HKAKA7j2aC7z+z9bsrRfoyrOI0gcBB0Z05fZMqJlbyOhMZsH9bk141JykLOBCDb7Gu00kwkwadz@lists.infradead.org X-Gm-Message-State: AOJu0Yz0ScrdcIpuwUc0ahLKvKg7cRdkmoaW3qagP97Hxvwfi6+TnjLY d4KBh8h6o0nRRPd1kKO3D1Kei6aGmHqciC6u0hBqpkzlMaLACGjnunjaVbaSd9JQGfxHH9yp8PC BgENrLg== X-Google-Smtp-Source: AGHT+IEDyt+T9WSjQe2tPO5YQX5MHOujfHpdD7iqlf6ce9MuLBoasfebCTsbGQEpakvLtWeTyF2ZgqEh5dA8 X-Received: from al-for-all.c.googlers.com ([fda3:e722:ac3:cc00:31:98fb:c0a8:545]) (user=konrada job=sendgmr) by 2002:a17:906:bcc5:b0:a99:fe61:adcb with SMTP id a640c23a62f3a-a9a34c7ac36mr210566b.1.1729164040346; Thu, 17 Oct 2024 04:20:40 -0700 (PDT) Date: Thu, 17 Oct 2024 11:20:36 +0000 Mime-Version: 1.0 X-Mailer: git-send-email 2.47.0.105.g07ac214952-goog Message-ID: <20241017112036.368772-1-konrada@google.com> Subject: [PATCH] iommu/mediatek: Add PGTABLE_PA_35_EN to mt8186 platform data From: Konrad Adamczyk To: Yong Wu , Joerg Roedel , Will Deacon , Robin Murphy , Matthias Brugger , AngeloGioacchino Del Regno , iommu@lists.linux.dev, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Wojciech Macek , Konrad Adamczyk X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241017_042043_614457_FC2D8E50 X-CRM114-Status: GOOD ( 11.36 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The MT8186 chip supports 35-bit physical addresses in page table [1]. Set this platform flag. [1] MT8186G_Application Processor Functional Specification_v1.0 Signed-off-by: Konrad Adamczyk Reviewed-by: Yong Wu --- drivers/iommu/mtk_iommu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c index 6a2707fe7a78..c45313c43b9e 100644 --- a/drivers/iommu/mtk_iommu.c +++ b/drivers/iommu/mtk_iommu.c @@ -1599,7 +1599,7 @@ static const unsigned int mt8186_larb_region_msk[MT8192_MULTI_REGION_NR_MAX][MTK static const struct mtk_iommu_plat_data mt8186_data_mm = { .m4u_plat = M4U_MT8186, .flags = HAS_BCLK | HAS_SUB_COMM_2BITS | OUT_ORDER_WR_EN | - WR_THROT_EN | IOVA_34_EN | MTK_IOMMU_TYPE_MM, + WR_THROT_EN | IOVA_34_EN | MTK_IOMMU_TYPE_MM | PGTABLE_PA_35_EN, .larbid_remap = {{0}, {1, MTK_INVALID_LARBID, 8}, {4}, {7}, {2}, {9, 11, 19, 20}, {MTK_INVALID_LARBID, 14, 16}, {MTK_INVALID_LARBID, 13, MTK_INVALID_LARBID, 17}},