mirror of
https://github.com/torvalds/linux.git
synced 2026-07-27 17:47:41 +02:00
spufs_mem_mmap_access() computes the local store offset as
address - vma->vm_start, but bounds-checks it against vma->vm_end
instead of the local store size. On 64-bit, offset is always well
below vma->vm_end, so the clamp never fires and len stays unbounded
against the LS_SIZE buffer returned by ctx->ops->get_ls().
Reject offsets at or beyond LS_SIZE and clamp len to the remaining
space, mirroring the guard already used by spufs_mem_mmap_fault() and
spufs_ps_fault().
Fixes:
|
||
|---|---|---|
| .. | ||
| spufs | ||
| Kconfig | ||
| Makefile | ||
| spu_base.c | ||
| spu_callbacks.c | ||
| spu_syscalls.c | ||