Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

ASoC: codecs: tlv320aic32x4: Fix Wvoid-pointer-to-enum-cast warning

'type' is an enum, thus cast of pointer on 64-bit compile test with W=1
causes:

tlv320aic32x4.c:1352:18: error: cast to smaller integer type 'enum aic32x4_type' from 'void *' [-Werror,-Wvoid-pointer-to-enum-cast]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20230815143204.379708-1-krzysztof.kozlowski@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Krzysztof Kozlowski and committed by
Mark Brown
66de320b 7f0315de

+1 -1
+1 -1
sound/soc/codecs/tlv320aic32x4.c
··· 1349 1349 return -ENOMEM; 1350 1350 1351 1351 aic32x4->dev = dev; 1352 - aic32x4->type = (enum aic32x4_type)dev_get_drvdata(dev); 1352 + aic32x4->type = (uintptr_t)dev_get_drvdata(dev); 1353 1353 1354 1354 dev_set_drvdata(dev, aic32x4); 1355 1355