• Arnd Bergmann's avatar
    ASoC: Intel: improve SND_SOC_INTEL_MACH dependencies · 960115b8
    Arnd Bergmann authored
    I ran into a build error with CONFIG_SND_SOC_INTEL_COMMON=m
    and SND_SOC_INTEL_MACH=y:
    
    ERROR: "snd_soc_acpi_intel_broadwell_machines" [sound/soc/intel/common/snd-soc-sst-acpi.ko] undefined!
    ERROR: "snd_soc_acpi_intel_haswell_machines" [sound/soc/intel/common/snd-soc-sst-acpi.ko] undefined!
    ERROR: "snd_soc_acpi_intel_cherrytrail_machines" [sound/soc/intel/atom/sst/snd-intel-sst-acpi.ko] undefined!
    ERROR: "snd_soc_acpi_intel_baytrail_machines" [sound/soc/intel/atom/sst/snd-intel-sst-acpi.ko] undefined!
    
    The problem here is that the sound/soc/intel/common/ directory
    is then entered only for building modules, but the sst-acpi.o
    never gets built since it depends on a built-in Kconfig symbol.
    
    That configuration obviously makes no sense since all options
    below SND_SOC_INTEL_MACH also depend on something else that
    in turn depends on CONFIG_SND_SOC_INTEL_COMMON.
    
    Adding a SND_SOC_INTEL_SST_TOPLEVEL dependency to SND_SOC_INTEL_MACH
    solves the build error. I notice we can also consolidate the
    'depends on SND_SOC_INTEL_MACH' lines by using an 'if' block to
    simplify it further and make sure the configuration stays sane.
    Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
    Acked-By: default avatarVinod Koul <vinod.koul@intel.com>
    Reviewed-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
    Signed-off-by: default avatarMark Brown <broonie@kernel.org>
    960115b8
Kconfig 9.3 KB