diff options
author | Thierry Reding <treding@nvidia.com> | 2019-09-09 15:25:45 +0300 |
---|---|---|
committer | Thierry Reding <treding@nvidia.com> | 2019-10-28 13:18:34 +0300 |
commit | 47b15779b03bf70ca5a315775d2b171c7913ebc3 (patch) | |
tree | ca167329a1ab72fca983c6e3186c181858550f4d /drivers/gpu/drm/tegra/vic.c | |
parent | 33904487f1ab1ec1f8103b1ec5dd3d26f94d9711 (diff) | |
download | linux-47b15779b03bf70ca5a315775d2b171c7913ebc3.tar.xz |
drm/tegra: Inherit device DMA parameters from host1x
The display controllers and VIC don't have any limitations on the
DMA segment size. Inherit the DMA parameters from the parent device,
which also doesn't have any such limitations.
Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'drivers/gpu/drm/tegra/vic.c')
-rw-r--r-- | drivers/gpu/drm/tegra/vic.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/gpu/drm/tegra/vic.c b/drivers/gpu/drm/tegra/vic.c index c97a61c877af..8d98b0cfc47b 100644 --- a/drivers/gpu/drm/tegra/vic.c +++ b/drivers/gpu/drm/tegra/vic.c @@ -214,6 +214,12 @@ static int vic_init(struct host1x_client *client) if (err < 0) goto free_syncpt; + /* + * Inherit the DMA parameters (such as maximum segment size) from the + * parent device. + */ + client->dev->dma_parms = client->parent->dma_parms; + return 0; free_syncpt: @@ -236,6 +242,9 @@ static int vic_exit(struct host1x_client *client) struct vic *vic = to_vic(drm); int err; + /* avoid a dangling pointer just in case this disappears */ + client->dev->dma_parms = NULL; + err = tegra_drm_unregister_client(tegra, drm); if (err < 0) return err; |