Skip to content

examples/advanced/xipfs: Add mountpoint memory image inclusion and mi…#22345

Open
GGuche-2XS-Univ-Lille wants to merge 2 commits into
RIOT-OS:masterfrom
GGuche-2XS-Univ-Lille:xipfs_incbin_pr
Open

examples/advanced/xipfs: Add mountpoint memory image inclusion and mi…#22345
GGuche-2XS-Univ-Lille wants to merge 2 commits into
RIOT-OS:masterfrom
GGuche-2XS-Univ-Lille:xipfs_incbin_pr

Conversation

@GGuche-2XS-Univ-Lille

Copy link
Copy Markdown
Contributor

…xed examples

  • Former xipfs example has been moved to xips_minimal_example
  • Pre-made offboard mountpoint memory image example has been added.
  • An example mixing allocated and included XiPFS mountpoints has been added. This example showcases XiPFS usage in source code.
  • XiPFS has been bumped to latest version.
  • tests have been fixed accordingly.
  • A double mutex lock has been fixed in unlink handler

Testing procedure

All examples have been tested on the dwm1001 board.

Each example is now detailed in an associated README.md file, next to sources.

For all examples :

  • please go to the relevant folder,
  • build and flash binary as usually,
  • read and follow the RIOT example usage section in the related README.mddocument.

@github-actions github-actions Bot added Area: doc Area: Documentation Area: tests Area: tests and testing framework Area: pkg Area: External package ports Area: sys Area: System Area: examples Area: Example Applications labels Jun 4, 2026
@crasbe crasbe added Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR labels Jun 4, 2026
@riot-ci

riot-ci commented Jun 4, 2026

Copy link
Copy Markdown

Murdock results

✔️ PASSED

14067ed fixup! examples/advanced/xipfs: Add mountpoint memory image inclusion and mixed examples

Success Failures Total Runtime
11128 0 11128 14m:54s

Artifacts

@AnnsAnns

AnnsAnns commented Jun 4, 2026

Copy link
Copy Markdown
Member

Hey, thank you for your PR, just out of curiosity since the AI declaration section wasn't included in the PR description, was any AI used in this?

@GGuche-2XS-Univ-Lille

GGuche-2XS-Univ-Lille commented Jun 4, 2026

Copy link
Copy Markdown
Contributor Author

@AnnsAnns Thank you for reviewing this PR.
No, there was no AI involved in this code.

Sorry, I thought that I had to mention it only if it was the case; I cleared this section of the template too quickly it seems.

Of course, I can edit the initial submission form, but could you please remind me what the text was ?
I fail to remember what was pre-filled right now.

@AnnsAnns

AnnsAnns commented Jun 4, 2026

Copy link
Copy Markdown
Member

@AnnsAnns Thank you for reviewing this PR. No, there was no IA involved in this code.

Sorry, I thought that I had to mention it only if it was the case; I cleared this section of the template too quickly it seems.

Of course, I can edit the initial submission form, but could you please remind me what the text was ? I fail to remember what was pre-filled right now.

All good, just wanted to have the confirmation, thank you for your PR

@crasbe crasbe left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Please note that a lot of the comments are general and should be applied to the other code files too, I just did not want to mark all the spots repeatedly.

Comment thread examples/advanced/xipfs/xipfs_complete_example/main.c
Comment thread examples/advanced/xipfs/xipfs_complete_example/main.c Outdated
Comment thread examples/advanced/xipfs/xipfs_complete_example/main.c Outdated
Comment thread examples/advanced/xipfs/xipfs_complete_example/main.c Outdated
Comment thread examples/advanced/xipfs/xipfs_complete_example/main.c Outdated
Comment thread examples/advanced/xipfs/xipfs_minimal_example/README.md Outdated
Comment thread examples/advanced/xipfs/xipfs_memory_image_example/README.md Outdated
Comment thread sys/include/fs/xipfs_fs.h Outdated
Comment thread sys/include/fs/xipfs_fs.h Outdated
Comment thread sys/include/fs/xipfs_fs.h Outdated
…xed examples

- Former xipfs example has been moved to xips_minimal_example
- Pre-made offboard mountpoint memory image example has been added.
- An example mixing allocated and included XiPFS mountpoints has been added.
This example showcases XiPFS usage in source code.
- XiPFS has been bumped to latest version.
- tests have been fixed accordingly.
- A double mutex lock has been fixed in unlink handler
@GGuche-2XS-Univ-Lille

Copy link
Copy Markdown
Contributor Author

@crasbe Thanks for your thorough review.
I took care to follow your remarks globally when required.
Please let me know if you spot some misses.

@crasbe crasbe left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think these are the only things I noticed.

Comment on lines +53 to +54
* @retval < 0 on errors
* @retval >= 0 otherwise

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
* @retval < 0 on errors
* @retval >= 0 otherwise
* @retval <0 on errors
* @retval >=0 otherwise

For retval to work, it's important not to leave a space here.

This is from another function, as .c files are not evaluated, but you get the idea.
Image

Comment thread sys/include/fs/xipfs_fs.h
*
* @retval Less than 0 on errors.
* @retval 0 on success.
* @retval < 0 on errors.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
* @retval < 0 on errors.
* @retval <0 on errors.

Comment thread sys/include/fs/xipfs_fs.h
Comment on lines +205 to +206
* @retval < 0 on errors.
* @retval >= 0 on success.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
* @retval < 0 on errors.
* @retval >= 0 on success.
* @retval <0 on errors.
* @retval >=0 on success.

Two FAE files have been crafted and are provided for demonstration purposes:

- `hello-world.fae`, which prints the traditional "Hello World!" message and displays the current temperature.
Source code is available in the folder [01-main](https://github.com/2xs/riot-xipfs-demonstrations/tree/master/01-main)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
Source code is available in the folder [01-main](https://github.com/2xs/riot-xipfs-demonstrations/tree/master/01-main)
Source code is available in the folder
[01-main](https://github.com/2xs/riot-xipfs-demonstrations/tree/master/01-main)

The two README.md files have some long lines that can be broken down. The exception are URLs that are too long themselves, as they cannot be broken into multiple lines.

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

Labels

Area: doc Area: Documentation Area: examples Area: Example Applications Area: pkg Area: External package ports Area: sys Area: System Area: tests Area: tests and testing framework CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants