Skip to content

Commit 5a56574

Browse files
nordic-krchnordicjm
authored andcommitted
all: nrfx_gppi: Fix parameter misuse in nrfx_gppi_ep_attach
Fix all places where order of arguments in nrfx_gppi_ep_attach was wrong. Signed-off-by: Krzysztof Chruściński <[email protected]> (cherry picked from commit c071ed6)
1 parent d6a90d0 commit 5a56574

File tree

7 files changed

+17
-17
lines changed

7 files changed

+17
-17
lines changed

samples/bluetooth/conn_time_sync/src/controller_time_nrf52.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ int config_egu_trigger_on_rtc_and_timer_match(void)
182182
printk("Failed allocating for RTC match\n");
183183
return ret;
184184
}
185-
(void)nrfx_gppi_ep_attach(ppi_on_timer_match, nrfx_gppi_group_task_dis_addr(group));
185+
(void)nrfx_gppi_ep_attach(nrfx_gppi_group_task_dis_addr(group), ppi_on_timer_match);
186186

187187
return 0;
188188
}

samples/bluetooth/conn_time_sync/src/controller_time_nrf53_app.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ int config_egu_trigger_on_rtc_and_timer_match(void)
153153
printk("Failed allocating for RTC match\n");
154154
return ret;
155155
}
156-
(void)nrfx_gppi_ep_attach(ppi_on_timer_match, nrfx_gppi_group_task_dis_addr(group));
156+
(void)nrfx_gppi_ep_attach(nrfx_gppi_group_task_dis_addr(group), ppi_on_timer_match);
157157

158158
return 0;
159159
}

samples/bluetooth/iso_time_sync/src/controller_time_nrf52.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ int config_egu_trigger_on_rtc_and_timer_match(void)
181181
printk("Failed allocating for RTC match\n");
182182
return ret;
183183
}
184-
(void)nrfx_gppi_ep_attach(ppi_on_timer_match, nrfx_gppi_group_task_dis_addr(group));
184+
(void)nrfx_gppi_ep_attach(nrfx_gppi_group_task_dis_addr(group), ppi_on_timer_match);
185185

186186
return 0;
187187
}

samples/bluetooth/iso_time_sync/src/controller_time_nrf53_app.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ int config_egu_trigger_on_rtc_and_timer_match(void)
154154
printk("Failed allocating for RTC match\n");
155155
return ret;
156156
}
157-
(void)nrfx_gppi_ep_attach(ppi_on_timer_match, nrfx_gppi_group_task_dis_addr(group));
157+
(void)nrfx_gppi_ep_attach(nrfx_gppi_group_task_dis_addr(group), ppi_on_timer_match);
158158

159159
return 0;
160160
}

samples/peripheral/radio_test/src/radio_test.c

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -452,15 +452,15 @@ static void radio_ppi_config(bool rx)
452452
{
453453
endpoints_clear();
454454

455-
nrfx_gppi_ep_attach(ppi_radio_start,
456-
nrf_egu_event_address_get(RADIO_TEST_EGU, RADIO_TEST_EGU_EVENT));
457-
nrfx_gppi_ep_attach(ppi_radio_start,
458-
nrf_radio_task_address_get(NRF_RADIO,
459-
rx ? NRF_RADIO_TASK_RXEN : NRF_RADIO_TASK_TXEN));
455+
nrfx_gppi_ep_attach(nrf_egu_event_address_get(RADIO_TEST_EGU, RADIO_TEST_EGU_EVENT),
456+
ppi_radio_start);
457+
nrfx_gppi_ep_attach(nrf_radio_task_address_get(NRF_RADIO,
458+
rx ? NRF_RADIO_TASK_RXEN : NRF_RADIO_TASK_TXEN),
459+
ppi_radio_start);
460460
atomic_set_bit(&endpoint_state, (rx ? ENDPOINT_EGU_RADIO_RX : ENDPOINT_EGU_RADIO_TX));
461461

462-
nrfx_gppi_ep_attach(ppi_radio_start,
463-
nrf_timer_task_address_get(timer.p_reg, NRF_TIMER_TASK_START));
462+
nrfx_gppi_ep_attach(nrf_timer_task_address_get(timer.p_reg, NRF_TIMER_TASK_START),
463+
ppi_radio_start);
464464
atomic_set_bit(&endpoint_state, ENDPOINT_FORK_EGU_TIMER);
465465

466466
nrfx_gppi_conn_enable(ppi_radio_start);
@@ -472,10 +472,10 @@ static void radio_ppi_tx_reconfigure(void)
472472

473473
endpoints_clear();
474474

475-
nrfx_gppi_ep_attach(ppi_radio_start,
476-
nrf_timer_event_address_get(timer.p_reg, NRF_TIMER_EVENT_COMPARE1));
477-
nrfx_gppi_ep_attach(ppi_radio_start,
478-
nrf_radio_task_address_get(NRF_RADIO, NRF_RADIO_TASK_TXEN));
475+
nrfx_gppi_ep_attach(nrf_timer_event_address_get(timer.p_reg, NRF_TIMER_EVENT_COMPARE1),
476+
ppi_radio_start);
477+
nrfx_gppi_ep_attach(nrf_radio_task_address_get(NRF_RADIO, NRF_RADIO_TASK_TXEN),
478+
ppi_radio_start);
479479
atomic_set_bit(&endpoint_state, ENDPOINT_TIMER_RADIO_TX);
480480

481481
nrfx_gppi_conn_enable(ppi_radio_start);

subsys/debug/cpu_load/cpu_load.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ static int ppi_setup(uint32_t eep, uint32_t tep)
8383
if (err >= 0) {
8484
/* It works only on single domain DPPI. */
8585
handle = (nrfx_gppi_handle_t)err;
86-
nrfx_gppi_ep_attach(handle, tep);
86+
nrfx_gppi_ep_attach(tep, handle);
8787
return 0;
8888
}
8989

subsys/mpsl/pin_debug/mpsl_pin_debug_radio_core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ static int m_ppi_config(void)
4949
#endif
5050
for (size_t i = 0; ARRAY_SIZE(tep); i++) {
5151
#if defined(DPPI_PRESENT)
52-
nrfx_gppi_ep_attach(handle[i], tep[i]);
52+
nrfx_gppi_ep_attach(tep[i], handle[i]);
5353
#else
5454
int err = nrfx_gppi_conn_alloc(eep[i], tep[i], &handle[i]);
5555

0 commit comments

Comments
 (0)