diff options
author | Laura Abbott <labbott@fedoraproject.org> | 2017-09-06 11:11:28 -0700 |
---|---|---|
committer | Laura Abbott <labbott@fedoraproject.org> | 2017-09-10 09:39:26 -0700 |
commit | b4668f245f4965cc754efce0321172fcb4067895 (patch) | |
tree | 43228df285a3e83ea99b79e859994c01f52142b8 /arm-tegra-fix-gpu-iommu.patch | |
parent | 66cc5ce03c44ec186e7957d45acc521f82a3e794 (diff) | |
download | kernel-b4668f245f4965cc754efce0321172fcb4067895.tar.gz kernel-b4668f245f4965cc754efce0321172fcb4067895.tar.xz kernel-b4668f245f4965cc754efce0321172fcb4067895.zip |
Linux v4.13.1
Diffstat (limited to 'arm-tegra-fix-gpu-iommu.patch')
-rw-r--r-- | arm-tegra-fix-gpu-iommu.patch | 56 |
1 files changed, 0 insertions, 56 deletions
diff --git a/arm-tegra-fix-gpu-iommu.patch b/arm-tegra-fix-gpu-iommu.patch index 8d2809b46..c775c88b4 100644 --- a/arm-tegra-fix-gpu-iommu.patch +++ b/arm-tegra-fix-gpu-iommu.patch @@ -37,59 +37,3 @@ index 187a36c6d0fc..b3b89befffeb 100644 #address-cells = <2>; #size-cells = <2>; -From patchwork Mon Jul 10 19:33:05 2017 -Content-Type: text/plain; charset="utf-8" -MIME-Version: 1.0 -Content-Transfer-Encoding: 7bit -Subject: gpu: host1x: Free the IOMMU domain when there is no device to attach -From: Paul Kocialkowski <contact@paulk.fr> -X-Patchwork-Id: 9833721 -Message-Id: <20170710193305.5987-1-contact@paulk.fr> -To: linux-arm-kernel@lists.infradead.org, linux-tegra@vger.kernel.org, - linux-kernel@vger.kernel.org -Cc: Thierry Reding <thierry.reding@gmail.com>, - Stephen Warren <swarren@wwwdotorg.org>, - Mikko Perttunen <mperttunen@nvidia.com>, - Paul Kocialkowski <contact@paulk.fr>, - Jonathan Hunter <jonathanh@nvidia.com> -Date: Mon, 10 Jul 2017 21:33:05 +0200 - -When there is no device to attach to the IOMMU domain, as may be the -case when the device-tree does not contain the proper iommu node, it is -best to keep going without IOMMU support rather than failing. -This allows the driver to probe and function instead of taking down -all of the tegra drm driver, leading to missing display support. - -Signed-off-by: Paul Kocialkowski <contact@paulk.fr> -Reviewed-by: Mikko Perttunen <mperttunen@nvidia.com> ---- - drivers/gpu/host1x/dev.c | 8 +++++++- - 1 file changed, 7 insertions(+), 1 deletion(-) - -diff --git a/drivers/gpu/host1x/dev.c b/drivers/gpu/host1x/dev.c -index ac65f52850a6..f296738d0de8 100644 ---- a/drivers/gpu/host1x/dev.c -+++ b/drivers/gpu/host1x/dev.c -@@ -186,8 +186,13 @@ static int host1x_probe(struct platform_device *pdev) - return -ENOMEM; - - err = iommu_attach_device(host->domain, &pdev->dev); -- if (err) -+ if (err == -ENODEV) { -+ iommu_domain_free(host->domain); -+ host->domain = NULL; -+ goto iommu_skip; -+ } else if (err) { - goto fail_free_domain; -+ } - - geometry = &host->domain->geometry; - -@@ -198,6 +203,7 @@ static int host1x_probe(struct platform_device *pdev) - host->iova_end = geometry->aperture_end; - } - -+iommu_skip: - err = host1x_channel_list_init(host); - if (err) { - dev_err(&pdev->dev, "failed to initialize channel list\n"); |