From e3ee1908ddf99711b65b46fdab0c7b4ddca7867d Mon Sep 17 00:00:00 2001 From: Aidan MacDonald Date: Mon, 29 Nov 2021 20:59:05 +0000 Subject: powermgmt: Small cleanups to battery capacity code - Don't include the 'battery capacity' setting unless the target allows changing it. - Clean up the preprocessor conditionals used to check for variable battery capacity support. - Don't use a variable for battery capacity unless it is actually needed. Change-Id: I3d8a338f107014f2c5098bc0a44ef0cfb4df9356 --- firmware/export/config.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'firmware/export/config.h') diff --git a/firmware/export/config.h b/firmware/export/config.h index bb3f405d6a..277a1d8632 100644 --- a/firmware/export/config.h +++ b/firmware/export/config.h @@ -709,6 +709,14 @@ Lyre prototype 1 */ #define BATTERY_CAPACITY_DEFAULT 0 #endif +#ifndef BATTERY_CAPACITY_MIN +#define BATTERY_CAPACITY_MIN BATTERY_CAPACITY_DEFAULT +#endif + +#ifndef BATTERY_CAPACITY_MAX +#define BATTERY_CAPACITY_MAX BATTERY_CAPACITY_DEFAULT +#endif + #ifndef BATTERY_CAPACITY_INC #define BATTERY_CAPACITY_INC 0 #endif -- cgit v1.2.3