]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
media: mtk-mdp: address a clang warning
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Wed, 24 Nov 2021 11:56:50 +0000 (11:56 +0000)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Mon, 29 Nov 2021 12:23:25 +0000 (13:23 +0100)
The typecasts at the dvb-core generate clang warnings when W=1
is enabled.

Such warning is harmless, but it causes the build to break with
CONFIG_WERROR and W=1 with clang, so do the cast on a way that
it won't produce warnings anymore.

Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/platform/mtk-mdp/mtk_mdp_core.c

index 976aa1f4829b8d6195838d5a3b3fd7d711f1c6e3..3d38793aaa25abf08f925369d09f0a04ac27fa56 100644 (file)
@@ -148,7 +148,7 @@ static int mtk_mdp_probe(struct platform_device *pdev)
                        continue;
                }
 
-               comp_type = (enum mtk_mdp_comp_type)of_id->data;
+               comp_type = (uintptr_t)of_id->data;
 
                comp = devm_kzalloc(dev, sizeof(*comp), GFP_KERNEL);
                if (!comp) {