Hi Daniel, I love your patch! Perhaps something to improve: [auto build test WARNING on sound/for-next] [also build test WARNING on asoc/for-next v5.4 next-20191207] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Daniel-Mack/ALSA-core-add-snd_pcm_format_by_name/20191207-084912 base: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next reproduce: # apt-get install sparse # sparse version: v0.6.1-91-g817270f-dirty make ARCH=x86_64 allmodconfig make C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' If you fix the issue, kindly add following tag Reported-by: kbuild test robot <lkp@xxxxxxxxx> sparse warnings: (new ones prefixed by >>) >> sound/core/pcm.c:243:33: sparse: sparse: incorrect type in assignment (different base types) @@ expected restricted snd_pcm_format_t [usertype] @@ got t_t [usertype] @@ >> sound/core/pcm.c:243:33: sparse: expected restricted snd_pcm_format_t [usertype] >> sound/core/pcm.c:243:33: sparse: got int [assigned] i sound/core/pcm.c:1022:9: sparse: sparse: context imbalance in 'snd_pcm_detach_substream' - different lock contexts for basic block vim +243 sound/core/pcm.c 227 228 /** 229 * snd_pcm_format_by_name - Return the PCM format code for the given name 230 * @name: PCM format name ('S16_LE', 'S24_3LE', ...) 231 * @format: Pointer to returned PCM format code 232 * 233 * The string comparison is done in a case-insensitive way. 234 * 235 * Return: 0 on success, or -ENOENT if the given format is not valid. 236 */ 237 int snd_pcm_format_by_name(const char *name, snd_pcm_format_t *format) 238 { 239 int i; 240 241 for (i = 0; i < ARRAY_SIZE(snd_pcm_format_names); i++) 242 if (strcasecmp(name, snd_pcm_format_names[i]) == 0) { > 243 *format = i; 244 return 0; 245 } 246 247 return -ENOENT; 248 } 249 EXPORT_SYMBOL_GPL(snd_pcm_format_by_name); 250 --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx Intel Corporation _______________________________________________ Alsa-devel mailing list Alsa-devel@xxxxxxxxxxxxxxxx https://mailman.alsa-project.org/mailman/listinfo/alsa-devel