Skip to content

Commit 786985d

Browse files
de-nordicrghaddab
authored andcommitted
[nrf fromtree] sample/fs: Add nrf54l15pdk/nrf54l15/cpuapp to fs_sample
Adds custom overlay and config allowing the sample to run on the nrf54l15pdk. Signed-off-by: Dominik Ermel <[email protected]> (cherry picked from commit 12fa294)
1 parent 102dff8 commit 786985d

File tree

3 files changed

+60
-0
lines changed

3 files changed

+60
-0
lines changed
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#
2+
# Copyright (c) 2024 Nordic Semiconductor ASA
3+
#
4+
# SPDX-License-Identifier: Apache-2.0
5+
#
6+
7+
CONFIG_DISK_DRIVERS=y
8+
CONFIG_DISK_DRIVER_FLASH=y
9+
# There may be no files on internal SoC flash, so this Kconfig
10+
# options has ben enabled to create some if listing does not
11+
# find in the first place.
12+
CONFIG_FS_SAMPLE_CREATE_SOME_ENTRIES=y
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
/*
2+
* Copyright (c) 2024 Nordic Semiconductor ASA
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
/* Because FAT FS needs at least 64kiB partition and default
8+
* storage_partition is 36kiB for this board, we need to reorganize
9+
* partitions to get at least 64KiB.
10+
*/
11+
/delete-node/ &slot0_partition;
12+
/delete-node/ &slot1_partition;
13+
/delete-node/ &slot0_ns_partition;
14+
/delete-node/ &slot1_ns_partition;
15+
/delete-node/ &storage_partition;
16+
17+
&cpuapp_rram {
18+
partitions {
19+
compatible = "fixed-partitions";
20+
#address-cells = <1>;
21+
#size-cells = <1>;
22+
23+
slot0_partition: parition@10000 {
24+
reg = <0x00010000 DT_SIZE_K(300)>;
25+
};
26+
slot1_partition: partition@5b000 {
27+
reg = <0x0005b000 DT_SIZE_K(300)>;
28+
};
29+
30+
storage_partition: partition@a6000 {
31+
label = "storage";
32+
reg = <0x000a6000 DT_SIZE_K(128)>;
33+
};
34+
};
35+
};
36+
37+
/ {
38+
msc_disk0 {
39+
status="okay";
40+
compatible = "zephyr,flash-disk";
41+
partition = <&storage_partition>;
42+
disk-name = "SD";
43+
cache-size = <512>;
44+
};
45+
};

samples/subsys/fs/fs_sample/sample.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ tests:
4343
extra_args:
4444
- OVERLAY_CONFIG=boards/nrf52840dk_nrf52840_ram_disk.conf
4545
- DTC_OVERLAY_FILE=boards/nrf52840dk_nrf52840_ram_disk_region.overlay
46+
sample.filesystem.fat_fs.nrf54l15pdk:
47+
build_only: true
48+
platform_allow: nrf54l15pdk/nrf54l15/cpuapp
4649
sample.filesystem.fat_fs.nrf52840dk_nrf52840.qspi:
4750
build_only: true
4851
platform_allow: nrf52840dk/nrf52840

0 commit comments

Comments
 (0)