[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ef3aaee1-e6ca-a89d-e002-42bf918736f4@collabora.com>
Date: Thu, 1 Jun 2023 11:29:47 +0200
From: AngeloGioacchino Del Regno
<angelogioacchino.delregno@...labora.com>
To: Yunfei Dong <yunfei.dong@...iatek.com>,
Chen-Yu Tsai <wenst@...omium.org>,
Nicolas Dufresne <nicolas.dufresne@...labora.com>,
Hans Verkuil <hverkuil-cisco@...all.nl>,
Benjamin Gaignard <benjamin.gaignard@...labora.com>,
NĂcolas F . R . A . Prado
<nfraprado@...labora.com>, Nathan Hebert <nhebert@...omium.org>
Cc: Hsin-Yi Wang <hsinyi@...omium.org>,
Fritz Koenig <frkoenig@...omium.org>,
Daniel Vetter <daniel@...ll.ch>,
Steve Cho <stevecho@...omium.org>, linux-media@...r.kernel.org,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org,
linux-mediatek@...ts.infradead.org,
Project_Global_Chrome_Upstream_Group@...iatek.com
Subject: Re: [PATCH 4/8] mediatek: vcodec: remove the dependency of debug log
Il 01/06/23 05:02, Yunfei Dong ha scritto:
> 'mtk_vcodec_debug' and 'mtk_vcodec_err' depends on 'mtk_vcodec_ctx'
> to get the index of each instance, using the index directly instead
> of with 'mtk_vcodec_ctx'.
>
> Signed-off-by: Yunfei Dong <yunfei.dong@...iatek.com>
> ---
> .../mediatek/vcodec/mtk_vcodec_util.h | 36 +++--
> .../vcodec/vdec/vdec_av1_req_lat_if.c | 78 +++++------
> .../mediatek/vcodec/vdec/vdec_h264_if.c | 46 +++----
> .../mediatek/vcodec/vdec/vdec_h264_req_if.c | 32 ++---
> .../vcodec/vdec/vdec_h264_req_multi_if.c | 62 ++++-----
> .../vcodec/vdec/vdec_hevc_req_multi_if.c | 54 ++++----
> .../mediatek/vcodec/vdec/vdec_vp8_if.c | 38 +++---
> .../mediatek/vcodec/vdec/vdec_vp8_req_if.c | 36 ++---
> .../mediatek/vcodec/vdec/vdec_vp9_if.c | 128 +++++++++---------
> .../vcodec/vdec/vdec_vp9_req_lat_if.c | 67 ++++-----
> .../platform/mediatek/vcodec/vdec_vpu_if.c | 48 +++----
> .../mediatek/vcodec/venc/venc_h264_if.c | 74 +++++-----
> .../mediatek/vcodec/venc/venc_vp8_if.c | 44 +++---
> .../platform/mediatek/vcodec/venc_vpu_if.c | 54 ++++----
> 14 files changed, 399 insertions(+), 398 deletions(-)
>
> diff --git a/drivers/media/platform/mediatek/vcodec/mtk_vcodec_util.h b/drivers/media/platform/mediatek/vcodec/mtk_vcodec_util.h
> index ecb0bdf3a4f4..f018af38b39d 100644
> --- a/drivers/media/platform/mediatek/vcodec/mtk_vcodec_util.h
> +++ b/drivers/media/platform/mediatek/vcodec/mtk_vcodec_util.h
> @@ -31,42 +31,38 @@ struct mtk_vcodec_dev;
> #define mtk_v4l2_err(fmt, args...) \
> pr_err("[MTK_V4L2][ERROR] " fmt "\n", ##args)
>
> -#define mtk_vcodec_err(h, fmt, args...) \
> - pr_err("[MTK_VCODEC][ERROR][%d]: " fmt "\n", \
> - ((struct mtk_vcodec_ctx *)(h)->ctx)->id, ##args)
> +#define mtk_vcodec_err(inst_id, fmt, args...) \
> + pr_err("[MTK_VCODEC][ERROR][%d]: " fmt "\n", inst_id, ##args)
>
This *huge* cleanup (congrats btw!) would be a great occasion to change those
pr_err() to dev_err(). Can we do that?
Regards,
Angelo
Powered by blists - more mailing lists