Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ASoC: fix 0-day warnings with snd_soc_new_compress()

All conditionally-defined routines in include/sound/soc.h expose a
static inline fallback to avoid 0-day warnings and compilation issues,
except snd_soc_new_compress().

Fixes: 5db6aab6f36f ('ASoC: topology: Add support for compressed PCMs')
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Pierre-Louis Bossart and committed by
Mark Brown
0b014d72 b543e467

+5
+5
include/sound/soc.h
··· 462 462 int soc_new_pcm(struct snd_soc_pcm_runtime *rtd, int num); 463 463 #ifdef CONFIG_SND_SOC_COMPRESS 464 464 int snd_soc_new_compress(struct snd_soc_pcm_runtime *rtd, int num); 465 + #else 466 + static inline int snd_soc_new_compress(struct snd_soc_pcm_runtime *rtd, int num) 467 + { 468 + return 0; 469 + } 465 470 #endif 466 471 467 472 void snd_soc_disconnect_sync(struct device *dev);