LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: "Clément Péron" <peron.clem@gmail.com>
To: David Airlie <airlied@linux.ie>, Daniel Vetter <daniel@ffwll.ch>,
	Rob Herring <robh+dt@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Maxime Ripard <maxime.ripard@bootlin.com>,
	Chen-Yu Tsai <wens@csie.org>,
	Tomeu Vizoso <tomeu.vizoso@collabora.com>,
	Will Deacon <will.deacon@arm.com>,
	Robin Murphy <robin.murphy@arm.com>,
	Joerg Roedel <joro@8bytes.org>,
	Neil Armstrong <narmstrong@baylibre.com>,
	Steven Price <steven.price@arm.com>
Cc: dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	iommu@lists.linux-foundation.org,
	"Clément Péron" <peron.clem@gmail.com>
Subject: [PATCH v6 2/6] iommu: io-pgtable: fix sanity check for non 48-bit mali iommu
Date: Tue, 21 May 2019 18:10:58 +0200	[thread overview]
Message-ID: <20190521161102.29620-3-peron.clem@gmail.com> (raw)
In-Reply-To: <20190521161102.29620-1-peron.clem@gmail.com>

Allwinner H6 SoC has a Mali T720MP2 with a 33-bit iommu which
trig the sanity check during the alloc of the pgtable.

Change the sanity check to allow non 48-bit configuration.

Suggested-by: Robin Murphy <robin.murphy@arm.com>
Signed-off-by: Clément Péron <peron.clem@gmail.com>
---
 drivers/iommu/io-pgtable-arm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/iommu/io-pgtable-arm.c b/drivers/iommu/io-pgtable-arm.c
index 4e21efbc4459..74f2ce802e6f 100644
--- a/drivers/iommu/io-pgtable-arm.c
+++ b/drivers/iommu/io-pgtable-arm.c
@@ -1016,7 +1016,7 @@ arm_mali_lpae_alloc_pgtable(struct io_pgtable_cfg *cfg, void *cookie)
 {
 	struct io_pgtable *iop;
 
-	if (cfg->ias != 48 || cfg->oas > 40)
+	if (cfg->ias > 48 || cfg->oas > 40)
 		return NULL;
 
 	cfg->pgsize_bitmap &= (SZ_4K | SZ_2M | SZ_1G);
-- 
2.17.1


  parent reply	other threads:[~2019-05-21 16:11 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-21 16:10 [PATCH v6 0/6] Allwinner H6 Mali GPU support Clément Péron
2019-05-21 16:10 ` [PATCH v6 1/6] drm: panfrost: add optional bus_clock Clément Péron
2019-05-21 16:10 ` Clément Péron [this message]
2019-05-21 16:10 ` [PATCH v6 3/6] dt-bindings: gpu: add bus clock for Mali Midgard GPUs Clément Péron
2019-05-21 16:11 ` [PATCH v6 4/6] dt-bindings: gpu: mali-midgard: Add H6 mali gpu compatible Clément Péron
2019-05-21 16:11 ` [PATCH v6 5/6] arm64: dts: allwinner: Add ARM Mali GPU node for H6 Clément Péron
2019-05-21 16:11 ` [PATCH v6 6/6] arm64: dts: allwinner: Add mali GPU supply for H6 boards Clément Péron
2019-05-22 19:27 ` [PATCH v6 0/6] Allwinner H6 Mali GPU support Rob Herring
2019-05-22 19:41   ` Clément Péron
2019-05-22 20:51     ` Rob Herring
2019-06-03 17:27   ` Clément Péron
2019-05-24 17:25 ` Robin Murphy
2019-05-29 15:09 ` Tomeu Vizoso
2019-05-29 17:38   ` Robin Murphy
2019-05-31 12:04     ` Tomeu Vizoso
2019-05-31 13:47       ` Robin Murphy
2019-08-28 11:28         ` Neil Armstrong
2019-08-28 11:49           ` Robin Murphy
2019-08-28 11:51             ` Neil Armstrong
2019-06-10 13:30     ` Tomeu Vizoso
2019-05-29 15:32 ` [PATCH] arm64: dts: allwinner: Add GPU operating points for H6 Tomeu Vizoso
2019-05-29 15:37   ` Clément Péron
2019-05-29 15:42     ` Tomeu Vizoso

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190521161102.29620-3-peron.clem@gmail.com \
    --to=peron.clem@gmail.com \
    --cc=airlied@linux.ie \
    --cc=daniel@ffwll.ch \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=iommu@lists.linux-foundation.org \
    --cc=joro@8bytes.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=maxime.ripard@bootlin.com \
    --cc=narmstrong@baylibre.com \
    --cc=robh+dt@kernel.org \
    --cc=robin.murphy@arm.com \
    --cc=steven.price@arm.com \
    --cc=tomeu.vizoso@collabora.com \
    --cc=wens@csie.org \
    --cc=will.deacon@arm.com \
    --subject='Re: [PATCH v6 2/6] iommu: io-pgtable: fix sanity check for non 48-bit mali iommu' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).