Re: [PATCH] i2c: Fix Kconfig dependencies

From: Michal Marek
Date: Tue Oct 05 2010 - 11:56:40 EST


On Tue, Oct 05, 2010 at 10:03:49AM +0200, Jean Delvare wrote:
> Hmm, too bad. What about the following then? It's nor exactly elegant,
> but if it works for you...
>
> ---
> drivers/i2c/Kconfig | 3 ++-
> drivers/i2c/algos/Kconfig | 13 +++++++++++++
> 2 files changed, 15 insertions(+), 1 deletion(-)
>
> --- linux-2.6.36-rc6.orig/drivers/i2c/algos/Kconfig 2010-10-05 09:01:34.000000000 +0200
> +++ linux-2.6.36-rc6/drivers/i2c/algos/Kconfig 2010-10-05 09:40:40.000000000 +0200
> @@ -15,3 +15,16 @@ config I2C_ALGOPCA
> tristate "I2C PCA 9564 interfaces"
>
> endmenu
> +
> +# In automatic configuration mode, we still have to define the
> +# symbols to avoid unmet dependencies.
> +
> +if I2C_HELPER_AUTO
> +config I2C_ALGOBIT
> + tristate
> +config I2C_ALGOPCF
> + tristate
> +config I2C_ALGOPCA
> + tristate
> +endif
> +
> --- linux-2.6.36-rc6.orig/drivers/i2c/Kconfig 2010-10-05 09:01:34.000000000 +0200
> +++ linux-2.6.36-rc6/drivers/i2c/Kconfig 2010-10-05 09:04:57.000000000 +0200
> @@ -75,7 +75,8 @@ config I2C_HELPER_AUTO
> In doubt, say Y.
>
> config I2C_SMBUS
> - tristate "SMBus-specific protocols" if !I2C_HELPER_AUTO
> + tristate
> + prompt "SMBus-specific protocols" if !I2C_HELPER_AUTO

This works for me, thanks!

Acked-by: Michal Marek <mmarek@xxxxxxx>

Michal
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/