[PATCH v2 5/5] ASoC: codecs: wsa881x: add static port map support

kernel test robot lkp at intel.com
Tue Mar 9 21:31:58 CET 2021


Hi Srinivas,

I love your patch! Yet something to improve:

[auto build test ERROR on asoc/for-next]
[also build test ERROR on vkoul-dmaengine/next robh/for-next linus/master v5.12-rc2 next-20210309]
[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/Srinivas-Kandagatla/soundwire-add-static-port-map-support/20210309-221834
base:   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
config: arm64-randconfig-r016-20210308 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 820f508b08d7c94b2dd7847e9710d2bc36d3dd45)
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 arm64 cross compiling tool for clang build
        # apt-get install binutils-aarch64-linux-gnu
        # https://github.com/0day-ci/linux/commit/d0e48ba0d85c188c14216aad9397bcd902d8a09a
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Srinivas-Kandagatla/soundwire-add-static-port-map-support/20210309-221834
        git checkout d0e48ba0d85c188c14216aad9397bcd902d8a09a
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm64 

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

All errors (new ones prefixed by >>):

>> sound/soc/codecs/wsa881x.c:1108:33: error: use of undeclared identifier 'dev'
           if (of_property_read_u32_array(dev->of_node, "qcom,port-mapping",
                                          ^
   sound/soc/codecs/wsa881x.c:1111:12: error: use of undeclared identifier 'dev'; did you mean 'pdev'?
                   dev_info(dev, "Static Port mapping not specified\n");
                            ^~~
                            pdev
   include/linux/dev_printk.h:118:12: note: expanded from macro 'dev_info'
           _dev_info(dev, dev_fmt(fmt), ##__VA_ARGS__)
                     ^
   sound/soc/codecs/wsa881x.c:1092:44: note: 'pdev' declared here
   static int wsa881x_probe(struct sdw_slave *pdev,
                                              ^
   2 errors generated.


vim +/dev +1108 sound/soc/codecs/wsa881x.c

  1091	
  1092	static int wsa881x_probe(struct sdw_slave *pdev,
  1093				 const struct sdw_device_id *id)
  1094	{
  1095		struct wsa881x_priv *wsa881x;
  1096	
  1097		wsa881x = devm_kzalloc(&pdev->dev, sizeof(*wsa881x), GFP_KERNEL);
  1098		if (!wsa881x)
  1099			return -ENOMEM;
  1100	
  1101		wsa881x->sd_n = devm_gpiod_get_optional(&pdev->dev, "powerdown",
  1102							GPIOD_FLAGS_BIT_NONEXCLUSIVE);
  1103		if (IS_ERR(wsa881x->sd_n)) {
  1104			dev_err(&pdev->dev, "Shutdown Control GPIO not found\n");
  1105			return PTR_ERR(wsa881x->sd_n);
  1106		}
  1107	
> 1108		if (of_property_read_u32_array(dev->of_node, "qcom,port-mapping",
  1109					       pdev->m_port_map,
  1110					       WSA881X_MAX_SWR_PORTS))
  1111			dev_info(dev, "Static Port mapping not specified\n");
  1112	
  1113		dev_set_drvdata(&pdev->dev, wsa881x);
  1114		wsa881x->slave = pdev;
  1115		wsa881x->dev = &pdev->dev;
  1116		wsa881x->sconfig.ch_count = 1;
  1117		wsa881x->sconfig.bps = 1;
  1118		wsa881x->sconfig.frame_rate = 48000;
  1119		wsa881x->sconfig.direction = SDW_DATA_DIR_RX;
  1120		wsa881x->sconfig.type = SDW_STREAM_PDM;
  1121		pdev->prop.sink_ports = GENMASK(WSA881X_MAX_SWR_PORTS, 0);
  1122		pdev->prop.sink_dpn_prop = wsa_sink_dpn_prop;
  1123		pdev->prop.scp_int1_mask = SDW_SCP_INT1_BUS_CLASH | SDW_SCP_INT1_PARITY;
  1124		gpiod_direction_output(wsa881x->sd_n, 1);
  1125	
  1126		wsa881x->regmap = devm_regmap_init_sdw(pdev, &wsa881x_regmap_config);
  1127		if (IS_ERR(wsa881x->regmap)) {
  1128			dev_err(&pdev->dev, "regmap_init failed\n");
  1129			return PTR_ERR(wsa881x->regmap);
  1130		}
  1131	
  1132		return devm_snd_soc_register_component(&pdev->dev,
  1133						       &wsa881x_component_drv,
  1134						       wsa881x_dais,
  1135						       ARRAY_SIZE(wsa881x_dais));
  1136	}
  1137	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 33552 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20210310/f7697e86/attachment-0001.gz>


More information about the Alsa-devel mailing list