diff options
author | Julia Lawall <Julia.Lawall@lip6.fr> | 2016-08-05 11:56:51 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2016-08-08 13:55:05 +0300 |
commit | 519302954b726612eea6362047660cd56aa15c2e (patch) | |
tree | 656919932cd14057e3d2e04c0f1328d140ed9d13 /sound/soc/soc-core.c | |
parent | 29b4817d4018df78086157ea3a55c1d9424a7cfc (diff) | |
download | linux-519302954b726612eea6362047660cd56aa15c2e.tar.xz |
ASoC: use of_property_read_bool
Use of_property_read_bool to check for the existence of a property.
The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)
// <smpl>
@@
expression e1,e2;
statement S2,S1;
@@
- if (of_get_property(e1,e2,NULL))
+ if (of_property_read_bool(e1,e2))
S1 else S2
// </smpl>
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/soc-core.c')
-rw-r--r-- | sound/soc/soc-core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index 16369cad4803..ead49d032e4c 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -3733,7 +3733,7 @@ unsigned int snd_soc_of_parse_daifmt(struct device_node *np, * SND_SOC_DAIFMT_CLOCK_MASK area */ snprintf(prop, sizeof(prop), "%scontinuous-clock", prefix); - if (of_get_property(np, prop, NULL)) + if (of_property_read_bool(np, prop)) format |= SND_SOC_DAIFMT_CONT; else format |= SND_SOC_DAIFMT_GATED; |