patch adds zephyr,uart-pipe to devie tree as chosen property.
This is added for frdmk64f because sanitycheck test was
breaking with changes of generating configs for UART_PIPE
from device tree instead of Kconfig.
Signed-off-by: Savinay Dharmappa <savinay.dharmappa@intel.com>
patch adds zephyr,bt-uart, zephyr,uart-pipe and zephyr,bt-mon-uart
to device tree as chosen property.
Signed-off-by: Savinay Dharmappa <savinay.dharmappa@intel.com>
patch uses chosen property zephyr,bt-uart, zephyr,uart-pipe
and zephyr,bt-mon-uart to determine the uart instance to be
used for bluetooth,uart_pipe and bluetooth_monitor and generate
appropriate configs.
Signed-off-by: Savinay Dharmappa <savinay.dharmappa@intel.com>
As there is no suffix to represent a literal as unsigned short
it is typecasted. It is fix for Jira ZEP-2156
Signed-off-by: Savinay Dharmappa <savinay.dharmappa@intel.com>
A user space buffer must be validated before required operation
can proceed. This API will check the current MMU
configuration to determine if the buffer held by the user is valid.
Jira: ZEP-2326
Signed-off-by: Adithya Baglody <adithya.nagaraj.baglody@intel.com>
K_POLL_MODE_INFORM_ONLY was renamed to K_POLL_MODE_NOTIFY_ONLY, but
stale use was in a docstring.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
It's expected that there will be few socket-based samples, so move
tehm under samples/sockets/ to not clutter the main dir.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
Implements asynchronous TCP echo server using non-blocking sockets
and poll, with concurrent connections support.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
poll() allows to (efficiently) wait for available data on sockets,
and is essential operation for working with non-blocking sockets.
This is initial, very basic implementation, effectively supporting
just POLLIN operation. (POLLOUT implementation is dummy - it's
assumed that socket is always writable, as there's currently no
reasonable way to test that.)
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
This needs to be in <arch/cpu.h> so that it can be called
from the k_panic()/k_oops() macros in kernel.h.
Fixes build errors on these arches when using k_panic() or
k_oops().
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
The coaps server sample application did not start because
number of IPv6 multicast addresses was too low. Increased
the address count from 2 to 5.
Jira: ZEP-2359
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
Use net_context_put(), not net_context_unref(). This makes sure
that after sending response, connections are properly closed.
Jira: ZEP-2362
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
Introduce a configurable boot delay option (defaulting to none) that
happens right after printing a boot delay banner, #before calling
main() in kernel/init.c:_main(), before taking timestamps for _main()
and once all the infrastructure is in place. Move also the boot banner
to happen after this delay.
The rationale for this is some boards will boot really fast and print
out some test case output in the serial port before the system that is
monitoring the serial port is able to read from the serial port.
This happens in MCUs whose serial port is embedded in a USB connection
which also is used to power the MCU board. When powering it on by
powering the USB port, there is a time it takes the host system to
detect the USB connection, enumerate the serial port, configure it and
load, start and read from the serial port. At this time, it might have
printed the output of the serial port.
While manually it is possible to press a reset button, on automation
setups this adds a lot of overhead and cabling or modifications to the
MCU that are easier (and cheaper) to overcome with this delay. Other
options (like using a separate serial line) might not be possible or
add a lot of cabling and cost, plus it'd also add extra build
configuration.
Change-Id: I2f4d1ba356de6cefa19b4ef5c9f19f87885d4dfd
Signed-off-by: Inaky Perez-Gonzalez <inaky.perez-gonzalez@intel.com>
Document clearly how and in what context, the various callbacks
in net_context API are being called.
Jira: ZEP-2352
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
Introduce net_context_bind_default() to ensure that local address is
set for context if not yet (via explict bind() call). This fixes
dereferences of NULL pointer to local address which was exposed when
MMU was enabled for qemu_x86.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
_FILE_PATH_HASH appears to be a legacy Diab-ism that doesn't
expand to anything in GCC.
As a result, when linking the combined binary, it's quite
possible that objects in separate C files would be merged
instead of truly being in their own section. This can confound
--gc-sections and result in unused objects still being in
the final binary if one of the other objects with the same
generated section name was actually used.
We instead just use __FILE__. This results in sometimes absurdly-
long section names in the intermediate .o files, but there is no
actual limit to how long section names in ELF binaries can be;
they are not stored directly in headers but instead referenced
as an offset in the .shstrtab section, which has all the section
names stored in it.
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
Different areas of memory will need to have different access
policies programmed into the MMU. We introduce MMU page alignment
to the following areas:
- The boundaries of the image "ROM" area
- The beginning of RAM representing kernel datas/bss/nonit
- The beginning of RAM representing app datas/bss/noinit
Some old alignment directives that are no longer necessary have
been removed.
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
1) start/end addresses for rodata
2) size of image ROM area
3) size of RAM (not including rodata/text) up to the limit of
physical memory
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
Since -P is not supported in non-GNU versions of grep, avoid using it
now that it is no longer required (no "|" operator anymore inside the
regex).
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
The macros for calculating the length of the configuration
descriptors have been interchanged, fix it, and use the
correct macro for the length of the DFU mode configuration
descriptor.
Signed-off-by: Johann Fischer <j.fischer@phytec.de>
When populating the hardware filter, add only slots that are marked as
taken to avoid the hardware being confused by all-0 addresses. This
solves an EBQ issue with whitelist filtering.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
To avoid warnings (seen on some machines) that a function reaches its
end without returning a value, conditionally compile the function in a
way that this cannot happen.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
Fix master terminate procedure so that if slave responded to
the ack from master for the LL_TERMINATE_IND then the master
correctly disconnected.
This fixes TP/CON/MAS/BV-09-C [Master Accepting Termination]
in LL.TS.5.0.0.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Tested-by: Ulrich Myhre <ulmy@nordicsemi.no>
Fix implementation to maintain a connection in the slave
role not taking slave latency into use before receiving an
acknowledgement from the master.
This fixes TP/CON/ADV/BV-03-C [Master Missing Slave Packets]
in LL.TS.5.0.0.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Tested-by: Ulrich Myhre <ulmy@nordicsemi.no>
It is incorrect to call spi_context_release() on a
spi_dw_data object's ctx field before data->ctx->config is first
set in spi_dw_configure(). This is because spi_context_release()
reads ctx->config->operation. In particular, during spi_dw_init(),
calling spi_context_release() reads the uninitialized memory in
spi->ctx->config->operation.
Call spi_context_unlock_unconditionally() instead to properly increase
the semaphore count.
Without this patch, the first call to spi_transceive() can block
forever depending on the value of the uninitialized memory holding
spi->ctx->config->operation.
Signed-off-by: Marti Bolivar <marti.bolivar@linaro.org>
It is incorrect to call spi_context_release() on an STM32
spi_stm32_data object's ctx field before data->ctx->config is first
set in spi_stm32_configure(). This is because spi_context_release()
reads ctx->config->operation. In particular, during spi_stm32_init(),
calling spi_context_release() reads the uninitialized memory in
data->ctx->config->operation.
Call spi_context_unlock_unconditionally() instead to properly increase
the semaphore count.
Without this patch, the first call to spi_transceive() can block
forever depending on the value of the uninitialized memory holding
data->ctx->config->operation.
Signed-off-by: Marti Bolivar <marti.bolivar@linaro.org>
A number of sectors are declared in the frdm_k64f flash partitions
node as part of an "application state" partition. Rather than require
users to treat this area of flash as a single partition, delete the
application-state node and leave a comment in its place describing its
purpose.
This enables use cases where the flash sectors must be split into
multiple partitions without defining overlapping partitions in overlay
files.
Signed-off-by: Marti Bolivar <marti.bolivar@linaro.org>
Currently, flash partitions used by mcuboot are defined in the
SoC-level dtsi file for NXP K6X. This should be made more granular so
that product owners can choose partition layouts to suit their
needs. To that end, move the partitions into frdm_k64f.dts.
Signed-off-by: Marti Bolivar <marti.bolivar@linaro.org>
The I2C controller nodes are the root of the I2C bus for that controller
and thus may have children nodes that represent the I2C devices on that
controller. Thus we need to specify the #address-cell & #size-cell
properties.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
+ The VBLUno52 board
nRF52832 ARM Cortex-M4F processor
Bluetooth Low Energy 5.0
DAPLink interface
UNO pinout
4 power
+ The following samples were tested:
hello_world
basic/button
basic/blinky
bluetooth/peripheral_hr
bluetooth/beacon
Signed-off-by: Nam Do <robotden@gmail.com>
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
The SimpleLink SDK provides a peripheral driver library and hardware
register access header files for the Texas Instruments SimpleLink
CC3220S and CC3220SF SoCs.
This patch updates the SDK version in Zephyr from 1.30.01.03
to 1.40.00.03.
The SDK can be downloaded from:
http://www.ti.com/tool/download/SIMPLELINK-CC3220-SDK
Jira: ZEP-1958
Signed-off-by: Gil Pitney <gil.pitney@linaro.org>
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>