]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
habanalabs: improve security in Debug IOCTL
authorOmer Shpigelman <oshpigelman@habana.ai>
Tue, 6 Aug 2019 07:37:59 +0000 (07:37 +0000)
committerOded Gabbay <oded.gabbay@gmail.com>
Thu, 5 Sep 2019 11:55:27 +0000 (14:55 +0300)
commit9b50f539fff10a8283ac9c80e4ec344870b575b5
tree83bf37f8e3569bbb6b156e995125ded72e1b0fb7
parent8d1759329d042ecad31754c5f37b3ca5cbf106f5
habanalabs: improve security in Debug IOCTL

This patch improves the security in the Debug IOCTL.
It adds checks that:
- The register index value is in the allowed range for all opcodes.
- The event types number is in the allowed range in SPMU enable.
- The events number is in the allowed range in SPMU disable.

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>
drivers/misc/habanalabs/goya/goya_coresight.c