Commit 5c7dee44 authored by Julian Braha's avatar Julian Braha Committed by Mark Brown

ASoC: fix unmet dependencies on GPIOLIB for SND_SOC_DMIC

When SND_SOC_AMD_RENOIR_MACH or SND_SOC_AMD_RV_RT5682_MACH
are selected, and GPIOLIB is not selected, Kbuild gives
the following warnings, respectively:

WARNING: unmet direct dependencies detected for SND_SOC_DMIC
  Depends on [n]: SOUND [=y] && !UML && SND [=y] && SND_SOC [=y] && GPIOLIB [=n]
  Selected by [y]:
  - SND_SOC_AMD_RENOIR_MACH [=y] && SOUND [=y] && !UML && SND [=y] && SND_SOC [=y] && SND_SOC_AMD_RENOIR [=y]

and

WARNING: unmet direct dependencies detected for SND_SOC_MAX98357A
  Depends on [n]: SOUND [=y] && !UML && SND [=y] && SND_SOC [=y] && GPIOLIB [=n]
  Selected by [y]:
  - SND_SOC_AMD_RV_RT5682_MACH [=y] && SOUND [=y] && !UML && SND [=y] && SND_SOC [=y] && SND_SOC_AMD_ACP3x [=y] && I2C [=y] && CROS_EC [=y]

This is because SND_SOC_DMIC and SND_SOC_MAX98357A are
selected by SND_SOC_AMD_RV_RT5682_MACH and SND_SOC_AMD_RENOIR_MACH,
respectively. However, neither of the selectors depend on or select GPIOLIB,
despite their selectees depending on GPIOLIB.

These unmet dependency bugs were detected by Kismet,
a static analysis tool for Kconfig. Please advise if this
is not the appropriate solution.
Signed-off-by: default avatarJulian Braha <julianbraha@gmail.com>
Link: https://lore.kernel.org/r/20211027184835.112916-1-julianbraha@gmail.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 1dcc81d9
...@@ -38,7 +38,7 @@ config SND_SOC_AMD_RV_RT5682_MACH ...@@ -38,7 +38,7 @@ config SND_SOC_AMD_RV_RT5682_MACH
select I2C_CROS_EC_TUNNEL select I2C_CROS_EC_TUNNEL
select SND_SOC_RT1015 select SND_SOC_RT1015
select SND_SOC_RT1015P select SND_SOC_RT1015P
depends on SND_SOC_AMD_ACP3x && I2C && CROS_EC depends on SND_SOC_AMD_ACP3x && I2C && CROS_EC && GPIOLIB
help help
This option enables machine driver for RT5682 and MAX9835. This option enables machine driver for RT5682 and MAX9835.
...@@ -51,7 +51,7 @@ config SND_SOC_AMD_RENOIR ...@@ -51,7 +51,7 @@ config SND_SOC_AMD_RENOIR
config SND_SOC_AMD_RENOIR_MACH config SND_SOC_AMD_RENOIR_MACH
tristate "AMD Renoir support for DMIC" tristate "AMD Renoir support for DMIC"
select SND_SOC_DMIC select SND_SOC_DMIC
depends on SND_SOC_AMD_RENOIR depends on SND_SOC_AMD_RENOIR && GPIOLIB
help help
This option enables machine driver for DMIC This option enables machine driver for DMIC
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment