diff options
author | Ofir Bitton <obitton@habana.ai> | 2020-11-10 16:26:22 +0100 |
---|---|---|
committer | Oded Gabbay <ogabbay@kernel.org> | 2020-11-30 09:47:37 +0100 |
commit | bd2f477f2037d2638464dc105f16994994308c20 (patch) | |
tree | 3588e149369b4ff6238453390b71bf4df7ecf571 /include | |
parent | habanalabs: indicate to user that a cs is gone (diff) | |
download | linux-bd2f477f2037d2638464dc105f16994994308c20.tar.xz linux-bd2f477f2037d2638464dc105f16994994308c20.zip |
habanalabs: add support for cs with timestamp
add support for user to request a timestamp upon
cs completion.
Signed-off-by: Ofir Bitton <obitton@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/uapi/misc/habanalabs.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/include/uapi/misc/habanalabs.h b/include/uapi/misc/habanalabs.h index 808d20da024a..6eff4e05eccb 100644 --- a/include/uapi/misc/habanalabs.h +++ b/include/uapi/misc/habanalabs.h @@ -592,6 +592,7 @@ struct hl_cs_chunk { #define HL_CS_FLAGS_SIGNAL 0x2 #define HL_CS_FLAGS_WAIT 0x4 #define HL_CS_FLAGS_COLLECTIVE_WAIT 0x8 +#define HL_CS_FLAGS_TIMESTAMP 0x20 #define HL_CS_STATUS_SUCCESS 0 @@ -662,13 +663,16 @@ struct hl_wait_cs_in { #define HL_WAIT_CS_STATUS_ABORTED 3 #define HL_WAIT_CS_STATUS_INTERRUPTED 4 -#define HL_WAIT_CS_STATUS_FLAG_GONE 0x1 +#define HL_WAIT_CS_STATUS_FLAG_GONE 0x1 +#define HL_WAIT_CS_STATUS_FLAG_TIMESTAMP_VLD 0x2 struct hl_wait_cs_out { /* HL_WAIT_CS_STATUS_* */ __u32 status; /* HL_WAIT_CS_STATUS_FLAG* */ __u32 flags; + /* valid only if HL_WAIT_CS_STATUS_FLAG_TIMESTAMP_VLD is set */ + __s64 timestamp_nsec; }; union hl_wait_cs_args { |