Commit graph zephyr/scripts
Author SHA1 Message Date
Jérôme Pouiller
85bb1830c1 code_relocation: Fix case of source in application directory
In the case the required file is locate in the root directory of the
application, the parent directory is named "app.dir". So, it does not match
with the existing rule.

Add a second pass to check if the object file can be found in "app.dir".

Note this bug has not been found earlier because the application source are
usually placed in "src/" subdirectory.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
2026-07-12 20:00:59 -04:00
Benjamin Cabé
d2ebbd7e12 scripts: do not install/recommend vulnerable python packages
requests < 2.33.0 is subject to GHSA-gc5v-m9x4-r6x2
gitpython < 3.1.47 is subject to GHSA-rpm5-65cw-6hj4
gitpython < 3.1.47 is subject to GHSA-x2qx-6953-8485
gitpython < 3.1.48 is subject to GHSA-7545-fcxq-7j24
gitpython < 3.1.49 is subject to GHSA-v87r-6q3f-2j67
gitpython < 3.1.50 is subject to GHSA-mv93-w799-cj2w
Pillow < 12.1.1 is subject to GHSA-cfh3-3jmp-rvhc
Pillow < 12.2.0 is subject to GHSA-pwv6-vv43-88gr
Pillow < 12.2.0 is subject to GHSA-r73j-pqj5-w3x7
Pillow < 12.2.0 is subject to GHSA-whj4-6x5x-4v2j
Pillow < 12.2.0 is subject to GHSA-wjx4-4jcj-g98j
protobuf < 5.29.6 is subject to GHSA-7gcm-g887-7qv7
pytest < 9.0.3 is subject to GHSA-6w46-j5rx-g56g
python-dotenv < 1.2.2 is subject to GHSA-mf9w-mj56-hr94

pytest and python-dotenv had no minimum version, which OSV-based
scanners treat as being subject to every advisory for the package.

Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2026-07-11 07:31:57 -04:00
Etienne Carriere
086b5b43f7 scripts: dts: python-devicetree: warn required props with a default value
Emit a warning trace message when a DT property is required but
also provides a default value.

Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
2026-07-10 08:52:35 -05:00
Tomasz Chyrowicz
3c9a08aadf kconfig: Allow to get partition MTD path
The partition MTD path is required to correctly check if two partitions
overlap with each other.

Signed-off-by: Tomasz Chyrowicz <tomasz.chyrowicz@nordicsemi.no>
2026-07-10 08:51:55 -05:00
Grzegorz Chwierut
3a36fc670f twister: expand module directory variables in path fields
Twister resolves filesystem paths from test YAML through
os.path.expandvars(), which only substitutes process environment
variables. The most useful pointer to a module's root,
ZEPHYR_<MODULE>_MODULE_DIR, is a CMake build-system variable and is
not available at test-discovery time.

Add a helper that expands ZEPHYR_<MODULE>_MODULE_DIR and
ZEPHYR_<MODULE>_MODULE_NAME, mirroring the CMake variables defined for
every module, with the name sanitized and upper-cased exactly as the
build system does. Apply it when resolving required_applications and
required_devices paths and pytest_root, so the same spelling works in
both CMake and Twister contexts.

Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
2026-07-09 13:45:13 +01:00
Benjamin Cabé
30f46ed484 scripts: zspdx: reference cross-document elements via ExternalMap
Each SPDX 3.0 document re-serialized every element it referenced, so
packages and files defined in one document were duplicated in full into
every other document that mentioned them.

Declare such cross-document references with an ExternalMap import
instead of copying their definitions and effectively do something
similar to what the SPDX 2 serializer did.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2026-07-09 13:44:58 +01:00
Anas Nashif
467087f783 scripts: coverage: add per-test matrix dashboard tool
Add scripts/gen_test_matrix_dashboard.py, a standalone tool that turns a
Twister per-test coverage matrix (test_matrix.json) into a self-contained,
interactive HTML dashboard. It has no dependency on Twister and can be run
on any previously generated matrix.

The dashboard shows, per test, how many files and lines it covers
alongside how many lines it covers uniquely -- lines no other test
reaches -- with sortable columns so redundant tests (zero unique) and
load-bearing tests stand out. Selecting a test lists the files it covers
with per-file line and unique-line counts, and a file lookup shows which
tests cover each line, highlighting uniquely-covered lines. All derived
metrics are computed in the browser from the matrix inlined into the page.

Assisted-by: Claude:claude-opus-4-8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-09 10:10:37 +01:00
Anas Nashif
e0093c5ec5 twister: coverage: add per-test coverage matrix
Add a --coverage-per-test mode that collects an isolated coverage
artifact for every Ztest test case and post-processes them into a
test-to-code coverage matrix, answering "which tests covered line X of
file foo.c".

The mode builds on CONFIG_ZTEST_COVERAGE_PER_TEST. On platforms that
support semihosting (ARM/RISC-V/Xtensa under QEMU, e.g. mps2/*) the
transport is switched to semihosting so per-test data is written straight
to the host as "<gcda>@@<suite>.<test>", avoiding the large amount of
serial traffic per-test dumping would otherwise generate; other platforms
fall back to the console transport. The required Kconfig is injected into
the build overlay.

Each test is captured by invoking gcov directly -- one
"gcov --stdout --json-format" per test over its gcda set, materialized in
a temporary object tree with symlinks to the shared gcno -- and its JSON
is converted to an lcov tracefile. This is far cheaper than a full lcov
capture per test; lcov capture remains a fallback for non-GCC toolchains.

To keep the end-of-run aggregation proportional to the number of
instances rather than the number of tests, each instance's per-test
tracefiles are collapsed into a single untagged union, and the aggregate
matrix is built by merging the per-instance matrices. Function records
are omitted from the tracefiles because gcov reports per-function counts
and end lines inconsistently across per-test dumps, which would fail
lcov's merge consistency checks; line and branch coverage are unaffected.

Per-test mode requires the lcov coverage tool (the matrix relies on lcov
TN records; gcovr has no equivalent) and this is validated at
argument-parsing time. Output is one <scenario>.<test>.info per test
under each build's coverage/tests/ directory plus a test_matrix.json with
by_line ({file:{line:[tests]}}) and by_test views.

Covered by unit tests for the tracefile conversion, tracefile union,
matrix build and merge, and the tagged-dump discovery and parsing
helpers.

Assisted-by: Claude:claude-opus-4-8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-09 10:10:37 +01:00
Anas Nashif
16668f09c2 twister: coverage: quiet per-instance report log lines
With --coverage-per-instance, run_coverage_instance() generates a
coverage report for every test instance, and each generate() call
emitted an info-level '<FORMAT> report generated: ...' line. On a run
with many instances this floods the console with one line per instance.

Log the per-instance report messages at debug level and keep only the
final aggregated report at info level, so the console stays readable
while the detail is still available with -vv.

Assisted-by: Claude:claude-opus-4-8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-09 10:10:37 +01:00
Anas Nashif
0b901cca59 twister: coverage: auto-detect gcov tool from the build
When --gcov-tool was not given, coverage relied on ZEPHYR_SDK_INSTALL_DIR
being exported and then hardcoded the x86_64-zephyr-elf gcov path. That
fails when the variable is not in the environment (even though the build
itself resolves the SDK via CMake), and the hardcoded architecture is
wrong for non-x86 targets.

Each Zephyr build already records the resolved gcov binary as CMAKE_GCOV
in its CMakeCache.txt, which for the Zephyr SDK points at the SDK's cross
gcov matching the toolchain. Read it back and use it so the gcov tool is
detected automatically without any environment setup and matches the
gcno/gcda data for any target architecture.

Keep ZEPHYR_SDK_INSTALL_DIR as a fallback, sourced from the environment
or, failing that, from a build's CMakeCache.txt, before erroring out.

Assisted-by: Claude:claude-opus-4-8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-09 10:10:37 +01:00
Anas Nashif
fbbefff301 twister: coverage: guard against unset ZEPHYR_TOOLCHAIN_VARIANT
choose_gcov_tool() called .endswith() directly on the result of
os.environ.get("ZEPHYR_TOOLCHAIN_VARIANT"). When the variable is not
exported in the environment, get() returns None and the coverage run
aborts with:

  AttributeError: 'NoneType' object has no attribute 'endswith'

Provide an empty-string default so an unset variant safely falls
through to the system gcov / Zephyr SDK gcov branches instead of
crashing.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-09 10:10:37 +01:00
Anas Nashif
d081a6c7da twister: mark tests not run when configure-time simulator is missing
Some simulators resolve their executable at CMake configure time via
find_program() instead of being known during test planning, and the
binary that gets used can depend on the build configuration. Arm FVP is
the motivating case: Corstone-300 selects a different model depending on
the Ethos-U NPU, so armfvp cannot be listed in SUPPORTED_SIMS_WITH_EXEC
and checked up front. As a result, when the FVP binary was not installed
Twister still considered the test runnable, attempted to run nothing, and
reported a misleading status.

Inspect CMakeCache after the build instead: add a SIM_PROGRAM_CMAKE_VARS
mapping of simulator name to the cache variable recording its resolved
executable. When the variable is absent or holds a *-NOTFOUND value
(e.g. ARMFVP:FILEPATH=ARMFVP-NOTFOUND), mark the instance as NOTRUN with
a clear reason and propagate that status to its test cases, so the test
is no longer reported as runnable.

This check is done in the post_build stage, which now always runs after a
successful build; the --post-build-checks option only gates the optional
build-failing checks, which are skipped inside post_build when it is not
set. This keeps the not-run determination separate from gather_metrics,
where it did not belong.

Assisted-by: Claude:claude-opus-4-8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-09 10:10:04 +01:00
Benjamin Cabé
3e1a5ba385 scripts: zspdx: normalize discovered include paths
Compiler-reported paths may contain "." or "..", causing the same header
to be treated as multiple files. This substantially increases ownership,
license, hash, and relationship processing during --analyze-includes.

Normalize paths before deduplication. In a test build pulling in LVGL,
this reduced the include set from 50,000+ entries to ~1,200.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2026-07-08 18:29:03 -04:00
Pieter De Gendt
26ad9ce22e scripts: pylib: make jsonschema import in domains optional
domains.py is imported during west command discovery, before the
missing dependencies are installed. Since jsonschema is not a west
dependency, this broke `west update`. Wrap the import in a try-except
and only fail when a domains.yaml is actually parsed.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2026-07-08 09:58:34 +02:00
Appana Durga Kedareswara rao
abfd36bd55 runners: xsdb: prefer xsdb_cfg.tcl as default board config
Look for xsdb_cfg.tcl before xsdb.cfg under boards/<board>/support/
so new boards can use a .tcl extension for correct syntax highlighting
while existing xsdb.cfg scripts keep working unchanged.

Signed-off-by: Appana Durga Kedareswara rao <appana.durga.kedareswara.rao@amd.com>
2026-07-08 09:53:28 +02:00
Appana Durga Kedareswara rao
87c8249589 runners: xsdb: Add --pmufw and simplify optional argument handling
The ZynqMP APU boot flow needs bitstream, FSBL, BL31, and PMU firmware
in addition to the application ELF. Add a --pmufw CLI option to pass the
PMU firmware ELF path to the board xsdb.cfg script.
Replace the growing if/elif dispatch logic in do_run() with ordered
appending of non-None optional arguments (bitstream, fsbl, pdi, bl31,
system-dtb, pmufw). Each board TCL script continues to interpret argv
according to its own boot flow.
Extend the unit tests to cover the ZynqMP APU argument combination.

Signed-off-by: Appana Durga Kedareswara rao <appana.durga.kedareswara.rao@amd.com>
2026-07-08 09:53:28 +02:00
Jordan Yates
19df2dc284 testsuite: coverage: support REBOOT with COVERAGE_SEMIHOST
Extend the `SEMIHOST` data dump function with support for multiple dumps
per application run, such as when the test application is intentionally
testing reboot paths.

Instead of the final `filename.gcda` file being overwritten on each
boot, create a unique `filename.gcda.{X}` file per boot, which are then
merged back into `filename.gcda` by `coverage.py`. The merging step is
required as the coverage tools expect specific paths for the GCDA files
derived from the source filename, they are not searching through the
folders for any filenames containing 'gcda'.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2026-07-08 09:50:59 +02:00
Sylvio Alves
54b57d25e0 ci: set_assignees: keep deferred area label on the pr
Collect the deferred area's label when a file is matched by both a
deferred file-group and a non-deferred area. The deferral removed the
area before labels were gathered, so its area label was silently lost
even though its maintainer stayed on as a reviewer.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2026-07-07 17:52:56 -04:00
Jamie McCrae
31da142a93 scripts: dts: gen_defines: Fix ZEPHYR_BASE output
Fixes this missing output, which helps with repducible build
debugging, to use the zephyr prefix when the bindings are located
there irrespective of if the (long deprecated) environmental value
is set

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2026-07-07 09:52:35 +02:00
Pieter De Gendt
ed209c0847 scripts: ci: Share style-check plumbing between Kconfig and CMake
Replace the regex-based CMakeStyle check with one that runs
scripts/cmake/cmake_style.py on changed CMake files and reports the style
issues on the touched lines.
Create a common parent class for Kconfig and CMake style checks.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Assisted-by: Claude Code:claude-opus-4.8
2026-07-06 14:49:36 +01:00
Pieter De Gendt
f982e7aaa7 scripts: cmake: Add CMake style checker
Add scripts/cmake/cmake_style.py, a tree-sitter based checker for the CMake
style guidelines: line length, indentation, lowercase commands, no space
before '(', cache-variable casing and unquoted booleans.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Assisted-by: Claude Code:claude-opus-4.8
2026-07-06 14:49:36 +01:00
Pieter De Gendt
3b78fe24da scripts: Add tree-sitter/tree-sitter-cmake to requirements
Add the tree-sitter packages needed for CMake parsing to the scripts
requirements.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2026-07-06 14:49:36 +01:00
Anas Nashif
adb51af391 scripts: ci: add script to merge junit files
junitparser merge cant deal with the large number of files and sizes in
the weekly build. Introduce this helper script to merge 200 files into
one in a more efficient way.

Assisted-by: Claude:claude-opus-4.8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-06 10:31:00 +02:00
Anas Nashif
a8992667c5 ci: scripts: remove remaining testcase.yaml occurances
Remove sample.yank / testcase.yaml from test_plan script.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-05 15:31:50 -04:00
Anas Nashif
4d5e7a9e87 scripts: ci: check_compliance: reject legacy test metadata filenames
Add a TestMetadataFilename compliance check that fails when a change
introduces a new sample or test metadata file named sample.yaml or
testcase.yaml. Sample and test metadata are now stored in a single,
consistently named tests.yaml file across the tree, and this check
keeps the legacy names from creeping back in via new PRs. The failure
message tells the contributor to rename the file to tests.yaml.

Only newly added files (diff-filter=A) are inspected, so the check does
not flag pre-existing files and does not require a tree-wide cleanup to
pass.

Assisted-by: Claude:claude-opus-4-8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-05 15:31:50 -04:00
Anas Nashif
c4eedd43e0 twister: support preferred toolchain for a platform
Support using a different toolchain for a specific platform.
A platform can now set preferred_toolchain in the yaml file and this
toolchain will be used instead of the the default. This allows us to
test multiple toolchains and have some platforms build using the
preferred toolchain in CI. This applies only when running twister,
everything behaves as usual when building with west.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-04 20:53:42 -04:00
Yasushi SHOJI
38414cced6 west: runners: minichlink: Add dev-id support
Add support for the common `--dev-id` runner option to the minichlink
runner. The value is passed to minichlink with its `-c` option so boards
can select a specific serial port or USB VID/PID from board_runner_args().

This allows board.cmake to set a default probe identifier, for example:

    board_runner_args(minichlink "--dev-id=0x1209b803")

Signed-off-by: Yasushi SHOJI <yashi@spacecubics.com>
2026-07-04 20:53:28 -04:00
Anas Nashif
dbabd7fc63 ci: test_plan: remove references to sample.yaml
Remove more references to sample.yaml, still support it for a while.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-03 19:22:54 -04:00
Shankar Ramasamy
5240b88539 scripts: twister: removed deprecated cmsis_dap_serial argument
Clean up Twister OpenOCD runner by removing
deprecated cmsis_dap_serial argument and
replacing with adapter serial

Signed-off-by: Shankar Ramasamy <shankar.ramasamy@microchip.com>
2026-07-03 13:55:57 +02:00
Jordan Yates
81f8fe3cae scripts: twisterlib: coverage: output processing time
Processing the raw coverage data into the output `html` can take a
significant amount of time. Add a display for the duration, similar to
the timers for building the testsuite list and test build/execute times.

Example output:
```
INFO    - Built testsuite list in 0.04 seconds
...
INFO    - 16 of 16 executed test configurations passed (100.00%), 0 \
          built (not run), 0 failed, 0 errored, with no warnings in \
          25.85 seconds.
...
INFO    - Coverage data processed in 11.45 seconds
```

Signed-off-by: Jordan Yates <jordan@embeint.com>
2026-07-03 13:54:29 +02:00
Jamie McCrae
678d76a74b scripts: list_hardware: Allow listing SoC series and family
These fields should be able to be listed if the user/calling
process wants them

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2026-07-03 05:43:02 -04:00
Jamie McCrae
c21a31eaea scripts: list_hardware: FIx missing support for limiting results
Fixing missing support for --soc, --soc-family and --soc-series
arguments, which previously would just return all SoCs irrespective
of what was wanted

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2026-07-03 05:43:02 -04:00
Grzegorz Chwierut
e90f7ae25e twister: use suite id as testsuites registry key
Use suite id instead of name as the key in the testsuites
registry. With --detailed-test-id enabled, the suite name
includes the path, which caused a false duplicate error when a
required application was passed via -T on the command line and
was also listed in the required_application section of another
test.

Duplicated scenarios are reported as an error regardless of
whether --detailed-test-id is used.

Update the twister unit tests.

Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
2026-07-03 05:33:44 -04:00
Jamie McCrae
961b7a8019 cmake: yaml: Switch to JSON schema
Moves from the deprecated pykwalify to JSON schema

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2026-07-02 13:02:57 +01:00
Benjamin Cabé
9c9d29b79e scripts: zspdx: capture compile options and build environment
Enrich the Build profile with per-target compile flags and defines and
the key build inputs (board, arch, toolchain), mirroring the
Build-profile output of projects such as the Linux kernel.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2026-07-02 12:59:42 +01:00
Benjamin Cabé
5605da2f5b scripts: zspdx: emit the SPDX 3.0 Build profile
Emit the SPDX 3.0.1 Build profile, recording how the image and each
target was built. The profile is omitted when no build information is
available.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2026-07-02 12:59:42 +01:00
Benjamin Cabé
48e8804ec0 scripts: zspdx: collect build information for the SBOM graph
Gather the parsed toolchain, CMake file-API and per-target metadata
into the SBOM graph so serializers have the build details they need.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2026-07-02 12:59:42 +01:00
Benjamin Cabé
45ef9b7bc9 scripts: zspdx: parse CMake toolchains-v1 and CMake info
Parse the CMake file-API toolchains-v1 reply and cmake index object so
the SPDX 3.0 Build profile can describe the build toolchain.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2026-07-02 12:59:42 +01:00
Benjamin Cabé
6f39860931 scripts: zspdx: convert cmakefileapi classes to dataclasses
Replace the hand-written __init__ boilerplate in the CMake file-API
data classes with @dataclass field declarations, matching the style
already used elsewhere in zspdx (e.g. model.py). This makes the
module easier to extend with new data classes going forward.

No behavioral change: field defaults, __repr__ output, and the
zero-argument construction pattern used by cmakefileapijson.py are
all preserved.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2026-07-02 12:59:42 +01:00
Anas Nashif
c3a4efa51d scripts: checkpatch: recognize __aligned() in declarations
checkpatch reported a false-positive LINE_SPACING "Missing a blank line
after declarations" for local variables declared with __aligned(), e.g.:

	uint32_t eicr, embr, eicr_val;
	uint32_t __aligned(4) data32 = 0;

The LINE_SPACING heuristic decides whether a line is a declaration with
a regex that lets the type absorb trailing modifiers/attributes. But
__aligned was missing from the $Attribute list, so the type matched only
"uint32_t", $Ident then matched "__aligned", and the following "(" did
not match the expected [=,;:[] terminator. The line was therefore not
seen as a declaration and a blank line was demanded after the preceding
one.

Add __aligned to $Attribute, consuming its parenthesized argument
(including one level of nesting such as __aligned(sizeof(x))). This is
the root cause: __aligned(N) is now understood as a type attribute
everywhere, not only in the LINE_SPACING check.

Fixes #110417

Assisted-by: Claude:claude-opus-4-8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-01 17:05:11 -04:00
Guðni Már Gilbert
e68fdcfe32 scripts: dts: apply ruff format to gen_edt.py
Drop the script from .ruff-excludes.toml

Signed-off-by: Guðni Már Gilbert <gudni.m.g@gmail.com>
2026-07-01 14:32:29 -04:00
Anas Nashif
932effedd6 ci: set_assignees: add defer-to-other-areas file-group support
Add a new optional boolean field defer-to-other-areas to file-groups in
MAINTAINERS.yml.  When set to true it signals that the files in that
group are not the sole responsibility of the enclosing area: if another
area also covers the same files without the flag, that other area's
maintainer takes precedence as the PR assignee and the deferred area's
maintainers are added as reviewers instead.  When no non-deferred area
covers the files, the deferral has no effect and the area is used for
assignment as normal.

Typical use-case: the Clock Control subsystem owns generic driver
infrastructure under drivers/clock_control/, but a platform area also
covers the platform-specific files there.  The subsystem maintainer
adds those files to a deferred file-group so the platform maintainer
becomes the assignee while the subsystem maintainer is still notified
as a reviewer.

Assisted-by: GitHub Copilot:claude-sonnet-4.6
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2026-07-01 14:32:11 -04:00
Jamie McCrae
0f07a53476 scripts: pylib: build_helpers: domains: Switch to JSON schema
Moves from the deprecated pykwalify to JSON schema

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2026-07-01 05:36:29 -04:00
Jamie McCrae
b836fcdd70 scripts: list_shields: Switch to JSON schema
Moves from the deprecated pykwalify to JSON schema

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2026-07-01 05:36:20 -04:00
Benjamin Cabé
3099022a3c scripts: zspdx: scope SPDX 3.0 relationships to their owner document
Ownership was decided while mutating the set it was tested against, so a
relationship's endpoints pulled in further relationships and the build
graph cascaded into every document. Decide ownership from a snapshot of
the document's own elements instead.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Assisted-by: Claude:opus-4.8
2026-07-01 05:24:13 -04:00
Benjamin Cabé
edcf5fec0b scripts: zspdx: stop duplicating SPDX 3.0 relationships
Every relationship is also stored on its "from" element, so iterating the
graph-wide list in addition to components and files emitted each one
twice. Drop the redundant pass.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Assisted-by: Claude:opus-4.8
2026-07-01 05:24:13 -04:00
Benjamin Cabé
b19c13b3f8 scripts: zspdx: speed up SPDX 3.0 element collection
Deduplicating against the output list with "not in" ran the model's deep
__eq__ for every comparison and dominated serialization time. Track the
gathered element IDs in a set and skip by ID instead.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Assisted-by: Claude:opus-4.8
2026-07-01 05:24:13 -04:00
Emil Gydesen
2e9413f181 samples: Bluetooth: Move Audio samples to subdirectory
Move all LE Audio samples to their own subdirectory.

This makes it easier to find samples specific for LE Audio,
where there will be more coming.

This makes the samples directory follow the subsystem
and tests directory patterns as well.

This adds a place where LE Audio samples can place common
code, e.g. handling of LC3 and USB audio, without cluttering
the generic Bluetooth samples directory.

This makes it simpler to apply search patterns, such as the ones
in the MAINTAINERS file.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2026-07-01 05:22:15 -04:00
Tomas Galbicka
b6fe144fb9 ipc: service: backends: add RPMSG-Lite backend
Add a new IPC service backend based on the RPMsg-Lite library.
The backend implements the ipc_service_backend ops (open, close,
register/deregister endpoint, send, send_nocopy, get/drop TX buffer,
hold/release RX buffer) on top of the RPMsg-Lite virtio transport.

A new DT binding (nxp,ipc-rpmsg-lite) is introduced to describe
each RPMsg-Lite link instance: shared memory region, role (host/remote),
link-id, MBOX channels, and per-instance buffer/priority tunables.
Multiple links share a single MBOX channel pair via the
notification-parent property; platform_notify() dispatches the
encoded vector_id to the correct link.

Signed-off-by: Tomas Galbicka <tomas.galbicka@nxp.com>
2026-07-01 05:20:27 -04:00
Jamie McCrae
c34d78d2dc scripts: Remove pykwalify parts
These are no longer needed

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2026-06-30 18:24:12 -04:00