summaryrefslogtreecommitdiff
path: root/mm/mm_slot.h
diff options
context:
space:
mode:
authorPranjal Ramajor Asha Kanojiya <quic_pkanojiy@quicinc.com>2023-09-01 11:22:41 -0600
committerJeffrey Hugo <quic_jhugo@quicinc.com>2023-09-22 09:55:12 -0600
commitcb850f6f69d1ee03ca4a5746df2870cf49e90871 (patch)
tree549e9bf3751f02b156b44f17a114875816c72cf6 /mm/mm_slot.h
parenta08e0622c42f6d445604d8bc042e0f78dee09594 (diff)
accel/qaic: Remove ->size field from struct qaic_bo
->size field in struct qaic_bo stores user requested buffer size for allocate path or size of the dmabuf(PRIME). Now for allocate path driver allocates a BO of size which is PAGE_SIZE aligned, this size is already stored in base BO structure (struct drm_gem_object). So difference is ->size of struct qaic_bo stores the raw value coming from user and ->size in struct drm_gem_object stores the PAGE_SZIE aligned size. Do not use ->size from struct qaic_bo for any validation or operation instead use ->size from struct drm_gem_object since we already have allocated that much memory then why not use it. Only validate if user is trying to use more then the BO size. This make the driver more flexible. After this change ->size field of struct qaic_bo becomes redundant. Remove it. Signed-off-by: Pranjal Ramajor Asha Kanojiya <quic_pkanojiy@quicinc.com> Reviewed-by: Jeffrey Hugo <quic_jhugo@quicinc.com> Signed-off-by: Jeffrey Hugo <quic_jhugo@quicinc.com> Reviewed-by: Stanislaw Gruszka <stanislaw.gruszka@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230901172247.11410-2-quic_jhugo@quicinc.com
Diffstat (limited to 'mm/mm_slot.h')
0 files changed, 0 insertions, 0 deletions