tree:
https://github.com/Freescale/linux-fslc pr/492
head: 51cffbf29ed5a516ce75d7ae8ea7b2e9a318b392
commit: a452c44357d9c68c27c39327e50b41e4b6cffe8d [15428/21574] MLK-25015: sound: soc:
codecs: pcm512x: set input sclk
config: arm-allyesconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 11.2.0
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
#
https://github.com/Freescale/linux-fslc/commit/a452c44357d9c68c27c39327e5...
git remote add freescale-fslc
https://github.com/Freescale/linux-fslc
git fetch --no-tags freescale-fslc pr/492
git checkout a452c44357d9c68c27c39327e50b41e4b6cffe8d
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir
ARCH=arm SHELL=/bin/bash sound/soc/fsl/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
77 | # define likely(x) __builtin_expect(!!(x), 1)
| ^
sound/soc/fsl/imx-pcm512x.c:246:21: note: in expansion of macro 'do_div'
246 | if (do_div(sample_rate, 8000)) {
| ^~~~~~
In file included from arch/arm/include/asm/div64.h:127,
from include/linux/kernel.h:18,
from include/linux/list.h:9,
from include/linux/module.h:9,
from sound/soc/fsl/imx-pcm512x.c:13:
include/asm-generic/div64.h:243:36: error: passing argument 1 of '__div64_32'
from incompatible pointer type [-Werror=incompatible-pointer-types]
243 | __rem = __div64_32(&(n), __base); \
| ^~~~
| |
| unsigned int *
sound/soc/fsl/imx-pcm512x.c:246:21: note: in expansion of macro 'do_div'
246 | if (do_div(sample_rate, 8000)) {
| ^~~~~~
In file included from include/linux/kernel.h:18,
from include/linux/list.h:9,
from include/linux/module.h:9,
from sound/soc/fsl/imx-pcm512x.c:13:
arch/arm/include/asm/div64.h:33:45: note: expected 'uint64_t *' {aka 'long
long unsigned int *'} but argument is of type 'unsigned int *'
33 | static inline uint32_t __div64_32(uint64_t *n, uint32_t base)
| ~~~~~~~~~~^
In file included from sound/soc/fsl/imx-pcm512x.c:21:
sound/soc/fsl/imx-pcm512x.c: At top level:
sound/soc/fsl/imx-pcm512x.c:357:37: warning: initialized field overwritten
[-Woverride-init]
357 | SND_SOC_DAILINK_REG(hifi),
| ^~~~
include/sound/soc.h:919:27: note: in definition of macro
'SND_SOC_DAILINK_REG3'
919 | .codecs = codec, \
| ^~~~~
include/sound/soc.h:924:53: note: in expansion of macro 'SND_SOC_DAILINK_REG1'
924 | #define SND_SOC_DAILINK_REGx(_1, _2, _3, func, ...) func
| ^~~~
sound/soc/fsl/imx-pcm512x.c:357:17: note: in expansion of macro
'SND_SOC_DAILINK_REG'
357 | SND_SOC_DAILINK_REG(hifi),
| ^~~~~~~~~~~~~~~~~~~
sound/soc/fsl/imx-pcm512x.c:357:37: note: (near initialization for
'imx_pcm512x_dai[0].codecs')
357 | SND_SOC_DAILINK_REG(hifi),
| ^~~~
include/sound/soc.h:919:27: note: in definition of macro
'SND_SOC_DAILINK_REG3'
919 | .codecs = codec, \
| ^~~~~
include/sound/soc.h:924:53: note: in expansion of macro 'SND_SOC_DAILINK_REG1'
924 | #define SND_SOC_DAILINK_REGx(_1, _2, _3, func, ...) func
| ^~~~
sound/soc/fsl/imx-pcm512x.c:357:17: note: in expansion of macro
'SND_SOC_DAILINK_REG'
357 | SND_SOC_DAILINK_REG(hifi),
| ^~~~~~~~~~~~~~~~~~~
In file included from include/linux/list.h:9,
from include/linux/module.h:9,
from sound/soc/fsl/imx-pcm512x.c:13:
include/linux/kernel.h:47:25: warning: initialized field overwritten [-Woverride-init]
47 | #define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]) +
__must_be_array(arr))
| ^
include/sound/soc.h:920:27: note: in expansion of macro 'ARRAY_SIZE'
920 | .num_codecs = ARRAY_SIZE(codec), \
| ^~~~~~~~~~
include/sound/soc.h:914:42: note: in expansion of macro 'SND_SOC_DAILINK_REG3'
914 | #define SND_SOC_DAILINK_REG1(name) SND_SOC_DAILINK_REG3(name##_cpus,
name##_codecs, name##_platforms)
| ^~~~~~~~~~~~~~~~~~~~
include/sound/soc.h:924:53: note: in expansion of macro 'SND_SOC_DAILINK_REG1'
924 | #define SND_SOC_DAILINK_REGx(_1, _2, _3, func, ...) func
| ^~~~
include/sound/soc.h:926:9: note: in expansion of macro 'SND_SOC_DAILINK_REGx'
926 | SND_SOC_DAILINK_REGx(__VA_ARGS__, \
| ^~~~~~~~~~~~~~~~~~~~
sound/soc/fsl/imx-pcm512x.c:357:17: note: in expansion of macro
'SND_SOC_DAILINK_REG'
357 | SND_SOC_DAILINK_REG(hifi),
| ^~~~~~~~~~~~~~~~~~~
include/linux/kernel.h:47:25: note: (near initialization for
'imx_pcm512x_dai[0].num_codecs')
47 | #define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]) +
__must_be_array(arr))
| ^
include/sound/soc.h:920:27: note: in expansion of macro 'ARRAY_SIZE'
920 | .num_codecs = ARRAY_SIZE(codec), \
| ^~~~~~~~~~
include/sound/soc.h:914:42: note: in expansion of macro 'SND_SOC_DAILINK_REG3'
914 | #define SND_SOC_DAILINK_REG1(name) SND_SOC_DAILINK_REG3(name##_cpus,
name##_codecs, name##_platforms)
| ^~~~~~~~~~~~~~~~~~~~
include/sound/soc.h:924:53: note: in expansion of macro 'SND_SOC_DAILINK_REG1'
924 | #define SND_SOC_DAILINK_REGx(_1, _2, _3, func, ...) func
| ^~~~
include/sound/soc.h:926:9: note: in expansion of macro 'SND_SOC_DAILINK_REGx'
926 | SND_SOC_DAILINK_REGx(__VA_ARGS__, \
| ^~~~~~~~~~~~~~~~~~~~
sound/soc/fsl/imx-pcm512x.c:357:17: note: in expansion of macro
'SND_SOC_DAILINK_REG'
357 | SND_SOC_DAILINK_REG(hifi),
| ^~~~~~~~~~~~~~~~~~~
In file included from include/linux/bitmap.h:9,
from include/linux/nodemask.h:95,
from include/linux/mmzone.h:17,
from include/linux/gfp.h:6,
from include/linux/umh.h:4,
from include/linux/kmod.h:9,
from include/linux/module.h:13,
from sound/soc/fsl/imx-pcm512x.c:13:
In function 'memcpy',
inlined from 'imx_pcm512x_probe' at sound/soc/fsl/imx-pcm512x.c:429:2:
> include/linux/string.h:399:25: error: call to
'__read_overflow2' declared with attribute error: detected read beyond size of
object passed as 2nd parameter
399 |
__read_overflow2();
| ^~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +/__read_overflow2 +399 include/linux/string.h
6974f0c4555e28 Daniel Micay 2017-07-12 390
6974f0c4555e28 Daniel Micay 2017-07-12 391 __FORTIFY_INLINE void *memcpy(void *p, const
void *q, __kernel_size_t size)
6974f0c4555e28 Daniel Micay 2017-07-12 392 {
6974f0c4555e28 Daniel Micay 2017-07-12 393 size_t p_size = __builtin_object_size(p,
0);
6974f0c4555e28 Daniel Micay 2017-07-12 394 size_t q_size = __builtin_object_size(q,
0);
6974f0c4555e28 Daniel Micay 2017-07-12 395 if (__builtin_constant_p(size)) {
6974f0c4555e28 Daniel Micay 2017-07-12 396 if (p_size < size)
6974f0c4555e28 Daniel Micay 2017-07-12 397 __write_overflow();
6974f0c4555e28 Daniel Micay 2017-07-12 398 if (q_size < size)
6974f0c4555e28 Daniel Micay 2017-07-12 @399 __read_overflow2();
6974f0c4555e28 Daniel Micay 2017-07-12 400 }
6974f0c4555e28 Daniel Micay 2017-07-12 401 if (p_size < size || q_size < size)
6974f0c4555e28 Daniel Micay 2017-07-12 402 fortify_panic(__func__);
b008ae4cc74d3a Daniel Axtens 2020-06-03 403 return __underlying_memcpy(p, q, size);
6974f0c4555e28 Daniel Micay 2017-07-12 404 }
6974f0c4555e28 Daniel Micay 2017-07-12 405
:::::: The code at line 399 was first introduced by commit
:::::: 6974f0c4555e285ab217cee58b6e874f776ff409 include/linux/string.h: add the option of
fortified string.h functions
:::::: TO: Daniel Micay <danielmicay(a)gmail.com>
:::::: CC: Linus Torvalds <torvalds(a)linux-foundation.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org