diff mbox series

[2/2] media: venus: vdec: ensure venus is powered on during stream off

Message ID 1649747356-3207-3-git-send-email-quic_vgarodia@quicinc.com (mailing list archive)
State New, archived
Headers show
Series Venus fixes | expand

Commit Message

Vikash Garodia April 12, 2022, 7:09 a.m. UTC
Video decoder driver auto-suspends the hardware if there is no
exchange of command or response for certain amount of time.
In auto suspended state, it becomes mandatory to power on the
hardware before requesting it to process a command. The fix
ensures the hardware is powered on during stop streaming.
---
 drivers/media/platform/qcom/venus/vdec.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Stanimir Varbanov April 12, 2022, 10:12 a.m. UTC | #1
Hi Vikash,

On 4/12/22 10:09, Vikash Garodia wrote:
> Video decoder driver auto-suspends the hardware if there is no
> exchange of command or response for certain amount of time.
> In auto suspended state, it becomes mandatory to power on the
> hardware before requesting it to process a command. The fix
> ensures the hardware is powered on during stop streaming.
> ---
>  drivers/media/platform/qcom/venus/vdec.c | 2 ++
>  1 file changed, 2 insertions(+)

Acked-by: Stanimir Varbanov <stanimir.varbanov@linaro.org>

> 
> diff --git a/drivers/media/platform/qcom/venus/vdec.c b/drivers/media/platform/qcom/venus/vdec.c
> index 91da3f5..4ac1132 100644
> --- a/drivers/media/platform/qcom/venus/vdec.c
> +++ b/drivers/media/platform/qcom/venus/vdec.c
> @@ -1200,6 +1200,8 @@ static void vdec_stop_streaming(struct vb2_queue *q)
>  	struct venus_inst *inst = vb2_get_drv_priv(q);
>  	int ret = -EINVAL;
>  
> +	vdec_pm_get_put(inst);
> +
>  	mutex_lock(&inst->lock);
>  
>  	if (q->type == V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE)
diff mbox series

Patch

diff --git a/drivers/media/platform/qcom/venus/vdec.c b/drivers/media/platform/qcom/venus/vdec.c
index 91da3f5..4ac1132 100644
--- a/drivers/media/platform/qcom/venus/vdec.c
+++ b/drivers/media/platform/qcom/venus/vdec.c
@@ -1200,6 +1200,8 @@  static void vdec_stop_streaming(struct vb2_queue *q)
 	struct venus_inst *inst = vb2_get_drv_priv(q);
 	int ret = -EINVAL;
 
+	vdec_pm_get_put(inst);
+
 	mutex_lock(&inst->lock);
 
 	if (q->type == V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE)