From cf34beebb0ddb03b86a67dfee89753b8933c8bf4 Mon Sep 17 00:00:00 2001 From: Martin Ling Date: Wed, 21 Sep 2022 12:08:47 +0100 Subject: [PATCH] Remove extra call to switchctrl_set and global switchctrl variable. This call is not required since the GPIOs are already configured in rf_path_pin_setup(). The global switchctrl is not used anywhere else. --- firmware/common/rf_path.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/firmware/common/rf_path.c b/firmware/common/rf_path.c index 691cf761..a7b14050 100644 --- a/firmware/common/rf_path.c +++ b/firmware/common/rf_path.c @@ -79,8 +79,6 @@ SWITCHCTRL_MIX_BYPASS | SWITCHCTRL_HP | SWITCHCTRL_NO_RX_AMP_PWR) #endif -uint8_t switchctrl = SWITCHCTRL_SAFE; - /* * Antenna port power on HackRF One is controlled by GPO1 on the RFFC5072. * This is the only thing we use RFFC5072 GPO for on HackRF One. The value of @@ -343,7 +341,7 @@ void rf_path_init(rf_path_t* const rf_path) #ifndef HACKRF_ONE mixer_setup(&mixer); #endif - switchctrl_set(rf_path, switchctrl); + (void) rf_path; /* silence unused param warning */ } void rf_path_set_direction(rf_path_t* const rf_path, const rf_path_direction_t direction)