gpu: nvgpu: allow all sizes in access fb API

For IOCTL NVGPU_DBG_GPU_IOCTL_ACCESS_FB_MEMORY, we do not allow size of buffer
which is not 4 byte aligned

Remove this hard restriction and allow non 4 byte aligned buffer sizes too
since we don't really need to enforce this restriction

Bug 2265535

Change-Id: Ic4d60604be3698e8629f2b289c9e2d19e20ea525
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1784511
Reviewed-by: Kajetan Dutka <kdutka@nvidia.com>
Tested-by: Kajetan Dutka <kdutka@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Vinod Gopalakrishnakurup <vinodg@nvidia.com>
Reviewed-by: Alex Waterman <alexw@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Deepak Nibade
2018-07-24 13:23:58 +05:30
committed by mobile promotions
parent b4b1fb97bd
commit b79c350d68

View File

@@ -1561,7 +1561,7 @@ static int nvgpu_dbg_gpu_ioctl_access_fb_memory(struct dbg_session_gk20a *dbg_s,
u64 access_limit_size = SZ_4K; u64 access_limit_size = SZ_4K;
int err = 0; int err = 0;
if ((args->offset & 3) || (!args->size) || (args->size & 3)) if ((args->offset & 3) || (!args->size))
return -EINVAL; return -EINVAL;
dmabuf = dma_buf_get(args->dmabuf_fd); dmabuf = dma_buf_get(args->dmabuf_fd);