diff options
author | Yang Li <yang.lee@linux.alibaba.com> | 2022-03-16 01:14:11 +0100 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@kernel.org> | 2022-03-18 06:05:43 +0100 |
commit | 71e6d0608e4d1b79069990c7dacb3600ced28a3b (patch) | |
tree | da3a8bde66ad6810f72df52b98aaba14ca643504 /drivers/media | |
parent | 5d1ca138026ed133f3d11fe0785de82bdee3c648 (diff) | |
download | linux-71e6d0608e4d1b79069990c7dacb3600ced28a3b.tar.bz2 |
media: platform: Remove unnecessary print function dev_err()
The print function dev_err() is redundant because platform_get_irq()
already prints an error.
Eliminate the follow coccicheck warnings:
./drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_drv.c:119:2-9:
line 119 is redundant because platform_get_irq() already prints an error
./drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_hw.c:103:2-9:
line 103 is redundant because platform_get_irq() already prints an error
Link: https://lore.kernel.org/linux-media/20220316001411.80167-1-yang.lee@linux.alibaba.com
Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_drv.c | 4 | ||||
-rw-r--r-- | drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_hw.c | 4 |
2 files changed, 2 insertions, 6 deletions
diff --git a/drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_drv.c b/drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_drv.c index 48dad9bb13d2..df7b25e9cbc8 100644 --- a/drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_drv.c +++ b/drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_drv.c @@ -115,10 +115,8 @@ static int mtk_vcodec_init_dec_resources(struct mtk_vcodec_dev *dev) return 0; dev->dec_irq = platform_get_irq(pdev, 0); - if (dev->dec_irq < 0) { - dev_err(&pdev->dev, "failed to get irq number"); + if (dev->dec_irq < 0) return dev->dec_irq; - } irq_set_status_flags(dev->dec_irq, IRQ_NOAUTOEN); ret = devm_request_irq(&pdev->dev, dev->dec_irq, diff --git a/drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_hw.c b/drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_hw.c index 60da59611434..14bed2bd4283 100644 --- a/drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_hw.c +++ b/drivers/media/platform/mediatek/vcodec/mtk_vcodec_dec_hw.c @@ -101,10 +101,8 @@ static int mtk_vdec_hw_init_irq(struct mtk_vdec_hw_dev *dev) int ret; dev->dec_irq = platform_get_irq(pdev, 0); - if (dev->dec_irq < 0) { - dev_err(&pdev->dev, "Failed to get irq resource"); + if (dev->dec_irq < 0) return dev->dec_irq; - } irq_set_status_flags(dev->dec_irq, IRQ_NOAUTOEN); ret = devm_request_irq(&pdev->dev, dev->dec_irq, |