summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/tegra/vic.h
diff options
context:
space:
mode:
authorArto Merilainen <amerilainen@nvidia.com>2016-12-14 13:16:13 +0200
committerThierry Reding <treding@nvidia.com>2017-04-05 18:11:48 +0200
commit0ae797a8ba05a2354db5e81c1d7df04671dd1c25 (patch)
treecd5a0fe4e47593fdafb7555f63003c89870e99b1 /drivers/gpu/drm/tegra/vic.h
parent6cc5f00f34c4c1a4891f976b71c0fb1c54a820ab (diff)
downloadlinux-0ae797a8ba05a2354db5e81c1d7df04671dd1c25.tar.bz2
drm/tegra: Add VIC support
This patch adds support for Video Image Compositor engine which can be used for 2d operations. Signed-off-by: Andrew Chew <achew@nvidia.com> Signed-off-by: Arto Merilainen <amerilainen@nvidia.com> Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'drivers/gpu/drm/tegra/vic.h')
-rw-r--r--drivers/gpu/drm/tegra/vic.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/drivers/gpu/drm/tegra/vic.h b/drivers/gpu/drm/tegra/vic.h
new file mode 100644
index 000000000000..21844817a7e1
--- /dev/null
+++ b/drivers/gpu/drm/tegra/vic.h
@@ -0,0 +1,31 @@
+/*
+ * Copyright (c) 2015, NVIDIA Corporation.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#ifndef TEGRA_VIC_H
+#define TEGRA_VIC_H
+
+/* VIC methods */
+
+#define VIC_SET_APPLICATION_ID 0x00000200
+#define VIC_SET_FCE_UCODE_SIZE 0x0000071C
+#define VIC_SET_FCE_UCODE_OFFSET 0x0000072C
+
+/* VIC registers */
+
+#define NV_PVIC_MISC_PRI_VIC_CG 0x000016d0
+#define CG_IDLE_CG_DLY_CNT(val) ((val & 0x3f) << 0)
+#define CG_IDLE_CG_EN (1 << 6)
+#define CG_WAKEUP_DLY_CNT(val) ((val & 0xf) << 16)
+
+/* Firmware offsets */
+
+#define VIC_UCODE_FCE_HEADER_OFFSET (6*4)
+#define VIC_UCODE_FCE_DATA_OFFSET (7*4)
+#define FCE_UCODE_SIZE_OFFSET (2*4)
+
+#endif /* TEGRA_VIC_H */