Re: [PATCH] max17042: Fix build errors caused by missing REGMAP_I2Cconfig

From: jonghwa3 . lee
Date: Sun Nov 24 2013 - 19:40:47 EST


On 2013ë 11ì 24ì 19:41, Austin Boyle wrote:

> max17042 now uses regmap interface but does not enable config option. This patch fixes the following build errors:
>
> drivers/power/max17042_battery.c:661:15: error: variable âmax17042_regmap_configâ has initializer but incomplete type
> drivers/power/max17042_battery.c:662:2: error: unknown field âreg_bitsâ specified in initializer
> drivers/power/max17042_battery.c:662:2: warning: excess elements in struct initializer
> drivers/power/max17042_battery.c:662:2: warning: (near initialization for âmax17042_regmap_configâ)
> drivers/power/max17042_battery.c:663:2: error: unknown field âval_bitsâ specified in initializer
> drivers/power/max17042_battery.c:663:2: warning: excess elements in struct initializer
> drivers/power/max17042_battery.c:663:2: warning: (near initialization for âmax17042_regmap_configâ)
> drivers/power/max17042_battery.c:664:2: error: unknown field âval_format_endianâ specified in initializer
> drivers/power/max17042_battery.c:664:23: error: âREGMAP_ENDIAN_NATIVEâ undeclared here (not in a function)
> drivers/power/max17042_battery.c:664:2: warning: excess elements in struct initializer
> drivers/power/max17042_battery.c:664:2: warning: (near initialization for âmax17042_regmap_configâ)
> drivers/power/max17042_battery.c: In function âmax17042_probeâ:
> drivers/power/max17042_battery.c:684:2: error: implicit declaration of function âdevm_regmap_init_i2câ
>
> Signed-off-by: Austin Boyle <boyle.austin@xxxxxxxxx>
> ---
> diff --git a/drivers/power/Kconfig b/drivers/power/Kconfig
> index 5e2054a..85ad58c 100644
> --- a/drivers/power/Kconfig
> +++ b/drivers/power/Kconfig
> @@ -196,6 +196,7 @@ config BATTERY_MAX17040
> config BATTERY_MAX17042
> tristate "Maxim MAX17042/17047/17050/8997/8966 Fuel Gauge"
> depends on I2C
> + select REGMAP_I2C
> help
> MAX17042 is fuel-gauge systems for lithium-ion (Li+) batteries
> in handheld and portable equipment. The MAX17042 is configured
>


Sorry, It's my fault. Thanks.

Acked-by: Jonghwa Lee <jonghwa3.lee@xxxxxxxxxxx>
--
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/