From 3fc2be977f17916a9b8fbf3ba5cb27a35fd1d457 Mon Sep 17 00:00:00 2001 From: Bjarki Arge Andreasen Date: Sat, 14 Dec 2024 23:05:32 +0100 Subject: [PATCH] Revert "[nrf fromlist] drivers: clock_control: nrf: Add helper macro for getting clock frequency" This reverts commit 91c801c3cad1c52c1f21b477171a33dbf87e0668. Signed-off-by: Bjarki Arge Andreasen --- .../drivers/clock_control/nrf_clock_control.h | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/include/zephyr/drivers/clock_control/nrf_clock_control.h b/include/zephyr/drivers/clock_control/nrf_clock_control.h index 7b660c104a7..2578feffd2b 100644 --- a/include/zephyr/drivers/clock_control/nrf_clock_control.h +++ b/include/zephyr/drivers/clock_control/nrf_clock_control.h @@ -319,25 +319,6 @@ int nrf_clock_control_cancel_or_release(const struct device *dev, #endif /* defined(CONFIG_CLOCK_CONTROL_NRF2) */ -/** @brief Get clock frequency that is used for the given node. - * - * Macro checks if node has clock property and if yes then if clock has clock_frequency property - * then it is returned. If it has supported_clock_frequency property with the list of supported - * frequencies then the last one is returned with assumption that they are ordered and the last - * one is the highest. If node does not have clock then 16 MHz is returned which is the default - * frequency. - * - * @param node Devicetree node. - * - * @return Frequency of the clock that is used for the node. - */ -#define NRF_PERIPH_GET_FREQUENCY(node) \ - COND_CODE_1(DT_CLOCKS_HAS_IDX(node, 0), \ - (COND_CODE_1(DT_NODE_HAS_PROP(DT_CLOCKS_CTLR(node), clock_frequency), \ - (DT_PROP(DT_CLOCKS_CTLR(node), clock_frequency)), \ - (DT_PROP_LAST(DT_CLOCKS_CTLR(node), supported_clock_frequency)))), \ - (NRFX_MHZ_TO_HZ(16))) - #ifdef __cplusplus } #endif