'coccicheck' target is used to initiate Coccinelle checker. It
can be called via four different modes that generate different
output corresponding the mode.
The four modes are:
* 'patch' proposes a fix, when possible.
* 'report' generates a list in the following format:
file:line:column-column: message
* 'context' highlights lines of interest and their context in
a diff-like style. Lines of interest are indicated with '-'.
* 'org' generates a report in the Org mode format of Emacs.
The 'coccicheck' front-end can be called with suitable arguments:
* --mode=<mode>: specify the mode for processsing.
* --cocci=<path/to/foo.cocci>: specify the SmPL file to use.
* --verbose=<1>: enable verbose output.
Run `./scripts/coccicheck --help` for more detailed info
on various options available.
With the above arguments the coccinelle transformation engine
runs on the entire/part of the source code tree depending on
various options supplied to the coccicheck sanity checker.
More detailed documentation can be found at:
doc/application/coccinelle.rst
Cc: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Himanshu Jha <himanshujha199640@gmail.com>
Shell macro SHELL_DEFINE no longer needs new line character.
Specification has been updated accordingly.
Signed-off-by: Jakub Rzeszutko <jakub.rzeszutko@nordicsemi.no>
1. Shell will accept CR or LF as line delimiter.
2. Macro SHELL_DEFINE simplified - it no longer requires
new line character.
3. Fixes: #10207.
Signed-off-by: Jakub Rzeszutko <jakub.rzeszutko@nordicsemi.no>
As a master switch to access POSIX APIs.
Also, remove dependency on pthreads for tests which don't require it.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
Don't duplicate definitions.
This fixes build errors due to redifinitions of preprocessor symbols.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
If pthreads support is not enabled, don't provide pthread-specific
bits of signal semantics, just plain old signal features.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
Not related to pthreads. Don't depends on CONFIG_POSIX_FS either,
as stats defines may apply to special files (devices, etc.) too.
Instead, depend on CONFIG_POSIX_API.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
It so happened that previously CONFIG_PTHREAD_IPC served this role.
But pthreads and IPC is only parts of POSIX, orthogonal to other
services.
Move CONFIG_POSIX_FS, etc. out from CONFIG_PTHREAD_IPC.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
Improve the documentation of the ARMv8-M MPU convenience macros
for setting up MPU regions at boot time, stressing that the
macros intend to be used for non-overlapping, fixed MPU regions.
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
This commit enhances the documentation of the mpu_config
element in include/arch/arm/cortex_m/mpu/arm_mpu.h, stressing
that it intends to store information for fixed MPU regions.
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
Remove an inline explanatory comment for the thread
stack region type that is obsolete. The comment had
been been erroneously kept in after the enumeration
of MPU region types was refactored and cleaned up.
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
When the code partition is not at the beginning of the flash, the load
offset is wrongly computed. The address in the device tree is already
relative to the beginning of the parent node, ie the beginning of the
flash memory space. There is therefore no need to subtract it.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Add a section to optionally install the Chocolatey packages required to
build the documentation in .pdf format on Windows.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
In order to make PDF generation work on Windows, search for a generic
Latex package and use full quotes for the latexmk environment variable.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
This patch is equivalent to 7b0ce85242,
but applied to more boards. As stated in the previous commit message:
This change aims at fixing 'unit_address_vs_reg' warning in arm based
boards. This warning pops up when a node name is made up with an
address (node_name@xx) but does not contain a reg property. This case
was encountered for led nodes for instance, where a reg property has
no meaning. Fix this by changing node_name@xx to node_name_xx which
removes the guilty '@XX' syntax but preserves node_name uniqueness.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
The node name parsing for the _LABEL #define does not parse the unique
node portion in the same fashion between @<unit_address> and _<number>.
This change normalizes the two modes.
Signed-off-by: David Leach <david.leach@nxp.com>
1. Command handler can return command exectution status as int.
2. Existing command handlers rework.
Signed-off-by: Jakub Rzeszutko <jakub.rzeszutko@nordicsemi.no>
This PR fixes: #10195.
Function _vprintk when used cannot parse '*' what
a as result causes dereferencing bad pointer.
Signed-off-by: Jakub Rzeszutko <jakub.rzeszutko@nordicsemi.no>
Adds getaddrinfo and freeaddrinfo to the offloaded API.
Signed-off-by: Joakim Andre Tønnesen <joakim.tonnesen@nordicsemi.no>
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Every board that uses dts-enabled spi drivers has a board-level dts, so
there is no need to have separate configs HAS_DTS_SPI_PINS and
HAS_DTS_SPI.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Every board that uses dts-enabled gpio drivers has a board-level dts, so
there is no need to have separate configs HAS_DTS_GPIO_DEVICE and
HAS_DTS_GPIO.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Every board that uses dts-enabled spi drivers has a board-level dts, so
there is no need to have separate configs HAS_DTS_SPI_DEVICE and
HAS_DTS_SPI.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Every board that uses dts-enabled i2c drivers has a board-level dts, so
there is no need to have separate configs HAS_DTS_I2C_DEVICE and
HAS_DTS_I2C.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Adds a board-specific dts overlay and fixup file to the arduino_101
environmental sensing sample, in preparation for making the sensor
drivers require dts.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Extending logger to support logging transient strings (with %s).
With dedicated call (log_strdup), string is duplicated to a buffer
from internal logger pool. Logger implicitly manages the pool.
Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
Argonkey board building has been recently broken by a LSM6DSL sensor
driver fix (see commit: a013ce3bf0).
The board configuration file must now enable HAS_DTS_GPIO_DEVICE macro
instead of HAS_DTS_SPI_DEVICE.
Signed-off-by: Armando Visconti <armando.visconti@st.com>
It is very inconvenient to maintain an application that both runs on a
Zephyr board and an out-of-tree board.
It forces one to write build scripts like this in the app:
if(BOARD STREQUAL my_out_of_tree_board)
set(BOARD_ROOT some/out/of/tree/board/path)
endif()
To avoid this we change the semantics of BOARD_ROOT. Instead of it
being a path to the board root it is now a prioritized list of board
root directories. Zephyr will append ZEPHYR_BASE to BOARD_ROOT.
This ensures that Zephyr boards can be used when the out-of-tree board
directory can not supply the requested board.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
The documentation has been setting the environment variable
KERNELVERSION to the PROJECT_VERSION of the documentation. But
PROJECT_VERSION is not set during the documentation build so this has
no effect.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
Change the format of KERNELVERSION as it exists in Kconfig to match
it's format elsewhere. Specifically, change from a string format
"1.10.3" to a numerical format.
This format change is a backwards-incompatible change. Any out-of-tree
Kconfig sources that were accessing KERNELVERSION with
$(KERNELVERSION) will need to be ported.
This change is to fix a bug. KERNELVERSION should have always been in
a numerical format. It should have been in a numerical format because;
KERNELVERSION is in a numerical format as a CMake variable and as a C
macro.
The purpose of having KERNELVERSION available in Kconfig is to have
configuration depend on the version, but this is only possible if it
exists in a numerical format[0].
[0] A string comparison of two semver strings does not always result
in a correct version comparison.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
The last parameter is 'period', we should not pass duration twice.
Doing so makes zephyr hang with current mainline when it is chosen to be
the Grand Master.
Signed-off-by: Tomasz Gorochowik <tgorochowik@antmicro.com>
Completely remove the last_sync_receipt_timeout time. It is not part of
the standard (see 802.1AS-2011, 10.2.11 for the complete list of
variables for this state machine). Additionally this extra variable was
never really initialized so the calculated duration made no sense.
Just start the timer based on the regular sync receipt timeout time
interval from the port data set.
Signed-off-by: Tomasz Gorochowik <tgorochowik@antmicro.com>