Commit graph

41120 commits

Author SHA1 Message Date
Gerson Fernando Budke
ccf462763f boards: sam4s_xplained: Enable spi0 bus in dts file
Set spi0.status = 'okay' in sam4s_xplained.dts file.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2020-02-05 14:25:23 -06:00
Gerson Fernando Budke
f3663292bc soc: arm: sam4s: Add spi driver support
Add device tree fixups and pinmap to enable spi driver.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2020-02-05 14:25:23 -06:00
Gerson Fernando Budke
86ceaf26b7 dts: arm: atmel: Add sam4s spi component info
Add spi device tree component definition.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2020-02-05 14:25:23 -06:00
Torsten Rasmussen
058b749538 dts: added cryptocell to the dts file for nRF9160
This commit adds cryptocell definitions to the nRF9160 dts file.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
2020-02-05 13:57:04 -06:00
Erwan Gouriou
609f78b75c drivers/adc: stm32: Don't enable ADC instance by default in driver
ADC_1 peripheral instance was enabled by default in driver.
This is not the usual way to enable peripheral instances, as it
makes board configuration unclear.
Move activation in boards that are declaring ADC support.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2020-02-05 13:56:26 -06:00
Francois Ramu
612f29ee27 soc: arm: stm32g4 disable sleep mode
This patch allows successive reflashing operation
on nucleo_g431rb boards

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2020-02-05 13:48:15 -06:00
Kumar Gala
4fb265657d libc: newlibc: Implement dummy _gettimeofday to link
With the change in SDK 0.11.1 to newlib to remove
-DMISSING_SYSCALL_NAMES we now need to implement a version of
_gettimeofday.  Previously with pre SDK 0.11.1 we had a recursive mess
of _gettimeofday_r -> gettimeofday -> _gettimeofday_r.  (which are all
implemented in newlib and thus we didn't get a link error).

With SDK 0.11.1 we have: _gettimeofday_r -> _gettimeofday.  And we
should provide a version of _gettimeofday.

Fixes #22484

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2020-02-05 20:47:41 +01:00
Andrei Gansari
820f2bf467 doc: device tree - document pre_dt_board.cmake
Document pre_dt_board.cmake file usage.

Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
2020-02-05 13:04:44 -06:00
Andrei Gansari
e87fec1554 scripts: simple-bus warning suppression
Single-bus warning in python parsing of device tree is suppressed if
this is also suppresed in the device tree compiler.

Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
2020-02-05 13:04:44 -06:00
Andrei Gansari
77b125a8b3 cmake: pass extra dtc flags to python scripts
Pass arguments as command line from cmake to python. Extra DTC flags are
used later on to check errors in python.

Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
2020-02-05 13:04:44 -06:00
Andrei Gansari
0a699f71a0 boards: suppress dtc simple_bus_reg warning on LPC
LPC SoCs share the same register for all GPIO poarts. This leads us to a
device tree configuration that missmatches GPIO register address and
GPIO port identifier.

Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
2020-02-05 13:04:44 -06:00
Andrei Gansari
37af9cb065 cmake: allow boards to have extra cmake parametes
This commit allows boards to have custom cmake parameters that are
loaded before device tree is processed.

Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
2020-02-05 13:04:44 -06:00
Peter Bigot
1977ac3ce2 lib: os: onoff: documentation clarifications
Note that the client structure must be reinitialized before each use,
and make more clear that its internal fields are not part of the
public API.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-02-05 13:48:31 -05:00
Joakim Andersson
1e80efaa1b Bluetooth: samples: peripheral_dis: Sample requires BT_SETTINGS
The DIS service requires BT_SETTINGS otherwise it will not have a
settings handler. Instead DIS will only use Kconfig to set it's
values.

Fixes: #22478

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2020-02-05 20:11:03 +02:00
Erwan Gouriou
124004c29a boards: stm32: Remove useless CONFIG_BOARD_FOO from _defconfig files
CONFIG_BOARD_FOO is enabled in a number of board *_defconfig files
although it is useless as it is set by default (as defined as a
one option choice, symbol defaults to 'y').
CONFIG_BOARD_FOO should remain only in target that are defined
in boards providing multiple choices (dual cores, board with multiple
revisions).

Clean it from STM32 impacted boards.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2020-02-05 11:29:21 -06:00
Wayne Ren
d1fa27c42f arch: arc: fix the bug where buffer validate should be atomic
reported by #22290 and similar to #22275, the access to mpu regs
in buffer validate should be atomic.

Signed-off-by: Wayne Ren <wei.ren@synopsys.com>
2020-02-05 08:49:10 -08:00
Wayne Ren
8450d26b34 arch: arc: fix the bug where firq comes out in user mode
firq's case is similar to regular irq, it also needs to consider
the case of reg bank switch.

Signed-off-by: Wayne Ren <wei.ren@synopsys.com>
2020-02-05 08:49:10 -08:00
Wayne Ren
05a669c568 arch: arc: fix the bug where regular irq comes out in user mode
if USERSPACE is configured, it needs to record the user/kernel mode
of interrupted thread, because the switch of aux_sec_k_sp/aux_user_sp
depends on the aux_irq_act's U bit.

Signed-off-by: Wayne Ren <wei.ren@synopsys.com>
2020-02-05 08:49:10 -08:00
Tobias Svehagen
d1f15724aa Bluetooth: samples: Add mesh_provisioner sample
Add sample for how to use provisioner and Configuration Database (CDB)
APIs.

Signed-off-by: Tobias Svehagen <tobias.svehagen@gmail.com>
2020-02-05 18:47:41 +02:00
Tobias Svehagen
46a95f12ad Bluetooth: Mesh: Add database for managing nodes and keys
Refactor the handling of network nodes and their keys into a separate
Mesh Configuration Database (CDB). This, not only creates a separation
of the local node and the other nodes, but also makes it possible to
implement functions to manage the whole, or at least parts of the mesh
network.

Signed-off-by: Tobias Svehagen <tobias.svehagen@gmail.com>
2020-02-05 18:47:41 +02:00
Krzysztof Chruscinski
8df133e547 doc: release-notes-2.2: mention clock_control callback prototype change
Mentioned that callback has one additional parameter (subsys).

Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
2020-02-05 17:07:01 +01:00
Krzysztof Chruscinski
ce766305b7 drivers: clock_control: Add subsys argument to the callback
Added subsys argument to the callback, updated one driver which
used it and test cases.

Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
2020-02-05 17:07:01 +01:00
Andrei Emeltchenko
3fc7688b9b doc: up_squared_adsp: Add documentation for the board
Add documentation for the board up_squared_adsp.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2020-02-05 10:43:25 -05:00
Andrei Emeltchenko
d44d986a03 west: Add signing support using the rimage tool from SOF
This way "west sign" can be used for signing images.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2020-02-05 10:43:25 -05:00
Andrei Emeltchenko
18e58db3e4 log: Add Intel ADSP logging backend
Add logging backend for Intel Audio DSP.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2020-02-05 10:43:25 -05:00
Tedd Ho-Jeong An
c4278b9888 boards: up_squared_adsp: Add scripts for diagnostic driver
This patch adds scripts which downloads the firmware and extracts the
trace messages. The scripts required the SOF diagnostics driver
installed.

Signed-off-by: Tedd Ho-Jeong An <tedd.an@intel.com>
2020-02-05 10:43:25 -05:00
Andrei Emeltchenko
30e67b4d97 boards: up_squared_adsp: Add logging frontend
Add a command-line frontend to match the logging backend for Intel
Apollolake-based boards like the Audio DSP in the Up Squared.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2020-02-05 10:43:25 -05:00
Johan Hedberg
3686ad1ac9 boards: xtensa: Add board definition for Audio DSP on Up Squared
Create a board definition for the Audio DSP found on the Up Squared
board.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-02-05 10:43:25 -05:00
Andrei Emeltchenko
9987c2e2f9 arch: xtensa: Use reset-vector.S in booloader code
Use BOOTLOADER definition to separate bootloader code. This allows to
use the same file reset-vector.S when building bootloader and when
CONFIG_XTENSA_RESET_VECTOR is enabled.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2020-02-05 10:43:25 -05:00
Johan Hedberg
31706c874e soc: xtensa: Add SoC definition for Audio DSP on Intel Apollolake
Create an SoC definition for the Audio DSP on Intel Apollolake

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-02-05 10:43:25 -05:00
Daniel Leung
969ca3b60b dts: cpu: add binding for Cadence Tensilica Xtensa LX4 CPU
This adds a simple binding for the Cadence Tensilica Xtensa LX4
CPU. File originally from the LX6 binding.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2020-02-05 10:43:25 -05:00
Johan Hedberg
8183a7fd29 arch: xtensa: Add support for Intel Apollolake
Add the necessary architecture changes for Intel Apollolake.

Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-02-05 10:43:25 -05:00
Johan Hedberg
f13fa8e616 CODEOWNERS: Add @dcpleung as owner for /dts/xtensa/intel/
Add Daniel Leung as code owner for all Intel xtensa dts files.

Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-02-05 10:43:25 -05:00
Gerson Fernando Budke
f51a38c319 boards: sam4e_xpro: Add spi supported in yaml file
Added spi supported in sam4e_xpro board.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2020-02-05 10:14:51 -05:00
Gerson Fernando Budke
5eab388c63 boards: sam4e_xpro: Enable spi0 bus in dts file
Set spi0.status = 'okay' in sam4e_xpro.dts file.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2020-02-05 10:14:51 -05:00
Gerson Fernando Budke
49ccf28242 drivers: spi: sam: Add SPI CS soc_pinmap for sam4e soc
Add SPI CS soc_pinmap definitions to enable SPI driver on sam4e series.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2020-02-05 10:14:51 -05:00
Gerson Fernando Budke
738f76736e drivers: spi: sam: Add sam4e chip select config
Add depends on SOC_SERIES_SAM4E to enable spi driver for sam4e soc.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2020-02-05 10:14:51 -05:00
Gerson Fernando Budke
e3d35713f6 drivers: gpio: Add sam4e defines
Enable sam4e MCU gpio specifics.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2020-02-05 08:18:02 -06:00
Michael Scott
2c7e420a8e samples: net: echo_client: handle net if mtu
UDP portion of the echo_client sends 1 packet with the sample data.
(TCP can send chunks of it depending on the response of the send()
function.)  Not every network interface can send a UDP packet large
enough to handle the size of the sample data.

Let's make sure to account for the network interface MTU when deciding
the amount of sample data to send.

Fixes: https://github.com/zephyrproject-rtos/zephyr/issues/22447

Signed-off-by: Michael Scott <mike@foundries.io>
2020-02-05 15:54:57 +02:00
Joakim Andersson
ba504fbffa Bluetooth: tests: Add privacy configuration for test basic_conn_encrypt
Add privacy configuration when using the split controller for the test
basic_conn_encrypt. The handling with or without controller based
privacy affects the RPA handling in the host due to different
connection complete events being used. This affects the overall pairing
procedure as the addresses are inputs to the pairing functions.

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2020-02-05 14:33:21 +02:00
Andrzej Puzdrowski
92b0ae1965 manifest: mcuboot upgrade
Upgraded mcuboot to version which have following issue
fixed:
Redundant 'source "$(ZEPHYR_BASE)/Kconfig.zephyr"
in 'boot/zephyr/Kconfig'

Within this version upgrade the default swap algorithm for nRF devices
was changed to `move swap` instead of `swap using scratch`.

Mcuboot start using new non-deprecated GPIO labels

Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
2020-02-05 12:40:19 +01:00
Peter Bigot
86d1b7d2c8 samples: boards: nrf: update battery sample for new GPIO API
Replace legacy API and configuration.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-02-05 12:00:36 +01:00
Peter Bigot
7c95d503b0 gpio: clean up internal API function prototypes
Use gpio_pin_t uniformly when passing pin indexes to the driver.  Use
gpio_flags_t uniformly when passing flags to the driver.  Change name
of pin configuration function in API function table to be consistent
with other API functions.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-02-05 12:00:36 +01:00
Peter Bigot
37239dbcbf gpio: rename typedef for devicetree flags
gpio_dt_flags_t is shorter and consistent with DT_ prefix.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-02-05 12:00:36 +01:00
Peter Bigot
f017209821 gpio: use reduced-size role typedef for public API pin indexes
There is a typedef used to store pin indexes in configuration
structures.  For consistency it should also be used to identify pin
indexes in function prototypes.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-02-05 12:00:36 +01:00
Peter Bigot
c7d526be04 gpio: remove port access op support
The only remaining port operations have dedicated API function table
entries.  Remove the defines for access op (mode), and remove support
for access op from all implementations.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-02-05 12:00:36 +01:00
Peter Bigot
1f9beb193f gpio: remove legacy read/write API functions
The last external reference to these was removed when the pin
write/read functions were deprecated.  Remove the syscall support, API
function table entries, and implementation from all drivers.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-02-05 12:00:36 +01:00
Peter Bigot
1947481cce gpio: deprecate gpio pin callback enable and disable API
These have been replaced by the appropriate call to
gpio_pin_interrupt_configure().  While the disable function could be
implemented using the new functionality, the enable function cannot
because the interrupt mode is not available.  Consequently we cannot
replace these with equivalent functionality using the legacy API.

Clean up the internal implementation by removing the inaccessible
port-based enable/disable feature, leaving the pin-based capability in
place.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-02-05 12:00:36 +01:00
Peter Bigot
e999f7c6fb doc: release-notes-2.2: update for GPIO deprecations
Add a section describing what's been deprecated and how to replace it.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-02-05 12:00:36 +01:00
Peter Bigot
4b25e75c8f drivers: sensor: lis3mdl: replace deprecated gpio_pin callback API
gpio_pin_disable_callback is to be replaced by
gpio_pin_interrupt_configure.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-02-05 12:00:36 +01:00