From 179cd9b162555da94eb079e651a51c6193f56813 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Thu, 25 Feb 2021 10:08:59 +0100 Subject: [PATCH] fix: linking error when USE_MSP_DISPLAYPORT is undefined --- src/main/config/config.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/config/config.c b/src/main/config/config.c index 31744673f8..58f0235602 100644 --- a/src/main/config/config.c +++ b/src/main/config/config.c @@ -599,6 +599,7 @@ static void validateAndFixConfig(void) batteryConfigMutable()->vbatmaxcellvoltage = VBAT_CELL_VOLTAGE_DEFAULT_MAX; } +#ifdef USE_MSP_DISPLAYPORT // validate that displayport_msp_serial is referencing a valid UART that actually has MSP enabled if (displayPortProfileMsp()->displayPortSerial != SERIAL_PORT_NONE) { const serialPortConfig_t *portConfig = serialFindPortConfiguration(displayPortProfileMsp()->displayPortSerial); @@ -610,6 +611,7 @@ static void validateAndFixConfig(void) displayPortProfileMspMutable()->displayPortSerial = SERIAL_PORT_NONE; } } +#endif #if defined(TARGET_VALIDATECONFIG) // This should be done at the end of the validation