From: Xiubo Li
Date: Thu, 23 Jan 2014 05:02:47 +0000 (+0800)
Subject: ASoC: core: set_tdm_slot() will return -ENOTSUPP if no operation provided
X-Git-Tag: firefly_0821_release~176^2~4090^2~1^2~3^2~7^2~10
X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=b2cbb6e1c1544fc889ee7d6c6a6c229c20cd03cd;p=firefly-linux-kernel-4.4.55.git
ASoC: core: set_tdm_slot() will return -ENOTSUPP if no operation provided
Make it easier for generic code to work with set_tdm_slot() by distinguishing
between the operation not being supported and an error as is done.
Signed-off-by: Xiubo Li
Signed-off-by: Mark Brown
---
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c
index fe1df50805a3..393ff069af69 100644
--- a/sound/soc/soc-core.c
+++ b/sound/soc/soc-core.c
@@ -3626,7 +3626,7 @@ int snd_soc_dai_set_tdm_slot(struct snd_soc_dai *dai,
return dai->driver->ops->set_tdm_slot(dai, tx_mask, rx_mask,
slots, slot_width);
else
- return -EINVAL;
+ return -ENOTSUPP;
}
EXPORT_SYMBOL_GPL(snd_soc_dai_set_tdm_slot);