From 55b41863d584bf6f9efba374bcb8f9c7b0ab54c7 Mon Sep 17 00:00:00 2001 From: George Oikonomou Date: Sat, 24 Oct 2015 20:54:33 +0100 Subject: [PATCH] Remove redundant function calls in CC26xx RFC code As discussed in #1279, the current CC13xx/CC26xx rf-core code makes some unnecessary power domain-related reads. This commit removes them. Closes #1279 --- cpu/cc26xx-cc13xx/rf-core/rf-core.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/cpu/cc26xx-cc13xx/rf-core/rf-core.c b/cpu/cc26xx-cc13xx/rf-core/rf-core.c index 45387ab42..ee4a03971 100644 --- a/cpu/cc26xx-cc13xx/rf-core/rf-core.c +++ b/cpu/cc26xx-cc13xx/rf-core/rf-core.c @@ -114,9 +114,7 @@ PROCESS(rf_core_process, "CC13xx / CC26xx RF driver"); uint8_t rf_core_is_accessible() { - if(ti_lib_prcm_rf_ready() && - ti_lib_prcm_power_domain_status(PRCM_DOMAIN_RFCORE) == - PRCM_DOMAIN_POWER_ON) { + if(ti_lib_prcm_rf_ready()) { return RF_CORE_ACCESSIBLE; } return RF_CORE_NOT_ACCESSIBLE; @@ -221,10 +219,6 @@ rf_core_power_up() ti_lib_prcm_load_set(); while(!ti_lib_prcm_load_get()); - while(!rf_core_is_accessible()) { - PRINTF("rf_core_power_up: Not ready\n"); - } - HWREG(RFC_DBELL_NONBUF_BASE + RFC_DBELL_O_RFCPEIFG) = 0x0; HWREG(RFC_DBELL_NONBUF_BASE + RFC_DBELL_O_RFCPEIEN) = 0x0; ti_lib_int_enable(INT_RF_CPE0);