@@ -153,6 +153,27 @@ static const struct test_clk_ctx hfxo_test_clk_ctx[] = {
153153 .clk_specs_size = ARRAY_SIZE (test_clk_specs_hfxo ),
154154 },
155155};
156+
157+ const struct nrf_clock_spec test_clk_spec_audiopll [] = {
158+ {
159+ .frequency = MHZ (12 ),
160+ .accuracy = 0 ,
161+ .precision = 0 ,
162+ },
163+ {
164+ .frequency = MHZ (11 ),
165+ .accuracy = 0 ,
166+ .precision = 0 ,
167+ },
168+ };
169+
170+ static const struct test_clk_ctx audiopll_test_clk_ctx [] = {
171+ {
172+ .clk_dev = DEVICE_DT_GET (DT_NODELABEL (audiopll )),
173+ .clk_specs = test_clk_spec_audiopll ,
174+ .clk_specs_size = ARRAY_SIZE (test_clk_spec_audiopll ),
175+ },
176+ };
156177#endif /* CONFIG_BOARD_NRF54H20DK_NRF54H20_CPUAPP */
157178
158179static void test_request_release_clock_spec (const struct device * clk_dev ,
@@ -166,7 +187,7 @@ static void test_request_release_clock_spec(const struct device *clk_dev,
166187 LOG_INF ("Clock under test: %s" , clk_dev -> name );
167188 sys_notify_init_spinwait (& cli .notify );
168189 ret = nrf_clock_control_request (clk_dev , clk_spec , & cli );
169- __ASSERT_NO_MSG (ret == 0 );
190+ __ASSERT_NO_MSG (( ret >= 0 ) || ( ret <= 2 ) );
170191 do {
171192 ret = sys_notify_fetch_result (& cli .notify , & res );
172193 k_yield ();
@@ -236,6 +257,7 @@ void run_tests(void)
236257 test_auxpll_control (DEVICE_DT_GET (DT_NODELABEL (canpll )));
237258 test_clock_control_request (hfxo_test_clk_ctx , ARRAY_SIZE (hfxo_test_clk_ctx ));
238259 test_clock_control_request (hsfll_test_clk_ctx , ARRAY_SIZE (hsfll_test_clk_ctx ));
260+ test_clock_control_request (audiopll_test_clk_ctx , ARRAY_SIZE (audiopll_test_clk_ctx ));
239261#endif /* CONFIG_BOARD_NRF54H20DK_NRF54H20_CPUAPP */
240262 test_clock_control_request (global_hsfll_test_clk_ctx ,
241263 ARRAY_SIZE (global_hsfll_test_clk_ctx ));
0 commit comments