[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20250325213455.3952361-1-m.felsch@pengutronix.de>
Date: Tue, 25 Mar 2025 22:34:53 +0100
From: Marco Felsch <m.felsch@...gutronix.de>
To: lgirdwood@...il.com,
broonie@...nel.org,
perex@...ex.cz,
tiwai@...e.com,
robh@...nel.org
Cc: kernel@...gutronix.de,
linux-sound@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: [PATCH 1/2] ASoC: soc-core: fix bitclock-master and frame-master present check
To check for a none boolean property of_property_present() should be
used instead of of_property_read_bool(). The later returns a warning
since commit c141ecc3cecd ("of: Warn when of_property_read_bool() is used
on non-boolean properties").
Fixes: 69dd15a8ef0a ("ASoC: Use of_property_read_bool()")
Signed-off-by: Marco Felsch <m.felsch@...gutronix.de>
---
sound/soc/soc-core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c
index 3c6d8aef4130..1e0cdd778a3b 100644
--- a/sound/soc/soc-core.c
+++ b/sound/soc/soc-core.c
@@ -3403,12 +3403,12 @@ unsigned int snd_soc_daifmt_parse_clock_provider_raw(struct device_node *np,
* check "[prefix]frame-master"
*/
snprintf(prop, sizeof(prop), "%sbitclock-master", prefix);
- bit = of_property_read_bool(np, prop);
+ bit = of_property_present(np, prop);
if (bit && bitclkmaster)
*bitclkmaster = of_parse_phandle(np, prop, 0);
snprintf(prop, sizeof(prop), "%sframe-master", prefix);
- frame = of_property_read_bool(np, prop);
+ frame = of_property_present(np, prop);
if (frame && framemaster)
*framemaster = of_parse_phandle(np, prop, 0);
--
2.39.5
Powered by blists - more mailing lists