diff options
| author | Dmitry Antipov <dantipov@nvidia.com> | 2018-12-28 07:56:36 -0500 |
|---|---|---|
| committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2019-04-23 11:49:20 -0400 |
| commit | db5d314a034ae81c499e76834a72a8f8a2e37c8b (patch) | |
| tree | f305c0661e96d048e6c25cfb57ff3b03903d8e08 /include/uapi/linux | |
| parent | 3036d56ce99019befc1766072ea1d48b75ebc925 (diff) | |
video: tegra: host: nvdla, pva: add task information to fences
For NSys, we're interested in having detailed information on what task
waits on a particular prefence or requests a particular postfence.
This is implemented by adding two extra fields, 'task_syncpt_id' and
'task_syncpt_thresh' to 'struct nvhost_task_fence', to record the task
this particular fence is associated with.
To avoid race conditon in pva_submit (similar to what was fixed in
0c2065fd669926536f79fd9e8ec33f33cbdcae2e), PVA task memory management
is changed to use simple kref-based scheme, much like it's done in DLA.
Finally, this patch renames syncpoint fields of 'task_fence' to 'syncpt_id'
and 'syncpt_thresh' to match the same field names in other events, which
is intended to simplify Python scripting.
JIRA DTSP-1662
JIRA DTSP-682
Bug 2568514
Signed-off-by: Dmitry Antipov <dantipov@nvidia.com>
Change-Id: I4c55efcae15eb80a0d950882d6ff6e5ac706ab20
Reviewed-on: https://git-master.nvidia.com/r/1978175
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com>
Reviewed-by: Shridhar Rasal <srasal@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Prashant Gaikwad <pgaikwad@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/2099982
Reviewed-by: Mitch Harwell <mharwell@nvidia.com>
Tested-by: Mitch Harwell <mharwell@nvidia.com>
Diffstat (limited to 'include/uapi/linux')
| -rw-r--r-- | include/uapi/linux/nvhost_events.h | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/include/uapi/linux/nvhost_events.h b/include/uapi/linux/nvhost_events.h index 7399906eb..1c1fd7229 100644 --- a/include/uapi/linux/nvhost_events.h +++ b/include/uapi/linux/nvhost_events.h | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* | 1 | /* |
| 2 | * Eventlib interface for PVA | 2 | * Eventlib interface for PVA |
| 3 | * | 3 | * |
| 4 | * Copyright (c) 2016-2018, NVIDIA Corporation. All rights reserved. | 4 | * Copyright (c) 2016-2019, NVIDIA Corporation. All rights reserved. |
| 5 | * | 5 | * |
| 6 | * This program is free software; you can redistribute it and/or modify it | 6 | * This program is free software; you can redistribute it and/or modify it |
| 7 | * under the terms and conditions of the GNU General Public License, | 7 | * under the terms and conditions of the GNU General Public License, |
| @@ -98,12 +98,16 @@ struct nvhost_task_fence { | |||
| 98 | /* Kind (prefence or postfence) */ | 98 | /* Kind (prefence or postfence) */ |
| 99 | u32 kind; | 99 | u32 kind; |
| 100 | 100 | ||
| 101 | /* Type (see nvdev_fence.h) */ | 101 | /* Fence-specific type (see nvdev_fence.h) */ |
| 102 | u32 type; | 102 | u32 fence_type; |
| 103 | 103 | ||
| 104 | /* Valid for NVDEV_FENCE_TYPE_SYNCPT only */ | 104 | /* Valid for NVDEV_FENCE_TYPE_SYNCPT only */ |
| 105 | u32 syncpoint_index; | 105 | u32 syncpt_id; |
| 106 | u32 syncpoint_value; | 106 | u32 syncpt_thresh; |
| 107 | |||
| 108 | /* The task this fence is associated with */ | ||
| 109 | u32 task_syncpt_id; | ||
| 110 | u32 task_syncpt_thresh; | ||
| 107 | 111 | ||
| 108 | /* Valid for NVDEV_FENCE_TYPE_SYNC_FD only */ | 112 | /* Valid for NVDEV_FENCE_TYPE_SYNC_FD only */ |
| 109 | u32 sync_fd; | 113 | u32 sync_fd; |
