Kernel timeouts have always been a 32 bit integer despite the
existence of generation macros, and existing code has been
inconsistent about using them. Upcoming commits are going to make the
timeout arguments opaque, so fix things up to be rigorously correct.
Changes include:
+ Adding a K_TIMEOUT_EQ() macro for code that needs to compare timeout
values for equality (e.g. with K_FOREVER or K_NO_WAIT).
+ Adding a k_msleep() synonym for k_sleep() which can continue to take
integral arguments as k_sleep() moves away to timeout arguments.
+ Pervasively using the K_MSEC(), K_SECONDS(), et. al. macros to
generate timeout arguments.
+ Removing the usage of K_NO_WAIT as the final argument to
K_THREAD_DEFINE(). This is just a count of milliseconds and we need
to use a zero.
This patch include no logic changes and should not affect generated
code at all.
Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
In the current implementation both SPSR and ELR registers are saved with
the callee-saved registers and restored by the context-switch routine.
To support nested IRQs we have to save those on the stack when entering
and exiting from an ISR.
Since the values are now carried on the stack we can now add those to
the ESF and the initial stack and take care to restore them for new
threads using the new thread wrapper routine.
Signed-off-by: Carlo Caione <ccaione@baylibre.com>
This commit adds a filter to restrict the `arch/arm/arm_runtime_nmi`
test to the ARM Cortex-M platforms only, since this test currently
does not support the Cortex-A and Cortex-R platforms.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
This commit enables nested interrupt test for the Cortex-A platforms
that use the ARM Generic Interrupt Controller (GIC).
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
This commit adds the nested interrupt testing support for the ARM
Generic Interrupt Controller (GIC).
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
This commit adds the GICD_SGIR register (used for generating software
generated interrupts) field definitions.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
The current `z_isr_install` implementation asserts that the IRQ to
which the ISR will be installed must be disabled.
This commit disables that assertion for the ARM GIC because the SGI-
type IRQs can never be disabled as per the specifications and this
causes the assertion to fail for them.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
The check for label property is really checking to see if a device
exists and the better way to do that is to use DT_HAS_NODE(). Replace
refernces of DT_NODE_HAS_PROP(DT_INST(...), label) with
DT_HAS_NODE(DT_INST(...)).
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
We are not propagting those options all the way to the device handler
now, fix this by using the suite member in the handler which has those
already.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Custom commands must depend on both the input files and the wrapper
targets for the input files.
See Sam Thursfield's blog post about "CMake: dependencies between
targets and files and custom commands" for why.
This fixes#23562
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
OBJ_LIST depends on ZEPHYR_PREBUILT_EXECUTABLE which again
transitively depends on PARSE_SYSCALLS_TARGET, so adding this
dependency is unnecessary.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
Fixes: #23872
Relocating Zephyr Unittest CMake package to ensure that
HINTS ${ZEPHYR_BASE} in
find_package(ZephyrUnittest HINTS ${ZEPHYR_BASE}) works correctly when
the package has not been exported to CMake user package registry.
This ensure that the new package functionality is fully backwards
compatible on systems where the package is not exported and ZEPHYR_BASE
is set.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
We are renaming the nrf9160 DK documentation page, and due to
re-organizing the doc directory we need to allow redirecting
the old URLs for nrf916 DK board targets' documentation.
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
Add a deprecation warning for nrf9160 DK when the old names
(nrf9160_pca10090, nrf52840_pca10090) are used instead of the
new board name. For nRF9160 SoC: do this for both secure and
non-secure board targets.
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
We rename the nRF91 Dev Kit board target for the NRF52840
controller (nrf52840_pca10090) to nrf9160dk_nrf52840. We
update all associated references in the supportive
documentation and all nRF9160-related cofigurations and
overlay files in the samples and tests in the tree. We
also remove an un-referenced board image file that had
erroneously been part of the documentation of this platform.
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
We rename the nRF91 Dev Kit board target (nrf9160_pca10090)
to nrf9160dk_nrf9160. We update all associated references
in the supportive documentation and all nRF9160-related
cofigurations and overlay files in the samples and tests
in the tree.
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
Add possibility to change the measurement modes
of the temperature and humidity measurements to
continuous or single-shot mode or switch them off.
Signed-off-by: Christian Hirsch <christian.hirsch@tuwien.ac.at>
This commit removes the Kconfig MAC address configurations for the
`sam_e70_xplained` board, as these have been migrated to use the device
tree configurations.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
This commit adds a new `sam_v71_xult` variant with the chip revision B
device tree.
In addition, this commit enables the newly added GMAC device tree
instance.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
This commit adds a GMAC instance to the SAM V71 device tree, with the
chip revision-specific hardware queue count.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
This commit adds a new `sam_e70b_xplained` variant with the chip
revision B device tree.
In addition, this commit enables the newly added GMAC device tree
instance.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
This commit adds a GMAC instance to the SAM E70 device tree, with the
chip revision-specific hardware queue count.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
This commit updates the Atmel SAM GMAC driver to use the device tree
values for GMAC hardware configuration.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
Add @nandojve, the SAM V71 platform maintainer, as a code owner for
the SAM E70 platform, as these two platforms share the same base and
are practically identical.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
PR https://github.com/zephyrproject-rtos/mcuboot/pull/8 was mistakenly
merged instead of pushed, which made the last 4 commits of zephyr's
mcuboot divergen in SHA with respect to the upstream ones.
In order to preserve the status of the zephyr mcuboot repo as an
exact mirror of the upstream one, a snapshot has been taken to preserve
the current SHA (0f4463caec3c3a8fac1350d0d6dfbee678a8ce06) and then the
master branch has been reset to the upstream equivalent
(7e7b4ad1999bf148f88059195f8d2e1d3dccf190). This commit switches the
pointer to the latter, but the mcuboot code itself is identical.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
Minor clean up to remove unnecessary references in the code to
CONFIG_HAS_SYS_POWER_STATE_SLEEP_1 and
CONFIG_HAS_SYS_POWER_STATE_SLEEP_2, as they are always defined for this
SoC.
Signed-off-by: Vincent Wan <vincent.wan@linaro.org>
Use of macros such as SYS_POWER_STATE_SLEEP_2 needs to be guarded by
making sure CONFIG_SYS_POWER_SLEEP_STATES is defined.
Signed-off-by: Vincent Wan <vincent.wan@linaro.org>
Use of macros such as SYS_POWER_STATE_SLEEP_2 needs to be guarded by
making sure CONFIG_SYS_POWER_SLEEP_STATES is defined.
Signed-off-by: Vincent Wan <vincent.wan@linaro.org>
The mcux lpc driver assumes that PINT interrupts are assigned to GPIO
port instances in groups of four, meaning that GPIO0 uses PIN_INT0-3 and
GPIO1 uses PIN_INT4-7. There was a mistake in the pin assignment
calculation that caused GPIO1 to incorrectly attach pins to PIN_INT0-3.
This caused the gpio isr to be invoked with what appeared to be the
wrong device argument and therefore not invoke any of the expected gpio
callbacks. But actually, it was the wrong irq that fired.
Found when adding support for the accelerometer interrupt on the
lpcxpresso55s69 board.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
The label property of the fixed-partitions child binding was duplicated
with two different values. This is invalid yaml, but went unnoticed by
pyYAML. Removed first entry to preserve value produced by pyYAML
behavior of overwriting duplicates.
Signed-off-by: Trond Einar Snekvik <Trond.Einar.Snekvik@nordicsemi.no>
This commit adds an explanation comment for the interrupt priorities
used by the Cortex-M nested interrupt test.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
Fix high-duty cycle directed advertising when extended advertising
feature has been enabled. The duration parameter when starting extended
high duty cycle directed advertising has to be set to a non-zero value
less than or equal to 1.28 seconds.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Avoid removing identity keys from the controller during the pairing
procedure. During the pairing procedure the keys will be cleared before
they are updated. This causes an unnecessary warning from HCI core where
it tries to remove an IRK key-set from the controller that has has not
been added yet.
While this is not an issue, the warning from HCI core is misleading and
might lead to unnecessary questions and investigations.
Warning appeared after: 6c6bd8c49e
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Move the pending ID keys add and delete flag out of keys storage area.
These flags are runtime flags and should not be stored in persistent
storage.
Due to struct alignment storage start has to be aligned so that
variables added before storage start does not affect the storage bytes
by introducing padding in the storage area
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Include build assert macros rework.
Update pip requirements by cbor package required by MCUBoot since
https://github.com/JuulLabs-OSS/mcuboot/pull/674 was merge.
Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>