media: hantro: remove an unnecessary NULL check
Thus the address of "&ctx->dev->variant->codec_ops[codec_mode]" can't possibly be NULL. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com> [hverkuil-cisco@xs4all.nl: rebased after rockchip/vpu -> hantro rename] Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
This commit is contained in:
parent
4b1f67dc8e
commit
94b5bf3ac9
@ -613,7 +613,7 @@ static int hantro_start_streaming(struct vb2_queue *q, unsigned int count)
|
||||
|
||||
vpu_debug(4, "Codec mode = %d\n", codec_mode);
|
||||
ctx->codec_ops = &ctx->dev->variant->codec_ops[codec_mode];
|
||||
if (ctx->codec_ops && ctx->codec_ops->init)
|
||||
if (ctx->codec_ops->init)
|
||||
ret = ctx->codec_ops->init(ctx);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user