Commit c08442c8 authored by Andrzej Głąbek's avatar Andrzej Głąbek Committed by Maureen Helm
Browse files

modules: hal_nordic: Adapt nrfx_busy_wait() for !SYS_CLOCK_EXISTS case



When the SYS_CLOCK_EXISTS Kconfig option is not enabled, k_busy_wait()
has no implementation, so in such case, call nrfx_coredep_delay_us()
directly.

Signed-off-by: default avatarAndrzej Głąbek <andrzej.glabek@nordicsemi.no>
parent 38b23fd8
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -6,6 +6,7 @@

#include <nrfx.h>
#include <zephyr/kernel.h>
#include <soc/nrfx_coredep.h>

void nrfx_isr(const void *irq_handler)
{
@@ -14,7 +15,11 @@ void nrfx_isr(const void *irq_handler)

void nrfx_busy_wait(uint32_t usec_to_wait)
{
	if (IS_ENABLED(CONFIG_SYS_CLOCK_EXISTS)) {
		k_busy_wait(usec_to_wait);
	} else {
		nrfx_coredep_delay_us(usec_to_wait);
	}
}

char const *nrfx_error_string_get(nrfx_err_t code)