diff options
author | Oded Gabbay <oded.gabbay@gmail.com> | 2019-07-15 20:55:57 +0200 |
---|---|---|
committer | Oded Gabbay <oded.gabbay@gmail.com> | 2019-09-05 13:55:26 +0200 |
commit | b888751a02e7b2bfa4c9660bd8c5af0ef886aeef (patch) | |
tree | 1a76dc607a47d6fef789fd46261799a381fe9b32 /drivers/misc/habanalabs/habanalabs.h | |
parent | habanalabs: Use dev_get_drvdata (diff) | |
download | linux-b888751a02e7b2bfa4c9660bd8c5af0ef886aeef.tar.xz linux-b888751a02e7b2bfa4c9660bd8c5af0ef886aeef.zip |
habanalabs: add handle field to context structure
This patch adds a field to the context's structure that will hold a unique
handle for the context.
This will be needed when the user will create the context.
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to '')
-rw-r--r-- | drivers/misc/habanalabs/habanalabs.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/misc/habanalabs/habanalabs.h b/drivers/misc/habanalabs/habanalabs.h index e041afe895cf..16f16f7c1e3a 100644 --- a/drivers/misc/habanalabs/habanalabs.h +++ b/drivers/misc/habanalabs/habanalabs.h @@ -636,6 +636,7 @@ struct hl_va_range { * execution phase before the context switch phase * has finished. * @asid: context's unique address space ID in the device's MMU. + * @handle: context's opaque handle for user */ struct hl_ctx { DECLARE_HASHTABLE(mem_hash, MEM_HASH_TABLE_BITS); @@ -657,6 +658,7 @@ struct hl_ctx { atomic_t thread_ctx_switch_token; u32 thread_ctx_switch_wait_token; u32 asid; + u32 handle; }; /** |