mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-22 09:11:26 +03:00
UPSTREAM: drm/tegra: dc: Inherit DMA mask
Inherit the DMA mask from host1x (on Tegra210 and earlier) or the display hub (on Tegra186 and later). This is necessary in order to properly map buffers without SMMU support and use the maximum IOVA space available with SMMU support. Change-Id: Id1be7d4e05b611ee29581b5ea61f0f40c1d296b1 Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2545940 Reviewed-by: svc_kernel_abi <svc_kernel_abi@nvidia.com> Reviewed-by: Mikko Perttunen <mperttunen@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit
This commit is contained in:
committed by
Laxman Dewangan
parent
84c0b7be41
commit
efed2371e4
@@ -870,12 +870,19 @@ static const struct host1x_client_ops tegra_display_hub_ops = {
|
||||
|
||||
static int tegra_display_hub_probe(struct platform_device *pdev)
|
||||
{
|
||||
u64 dma_mask = dma_get_mask(pdev->dev.parent);
|
||||
struct device_node *child = NULL;
|
||||
struct tegra_display_hub *hub;
|
||||
struct clk *clk;
|
||||
unsigned int i;
|
||||
int err;
|
||||
|
||||
err = dma_coerce_mask_and_coherent(&pdev->dev, dma_mask);
|
||||
if (err < 0) {
|
||||
dev_err(&pdev->dev, "failed to set DMA mask: %d\n", err);
|
||||
return err;
|
||||
}
|
||||
|
||||
hub = devm_kzalloc(&pdev->dev, sizeof(*hub), GFP_KERNEL);
|
||||
if (!hub)
|
||||
return -ENOMEM;
|
||||
|
||||
Reference in New Issue
Block a user