diff options
author | Mikko Perttunen <mperttunen@nvidia.com> | 2021-06-10 14:04:45 +0300 |
---|---|---|
committer | Thierry Reding <treding@nvidia.com> | 2021-08-10 14:41:19 +0200 |
commit | e902585fc8b639f1a1258eaa6265e98994e34ef8 (patch) | |
tree | 58bb0fab112f61f6bfcc198d36a0e0cd5d98a516 /drivers/gpu/host1x/job.h | |
parent | 17a298e9ac7c011e64a9c0b6f807b43f9af22eac (diff) |
gpu: host1x: Add support for syncpoint waits in CDMA pushbuffer
Add support for inserting syncpoint waits in the CDMA pushbuffer.
These waits need to be done in HOST1X class, while gather submitted
by the application execute in engine class.
Support is added by converting the gather list of job into a command
list that can include both gathers and waits. When the job is
submitted, these commands are pushed as the appropriate opcodes
on the CDMA pushbuffer.
Also supported are waits relative to the start of the job,
which are useful for jobs doing multiple things with an engine
that doesn't natively support pipelining.
While at it, use 32-bit waits on chips that support them.
Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'drivers/gpu/host1x/job.h')
-rw-r--r-- | drivers/gpu/host1x/job.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/gpu/host1x/job.h b/drivers/gpu/host1x/job.h index 94bc2e4ae241..b4428c5495c9 100644 --- a/drivers/gpu/host1x/job.h +++ b/drivers/gpu/host1x/job.h @@ -18,6 +18,22 @@ struct host1x_job_gather { bool handled; }; +struct host1x_job_wait { + u32 id; + u32 threshold; + u32 next_class; + bool relative; +}; + +struct host1x_job_cmd { + bool is_wait; + + union { + struct host1x_job_gather gather; + struct host1x_job_wait wait; + }; +}; + struct host1x_job_unpin_data { struct host1x_bo *bo; struct sg_table *sgt; |