Skip to content

openthread: return OT_ERROR_BUSY from otPlatRadioSleep during TX - #30802

Open
edmont wants to merge 1 commit into
nrfconnect:mainfrom
edmont:pr/fix-ot-sleep
Open

openthread: return OT_ERROR_BUSY from otPlatRadioSleep during TX#30802
edmont wants to merge 1 commit into
nrfconnect:mainfrom
edmont:pr/fix-ot-sleep

Conversation

@edmont

@edmont edmont commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

Align nrf5 radio platform sleep behavior with OpenThread API: reject sleep requests while a Mac-initiated transmission is in progress using OT_ERROR_BUSY instead of OT_ERROR_INVALID_STATE.

Align nrf5 radio platform sleep behavior with OpenThread API: reject
sleep requests while a Mac-initiated transmission is in progress using
OT_ERROR_BUSY instead of OT_ERROR_INVALID_STATE.

Signed-off-by: Eduardo Montoya <eduardo.montoya@nordicsemi.no>
@edmont
edmont requested a review from a team as a code owner August 20, 2026 07:21
Copilot AI lite review requested due to automatic review settings August 20, 2026 07:21

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aligns the nRF5 OpenThread radio platform’s otPlatRadioSleep() behavior with the OpenThread API expectation by rejecting sleep requests while a MAC-driven transmission is in progress, returning OT_ERROR_BUSY (instead of OT_ERROR_INVALID_STATE).

Changes:

  • Add an early check in otPlatRadioSleep() to return OT_ERROR_BUSY when the radio state is OT_RADIO_STATE_TRANSMIT.
  • Preserve existing OT_ERROR_INVALID_STATE behavior for other disallowed states.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@NordicBuilder

NordicBuilder commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

CI Information

To view the history of this post, click the 'edited' button above
Build number: 1

Inputs:

Sources:

sdk-nrf: PR head: ad46909b1a46ecacf8dd1cea11b02e5b222aec6c

more details

sdk-nrf:

PR head: ad46909b1a46ecacf8dd1cea11b02e5b222aec6c
merge base: 40a978d1dd14e279c0fe6fed3530364d5582efea
target head (main): 40a978d1dd14e279c0fe6fed3530364d5582efea
Diff

Github labels

Enabled Name Description
ci-disabled Disable the ci execution
ci-all-test Run all of ci, no test spec filtering will be done
ci-force-downstream Force execution of downstream even if twister fails
ci-run-twister Force run twister
ci-run-zephyr-twister Force run zephyr twister
ci-run-draft Run CI on draft pull requests
List of changed files detected by CI (1)
modules
│  ├── openthread
│  │  ├── platform
│  │  │  │ radio_nrf5.c

Outputs:

Toolchain

Version: e214c2a47c
Build docker image: docker-dtr.nordicsemi.no/sw-production/ncs-build:e214c2a47c_a140d687bb

Test Spec & Results: ✅ Success; ❌ Failure; 🟠 Queued; 🟡 Progress; ◻️ Skipped; ⚠️ Quarantine

  • ◻️ Toolchain - Skipped: existing toolchain is used
  • ✅ Build twister
    • sdk-nrf test count: 137
  • ✅ Integration tests
    • ✅ test-fw-nrfconnect-thread-main
Disabled integration tests
    • test-fw-nrfconnect-nrf_lrcs_mosh
    • test-fw-nrfconnect-nrf_lrcs_positioning
    • desktop52_verification
    • test_ble_nrf_config
    • test-fw-nrfconnect-apps
    • test-fw-nrfconnect-apps_nrfdesktop
    • test-fw-nrfconnect-ble_mesh
    • test-fw-nrfconnect-ble_samples
    • test-fw-nrfconnect-fem
    • test-fw-nrfconnect-nfc
    • test-fw-nrfconnect-nrf-iot_libmodem-nrf
    • test-fw-nrfconnect-nrf-iot_lwm2m
    • test-fw-nrfconnect-nrf-iot_samples
    • test-fw-nrfconnect-nrf-iot_zephyr_lwm2m
    • test-fw-nrfconnect-nrf_crypto
    • test-fw-nrfconnect-rpc
    • test-fw-nrfconnect-rs
    • test-fw-nrfconnect-tfm
    • test-low-level
    • test-sdk-audio
    • test-sdk-dfu
    • test-sdk-find-my
    • test-sdk-mcuboot
    • test-sdk-wifi
    • test-sdk-wifi-net

Note: This message is automatically posted and updated by the CI

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants