summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/tegra/vic.c
diff options
context:
space:
mode:
authorMikko Perttunen <mperttunen@nvidia.com>2021-01-12 13:37:07 +0200
committerThierry Reding <treding@nvidia.com>2021-01-15 17:16:03 +0100
commit59e520a695e7c775d787d7108becc2662bde8061 (patch)
treebfee6dd6c1e2e968b52410f3e5390b5e0d2e3c44 /drivers/gpu/drm/tegra/vic.c
parent58ef3aeb9ac3b2c542d85a2e6b4af8ff12c09b68 (diff)
downloadlinux-59e520a695e7c775d787d7108becc2662bde8061.tar.bz2
drm/tegra: vic: Add comments on STREAMID registers
Add comments clarifying use of the THI_STREAMID0 and THI_STREAMID1 registers. Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com> 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.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/gpu/drm/tegra/vic.c b/drivers/gpu/drm/tegra/vic.c
index a3dbb8813faf..48e98a60ab6e 100644
--- a/drivers/gpu/drm/tegra/vic.c
+++ b/drivers/gpu/drm/tegra/vic.c
@@ -117,7 +117,19 @@ static int vic_boot(struct vic *vic)
if (spec->num_ids > 0) {
value = spec->ids[0] & 0xffff;
+ /*
+ * STREAMID0 is used for input/output buffers.
+ * Initialize it to SID_VIC in case context isolation
+ * is not enabled, and SID_VIC is used for both firmware
+ * and data buffers.
+ *
+ * If context isolation is enabled, it will be
+ * overridden by the SETSTREAMID opcode as part of
+ * each job.
+ */
vic_writel(vic, value, VIC_THI_STREAMID0);
+
+ /* STREAMID1 is used for firmware loading. */
vic_writel(vic, value, VIC_THI_STREAMID1);
}
}