sound/soc/codecs/wm_adsp.c:421:5-11: inconsistent IS_ERR and PTR_ERR on line 422.
kernel test robot
build bottree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master head: 393d0c54cae31317deaa9043320c5fd9454deabc commit: b5d057a86e2086af0b1e6d0ca8b306be1c73a627 [2287/6092] ASoC: wm_adsp: Use vmemdup_user() instead of open-coding config: mips-randconfig-r053-20250426 (https://download.01.org/0day-ci/archive/20250427/[email protected]/config) compiler: clang version 21.0.0git (https://github.com/llvm/llvm-project f819f46284f2a79790038e1f6649172789734ae8)
If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/
cocci warnings: (new ones prefixed by >>)
>> sound/soc/codecs/wm_adsp.c:421:5-11: inconsistent IS_ERR and PTR_ERR on line 422.
vim +421 sound/soc/codecs/wm_adsp.c
411
412 static int wm_coeff_tlv_put(struct snd_kcontrol *kctl,
413 const unsigned int __user *bytes, unsigned int size)
414 {
415 struct soc_bytes_ext *bytes_ext =
416 (struct soc_bytes_ext *)kctl->private_value;
417 struct wm_coeff_ctl *ctl = bytes_ext_to_ctl(bytes_ext);
418 struct cs_dsp_coeff_ctl *cs_ctl = ctl->cs_ctl;
419 void *scratch __free(kvfree) = vmemdup_user(bytes, size);
420
> 421 if (IS_ERR(scratch)) > 422 return PTR_ERR(no_free_ptr(scratch));
423
424 return cs_dsp_coeff_lock_and_write_ctrl(cs_ctl, 0, scratch, size);
425 }
426
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki