diff options
| author | Rob Herring <[email protected]> | 2023-03-10 14:47:31 +0000 |
|---|---|---|
| committer | Mark Brown <[email protected]> | 2023-03-11 12:18:54 +0000 |
| commit | 1e108e60a44a924e3666fa2a10b53f6c31522856 (patch) | |
| tree | 6dc8938b5b7f0f678ea0a9ba0974341b45eceb5c /sound/soc/stm/stm32_i2s.c | |
| parent | ASoC: SOF: Intel: MTL: Don't access EM2 (diff) | |
| download | kernel-1e108e60a44a924e3666fa2a10b53f6c31522856.tar.gz kernel-1e108e60a44a924e3666fa2a10b53f6c31522856.zip | |
ASoC: Use of_property_present() for testing DT property presence
It is preferred to use typed property access functions (i.e.
of_property_read_<type> functions) rather than low-level
of_get_property/of_find_property functions for reading properties. As
part of this, convert of_get_property/of_find_property calls to the
recently added of_property_present() helper when we just want to test
for presence of a property and nothing more.
Signed-off-by: Rob Herring <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Mark Brown <[email protected]>
Diffstat (limited to 'sound/soc/stm/stm32_i2s.c')
| -rw-r--r-- | sound/soc/stm/stm32_i2s.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/stm/stm32_i2s.c b/sound/soc/stm/stm32_i2s.c index f3dd9f8e621c..9dad85ecb93f 100644 --- a/sound/soc/stm/stm32_i2s.c +++ b/sound/soc/stm/stm32_i2s.c @@ -1066,7 +1066,7 @@ static int stm32_i2s_parse_dt(struct platform_device *pdev, "Could not get x11k parent clock\n"); /* Register mclk provider if requested */ - if (of_find_property(np, "#clock-cells", NULL)) { + if (of_property_present(np, "#clock-cells")) { ret = stm32_i2s_add_mclk_provider(i2s); if (ret < 0) return ret; |
