habanalabs: use get_task_pid() to take PID
authorOded Gabbay <ogabbay@kernel.org>
Sat, 3 Jul 2021 08:50:32 +0000 (11:50 +0300)
committerOded Gabbay <ogabbay@kernel.org>
Sun, 29 Aug 2021 06:47:45 +0000 (09:47 +0300)
commite79e745b208b3c709cc5e689e587d04a4c0fe1bb
tree986e6ed83f64bf48014447a4d60a345085953325
parentfbcd0efefc7e32f2acb9ca5d9196306dfa3da880
habanalabs: use get_task_pid() to take PID

The previous function we used, find_get_pid(), wasn't good in case
the user process was run inside docker.

As a result, we didn't had the PID and we couldn't kill the user
process in case the device got stuck and we needed to reset the
device.

Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
drivers/misc/habanalabs/common/device.c
drivers/misc/habanalabs/common/habanalabs_drv.c