[alsa-devel] [asoc:for-4.19 199/204] sound/soc//meson/axg-tdm-interface.c:225:8: error: implicit declaration of function 'clk_set_duty_cycle'; did you mean 'clk_set_rate'?
kbuild test robot
lkp at intel.com
Fri Jul 20 20:12:27 CEST 2018
tree: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-4.19
head: a8e43c21a8a32a3af4abc605b6ebcab039f28e00
commit: c41c2a355b86368608377eaf3df442ec0f342f1e [199/204] ASoC: meson: add tdm output driver
config: m68k-allyesconfig (attached as .config)
compiler: m68k-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout c41c2a355b86368608377eaf3df442ec0f342f1e
# save the attached .config to linux build tree
GCC_VERSION=7.2.0 make.cross ARCH=m68k
All errors (new ones prefixed by >>):
sound/soc//meson/axg-tdm-interface.c: In function 'axg_tdm_iface_set_lrclk':
>> sound/soc//meson/axg-tdm-interface.c:225:8: error: implicit declaration of function 'clk_set_duty_cycle'; did you mean 'clk_set_rate'? [-Werror=implicit-function-declaration]
ret = clk_set_duty_cycle(iface->lrclk, ratio_num, 2);
^~~~~~~~~~~~~~~~~~
clk_set_rate
cc1: some warnings being treated as errors
vim +225 sound/soc//meson/axg-tdm-interface.c
d60e4f1e Jerome Brunet 2018-07-17 188
d60e4f1e Jerome Brunet 2018-07-17 189 static int axg_tdm_iface_set_lrclk(struct snd_soc_dai *dai,
d60e4f1e Jerome Brunet 2018-07-17 190 struct snd_pcm_hw_params *params)
d60e4f1e Jerome Brunet 2018-07-17 191 {
d60e4f1e Jerome Brunet 2018-07-17 192 struct axg_tdm_iface *iface = snd_soc_dai_get_drvdata(dai);
d60e4f1e Jerome Brunet 2018-07-17 193 unsigned int ratio_num;
d60e4f1e Jerome Brunet 2018-07-17 194 int ret;
d60e4f1e Jerome Brunet 2018-07-17 195
d60e4f1e Jerome Brunet 2018-07-17 196 ret = clk_set_rate(iface->lrclk, params_rate(params));
d60e4f1e Jerome Brunet 2018-07-17 197 if (ret) {
d60e4f1e Jerome Brunet 2018-07-17 198 dev_err(dai->dev, "setting sample clock failed: %d\n", ret);
d60e4f1e Jerome Brunet 2018-07-17 199 return ret;
d60e4f1e Jerome Brunet 2018-07-17 200 }
d60e4f1e Jerome Brunet 2018-07-17 201
d60e4f1e Jerome Brunet 2018-07-17 202 switch (iface->fmt & SND_SOC_DAIFMT_FORMAT_MASK) {
d60e4f1e Jerome Brunet 2018-07-17 203 case SND_SOC_DAIFMT_I2S:
d60e4f1e Jerome Brunet 2018-07-17 204 case SND_SOC_DAIFMT_LEFT_J:
d60e4f1e Jerome Brunet 2018-07-17 205 case SND_SOC_DAIFMT_RIGHT_J:
d60e4f1e Jerome Brunet 2018-07-17 206 /* 50% duty cycle ratio */
d60e4f1e Jerome Brunet 2018-07-17 207 ratio_num = 1;
d60e4f1e Jerome Brunet 2018-07-17 208 break;
d60e4f1e Jerome Brunet 2018-07-17 209
d60e4f1e Jerome Brunet 2018-07-17 210 case SND_SOC_DAIFMT_DSP_A:
d60e4f1e Jerome Brunet 2018-07-17 211 case SND_SOC_DAIFMT_DSP_B:
d60e4f1e Jerome Brunet 2018-07-17 212 /*
d60e4f1e Jerome Brunet 2018-07-17 213 * A zero duty cycle ratio will result in setting the mininum
d60e4f1e Jerome Brunet 2018-07-17 214 * ratio possible which, for this clock, is 1 cycle of the
d60e4f1e Jerome Brunet 2018-07-17 215 * parent bclk clock high and the rest low, This is exactly
d60e4f1e Jerome Brunet 2018-07-17 216 * what we want here.
d60e4f1e Jerome Brunet 2018-07-17 217 */
d60e4f1e Jerome Brunet 2018-07-17 218 ratio_num = 0;
d60e4f1e Jerome Brunet 2018-07-17 219 break;
d60e4f1e Jerome Brunet 2018-07-17 220
d60e4f1e Jerome Brunet 2018-07-17 221 default:
d60e4f1e Jerome Brunet 2018-07-17 222 return -EINVAL;
d60e4f1e Jerome Brunet 2018-07-17 223 }
d60e4f1e Jerome Brunet 2018-07-17 224
d60e4f1e Jerome Brunet 2018-07-17 @225 ret = clk_set_duty_cycle(iface->lrclk, ratio_num, 2);
d60e4f1e Jerome Brunet 2018-07-17 226 if (ret) {
d60e4f1e Jerome Brunet 2018-07-17 227 dev_err(dai->dev,
d60e4f1e Jerome Brunet 2018-07-17 228 "setting sample clock duty cycle failed: %d\n", ret);
d60e4f1e Jerome Brunet 2018-07-17 229 return ret;
d60e4f1e Jerome Brunet 2018-07-17 230 }
d60e4f1e Jerome Brunet 2018-07-17 231
d60e4f1e Jerome Brunet 2018-07-17 232 /* Set sample clock inversion */
d60e4f1e Jerome Brunet 2018-07-17 233 ret = clk_set_phase(iface->lrclk,
d60e4f1e Jerome Brunet 2018-07-17 234 axg_tdm_lrclk_invert(iface->fmt) ? 180 : 0);
d60e4f1e Jerome Brunet 2018-07-17 235 if (ret) {
d60e4f1e Jerome Brunet 2018-07-17 236 dev_err(dai->dev,
d60e4f1e Jerome Brunet 2018-07-17 237 "setting sample clock phase failed: %d\n", ret);
d60e4f1e Jerome Brunet 2018-07-17 238 return ret;
d60e4f1e Jerome Brunet 2018-07-17 239 }
d60e4f1e Jerome Brunet 2018-07-17 240
d60e4f1e Jerome Brunet 2018-07-17 241 return 0;
d60e4f1e Jerome Brunet 2018-07-17 242 }
d60e4f1e Jerome Brunet 2018-07-17 243
:::::: The code at line 225 was first introduced by commit
:::::: d60e4f1e4be5e2dfb55fb084b119aed094227a35 ASoC: meson: add tdm interface driver
:::::: TO: Jerome Brunet <jbrunet at baylibre.com>
:::::: CC: Mark Brown <broonie at kernel.org>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 46250 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20180721/27987f37/attachment-0001.bin>
More information about the Alsa-devel
mailing list