habanalabs: skip VA block list update in reset flow
authorOmer Shpigelman <oshpigelman@habana.ai>
Thu, 14 Nov 2019 18:23:57 +0000 (18:23 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 4 Jan 2020 18:18:18 +0000 (19:18 +0100)
commit02270fc85b51a514b55ae6f6b3050de34e159e34
tree8d440388a81b3bbc3c4c06b37d242d0859b65bf8
parentce7269497052f463cb3c74f1388d352c37d24b80
habanalabs: skip VA block list update in reset flow

[ Upstream commit 71c5e55e7c077fa17c42fbda91a8d14322825c44 ]

Reduce context close time by skipping the VA block free list update in
order to avoid hard reset with open contexts.
Reset with open contexts can potentially lead to a kernel crash as the
generic pool of the MMU hops is destroyed while it is not empty because
some unmap operations are not done.
The commit affect mainly when running on simulator.

Signed-off-by: Omer Shpigelman <oshpigelman@habana.ai>
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com>
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/misc/habanalabs/memory.c