As other stm32 series support MPU, move common file in a file tree
useable by socs from other series
JIRA: ZEP-2220
Signed-off-by: Michel Jaouen <michel.jaouen@st.com>
Allow to use an external debug adapter such as J-Link or ULINK
connected to a 20-pin JTAG header to flash the image. SWD is
the actual protocol used by the debug interface.
Signed-off-by: Piotr Mienkowski <piotr.mienkowski@gmail.com>
As there are multiple ways to flash or debug (pyOCD or openOCD) allow
the user to override the default.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
If we have more than one board of a given type we need to be able to
specify the board_id to select which specific board that the pyocd
command should target. Introduce an environment variable PYOCD_BOARD_ID
to we can set that will get passed to the pyocd command that needs it.
Here's an example:
$ make -C samples/hello_world/ BOARD=frdm_k64f flash PYOCD_BOARD_ID=1234
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
We define a variable to pickup a default for the bossa binary, however
we weren't using it. Lets do so now.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Three response codes are missed in zoap_header_get_code() which will
result in the response code returned from the function being set as
ZOAP_CODE_EMPTY. Check include/net/zoap.h for the missing code
definition.
Signed-off-by: Robert Chou <robert.ch.chou@acer.com>
We incorrectly had an arch_whitelist constraint set to 'qemu_x86' that
should have been a platform_whitelist, so fix that and add arduino_101
frdm_k64f to the platform_whitelist as targets that we can test this on.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Use sizeof instead of strlen to get the correct buffer
length and initialize rx buffer with zeros before the dma
transfer.
Signed-off-by: Johann Fischer <j.fischer@phytec.de>
It's possible that the controller will emit the number of completed
packets event before bt_send() returns, or possibly preempt
send_frag() before it manages to call add_pending_tx(). We have to
therefore add the pending TX entry before calling bt_send().
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Fixed assert due to stale tick count in role event
preparation. This happens when ticker timeout expiry is
delayed from the requested realtime anchor, due to thread
mode processing overheads and occurring interrupts therein,
if any, that added a delay between requested anchor tick
and actual scheduling for the requested ticker timeout.
The assert is reproduced in bt shell by starting advertising
and following it with continuous scanning (interval 2.5ms,
window 2.5ms), on nRF51x. If the overheads and/or a
advertiser event delayed the scheduling of scanner by over
2.5ms, then the preparation of scanner asserted.
The assert has been fixed by checking for stale tick count
at expiry in role event preparation and skip the event
gracefully.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
For whitelist and resolving list handling, avoid trying to start the
advertiser and scanner roles when they are already running.
Additionally, and since simultaneous scanning and initiating is not
supported, correctly report this to the host both in the supported
states and in the HCI command via an error code, instead of silently
disabling scanning.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
as config SPI_CS_GPIO was selecting GPIO instead it
should just depend on it. This patch is a fix for
ZEP-2071 jira.
Signed-off-by: Savinay Dharmappa <savinay.dharmappa@intel.com>
commit d859295be9 ("tests: protection: convert to testcase.yaml")
removed testcase.ini but did not add an equivalent testcase.yaml.
Add it.
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
We have conflicting types between the decleration and implementation of
several radio functions. We should be using u32_t everywhere. This
shows up when we try and build with newlib enabled.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Added HAL Radio abstractions to use SoC specific Radio Timings
as documented in SoC's electrical characteristics.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
patch adds necessary files and does the modification
to the existing files to add device support for
arduino_101 board.
Signed-off-by: Savinay Dharmappa <savinay.dharmappa@intel.com>
patch enables qmsi serial driver to pick baudrate and name
from device tree instead of Kconfig for UART0 and UART1
instance
Signed-off-by: Savinay Dharmappa <savinay.dharmappa@intel.com>
patch adds necessary files and does the modification to the existing
files to add device support for x86 based intel quark microcontroller
Signed-off-by: Savinay Dharmappa <savinay.dharmappa@intel.com>
Add details about that fact that ram/flash params on the board yaml are
specified in terms of Kilobytes. Also what the defaults are if they are
not specified.
Clarified that ignore_tags is meant for ignoring something from both
build and running. (I can see adding a tag for tests we build, but
ignore that we can run).
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
The build_on_all tag in synchronisation sample was resetting the
supplied arguemnt for filtering platforms.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
With the introduction of privacy, the system workqueue is now being
linked into the image, growing the RAM footprint considerably.
In order for the sample to fit in QFAA and QFAB variants of the nRF51
(16KB of RAM) we reduce the workqueue stack size to 512 since the RPA
update mechanism doesn't use more than 340 bytes and we stick to 16
connections maximum.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
The condition in src/Makefile is not necessary since the
net_private.h is always included from wpanusb.c and is not
dependent on the transceiver.
Change-Id: I07a0bf599f328bacb8c5677f20eb221a05f30866
Signed-off-by: Johann Fischer <j.fischer@phytec.de>
In LISTEN state ignore a TCP RST. In SYN RCVD state, reset TCP
connection state to LISTEN when a valid RST segment is received. In all
other states close the connection - except that these other states will
not be handled in tcp_syn_rcvd() function.
Jira: ZEP-2279
Signed-off-by: Patrik Flykt <patrik.flykt@intel.com>
Add a self-protection test suite with a set of tests
to check whether one can overwrite read-only data
and text, and whether one can execute from data,
stack, or heap buffers. These tests are modeled after
a subset of the lkdtm tests in the Linux kernel.
These tests have twice caught bugs in the Zephyr NXP MPU
driver, once during initial testing/review of the code
(in its earliest forms on gerrit, reported to the original
author there) and most recently the regression introduced
by commit bacbea6e21 ("arm: nxp: mpu: Rework handling
of region descriptor 0"), which was fixed by
commit a8aa9d4f3dbbe8 ("arm: nxp: mpu: Fix region descriptor
0 attributes") after being reported.
This is intended to be a testsuite of self-protection features
rather than just a test of MPU functionality. It is envisioned
that these tests will be expanded to cover a wider range of
protection features beyond just memory protection, and the
current tests are independent of any particular enforcement
mechanism (e.g. MPU, MMU, or other).
The tests are intended to be cross-platform, and have been
built and run on both x86- and ARM-based boards. The tests
currently fail on x86-based boards, but this is an accurate
reflection of current protections and should change as MMU
support arrives.
The tests leverage the ztest framework, making them suitable
for incorporation into automated regression testing for Zephyr.
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
ztest provides a ztest_test_fail() interface to fail the currently
running test, but does not provide an equivalent ztest_test_pass().
Normally a test passes just by returning without an assertion failure
or other call to ztest_test_fail(). However, if the correct behavior
for a test is to trigger a fatal fault (as with tests/kernel/fatal or
protection or MPU tests), then we need a way for the test to pass the
currently running test before aborting the current thread.
Otherwise, ztest hangs forever in run_test() on the
k_sem_take(&test_end_signal, K_FOREVER) call. Add
a ztest_test_pass() interface and implement it for kernel and
userspace variants of ztest. This interface will be used in the
protection tests.
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
It is confusing if we print timeout error when expecting
a timeout to happen. So for timeout test, do not print
an error message as the timeout is suppose to happen.
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
The TCP tests had several failures because of unnecessary
Kconfig options. These are now fixed and the TCP tests are
also run automatically by CI.
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
The MLD (Multicast Listener Discovery) tests had a failure.
This is now fixed and the MLD tests are also run automatically by CI.
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
The IPv6 tests had failures and the tests did not pass
properly. These are now fixed and the tests are also
run automatically by CI.
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>