On 4/8/20 1:55 PM, Arnd Bergmann wrote:
When I2C is disabled, building rt5682 produces a compile-time error: sound/soc/codecs/rt5682.c:3716:1: warning: data definition has no type or storage class 3716 | module_i2c_driver(rt5682_i2c_driver); | ^~~~~~~~~~~~~~~~~ sound/soc/codecs/rt5682.c:3716:1: error: type defaults to 'int' in declaration of 'module_i2c_driver' [-Werror=implicit-int] sound/soc/codecs/rt5682.c:3716:1: warning: parameter names (without types) in function declaration sound/soc/codecs/rt5682.c:3706:26: error: 'rt5682_i2c_driver' defined but not used [-Werror=unused-variable] 3706 | static struct i2c_driver rt5682_i2c_driver = { | ^~~~~~~~~~~~~~~~~ Move the i2c specific entry points into an #ifdef section so it can actually be built standalone. Fixes: 5549ea647997 ("ASoC: rt5682: fix unmet dependencies")
it's already fixed by [PATCH -next] ASoC: rt5682: Fix build error without CONFIG_I2C