Skip to content

Commit 400fd18

Browse files
nika-nordichenrikbrixandersen
authored andcommitted
drivers: clock_control: nrf: ifdef optional events
Some of the CLOCK events are associated with features not available on every nRF device. Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
1 parent a708cca commit 400fd18

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

drivers/clock_control/clock_control_nrf.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -629,6 +629,7 @@ static void clock_event_handler(nrfx_clock_evt_type_t event)
629629
}
630630
clkstarted_handle(dev, CLOCK_CONTROL_NRF_TYPE_LFCLK);
631631
break;
632+
#if NRF_CLOCK_HAS_CALIBRATION
632633
case NRFX_CLOCK_EVT_CAL_DONE:
633634
if (IS_ENABLED(CONFIG_CLOCK_CONTROL_NRF_DRIVER_CALIBRATION)) {
634635
z_nrf_clock_calibration_done_handler();
@@ -637,7 +638,10 @@ static void clock_event_handler(nrfx_clock_evt_type_t event)
637638
__ASSERT_NO_MSG(false);
638639
}
639640
break;
641+
#endif
642+
#if NRF_CLOCK_HAS_PLL
640643
case NRFX_CLOCK_EVT_PLL_STARTED:
644+
#endif
641645
#if NRF_CLOCK_HAS_XO_TUNE
642646
case NRFX_CLOCK_EVT_XO_TUNED:
643647
case NRFX_CLOCK_EVT_XO_TUNE_ERROR:

0 commit comments

Comments
 (0)