power: supply: max17042_battery: Do not use CONFIG_ prefix in regular C code
Subsystems (2)
PATCH 1/1 power: supply: max17042_battery: Do not use CONFIG_ prefix in regular C code
From: przemoch <[email protected]>
Using CONFIG_ prefix for macros is not a good practice. Use CONFIG_ prefix in Kconfig only.
Signed-off-by Przemyslaw Chwiala <[email protected]>
--- drivers/power/supply/max17042_battery.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/power/supply/max17042_battery.c +3 -3
@@ -36,7 +36,7 @@#define STATUS_BR_BIT (1 << 15)/* Interrupt mask bits */ -#define CONFIG_ALRT_BIT_ENBL (1 << 2) +#define CFG_ALRT_BIT_ENBL (1 << 2)#define VFSOC0_LOCK 0x0000#define VFSOC0_UNLOCK 0x0080
@@ -1116,8 +1116,8 @@ static int max17042_probe(struct i2c_client *client) chip);if (!ret) {regmap_update_bits (chip->regmap,MAX17042_CONFIG , -CONFIG_ALRT_BIT_ENBL , -CONFIG_ALRT_BIT_ENBL ); +CFG_ALRT_BIT_ENBL , +CFG_ALRT_BIT_ENBL );max17042_set_soc_threshold (chip,1 ); }else { client->irq =0 ;
Signature · 1 line
2.25.1
Quoted 1 line · Przemyslaw
From: przemoch <[email protected]>
Please use the same name in commit author and SoB.
Quoted 5 lines
Using
CONFIG_prefix for macros is not a good practice. UseCONFIG_prefix inKconfigonly.Signed-off-by Przemyslaw Chwiala <[email protected]>
Code is okay, so please send v2 with fixed author.
Best regards,
Krzysztof