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: samsung: odroid: use of_property_present to check for property

"samsung,audio-widgets" and "samsung,audio-routing" are not boolean
properties, thus more appropriate is to use of_property_present() to
check if they are present.

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

authored by

Krzysztof Kozlowski and committed by
Mark Brown
ebba2fd5 631e9d4b

+2 -2
+2 -2
sound/soc/samsung/odroid.c
··· 223 223 if (ret < 0) 224 224 return ret; 225 225 226 - if (of_property_read_bool(dev->of_node, "samsung,audio-widgets")) { 226 + if (of_property_present(dev->of_node, "samsung,audio-widgets")) { 227 227 ret = snd_soc_of_parse_audio_simple_widgets(card, 228 228 "samsung,audio-widgets"); 229 229 if (ret < 0) 230 230 return ret; 231 231 } 232 232 233 - if (of_property_read_bool(dev->of_node, "samsung,audio-routing")) { 233 + if (of_property_present(dev->of_node, "samsung,audio-routing")) { 234 234 ret = snd_soc_of_parse_audio_routing(card, 235 235 "samsung,audio-routing"); 236 236 if (ret < 0)