Skip to content

Commit

Permalink
media: qcom: camss: Propagate vfe_reset error up the callstack
Browse files Browse the repository at this point in the history
A previous patch I had removed the returns from vfe_disable() since we
didn't trap any meaningful errors. Konrad pointed out vfe_reset() could
return an error, which is true.

Trap the vfe_reset() error code and throw it up the callstack.

Suggested-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
  • Loading branch information
Bryan O'Donoghue authored and Hans Verkuil committed Oct 7, 2023
1 parent 90cc455 commit 5c07f30
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions drivers/media/platform/qcom/camss/camss-vfe.c
Original file line number Diff line number Diff line change
Expand Up @@ -435,8 +435,11 @@ static int vfe_disable_output(struct vfe_line *line)
int vfe_disable(struct vfe_line *line)
{
struct vfe_device *vfe = to_vfe(line);
int ret;

vfe_disable_output(line);
ret = vfe_disable_output(line);
if (ret)
goto error;

vfe_put_output(line);

Expand All @@ -446,7 +449,8 @@ int vfe_disable(struct vfe_line *line)

mutex_unlock(&vfe->stream_lock);

return 0;
error:
return ret;
}

/**
Expand Down

0 comments on commit 5c07f30

Please sign in to comment.