Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

applications: sdp: mspi: Initial implementation #19077

Merged
merged 1 commit into from
Dec 4, 2024

Conversation

mif1-nordic
Copy link

Added initial mspi implementation with hard real time task running on interrupts.

@mif1-nordic mif1-nordic requested review from a team as code owners November 26, 2024 13:56
@github-actions github-actions bot added the changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. label Nov 26, 2024
@NordicBuilder
Copy link
Contributor

NordicBuilder commented Nov 26, 2024

CI Information

To view the history of this post, clich the 'edited' button above
Build number: 32

Inputs:

Sources:

sdk-nrf: PR head: e2fc7e80e7b5f39f92c739fc898ae6417bb1501f

more details

sdk-nrf:

PR head: e2fc7e80e7b5f39f92c739fc898ae6417bb1501f
merge base: ea198740d6eac8a367b00bc8a3c9671c53c34021
target head (main): f4e6aaf77bf1f4d1069e51fb93ad128bd75d80a9
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
List of changed files detected by CI (11)
applications
│  ├── sdp
│  │  ├── mspi
│  │  │  ├── CMakeLists.txt
│  │  │  ├── boards
│  │  │  │  ├── nrf54l15dk_nrf54l15_cpuflpr.conf
│  │  │  │  │ nrf54l15dk_nrf54l15_cpuflpr.overlay
│  │  │  ├── prj.conf
│  │  │  ├── sample.yaml
│  │  │  ├── src
│  │  │  │  ├── hrt
│  │  │  │  │  ├── hrt.c
│  │  │  │  │  ├── hrt.h
│  │  │  │  │  │ hrt.s
│  │  │  │  │ main.c
│  │  │  │ sysbuild.conf
cmake
│  │ sdp.cmake

Outputs:

Toolchain

Version: b77d8c1312
Build docker image: docker-dtr.nordicsemi.no/sw-production/ncs-build:b77d8c1312_912848a074

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

  • ◻️ Toolchain - Skipped: existing toolchain is used
  • ✅ Build twister - Skipped: Skipping Build & Test as it succeeded in a previous run: 30
  • ❌ Integration tests
    • ✅ test-sdk-audio - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ desktop52_verification - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-boot - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-apps - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test_ble_nrf_config - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-ble_mesh - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-ble_samples - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-chip - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-nfc - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-nrf-iot_libmodem-nrf - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-nrf-iot_serial_lte_modem - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-nrf-iot_zephyr_lwm2m - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-nrf-iot_samples - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-nrf-iot_lwm2m - Skipped: Job was skipped as it succeeded in a previous run
    • ❌ doc-internal
    • ✅ test-fw-nrfconnect-nrf-iot_thingy91 - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-nrf_crypto - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-rpc - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-rs - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-fem - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-tfm - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-thread - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-zigbee - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-sdk-find-my - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-nrf-iot_mosh
    • ✅ test-fw-nrfconnect-nrf-iot_positioning - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-sdk-sidewalk - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-sdk-wifi - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-low-level - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-nrf-iot_nrf_provisioning - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-sdk-pmic-samples - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-sdk-mcuboot - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-sdk-dfu - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-fw-nrfconnect-ps - Skipped: Job was skipped as it succeeded in a previous run
    • ✅ test-secdom-samples-public - Skipped: Job was skipped as it succeeded in a previous run

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

applications/sdp/mspi/CMakeLists.txt Outdated Show resolved Hide resolved
applications/sdp/mspi/sample.yaml Outdated Show resolved Hide resolved
applications/sdp/mspi/sample.yaml Outdated Show resolved Hide resolved
applications/sdp/mspi/src/backend/backend.h Outdated Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.h Outdated Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.h Outdated Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.s Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
@mif1-nordic mif1-nordic force-pushed the NoIpcPart branch 9 times, most recently from 89779ab to 46c2f4d Compare November 27, 2024 09:56
@NordicBuilder
Copy link
Contributor

You can find the documentation preview for this PR at this link. It will be updated about 10 minutes after the documentation build succeeds.

Note: This comment is automatically posted by the Documentation Publish GitHub Action.

@jaz1-nordic jaz1-nordic requested a review from a team November 27, 2024 10:37
Copy link
Contributor

@jaz1-nordic jaz1-nordic left a comment

Choose a reason for hiding this comment

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

I don't see the configuration and IPC part.
Will this be added in a separate PR?

applications/sdp/mspi/sample.yaml Outdated Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.h Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
@mif1-nordic mif1-nordic force-pushed the NoIpcPart branch 3 times, most recently from 6db8c81 to 404b685 Compare November 27, 2024 14:34
@masz-nordic
Copy link
Contributor

@nordicjm Can you take a look at applications/sdp/mspi/CMakeLists.txt?

applications/sdp/mspi/prj.conf Outdated Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.h Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Show resolved Hide resolved
applications/sdp/mspi/src/main.c Show resolved Hide resolved
applications/sdp/mspi/src/main.c Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
Copy link
Contributor

@nordicjm nordicjm left a comment

Choose a reason for hiding this comment

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

-- Using ccache: /usr/bin/ccache
CMake Warning at /tmp/bb/zephyr/CMakeLists.txt:952 (message):
  No SOURCES given to Zephyr library: drivers__mbox

  Excluding target from build.


CMake Warning (dev) at /tmp/bb/nrf/cmake/sdp.cmake:39 (add_custom_command):
  The following keywords are not supported when using
  add_custom_command(TARGET): DEPENDS.

  Policy CMP0175 is not set: add_custom_command() rejects invalid arguments.
  Run "cmake --help-policy CMP0175" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.
Call Stack (most recent call first):
  CMakeLists.txt:12 (sdp_assembly_generate)
This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Warning (dev) at /tmp/bb/nrf/cmake/sdp.cmake:39 (add_custom_command):
  Exactly one of PRE_BUILD, PRE_LINK, or POST_BUILD must be given.  Assuming
  POST_BUILD to preserve backward compatibility.

  Policy CMP0175 is not set: add_custom_command() rejects invalid arguments.
  Run "cmake --help-policy CMP0175" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.
Call Stack (most recent call first):
  CMakeLists.txt:12 (sdp_assembly_generate)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Configuring done (7.7s)
-- Generating done (0.1s)

this needs fixing

@nordicjm
Copy link
Contributor

I don't understand what the intention here is with this, should the .s file be present? Shouldn't it be generated by the build itself? If I build the application then run the asm_install command I get a completely different file e.g.

diff --git a/applications/sdp/mspi/src/hrt/hrt.s b/applications/sdp/mspi/src/hrt/hrt.s
index 1ba7a9026c..e4eece2a87 100644
--- a/applications/sdp/mspi/src/hrt/hrt.s
+++ b/applications/sdp/mspi/src/hrt/hrt.s
@@ -9,224 +9,182 @@
        .globl  write_single_by_word
        .type   write_single_by_word, @function
 write_single_by_word:
-       addi    sp,sp,-16
-       sw      s0,12(sp)
+       addi    sp,sp,-4
+       sw      s0,0(sp)
+       mv      t1,a4
  #APP
-       csrr t1, 3009
+       csrr a4, 3009
  #NO_APP
-       slli    t1,t1,16
-       srli    t1,t1,16
-       ori     t1,t1,35
+       ori     a4,a4,35
+       slli    a4,a4,16
+       srli    a4,a4,16
  #APP
-       csrw 3009, t1
-       csrr t1, 3008
+       csrw 3009, a4
+       csrr a4, 3008
  #NO_APP
-       slli    t1,t1,16
-       srli    t1,t1,16
-       ori     t1,t1,32
+       ori     a4,a4,32
+       slli    a4,a4,16
+       srli    a4,a4,16
  #APP
-       csrw 3008, t1
+       csrw 3008, a4

@mif1-nordic mif1-nordic force-pushed the NoIpcPart branch 2 times, most recently from bbacf51 to 17bf877 Compare November 29, 2024 12:21
@mif1-nordic mif1-nordic force-pushed the NoIpcPart branch 2 times, most recently from ebee9f9 to f910c03 Compare November 29, 2024 12:55
@mif1-nordic
Copy link
Author

@nordicjm How did you get this log, I'm not seing these warnings while building project

@masz-nordic masz-nordic requested a review from nordicjm November 29, 2024 16:53
@jaz1-nordic jaz1-nordic mentioned this pull request Dec 2, 2024
@nordicjm
Copy link
Contributor

nordicjm commented Dec 2, 2024

@nordicjm How did you get this log, I'm not seing these warnings while building project

Using cmake -GNinja -DBOARD=nrf54l15dk/nrf54l15/cpuflpr -DAPP_DIR=.. <zephyr>/share/sysbuild inside <app_dir>/build

Copy link
Contributor

@jaz1-nordic jaz1-nordic left a comment

Choose a reason for hiding this comment

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

LGTM, but there are still a few comments from Magda to take care of.

@mif1-nordic mif1-nordic force-pushed the NoIpcPart branch 6 times, most recently from 6ece761 to 7a16741 Compare December 3, 2024 08:27
Copy link
Contributor

@nordicjm nordicjm left a comment

Choose a reason for hiding this comment

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

Some nits. but cmake warnings are gone

applications/sdp/mspi/src/hrt/hrt.c Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/hrt/hrt.h Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
applications/sdp/mspi/src/main.c Outdated Show resolved Hide resolved
@nordicjm
Copy link
Contributor

nordicjm commented Dec 3, 2024

Apply comments throughout (only first instances were highlighted)

@mif1-nordic mif1-nordic force-pushed the NoIpcPart branch 3 times, most recently from bf204ce to 7c327f9 Compare December 3, 2024 11:00
@masz-nordic masz-nordic requested a review from nordicjm December 3, 2024 14:14
@mif1-nordic mif1-nordic force-pushed the NoIpcPart branch 2 times, most recently from 699ab5c to 3c2d40a Compare December 3, 2024 14:18
Added initial mspi implementation with hard real time task running on
interrupts.

Signed-off-by: Michal Frankiewicz <[email protected]>
Signed-off-by: Magdalena Pastula <[email protected]>
@carlescufi carlescufi merged commit 7ed31aa into nrfconnect:main Dec 4, 2024
12 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants