media: venus: fix EOS handling in decoder stop command
authorDikshita Agarwal <quic_dikshita@quicinc.com>
Mon, 22 May 2023 06:02:52 +0000 (07:02 +0100)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Fri, 9 Jun 2023 13:02:04 +0000 (14:02 +0100)
Use firmware version based check to assign correct
device address for EOS buffer to fix the EOS handling
with different firmware version.

Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Tested-by: Nathan Hebert <nhebert@chromium.org>
Signed-off-by: Vikash Garodia <quic_vgarodia@quicinc.com>
Signed-off-by: Viswanath Boma <quic_vboma@quicinc.com>
Signed-off-by: Dikshita Agarwal <quic_dikshita@quicinc.com>
Signed-off-by: Stanimir Varbanov <stanimir.k.varbanov@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
drivers/media/platform/qcom/venus/vdec.c

index f42570a816fe7b1e8babe110e07cd8147b73f19d..c6f0fd084758db080f3097811553e99380840a13 100644 (file)
@@ -551,7 +551,7 @@ vdec_decoder_cmd(struct file *file, void *fh, struct v4l2_decoder_cmd *cmd)
 
                fdata.buffer_type = HFI_BUFFER_INPUT;
                fdata.flags |= HFI_BUFFERFLAG_EOS;
-               if (IS_V6(inst->core))
+               if (IS_V6(inst->core) && is_fw_rev_or_older(inst->core, 1, 0, 87))
                        fdata.device_addr = 0;
                else
                        fdata.device_addr = 0xdeadb000;