diff --git a/drivers/gpu/nvgpu/os/linux/ioctl_ctrl.c b/drivers/gpu/nvgpu/os/linux/ioctl_ctrl.c index 08c3fd281..e21cdf792 100644 --- a/drivers/gpu/nvgpu/os/linux/ioctl_ctrl.c +++ b/drivers/gpu/nvgpu/os/linux/ioctl_ctrl.c @@ -1958,7 +1958,7 @@ int gk20a_ctrl_dev_mmap(struct file *filp, struct vm_area_struct *vma) if (priv->usermode_vma.vma != NULL) return -EBUSY; - if (vma->vm_end - vma->vm_start < PAGE_SIZE) + if (vma->vm_end - vma->vm_start > SZ_64K) return -EINVAL; if (vma->vm_pgoff != 0UL)