tree:
git://git.kernel.org/pub/scm/linux/kernel/git/lkundrak/linux-mmp.git lr/ariel
head: 4d586ea0de8af0daaef44b13621d8a48f6565be2
commit: 5af54aabd51377d10927e6478f75838bb3fc33b7 [45/50] p1
config: powerpc64-randconfig-r015-20200612 (attached as .config)
compiler: clang version 11.0.0 (
https://github.com/llvm/llvm-project
3b43f006294971b8049d4807110032169780e5b8)
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 powerpc64 cross compiling tool for clang build
# apt-get install binutils-powerpc64-linux-gnu
git checkout 5af54aabd51377d10927e6478f75838bb3fc33b7
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>, old ones prefixed by <<):
__do_##name al; ^~~~~~~~~~~~~~
<scratch space>:89:1: note: expanded from here
__do_insw
^
arch/powerpc/include/asm/io.h:542:56: note: expanded from macro '__do_insw'
#define __do_insw(p, b, n) readsw((PCI_IO_ADDR)_IO_BASE+(p), (b), (n))
~~~~~~~~~~~~~~~~~~~~~^
In file included from sound/soc/codecs/88ce156-codec.c:20:
In file included from include/linux/spi/spi.h:14:
In file included from include/linux/scatterlist.h:9:
In file included from arch/powerpc/include/asm/io.h:604:
arch/powerpc/include/asm/io-defs.h:47:1: warning: performing pointer arithmetic on a null
pointer has undefined behavior [-Wnull-pointer-arithmetic]
DEF_PCI_AC_NORET(insl, (unsigned long p, void *b, unsigned long c),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/powerpc/include/asm/io.h:601:3: note: expanded from macro 'DEF_PCI_AC_NORET'
__do_##name al; ^~~~~~~~~~~~~~
<scratch space>:91:1: note: expanded from here
__do_insl
^
arch/powerpc/include/asm/io.h:543:56: note: expanded from macro '__do_insl'
#define __do_insl(p, b, n) readsl((PCI_IO_ADDR)_IO_BASE+(p), (b), (n))
~~~~~~~~~~~~~~~~~~~~~^
In file included from sound/soc/codecs/88ce156-codec.c:20:
In file included from include/linux/spi/spi.h:14:
In file included from include/linux/scatterlist.h:9:
In file included from arch/powerpc/include/asm/io.h:604:
arch/powerpc/include/asm/io-defs.h:49:1: warning: performing pointer arithmetic on a null
pointer has undefined behavior [-Wnull-pointer-arithmetic]
DEF_PCI_AC_NORET(outsb, (unsigned long p, const void *b, unsigned long c),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/powerpc/include/asm/io.h:601:3: note: expanded from macro 'DEF_PCI_AC_NORET'
__do_##name al; ^~~~~~~~~~~~~~
<scratch space>:93:1: note: expanded from here
__do_outsb
^
arch/powerpc/include/asm/io.h:544:58: note: expanded from macro '__do_outsb'
#define __do_outsb(p, b, n) writesb((PCI_IO_ADDR)_IO_BASE+(p),(b),(n))
~~~~~~~~~~~~~~~~~~~~~^
In file included from sound/soc/codecs/88ce156-codec.c:20:
In file included from include/linux/spi/spi.h:14:
In file included from include/linux/scatterlist.h:9:
In file included from arch/powerpc/include/asm/io.h:604:
arch/powerpc/include/asm/io-defs.h:51:1: warning: performing pointer arithmetic on a null
pointer has undefined behavior [-Wnull-pointer-arithmetic]
DEF_PCI_AC_NORET(outsw, (unsigned long p, const void *b, unsigned long c),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/powerpc/include/asm/io.h:601:3: note: expanded from macro 'DEF_PCI_AC_NORET'
__do_##name al; ^~~~~~~~~~~~~~
<scratch space>:95:1: note: expanded from here
__do_outsw
^
arch/powerpc/include/asm/io.h:545:58: note: expanded from macro '__do_outsw'
#define __do_outsw(p, b, n) writesw((PCI_IO_ADDR)_IO_BASE+(p),(b),(n))
~~~~~~~~~~~~~~~~~~~~~^
In file included from sound/soc/codecs/88ce156-codec.c:20:
In file included from include/linux/spi/spi.h:14:
In file included from include/linux/scatterlist.h:9:
In file included from arch/powerpc/include/asm/io.h:604:
arch/powerpc/include/asm/io-defs.h:53:1: warning: performing pointer arithmetic on a null
pointer has undefined behavior [-Wnull-pointer-arithmetic]
DEF_PCI_AC_NORET(outsl, (unsigned long p, const void *b, unsigned long c),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/powerpc/include/asm/io.h:601:3: note: expanded from macro 'DEF_PCI_AC_NORET'
__do_##name al; ^~~~~~~~~~~~~~
<scratch space>:97:1: note: expanded from here
__do_outsl
^
arch/powerpc/include/asm/io.h:546:58: note: expanded from macro '__do_outsl'
#define __do_outsl(p, b, n) writesl((PCI_IO_ADDR)_IO_BASE+(p),(b),(n))
~~~~~~~~~~~~~~~~~~~~~^
sound/soc/codecs/88ce156-codec.c:97:33: error: no member named 'reg_cache_default'
in 'struct snd_soc_component_driver'
u8 *cache = (u8*)componentdrv->reg_cache_default;
~~~~~~~~~~~~ ^
sound/soc/codecs/88ce156-codec.c:98:37: error: no member named 'reg_cache_size' in
'struct snd_soc_component_driver'
if (reg < 0 || reg > componentdrv->reg_cache_size)
~~~~~~~~~~~~ ^
sound/soc/codecs/88ce156-codec.c:111:33: error: no member named 'control_data' in
'struct snd_soc_component'
if (i2c_master_send(component->control_data, data, 1) == 1) {
~~~~~~~~~ ^
sound/soc/codecs/88ce156-codec.c:112:30: error: no member named 'control_data' in
'struct snd_soc_component'
i2c_master_recv(component->control_data, data, 1);
~~~~~~~~~ ^
sound/soc/codecs/88ce156-codec.c:135:33: error: no member named
'reg_cache_default' in 'struct snd_soc_component_driver'
u8 *cache = (u8*)componentdrv->reg_cache_default;
~~~~~~~~~~~~ ^
sound/soc/codecs/88ce156-codec.c:136:37: error: no member named 'reg_cache_size'
in 'struct snd_soc_component_driver'
if (reg < 0 || reg > componentdrv->reg_cache_size) {
~~~~~~~~~~~~ ^
sound/soc/codecs/88ce156-codec.c:272:33: error: no member named 'control_data' in
'struct snd_soc_component'
if (i2c_master_send(component->control_data, data, 2) == 2) {
~~~~~~~~~ ^
sound/soc/codecs/88ce156-codec.c:371:5: warning: no previous prototype for function
'ce156_hw_init' [-Wmissing-prototypes]
int ce156_hw_init(struct snd_soc_component *component)
^
sound/soc/codecs/88ce156-codec.c:371:1: note: declare 'static' if the function is
not intended to be used outside of this translation unit
int ce156_hw_init(struct snd_soc_component *component)
^
static
> sound/soc/codecs/88ce156-codec.c:405:5: warning: no previous
prototype for function 'ce156_set_sample_rate' [-Wmissing-prototypes]
int
ce156_set_sample_rate(struct snd_soc_dai *codec_dai,
^
sound/soc/codecs/88ce156-codec.c:405:1: note: declare 'static' if the function is
not intended to be used outside of this translation unit
int ce156_set_sample_rate(struct snd_soc_dai *codec_dai,
^
static
sound/soc/codecs/88ce156-codec.c:923:2: error: field designator 'invert' does not
refer to any field in type 'const struct snd_soc_dapm_widget'
CE156_DAPM_OUTPUT("RSYNC", ce156_rsync_event),
^
sound/soc/codecs/88ce156-codec.c:42:15: note: expanded from macro
'CE156_DAPM_OUTPUT'
.shift = 0, .invert = 0, .kcontrols = NULL, ^
sound/soc/codecs/88ce156-codec.c:1038:7: error: invalid application of 'sizeof' to
an incomplete type 'const struct snd_soc_dapm_widget []'
ARRAY_SIZE(ce156_dapm_widgets));
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/kernel.h:47:32: note: expanded from macro 'ARRAY_SIZE'
#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]) + __must_be_array(arr))
^~~~~
sound/soc/codecs/88ce156-codec.c:1395:24: warning: unused variable 'ce156_priv'
[-Wunused-variable]
struct ce156_private *ce156_priv = snd_soc_component_get_drvdata(component);
^
sound/soc/codecs/88ce156-codec.c:1445:13: error: incompatible function pointer types
initializing 'void (*)(struct snd_soc_component *)' with an expression of type
'int (struct snd_soc_component *)'
[-Werror,-Wincompatible-function-pointer-types]
.remove = ce156_remove,
^~~~~~~~~~~~
sound/soc/codecs/88ce156-codec.c:1446:13: error: incompatible function pointer types
initializing 'int (*)(struct snd_soc_component *)' with an expression of type
'int (struct snd_soc_component *, pm_message_t)' (aka 'int (struct
snd_soc_component *, struct pm_message)')
[-Werror,-Wincompatible-function-pointer-types]
.suspend = ce156_suspend,
^~~~~~~~~~~~~
sound/soc/codecs/88ce156-codec.c:1451:3: error: field designator 'reg_cache_size'
does not refer to any field in type 'struct snd_soc_component_driver'
.reg_cache_size = ARRAY_SIZE(ce156_reg),
^
sound/soc/codecs/88ce156-codec.c:1452:3: error: field designator 'reg_cache_step'
does not refer to any field in type 'struct snd_soc_component_driver'
.reg_cache_step = 1,
^
sound/soc/codecs/88ce156-codec.c:1453:3: error: field designator 'reg_word_size'
does not refer to any field in type 'struct snd_soc_component_driver'
.reg_word_size = sizeof(u8),
^
sound/soc/codecs/88ce156-codec.c:1454:3: error: field designator
'reg_cache_default' does not refer to any field in type 'struct
snd_soc_component_driver'
.reg_cache_default = ce156_reg,
^
9 warnings and 15 errors generated.
vim +/ce156_set_sample_rate +405 sound/soc/codecs/88ce156-codec.c
f92f68a79bd0bba Lubomir Rintel 2020-05-24 403
f92f68a79bd0bba Lubomir Rintel 2020-05-24 404
f92f68a79bd0bba Lubomir Rintel 2020-05-24 @405 int ce156_set_sample_rate(struct
snd_soc_dai *codec_dai,
f92f68a79bd0bba Lubomir Rintel 2020-05-24 406 int div_id, int div)
f92f68a79bd0bba Lubomir Rintel 2020-05-24 407 {
5af54aabd51377d Lubomir Rintel 2020-05-24 408 struct snd_soc_component *component =
codec_dai->component;
5af54aabd51377d Lubomir Rintel 2020-05-24 409 u8 rate = ce156_read_reg_cache(component,
CE156_ADC_RATE) & 0xf0;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 410 switch(div_id){
f92f68a79bd0bba Lubomir Rintel 2020-05-24 411 case SAMPLE_RATE_8000:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 412 rate |= 0x0;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 413 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 414 case SAMPLE_RATE_12000:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 415 rate |= 0x1;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 416 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 417 case SAMPLE_RATE_16000:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 418 rate |= 0x2;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 419 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 420 case SAMPLE_RATE_24000:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 421 rate |= 0x3;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 422 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 423 case SAMPLE_RATE_32000:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 424 rate |= 0x4;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 425 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 426 case SAMPLE_RATE_48000:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 427 rate |= 0x5;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 428 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 429 case SAMPLE_RATE_96000:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 430 rate |= 0x6;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 431 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 432 case SAMPLE_RATE_11025:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 433 rate |= 0x7;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 434 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 435 case SAMPLE_RATE_22050:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 436 rate |= 0x8;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 437 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 438 case SAMPLE_RATE_44100:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 439 rate |= 0x9;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 440 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 441 case SAMPLE_RATE_88200:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 442 rate |= 0xa;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 443 break;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 444 default:
f92f68a79bd0bba Lubomir Rintel 2020-05-24 445 printk(KERN_INFO "sample rate set
failed!\n");
f92f68a79bd0bba Lubomir Rintel 2020-05-24 446 return -EINVAL;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 447 }
5af54aabd51377d Lubomir Rintel 2020-05-24 448 ce156_write(component, CE156_ADC_RATE,
rate);
f92f68a79bd0bba Lubomir Rintel 2020-05-24 449 return 0;
f92f68a79bd0bba Lubomir Rintel 2020-05-24 450 }
f92f68a79bd0bba Lubomir Rintel 2020-05-24 451 EXPORT_SYMBOL_GPL(ce156_set_sample_rate);
f92f68a79bd0bba Lubomir Rintel 2020-05-24 452
:::::: The code at line 405 was first introduced by commit
:::::: f92f68a79bd0bba6baf56c272cc22f9a4a030032 XXX 88CE156
:::::: TO: Lubomir Rintel <lkundrak(a)v3.sk>
:::::: CC: Lubomir Rintel <lkundrak(a)v3.sk>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org