aboutsummaryrefslogtreecommitdiffstats
path: root/lib/test_dynamic_debug.c
diff options
context:
space:
mode:
authorTomer Tayar <ttayar@habana.ai>2023-08-09 16:14:49 +0300
committerOded Gabbay <ogabbay@kernel.org>2023-10-09 12:37:22 +0300
commit0b75cb5b240fddf181c284d415ee77ef61b418d6 (patch)
treeeaf4beaab260e709c83a8bc54f5056385d9063db /lib/test_dynamic_debug.c
parentaccel/habanalabs: use exported size from dma_buf and not from phys_pg_pack (diff)
downloadlinux-rng-0b75cb5b240fddf181c284d415ee77ef61b418d6.tar.xz
linux-rng-0b75cb5b240fddf181c284d415ee77ef61b418d6.zip
accel/habanalabs: export dma-buf only if size/offset multiples of PAGE_SIZE
It is currently allowed for a user to export dma-buf with size and offset that are not multiples of PAGE_SIZE. The exported memory is mapped for the importer device, and there it will be rounded to PAGE_SIZE, leading to actually exporting more than the user intended to. To make the user be aware of it, accept only size and offset which are multiple of PAGE_SIZE. Signed-off-by: Tomer Tayar <ttayar@habana.ai> Reviewed-by: Oded Gabbay <ogabbay@kernel.org> Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
Diffstat (limited to 'lib/test_dynamic_debug.c')
0 files changed, 0 insertions, 0 deletions