diff options
author | Bulbul Dabi <bdabi@codeaurora.org> | 2016-06-21 22:58:20 +0530 |
---|---|---|
committer | Robb Glasser <rglasser@google.com> | 2016-06-23 10:30:25 -0700 |
commit | 73d48e78e558ddd45ae4e245b15b60c8f2650f28 (patch) | |
tree | f1b6d673bee7ef501d8add947efe861beb11c360 | |
parent | 26de0594023a28e9bf237853d6ce31219a73361b (diff) |
msm: vidc: update the check to ignore extradata plane inandroid-n-preview-5_r0.9android-7.0.0_r0.1
dqbuf
userptr may or may not be a null-value. Checking for this field
to qualify a plane as extradata has no merit. Ignore that check
Bug: 28747768
Change-Id: I08d85ef462f09003aaa17f6ebc5d27de7083796f
Signed-off-by: Praveen Chavan <pchavan@codeaurora.org>
Signed-off-by: Praneeth Paladugu <ppaladug@codeaurora.org>
-rw-r--r-- | drivers/media/platform/msm/vidc/msm_vidc.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/media/platform/msm/vidc/msm_vidc.c b/drivers/media/platform/msm/vidc/msm_vidc.c index 6a4620a3e16f..ff1b2177f147 100644 --- a/drivers/media/platform/msm/vidc/msm_vidc.c +++ b/drivers/media/platform/msm/vidc/msm_vidc.c @@ -259,11 +259,11 @@ struct buffer_info *get_registered_buf(struct msm_vidc_inst *inst, list_for_each_entry(temp, &inst->registeredbufs.list, list) { for (i = 0; (i < temp->num_planes) && (i < VIDEO_MAX_PLANES); i++) { - bool ion_hndl_matches = + bool ion_hndl_matches = temp->handle[i] ? msm_smem_compare_buffers(inst->mem_client, fd, - temp->handle[i]->smem_priv); + temp->handle[i]->smem_priv) : false; if (temp && - ((fd == temp->fd[i]) || + (ion_hndl_matches || (device_addr == temp->device_addr[i])) && (CONTAINS(temp->buff_off[i], temp->size[i], buff_off) @@ -271,7 +271,7 @@ struct buffer_info *get_registered_buf(struct msm_vidc_inst *inst, size, temp->buff_off[i]) || OVERLAPS(buff_off, size, temp->buff_off[i], - temp->size[i])) && ion_hndl_matches) { + temp->size[i]))) { dprintk(VIDC_DBG, "This memory region is already mapped\n"); ret = temp; @@ -1000,8 +1000,8 @@ int msm_vidc_dqbuf(void *instance, struct v4l2_buffer *b) if (!inst->map_output_buffer) continue; if (EXTRADATA_IDX(b->length) && - (i == EXTRADATA_IDX(b->length)) && - !b->m.planes[i].m.userptr) { + i == EXTRADATA_IDX(b->length)) + { continue; } buffer_info = device_to_uvaddr(&inst->registeredbufs, |