diff options
author | Mikko Perttunen <mperttunen@nvidia.com> | 2022-06-27 17:19:53 +0300 |
---|---|---|
committer | Thierry Reding <treding@nvidia.com> | 2022-07-08 16:27:52 +0200 |
commit | e09db97889ec647ad373f7a7422c83099c6120c5 (patch) | |
tree | 32f642ec3be9e19ac790f325414cb660b0edefd4 /drivers/gpu/drm/tegra/drm.h | |
parent | 88c0292f023da4e4753a271430a36a66e6fb974f (diff) | |
download | linux-stable-e09db97889ec647ad373f7a7422c83099c6120c5.tar.gz linux-stable-e09db97889ec647ad373f7a7422c83099c6120c5.tar.bz2 linux-stable-e09db97889ec647ad373f7a7422c83099c6120c5.zip |
drm/tegra: Support context isolation
For engines that support context isolation, allocate a context when
opening a channel, and set up stream ID offset and context fields
when submitting a job.
As of this commit, the stream ID offset and fallback stream ID
are not used when context isolation is disabled. However, with
upcoming patches that enable a full featured job opcode sequence,
these will be necessary.
Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'drivers/gpu/drm/tegra/drm.h')
-rw-r--r-- | drivers/gpu/drm/tegra/drm.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/gpu/drm/tegra/drm.h b/drivers/gpu/drm/tegra/drm.h index fc0a19554eac..2acc8f2948ad 100644 --- a/drivers/gpu/drm/tegra/drm.h +++ b/drivers/gpu/drm/tegra/drm.h @@ -80,6 +80,7 @@ struct tegra_drm_context { /* Only used by new UAPI. */ struct xarray mappings; + struct host1x_memory_context *memory_context; }; struct tegra_drm_client_ops { @@ -91,6 +92,8 @@ struct tegra_drm_client_ops { int (*submit)(struct tegra_drm_context *context, struct drm_tegra_submit *args, struct drm_device *drm, struct drm_file *file); + int (*get_streamid_offset)(struct tegra_drm_client *client, u32 *offset); + int (*can_use_memory_ctx)(struct tegra_drm_client *client, bool *supported); }; int tegra_drm_submit(struct tegra_drm_context *context, |