summaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorDmitry Antipov <dantipov@nvidia.com>2018-08-14 07:17:05 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2018-08-28 12:24:21 -0400
commitc9d85a691fc2421c9bbf5b70091bfd591d4d11ef (patch)
tree251379111446a4fb2de3b6f48533517d8f10c120 /include/linux
parent5fc742cd01013e801c90fd834c49cfbdebf53f7c (diff)
eventlib: unify NVDLA/PVA fence types and add fence recording
Bug 2170736 Change-Id: If4fdeda140bf2474a08beb2a0d7c3fc1737a1a66 Signed-off-by: Dmitry Antipov <dantipov@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1750906 Reviewed-by: Saleh Dindar <sdindar@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Colin Tracey <ctracey@nvidia.com> Reviewed-by: Prashant Gaikwad <pgaikwad@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/nvhost.h12
-rw-r--r--include/linux/nvhost_ioctl.h5
-rw-r--r--include/linux/nvhost_nvdla_ioctl.h6
3 files changed, 14 insertions, 9 deletions
diff --git a/include/linux/nvhost.h b/include/linux/nvhost.h
index c274df92e..78c95e5fc 100644
--- a/include/linux/nvhost.h
+++ b/include/linux/nvhost.h
@@ -49,6 +49,7 @@ struct nvhost_as_moduleops;
49struct nvhost_ctrl_sync_fence_info; 49struct nvhost_ctrl_sync_fence_info;
50struct nvhost_sync_timeline; 50struct nvhost_sync_timeline;
51struct nvhost_sync_pt; 51struct nvhost_sync_pt;
52struct nvdev_fence;
52struct sync_pt; 53struct sync_pt;
53 54
54#define NVHOST_MODULE_MAX_CLOCKS 8 55#define NVHOST_MODULE_MAX_CLOCKS 8
@@ -653,6 +654,12 @@ static inline void nvhost_eventlib_log_submit(struct platform_device *pdev,
653 u64 timestamp) 654 u64 timestamp)
654{ 655{
655} 656}
657static inline void nvhost_eventlib_log_fence(struct platform_device *pdev,
658 u32 kind,
659 struct nvdev_fence *fence,
660 u64 timestamp)
661{
662}
656#else 663#else
657 664
658#ifdef CONFIG_DEBUG_FS 665#ifdef CONFIG_DEBUG_FS
@@ -765,6 +772,11 @@ void nvhost_eventlib_log_submit(struct platform_device *pdev,
765 u32 syncpt_thresh, 772 u32 syncpt_thresh,
766 u64 timestamp); 773 u64 timestamp);
767 774
775void nvhost_eventlib_log_fence(struct platform_device *pdev,
776 u32 kind,
777 struct nvdev_fence *fence,
778 u64 timestamp);
779
768/* public host1x interrupt management APIs */ 780/* public host1x interrupt management APIs */
769int nvhost_intr_register_notifier(struct platform_device *pdev, 781int nvhost_intr_register_notifier(struct platform_device *pdev,
770 u32 id, u32 thresh, 782 u32 id, u32 thresh,
diff --git a/include/linux/nvhost_ioctl.h b/include/linux/nvhost_ioctl.h
index ad3505fc9..c1b3df572 100644
--- a/include/linux/nvhost_ioctl.h
+++ b/include/linux/nvhost_ioctl.h
@@ -122,11 +122,6 @@ struct nvhost_set_nvmap_fd_args {
122 __u32 fd; 122 __u32 fd;
123} __packed; 123} __packed;
124 124
125struct nvhost_fence {
126 __u32 syncpt_id; /* syncpoint id or sync fence fd */
127 __u32 value; /* syncpoint value (discarded when using sync fence) */
128};
129
130enum nvhost_clk_attr { 125enum nvhost_clk_attr {
131 NVHOST_CLOCK = 0, 126 NVHOST_CLOCK = 0,
132 NVHOST_BW, 127 NVHOST_BW,
diff --git a/include/linux/nvhost_nvdla_ioctl.h b/include/linux/nvhost_nvdla_ioctl.h
index 0195a450e..10c1fcfa5 100644
--- a/include/linux/nvhost_nvdla_ioctl.h
+++ b/include/linux/nvhost_nvdla_ioctl.h
@@ -175,10 +175,8 @@ struct nvdla_ioctl_emu_submit_task {
175/** 175/**
176 * struct nvdla_fence structure for passing fence information 176 * struct nvdla_fence structure for passing fence information
177 * 177 *
178 * @type type of fence: syncpoint, Linux Sync Fd 178 * NOTE: this will be removed soon, please use generic fence type
179 * @syncpoint_index syncpoint id 179 * from nvdev_fence.h
180 * @syncpoint_value value of syncpoint id
181 * @sync_fd Linux sync FD handle
182 */ 180 */
183struct nvdla_fence { 181struct nvdla_fence {
184 __u32 type; 182 __u32 type;