4 #include "sw/device/lib/crypto/drivers/ibex.h"
8 #include "sw/device/lib/base/status.h"
10 #include "sw/device/lib/testing/test_framework/check.h"
15 #include "rv_core_ibex_regs.h"
21 OTTF_DEFINE_TEST_CONFIG();
23 static status_t ibex_entropy_test(
void) {
28 TRY(ibex_rnd_data_read(rnd_data));
30 TRY(ibex_wait_rnd_valid());
31 TRY(ibex_rnd_status_read(&rnd_status));
33 RV_CORE_IBEX_RND_STATUS_RND_DATA_VALID_BIT));
35 TRY(ibex_rnd_data_read(&rnd_data[1]));
36 TRY_CHECK(rnd_data[0] != rnd_data[1]);
45 return status_ok(result);