]> git.baikalelectronics.ru Git - kernel.git/commit
habanalabs: increment ctx ref from within a cs allocation
authorOfir Bitton <obitton@habana.ai>
Sun, 3 Jan 2021 12:13:06 +0000 (14:13 +0200)
committerOded Gabbay <ogabbay@kernel.org>
Wed, 27 Jan 2021 19:03:50 +0000 (21:03 +0200)
commit5a507f21d09047c29ab30f0ef33ad9fab6f6a430
tree501fbefbcf34ee074a3d67cdb690eb64205804c9
parent8ead9d27dadbf4f88cc829f982174f0a255b9477
habanalabs: increment ctx ref from within a cs allocation

A CS must increment the relevant context reference count.
We want to increment the reference inside the CS allocation function
as opposed for today where we increment it outside.
This is logical since we want to avoid explicitly incrementing
the context every time we call the CS allocate function.

Signed-off-by: Ofir Bitton <obitton@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
drivers/misc/habanalabs/common/command_submission.c