When we determine the address and size cells to determine how to parse a
reg property, we need to stop at the parent of the node, not at the node
itself. If we have #address-cells or #size-cells in a node its meant
for the children of that node and not the node itself.
Fixes#4568
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
For those still using old variable ZEPHYR_GCC_VARIANT.
raise an error if the variable is not defined.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Add the STM32 ccm_bss, ccm_noinit, abd ccm_data sections
to the list of allowed sections so the sanity check passes.
Signed-off-by: Erwin Rol <erwin@erwinrol.com>
Allow for any toolchain variants to be useable with sanitycheck without
the need for them to be registered.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
We want to support other toolchain not based on GCC, so the variable is
confusing, use ZEPHYR_TOOLCHAIN_VARIANT instead.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
As per current policy of requiring supervisor mode to register
callbacks, dma_config() is omitted.
A note added about checking the channel ID for start/stop, current
implementations already do this but best make it explicitly
documented.
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
It is important that it is easy to reproduce CI issues locally. Using
the same sanitycheck options locally and in CI helps in this
regard. Specifically, Ninja and Make can produce different results and
therefore the default generator should be the same for sanitycheck and
shippable.
This patch makes four changes:
The sanitycheck option '--make' is introduced to allow specifying Make
as a generator.
CI no longer passes the option '--ninja' to sanitycheck.
Sanitycheck defaults to using Ninja.
Sanitycheck documents the --ninja option as deprecated.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
When generating coverage report:
* Also generate branch coverage
* If the report is properly generated tell user where to find it
* Handle case in which no ztests are run (it would crash before)
Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com>
Aligned sanitycheck command line options in doc
with the actual ones.
+
Minor fix in --coverage description.
Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com>
Sort the glob results when Kconfig sources do 'source
"/path/*/Kconfig"' to ensure that the resulting dotconfig file is the
same for all platforms.
This fixes#5743
Credit goes to @ulfalizer.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
sanitycheck: Compile unit tests with coverage enabled always
+ run also first unit tests together with native_posix
shippable: also include unit_testing coverage into report to
codecov
Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com>
Added a label for soc-nv-flash nodes. Made some updates to the
generation to maintain creating defines for properties like
erase-block-size and write-block-size so they we get both
FLASH_ERASE_BLOCK_SIZE and FLASH_${LABEL}_ERASE_BLOCK_SIZE (same for
WRITE_BLOCK_SIZE).
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This patch adds app_pad and priv_stacks to the rw section list so that
tests which validate the sections found in the binary pass when run on
systems which contain MPUs.
Signed-off-by: Andy Gross <andy.gross@linaro.org>
Rather than having handler generate differently named log files,
generate the same for all handlers, so qemu, native and unit will now
generate handler.log.
This will simplify things and reporting will be consistent. Also, this
fixes a bug where we only included qemu.log in generated reports.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This patch converts over the current ELF processing scripts to use the
new elf helper python library.
Signed-off-by: Andy Gross <andy.gross@linaro.org>
This patch adds a python helper library that encapsulates the ELF
processing being done across multiple scripts. Users of this script
will be converted over in a following patch.
Signed-off-by: Andy Gross <andy.gross@linaro.org>
This patch adds the generation and incorporation of privileged stack
regions that are used by ARM user mode threads. This patch adds the
infrastructure for privileged stacks. Later patches will utilize the
generated stacks and helper functions.
Signed-off-by: Chunlin Han <chunlin.han@linaro.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
This patch adds application data section alignment constraints
to match the region definition requirements for ARM MPUs. Most MPUs
require a minimum of 32 bytes of alignment for any regions, but some
require power of two alignment to the size of a region.
This requires that the linker align the application data section to
the size of the section. This requires a linker pass to determine the
size. Once this is accomplished the correct value is added to a linker
include file that is utilized in subsequent linker operations.
Signed-off-by: Andy Gross <andy.gross@linaro.org>
A lot of improvements have made it into Kconfiglib since we introduced
it into Zephyr. This rebases our 2 Zephyr-specific commits into the
latest Kconfiglib upstream.
Origin: https://github.com/zephyrproject-rtos/Kconfiglib/tree/zephyr
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
When adding support for the 'flash' command to the jlink runner, it was
not clear if the jlink commander would erase flash before programming,
therefore an explicit mass erase was implemented in the jlink runner as
a precaution and enabled by default.
The Segger folks later confirmed that the jlink commander does an
implicit erase of relevant flash sectors with the loadbin command,
therefore the explicit mass erase is not required.
Keep the mass erase option available in the jlink runner, but change the
default to false.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
When building the testcase path, replace symlinks in path
with the realpath both in the testcase root and in ZEPHYR_BASE
For more info see issue #5772Fixes: #5772
Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com>
Adds support for the 'flash' command to the jlink runner so we can flash
via 'make flash'. This works by generating a temporary jlink commander
script file and passing the script to the jlink commander executable.
Previously, the only way to flash with jlink was via 'make debug'.
Includes support for DT based flash address, and an optional mass erase
before loading the flash.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Instead of crashing when a source file outside of ZEPHYR_BASE is
detected we accept it as-is to include it in the report.
This fixes#5866
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
Its possible we have dashes in interrupt names that we need to convert
to underscores when we generate defines. Make sure we do that otherwise
things aren't going to build.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Some boards do not generate .bin files by default, this file is however
needed when generating ram/rom reports, so in case it is not present,
create it.
Fixes#5784
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Changed the default behavior for when we run sanitycheck to match the -R
flag that turns on assertions. Introduced a --disable-asserts option if
we desire to explicitly turn of asserts.
This matches behavior that our CI builds have been doing and addresses
part of #5726.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Add 2 classes, one to handle the current TestCase scenario, and one more
for handling generic Console with regex matching.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
size_report was assuming Unix-style absolute paths and misbehaving
when paths had a colon ("C:\") in them. Also, refactored and improved
documentation.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
Use Universal newlines when calling check_output and rely on the
locale's encoding to decode the output instead of explicitly decoding
UTF-8.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
size_report was assuming that the GNU Binutils programs were
generating files with the line ending '\n'. But on native Windows
binutils will generate files with the line ending \r\n.
This patches size_report to use so-called "Universal newlines"[0], so
that size_report can deal with any kind of newline on any kind of
platform.
[0] https://www.python.org/dev/peps/pep-0278/
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
Some boards are supported natively by qemu. This option will allow us to
run tests using those platforms directly without having to go via a
dedicated qemu board definition.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
if we are using command line platform filter, no need to list every
other platform as excluded, we know that already. Show only the
discards that apply to the selected platforms on the command line
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
When we load tests from a file, we do not have the discarded list, this
would have been done already when saving the test file.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This issuse is found in arch/arc's memory domain api support.
For arc, dwarf-2 is used to keep compatible with synopsys metaware
mdb debugger. However, the gen_kobject_list.py cannot generate the
correct information from dwarf-2, because loc.form's value is
DW_FORM_block1.
If dwarf-4 is adopted, there is no issuse.
Other arch and tools may use dwarf-2 and face the same issuse, so
this commit is created.
Signed-off-by: Wayne Ren <wei.ren@synopsys.com>
When checking if a testcase passed or failed, allow there
to be prefixes or postfixes in the line, around
PROJECT EXECUTION SUCCESSFUL/FAILED
Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com>
Update tags.sh tool to generate appropriate files to use with cscope and
ctags programs.
Current implementation generates tags for all but samples and it's
possible to filter by architecture.
Signed-off-by: Juan Manuel Torres Palma <j.m.torrespalma@gmail.com>
Specifying a C standard triggered a compiler warning on Ubuntu (gcc
5.4.0) and a compiler error on Mac OS 10.12.6. Omit specifying the
standard and let the host toolchain use it's default instead. Tested
on Mac OS and Ubuntu 16.04.3.
This fixes#5640
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
We have been using a fork of the Linux kernel's Kconfig system to
configure the Zephyr tree. The issue is that this is a native tool
written in C that is not easy to compile for Windows. This patch
replaces the use of the conf executable with kconfig.py, a script that
uses Kconfiglib to generate the .config and autoconf.h files required to
compile Zephyr.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>