]> git.baikalelectronics.ru Git - kernel.git/commit
habanalabs: proper handling of alloc size in coresight
authorOfir Bitton <obitton@habana.ai>
Thu, 6 Aug 2020 08:33:27 +0000 (11:33 +0300)
committerOded Gabbay <oded.gabbay@gmail.com>
Sat, 22 Aug 2020 09:47:57 +0000 (12:47 +0300)
commit7c71fcc2514ec3888043f68afba11a4cbab24748
tree44166f350a9a7059d09edc184434d0eab49a02e6
parent193b33897e8c30da22ab0615b2b23ae388cf29df
habanalabs: proper handling of alloc size in coresight

Allocation size can go up to 64bit but truncated to 32bit,
we should make sure it is not truncated and validate no address
overflow.

Signed-off-by: Ofir Bitton <obitton@habana.ai>
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com>
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
drivers/misc/habanalabs/common/habanalabs.h
drivers/misc/habanalabs/gaudi/gaudi_coresight.c
drivers/misc/habanalabs/goya/goya_coresight.c