All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Shengjiu Wang <shengjiu.wang@nxp.com>,
	lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz,
	tiwai@suse.com, alsa-devel@alsa-project.org,
	linux-kernel@vger.kernel.org
Cc: clang-built-linux@googlegroups.com, kbuild-all@lists.01.org
Subject: Re: [PATCH] ASoC: ak4458: check reset control status
Date: Sat, 17 Apr 2021 02:15:00 +0800	[thread overview]
Message-ID: <202104170249.mIIp03lf-lkp@intel.com> (raw)
In-Reply-To: <1618573502-1488-1-git-send-email-shengjiu.wang@nxp.com>

[-- Attachment #1: Type: text/plain, Size: 5750 bytes --]

Hi Shengjiu,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on asoc/for-next]
[also build test ERROR on v5.12-rc7 next-20210416]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Shengjiu-Wang/ASoC-ak4458-check-reset-control-status/20210416-200151
base:   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
config: riscv-randconfig-r006-20210416 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 6a18cc23efad410db48a3ccfc233d215de7d4cb9)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # install riscv cross compiling tool for clang build
        # apt-get install binutils-riscv64-linux-gnu
        # https://github.com/0day-ci/linux/commit/48f467759d71681e2d3c35253a6eed08e686bd16
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Shengjiu-Wang/ASoC-ak4458-check-reset-control-status/20210416-200151
        git checkout 48f467759d71681e2d3c35253a6eed08e686bd16
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=riscv 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

>> sound/soc/codecs/ak4458.c:422:2: error: use of undeclared identifier 'ret'
           ret = ak4458_rstn_control(component, 0);
           ^
   sound/soc/codecs/ak4458.c:423:6: error: use of undeclared identifier 'ret'
           if (ret)
               ^
   sound/soc/codecs/ak4458.c:424:10: error: use of undeclared identifier 'ret'
                   return ret;
                          ^
   sound/soc/codecs/ak4458.c:426:2: error: use of undeclared identifier 'ret'
           ret = ak4458_rstn_control(component, 1);
           ^
   sound/soc/codecs/ak4458.c:427:6: error: use of undeclared identifier 'ret'
           if (ret)
               ^
   sound/soc/codecs/ak4458.c:428:10: error: use of undeclared identifier 'ret'
                   return ret;
                          ^
   6 errors generated.


vim +/ret +422 sound/soc/codecs/ak4458.c

   328	
   329	static int ak4458_hw_params(struct snd_pcm_substream *substream,
   330				    struct snd_pcm_hw_params *params,
   331				    struct snd_soc_dai *dai)
   332	{
   333		struct snd_soc_component *component = dai->component;
   334		struct ak4458_priv *ak4458 = snd_soc_component_get_drvdata(component);
   335		int pcm_width = max(params_physical_width(params), ak4458->slot_width);
   336		u8 format, dsdsel0, dsdsel1;
   337		int nfs1, dsd_bclk;
   338	
   339		nfs1 = params_rate(params);
   340		ak4458->fs = nfs1;
   341	
   342		/* calculate bit clock */
   343		switch (params_format(params)) {
   344		case SNDRV_PCM_FORMAT_DSD_U8:
   345		case SNDRV_PCM_FORMAT_DSD_U16_LE:
   346		case SNDRV_PCM_FORMAT_DSD_U16_BE:
   347		case SNDRV_PCM_FORMAT_DSD_U32_LE:
   348		case SNDRV_PCM_FORMAT_DSD_U32_BE:
   349			dsd_bclk = nfs1 * params_physical_width(params);
   350			switch (dsd_bclk) {
   351			case 2822400:
   352				dsdsel0 = 0;
   353				dsdsel1 = 0;
   354				break;
   355			case 5644800:
   356				dsdsel0 = 1;
   357				dsdsel1 = 0;
   358				break;
   359			case 11289600:
   360				dsdsel0 = 0;
   361				dsdsel1 = 1;
   362				break;
   363			case 22579200:
   364				if (ak4458->drvdata->type == AK4497) {
   365					dsdsel0 = 1;
   366					dsdsel1 = 1;
   367				} else {
   368					dev_err(dai->dev, "DSD512 not supported.\n");
   369					return -EINVAL;
   370				}
   371				break;
   372			default:
   373				dev_err(dai->dev, "Unsupported dsd bclk.\n");
   374				return -EINVAL;
   375			}
   376	
   377			snd_soc_component_update_bits(component, AK4458_06_DSD1,
   378						      AK4458_DSDSEL_MASK, dsdsel0);
   379			snd_soc_component_update_bits(component, AK4458_09_DSD2,
   380						      AK4458_DSDSEL_MASK, dsdsel1);
   381			break;
   382		}
   383	
   384		/* Master Clock Frequency Auto Setting Mode Enable */
   385		snd_soc_component_update_bits(component, AK4458_00_CONTROL1, 0x80, 0x80);
   386	
   387		switch (pcm_width) {
   388		case 16:
   389			if (ak4458->fmt == SND_SOC_DAIFMT_I2S)
   390				format = AK4458_DIF_24BIT_I2S;
   391			else
   392				format = AK4458_DIF_16BIT_LSB;
   393			break;
   394		case 32:
   395			switch (ak4458->fmt) {
   396			case SND_SOC_DAIFMT_I2S:
   397				format = AK4458_DIF_32BIT_I2S;
   398				break;
   399			case SND_SOC_DAIFMT_LEFT_J:
   400				format = AK4458_DIF_32BIT_MSB;
   401				break;
   402			case SND_SOC_DAIFMT_RIGHT_J:
   403				format = AK4458_DIF_32BIT_LSB;
   404				break;
   405			case SND_SOC_DAIFMT_DSP_B:
   406				format = AK4458_DIF_32BIT_MSB;
   407				break;
   408			case SND_SOC_DAIFMT_PDM:
   409				format = AK4458_DIF_32BIT_MSB;
   410				break;
   411			default:
   412				return -EINVAL;
   413			}
   414			break;
   415		default:
   416			return -EINVAL;
   417		}
   418	
   419		snd_soc_component_update_bits(component, AK4458_00_CONTROL1,
   420				    AK4458_DIF_MASK, format);
   421	
 > 422		ret = ak4458_rstn_control(component, 0);
   423		if (ret)
   424			return ret;
   425	
   426		ret = ak4458_rstn_control(component, 1);
   427		if (ret)
   428			return ret;
   429	
   430		return 0;
   431	}
   432	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 39009 bytes --]

WARNING: multiple messages have this Message-ID (diff)
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [PATCH] ASoC: ak4458: check reset control status
Date: Sat, 17 Apr 2021 02:15:00 +0800	[thread overview]
Message-ID: <202104170249.mIIp03lf-lkp@intel.com> (raw)
In-Reply-To: <1618573502-1488-1-git-send-email-shengjiu.wang@nxp.com>

[-- Attachment #1: Type: text/plain, Size: 5915 bytes --]

Hi Shengjiu,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on asoc/for-next]
[also build test ERROR on v5.12-rc7 next-20210416]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Shengjiu-Wang/ASoC-ak4458-check-reset-control-status/20210416-200151
base:   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
config: riscv-randconfig-r006-20210416 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 6a18cc23efad410db48a3ccfc233d215de7d4cb9)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # install riscv cross compiling tool for clang build
        # apt-get install binutils-riscv64-linux-gnu
        # https://github.com/0day-ci/linux/commit/48f467759d71681e2d3c35253a6eed08e686bd16
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Shengjiu-Wang/ASoC-ak4458-check-reset-control-status/20210416-200151
        git checkout 48f467759d71681e2d3c35253a6eed08e686bd16
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=riscv 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

>> sound/soc/codecs/ak4458.c:422:2: error: use of undeclared identifier 'ret'
           ret = ak4458_rstn_control(component, 0);
           ^
   sound/soc/codecs/ak4458.c:423:6: error: use of undeclared identifier 'ret'
           if (ret)
               ^
   sound/soc/codecs/ak4458.c:424:10: error: use of undeclared identifier 'ret'
                   return ret;
                          ^
   sound/soc/codecs/ak4458.c:426:2: error: use of undeclared identifier 'ret'
           ret = ak4458_rstn_control(component, 1);
           ^
   sound/soc/codecs/ak4458.c:427:6: error: use of undeclared identifier 'ret'
           if (ret)
               ^
   sound/soc/codecs/ak4458.c:428:10: error: use of undeclared identifier 'ret'
                   return ret;
                          ^
   6 errors generated.


vim +/ret +422 sound/soc/codecs/ak4458.c

   328	
   329	static int ak4458_hw_params(struct snd_pcm_substream *substream,
   330				    struct snd_pcm_hw_params *params,
   331				    struct snd_soc_dai *dai)
   332	{
   333		struct snd_soc_component *component = dai->component;
   334		struct ak4458_priv *ak4458 = snd_soc_component_get_drvdata(component);
   335		int pcm_width = max(params_physical_width(params), ak4458->slot_width);
   336		u8 format, dsdsel0, dsdsel1;
   337		int nfs1, dsd_bclk;
   338	
   339		nfs1 = params_rate(params);
   340		ak4458->fs = nfs1;
   341	
   342		/* calculate bit clock */
   343		switch (params_format(params)) {
   344		case SNDRV_PCM_FORMAT_DSD_U8:
   345		case SNDRV_PCM_FORMAT_DSD_U16_LE:
   346		case SNDRV_PCM_FORMAT_DSD_U16_BE:
   347		case SNDRV_PCM_FORMAT_DSD_U32_LE:
   348		case SNDRV_PCM_FORMAT_DSD_U32_BE:
   349			dsd_bclk = nfs1 * params_physical_width(params);
   350			switch (dsd_bclk) {
   351			case 2822400:
   352				dsdsel0 = 0;
   353				dsdsel1 = 0;
   354				break;
   355			case 5644800:
   356				dsdsel0 = 1;
   357				dsdsel1 = 0;
   358				break;
   359			case 11289600:
   360				dsdsel0 = 0;
   361				dsdsel1 = 1;
   362				break;
   363			case 22579200:
   364				if (ak4458->drvdata->type == AK4497) {
   365					dsdsel0 = 1;
   366					dsdsel1 = 1;
   367				} else {
   368					dev_err(dai->dev, "DSD512 not supported.\n");
   369					return -EINVAL;
   370				}
   371				break;
   372			default:
   373				dev_err(dai->dev, "Unsupported dsd bclk.\n");
   374				return -EINVAL;
   375			}
   376	
   377			snd_soc_component_update_bits(component, AK4458_06_DSD1,
   378						      AK4458_DSDSEL_MASK, dsdsel0);
   379			snd_soc_component_update_bits(component, AK4458_09_DSD2,
   380						      AK4458_DSDSEL_MASK, dsdsel1);
   381			break;
   382		}
   383	
   384		/* Master Clock Frequency Auto Setting Mode Enable */
   385		snd_soc_component_update_bits(component, AK4458_00_CONTROL1, 0x80, 0x80);
   386	
   387		switch (pcm_width) {
   388		case 16:
   389			if (ak4458->fmt == SND_SOC_DAIFMT_I2S)
   390				format = AK4458_DIF_24BIT_I2S;
   391			else
   392				format = AK4458_DIF_16BIT_LSB;
   393			break;
   394		case 32:
   395			switch (ak4458->fmt) {
   396			case SND_SOC_DAIFMT_I2S:
   397				format = AK4458_DIF_32BIT_I2S;
   398				break;
   399			case SND_SOC_DAIFMT_LEFT_J:
   400				format = AK4458_DIF_32BIT_MSB;
   401				break;
   402			case SND_SOC_DAIFMT_RIGHT_J:
   403				format = AK4458_DIF_32BIT_LSB;
   404				break;
   405			case SND_SOC_DAIFMT_DSP_B:
   406				format = AK4458_DIF_32BIT_MSB;
   407				break;
   408			case SND_SOC_DAIFMT_PDM:
   409				format = AK4458_DIF_32BIT_MSB;
   410				break;
   411			default:
   412				return -EINVAL;
   413			}
   414			break;
   415		default:
   416			return -EINVAL;
   417		}
   418	
   419		snd_soc_component_update_bits(component, AK4458_00_CONTROL1,
   420				    AK4458_DIF_MASK, format);
   421	
 > 422		ret = ak4458_rstn_control(component, 0);
   423		if (ret)
   424			return ret;
   425	
   426		ret = ak4458_rstn_control(component, 1);
   427		if (ret)
   428			return ret;
   429	
   430		return 0;
   431	}
   432	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 39009 bytes --]

WARNING: multiple messages have this Message-ID (diff)
From: kernel test robot <lkp@intel.com>
To: Shengjiu Wang <shengjiu.wang@nxp.com>,
	lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz,
	tiwai@suse.com, alsa-devel@alsa-project.org,
	linux-kernel@vger.kernel.org
Cc: kbuild-all@lists.01.org, clang-built-linux@googlegroups.com
Subject: Re: [PATCH] ASoC: ak4458: check reset control status
Date: Sat, 17 Apr 2021 02:15:00 +0800	[thread overview]
Message-ID: <202104170249.mIIp03lf-lkp@intel.com> (raw)
In-Reply-To: <1618573502-1488-1-git-send-email-shengjiu.wang@nxp.com>

[-- Attachment #1: Type: text/plain, Size: 5750 bytes --]

Hi Shengjiu,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on asoc/for-next]
[also build test ERROR on v5.12-rc7 next-20210416]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Shengjiu-Wang/ASoC-ak4458-check-reset-control-status/20210416-200151
base:   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
config: riscv-randconfig-r006-20210416 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 6a18cc23efad410db48a3ccfc233d215de7d4cb9)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # install riscv cross compiling tool for clang build
        # apt-get install binutils-riscv64-linux-gnu
        # https://github.com/0day-ci/linux/commit/48f467759d71681e2d3c35253a6eed08e686bd16
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Shengjiu-Wang/ASoC-ak4458-check-reset-control-status/20210416-200151
        git checkout 48f467759d71681e2d3c35253a6eed08e686bd16
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=riscv 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

>> sound/soc/codecs/ak4458.c:422:2: error: use of undeclared identifier 'ret'
           ret = ak4458_rstn_control(component, 0);
           ^
   sound/soc/codecs/ak4458.c:423:6: error: use of undeclared identifier 'ret'
           if (ret)
               ^
   sound/soc/codecs/ak4458.c:424:10: error: use of undeclared identifier 'ret'
                   return ret;
                          ^
   sound/soc/codecs/ak4458.c:426:2: error: use of undeclared identifier 'ret'
           ret = ak4458_rstn_control(component, 1);
           ^
   sound/soc/codecs/ak4458.c:427:6: error: use of undeclared identifier 'ret'
           if (ret)
               ^
   sound/soc/codecs/ak4458.c:428:10: error: use of undeclared identifier 'ret'
                   return ret;
                          ^
   6 errors generated.


vim +/ret +422 sound/soc/codecs/ak4458.c

   328	
   329	static int ak4458_hw_params(struct snd_pcm_substream *substream,
   330				    struct snd_pcm_hw_params *params,
   331				    struct snd_soc_dai *dai)
   332	{
   333		struct snd_soc_component *component = dai->component;
   334		struct ak4458_priv *ak4458 = snd_soc_component_get_drvdata(component);
   335		int pcm_width = max(params_physical_width(params), ak4458->slot_width);
   336		u8 format, dsdsel0, dsdsel1;
   337		int nfs1, dsd_bclk;
   338	
   339		nfs1 = params_rate(params);
   340		ak4458->fs = nfs1;
   341	
   342		/* calculate bit clock */
   343		switch (params_format(params)) {
   344		case SNDRV_PCM_FORMAT_DSD_U8:
   345		case SNDRV_PCM_FORMAT_DSD_U16_LE:
   346		case SNDRV_PCM_FORMAT_DSD_U16_BE:
   347		case SNDRV_PCM_FORMAT_DSD_U32_LE:
   348		case SNDRV_PCM_FORMAT_DSD_U32_BE:
   349			dsd_bclk = nfs1 * params_physical_width(params);
   350			switch (dsd_bclk) {
   351			case 2822400:
   352				dsdsel0 = 0;
   353				dsdsel1 = 0;
   354				break;
   355			case 5644800:
   356				dsdsel0 = 1;
   357				dsdsel1 = 0;
   358				break;
   359			case 11289600:
   360				dsdsel0 = 0;
   361				dsdsel1 = 1;
   362				break;
   363			case 22579200:
   364				if (ak4458->drvdata->type == AK4497) {
   365					dsdsel0 = 1;
   366					dsdsel1 = 1;
   367				} else {
   368					dev_err(dai->dev, "DSD512 not supported.\n");
   369					return -EINVAL;
   370				}
   371				break;
   372			default:
   373				dev_err(dai->dev, "Unsupported dsd bclk.\n");
   374				return -EINVAL;
   375			}
   376	
   377			snd_soc_component_update_bits(component, AK4458_06_DSD1,
   378						      AK4458_DSDSEL_MASK, dsdsel0);
   379			snd_soc_component_update_bits(component, AK4458_09_DSD2,
   380						      AK4458_DSDSEL_MASK, dsdsel1);
   381			break;
   382		}
   383	
   384		/* Master Clock Frequency Auto Setting Mode Enable */
   385		snd_soc_component_update_bits(component, AK4458_00_CONTROL1, 0x80, 0x80);
   386	
   387		switch (pcm_width) {
   388		case 16:
   389			if (ak4458->fmt == SND_SOC_DAIFMT_I2S)
   390				format = AK4458_DIF_24BIT_I2S;
   391			else
   392				format = AK4458_DIF_16BIT_LSB;
   393			break;
   394		case 32:
   395			switch (ak4458->fmt) {
   396			case SND_SOC_DAIFMT_I2S:
   397				format = AK4458_DIF_32BIT_I2S;
   398				break;
   399			case SND_SOC_DAIFMT_LEFT_J:
   400				format = AK4458_DIF_32BIT_MSB;
   401				break;
   402			case SND_SOC_DAIFMT_RIGHT_J:
   403				format = AK4458_DIF_32BIT_LSB;
   404				break;
   405			case SND_SOC_DAIFMT_DSP_B:
   406				format = AK4458_DIF_32BIT_MSB;
   407				break;
   408			case SND_SOC_DAIFMT_PDM:
   409				format = AK4458_DIF_32BIT_MSB;
   410				break;
   411			default:
   412				return -EINVAL;
   413			}
   414			break;
   415		default:
   416			return -EINVAL;
   417		}
   418	
   419		snd_soc_component_update_bits(component, AK4458_00_CONTROL1,
   420				    AK4458_DIF_MASK, format);
   421	
 > 422		ret = ak4458_rstn_control(component, 0);
   423		if (ret)
   424			return ret;
   425	
   426		ret = ak4458_rstn_control(component, 1);
   427		if (ret)
   428			return ret;
   429	
   430		return 0;
   431	}
   432	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 39009 bytes --]

  parent reply	other threads:[~2021-04-16 18:17 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-16 11:45 [PATCH] ASoC: ak4458: check reset control status Shengjiu Wang
2021-04-16 15:05 ` kernel test robot
2021-04-16 15:05   ` kernel test robot
2021-04-16 18:15 ` kernel test robot [this message]
2021-04-16 18:15   ` kernel test robot
2021-04-16 18:15   ` kernel test robot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202104170249.mIIp03lf-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=clang-built-linux@googlegroups.com \
    --cc=kbuild-all@lists.01.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=shengjiu.wang@nxp.com \
    --cc=tiwai@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.