Commit Graph

310 Commits

Author SHA1 Message Date
Anas Nashif 8949233390 kconfig: fix more help spacing issues
Fix Kconfig help sections and add spacing to be consistent across all
Kconfig file. In a previous run we missed a few.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-02-15 23:20:55 -05:00
Paul Sokolovsky 42680b07af mbedtls: Switch default MBEDTLS_CFG_FILE to config-mini-tls1_2.h
The previous default, "config-threadnet.h", is more or less arbitrary
choice made in a commit 312def2c78 1.5 years ago. In particular,
it's not related to Thread support in Zephyr per se (there was no
such support at that time).

It doesn't make sense to have a default intended for a particular,
not widely used (yet) protocol. Instead, the default should work
out of the box with a contemporary widely deployed arrays of TLS
servers, which are HTTPS server. config-mini-tls1_2.h works with
https://google.com, and by extension, with many other servers on
the Internet.

So, have that as the default, and let applications with special
needs to override that to what they need.

Addresses: #6132

Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
2018-02-15 12:35:31 -05:00
Paul Sokolovsky 9f3d335b0c mbedtls: config-mini-tls1_2.h: Update stale comments
This config enables TLS 1.2 (only), as its name suggests, and
contrary to the (copy-pasted) comments in the file header, so
update these comments.

Fixes: #6131

Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
2018-02-15 12:08:36 -05:00
Sean Nyekjaer a09b6f538a arch: atmel_sam0: rename samd SoC series to samd21
Atmel SAMD21 series was classified too broadly as SAMD.
This patch names it correctly to make room,
for other members of SAMD series

Signed-off-by: Sean Nyekjaer <sean@nyekjaer.dk>
2018-02-09 08:34:55 -06:00
Vipul Rahane 19b1ce6b64 ext: lib: tinycbor: Add req Zephyr specific files
Include both build an configuration files required to build
TinyCBOR with Zephyr.

Signed-off-by: Vipul Rahane <vipulrahane@apache.org>
2018-02-08 21:17:22 +01:00
Vipul Rahane 2988deb735 ext: lib: tinycbor: half/full-FP support changes
- Make half float encode/decode conditional
- src/cborpretty.c, src/cbortojson.c and src/cborvalidation.c
  conditionally include math.h and half float type support
- Conditionally include math.h in src/compilersupport_p.h to avoid
  newlib libc from getting compiled in
- Conditionally compile src/cborparser_dup_string.c if newlib libc is
  compiled in

Signed-off-by: Vipul Rahane <vipulrahane@apache.org>
2018-02-08 21:17:22 +01:00
Vipul Rahane 1bcacf5c56 ext: lib: tinycbor: Apply req patch to 0.5.0-beta1
For a full description of changes see the commit message
URL: https://github.com/zephyrproject-rtos/tinycbor/tree/zephyr

Signed-off-by: Vipul Rahane <vipulrahane@apache.org>
2018-02-08 21:17:22 +01:00
Vipul Rahane b4c2d93495 ext: lib: tinycbor: Add tinyCBOR as an ext lib
The TinyCBOR library is a small Concise Binary Object
Representation (CBOR) encoder and decoder library, optimized for
very fast operation with very small footprint.

Origin: TinyCBOR
License: MIT
URL: https://github.com/intel/tinycbor
Version: 0.5.0-beta1
commit: 497066ee87dd54341adaa1195bf15ad11ee33b20
Purpose: Introduction of TinyCBOR
Maintained-by: External

Signed-off-by: Vipul Rahane <vipulrahane@apache.org>
2018-02-08 21:17:22 +01:00
Ramakrishna Pallala 40c15566eb ext: hal: altera: disable altera_avalon_i2c compilation warnings
Disable compilation warnings for altera_avalon_i2c.c as it is not
maintained in Zephyr.

Cmake does not allow us to use set_source_files_properties on
source files directly, these files need to be linked to either
a target executable or a target library. Due to the above reason,
altera_avalon_i2c CMakeLists.txt creates a library and links the
source file to the zephyr library.

Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
2018-02-07 19:37:35 -05:00
Ramakrishna Pallala b574a9ba9b ext: hal: altera: Add wrapper functions for Altera HAL runtime API's
Add wrapper or helper functions for Altera HAL runtime API's to
enable Altera HAL drivers on Zephyr.

Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
2018-02-07 19:37:35 -05:00
Kumar Gala bb72c3d020 crypto: mbedtls: Update mbedTLS to 2.7.0
Due to a security advisory released on February 1st 2018[1], it's
advisable to update mbedTLS to 2.7.0.

The vulnerability, identified as CVE-2018-0488 and CVE-2018-0487, risk
remote code execution when truncated HMAC is enabled or when verifying
RSASSA-PSS signatures.

[1] https://tls.mbed.org/tech-updates/security-advisories/mbedtls-security-advisory-2018-01

Fixes: #6025

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-02-07 16:25:27 -05:00
Ioannis Glaropoulos 3d1348e02e cmsis: Update ARM CMSIS headers to version 5.2.0
Origin: ARM CMSIS v5.2.0
License: Apache-2.0
URL: https://github.com/ARM-software/CMSIS_5.git
commit: 80cc44bba16cb4c8f495b7aa9709d41ac50e9529
Purpose: CMSIS Headers update.
Maintained-by: External

Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
2018-02-06 08:46:41 -06:00
Ramakrishna Pallala be14653754 ext: hal: altera: Add QSPI Controller HAL driver
Add Altera Nios-II QSPI Controller HAL driver to Zephyr.
The sources are taken from the Altera SDK v17.

Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
2018-02-05 06:30:50 -08:00
Michael Hope cff16051bb disk: delete the GET_DISK_SIZE IOCTL.
The argument is a u32_t which limits the maximum disk size to 4 GiB.
Rather than fix this, delete the ioctl and switch the only use to
GET_SECTOR_COUNT instead.

Signed-off-by: Michael Hope <mlhx@google.com>
2018-01-31 09:14:40 -05:00
Sebastian Bøe c3f53911de mbedtls: Added support for using an externally built mbedtls
Kbuild supported CONFIG_MBEDTLS_LIBRARY and
CONFIG_MBEDTLS_INSTALL_PATH to allow users to link in an externally
built mbedtls. This was not ported over to CMake, causing build
failures when it was kconfig-enabled.

This patch implements this support. This support has been tested
as well as MBEDTLS_LIBRARY was tested in CI.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
Signed-off-by: Ding Tao <miyatsu@qq.com>
2018-01-29 23:46:15 -05:00
Sebastian Bøe 61cf3b0573 mbedtls: Kconfig: Re-organize to enable choosing an mbedtls impl.
CONFIG_MBEDTLS means you are using MBEDTLS
CONFIG_MBEDTLS_BUILTIN means you are using a built-in MDEDTLS
CONFIG_MBEDTLS_LIBRARY means you are using an external MBEDTLS

This patch ensures that you must select one or the other
implementation when MBEDTLS is enabled.

Tested by opening xconfig and observing that when MBEDTLS was enabled,
BUILTIN was automatically enabled, and a radio-button interface
existed to change the implementation.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
Signed-off-by: Ding Tao <miyatsu@qq.com>
2018-01-29 23:46:15 -05:00
Michał Kruszewski aee2ff526d ext: nordic: Replace HAL and MDK with the ones from nrfx
The old HAL and MDK have been removed from the source tree.
Since RADIO HAL is not yet present in nrfx, the "nrf_radio.h" file
was temporarily moved to "nrfx/hal" folder. It will be replaced with
the proper file from nrfx in its next update.

Signed-off-by: Michał Kruszewski <michal.kruszewski@nordicsemi.no>
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2018-01-29 03:02:06 +05:30
Andrzej Głąbek c84c2eaa82 ext: nordic: Add initial adaptation layer for nrfx
This commit adds a glue layer that adapts nrfx to be usable in Zephyr
as a host environment and files with static configuration of nrfx
drivers for several supported SoCs.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2018-01-29 03:02:06 +05:30
Andrzej Głąbek f06c000911 ext: nordic: Import relevant files from nrfx 0.8.0
nrfx is an extract from the nRF5 SDK that contains solely the drivers
for peripherals present in Nordic SoCs, for convenience complemented
with the MDK package containing required structures and bitfields
definitions, startup files etc.

Origin: nrfx
License: BSD 3-Clause
URL: https://github.com/NordicSemiconductor/nrfx/tree/v0.8.0
commit: b7cfe970b45ad7cc9c36b62ee620508e9e2c7fb5
Purpose: Provide peripheral drivers for Nordic SoCs
Maintained-by: External

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2018-01-29 03:02:06 +05:30
Vincent Veron 096314872a drivers: sensor: vl53l0x: ST library customization for Zephyr
The generic library provided by ST in ext/hal/st/lib/sensor/vl53l0x
needs to be adapted to the platform. In this case, the main
modification is the way to use I2C. This is now using the Zephyr
I2C API.

Signed-off-by: Vincent Veron <vincent.veron@st.com>
2018-01-23 10:14:49 -06:00
Vincent Veron 2862c8559b ext: enable st/lib compilation
This commit modify the ext/ build system to add
the ST Microelectronics libraries.

Signed-off-by: Vincent Veron <vincent.veron@st.com>
2018-01-23 10:14:49 -06:00
Vincent Veron 45bf893164 ext: Fix warnings in vl53l0x ST library when compiling on Zephyr
Warning are present in the default ST source code, fix them here.

Signed-off-by: Vincent Veron <vincent.veron@st.com>
2018-01-23 10:14:49 -06:00
Vincent Veron 81d4342dc0 ext: Add official ST library for vl53l0x
In order to ease the usage of its sensors, STMicroelectronics provides
some generic libraries. The first sensor to use that is vl53l0x time of
flight sensor. I have made the implementation generic enough to add some
more libraries in the future.

All the libraries will be located in ext/hal/st/lib.

The vl53l0X library is made of 2 parts :
    * the core, that is generic to all platforms
    * the platform, contains the adaptation layer. This will be
      implemented in driver as it is Zephyr specific.

Origin: ST Microelectronics
License: BSD-3-Clause
URL: http://www.st.com/en/embedded-software/stsw-img005.html
Commit: 1.0.2
Purpose: API to ease the usage of vl53l0x sensor
Maintained-by: External

Signed-off-by: Vincent Veron <vincent.veron@st.com>
2018-01-23 10:14:49 -06:00
Shiksha Patel 53cbfd3fd3 lpc: Add usart shim driver for lpcxpresso54114
Add usart-yaml in dts.

Build fsl_lpc_usart and fsl_lpc_flexcomm in
ext/hal/nxp/mcux/drivers/Makefile.

Only polling mode is implemented in usart now. Interrupt can be added in
future.

Signed-off-by: Shiksha Patel <shiksha.patel@nxp.com>
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-01-23 09:18:32 -06:00
Shiksha Patel 460d68e425 lpc: Add device header and driver files for lpc54114 from mcux 2.2.1
Renamed fsl drivers for lpc board as fsl_lpc drivers.

Origin: NXP MCUXpresso SDK 2.2.1
URL: mcux.nxp.com
Maintained-by: External

Signed-off-by: Shiksha Patel <shiksha.patel@nxp.com>
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-01-23 09:18:32 -06:00
Erwin Rol 2e0c11d604 ext: hal: stm32cube: update README
Update the README file to reflect the new Kconfig structure.

Signed-off-by: Erwin Rol <erwin@erwinrol.com>
2018-01-23 08:46:16 -06:00
Erwin Rol 772ac20336 ext: hal: stm32cube: allow HAL/LL files to be selected via Kconfig
By providing USE_STM32_HAL_* and USE_STM32_LL_* menuconfig
options drivers and user aplications can select parts of the HAL
without needing to change the Zephyr source code.

Signed-off-by: Erwin Rol <erwin@erwinrol.com>
2018-01-23 08:46:16 -06:00
Erwan Gouriou 28c2079c63 ext: stm32cube: update stm32l4xx cube version
Update Cube version for STM32L4XX family
from version: V1.9.0
to version: V1.10.0

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2018-01-17 09:55:30 -06:00
Erwan Gouriou 366c31c03b ext: stm32cube: update stm32f4xx cube version
Update Cube version for STM32F4XX family
from version: V1.16.0
to version: V1.18.0

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2018-01-17 09:55:30 -06:00
Erwan Gouriou a6d9fef241 stm32cube: f3: fix wrong package version
Fix stm32f3xx README with actual package version : V1.9.0


Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2018-01-17 09:55:30 -06:00
Neil Armstrong 5f5480ac7d hal: stm32cube: Fix warning when SPI STM32F0 LL API is compiled
Current implementation of LL_SPI_TransmitData16 on F0 family
generates following warning:
"warning: dereferencing type-punned pointer will break strict-aliasing
rules [-Wstrict-aliasing]"
Besides being forbidden by rule, this cast is not needed, as register is
16 bits wide. Modification has been tested on F0 SoC.
stm32yyxx_ll_spi.h being included in soc.h file, warning is generated
at each compiled object, this commit allows a clean build.
This issue is referenced in ST and tracked under
reference  13359. Code will be updated on upcoming stm32cube updates.

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
2018-01-11 19:00:19 -05:00
Neil Armstrong b5938c43fb ext: hal: stm32cube: build LL SPI code for STM32F0
Build the STM32Cube LL SPI Code for STM32F0

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
2018-01-11 19:00:19 -05:00
Anas Nashif 5218b9ad0c ext: tinycrypt: Update README to reflect latest version
We forgot to update the version number in the README

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-01-08 08:08:45 -05:00
Michael Hope aa6b5558fd ext: Import Atmel SAMD21 header files from ASF library
Atmel Software Framework (ASF) provides a set of low-level header
files that give access to different hardware peripherals of Atmel's
ICs.

Origin: Atmel SAMD21 Series Device Support (1.2.276)
License: Apache-2.0
URL: http://packs.download.atmel.com/Atmel.SAMD21_DFP.1.2.276.atpack
Purpose: Introduction of ASF for the SAM0 series.
Maintained-by: External

Signed-off-by: Michael Hope <mlhx@google.com>
2018-01-04 13:18:25 -05:00
Sebastian Bøe 6f642a19fd cmake: Ported mbedTLS to use Zephyr interface libraries
mbedTLS include directories will now default to be in the 'app'
include path when mbedTLS has been enabled.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2018-01-02 22:09:01 -05:00
Ramakrishna Pallala e1af972d73 ext: hal: altera: fix PIO build config option
Fix Kconfig option of PIO HAL to CONFIG_ALTERA_AVALON_PIO

Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
2017-12-21 12:02:24 -08:00
Michael Scott 2fc554b8fc crypto: config: config-coap: add CONFIG for setting max content length
The CoAP samples use an MBEDTLS config "config-coap.h" which could be
re-used by the LwM2M sample, except that most servers use a larger
maximum content length setting of 1500 bytes.

Let's add a CONFIG to set this for users of the CoAP lib and set the
CONFIG value for the samples to the 256 size currently used.

Signed-off-by: Michael Scott <michael@opensourcefoundries.com>
2017-12-15 17:52:13 -05:00
Anas Nashif 429c2a4d9d kconfig: fix help syntax and add spaces
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2017-12-13 17:43:28 -06:00
Neil Armstrong cc9642402d ext: stm32cube: build I2C+RCC LL for STM32F0
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
2017-12-12 12:36:08 -06:00
Ramakrishna Pallala 9906d3a48a ext: hal: altera: Add Altera HAL README file
Add Altera HAL README file as per Zephyr Guidelines.

Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
2017-11-17 07:46:40 -05:00
Ramakrishna Pallala 41a6b812d9 ext: hal: altera: Add basic infrastructure to enable HAL drivers
Add the basic infrastructure like driver <-> IRQ mapping table
and ZEPHYR_RTOS compile time flag which are neccessary to make
use the HAL drivers from Zephyr shim drivers.

Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
2017-11-17 07:46:40 -05:00
Ramakrishna Pallala 2c2b087b81 ext: hal: altera: Add Altera HAL into Zephyr build system
Make Altera HAL drivers compilable by adding them into
Zephyr build system.

Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
2017-11-17 07:46:40 -05:00
Ramakrishna Pallala 3c922749d6 ext: hal: altera: Add altera HAL sources in Zephyr
Add the Altera HAL sources from Altera Quartus Lite SDK
to Zephyr OS under 'ext/hal/altera' folder.

Origin: Altera Quartus Prime Lite SDK
URL: http://dl.altera.com/?edition=lite
Version: v17.0
Purpose: Provides HAL support to Altera's soft IP's
Maintained-by: External

Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
2017-11-17 07:46:40 -05:00
Maureen Helm 6043c74fd3 gpio: Introduce mcux igpio shim driver
Adds a new gpio driver for the NXP i.MX family of SoCs. Read, write,
configure, and callback API functions are all implemented.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-11-15 09:09:58 -06:00
Maureen Helm 0f3b490905 clock_control: Introduce mcux ccm driver
Adds a new clock control driver for i.MX SoCs that have the clock
control module (CCM).

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-11-15 09:09:58 -06:00
Maureen Helm 8a1d3b5b11 ext: mcux: Add mcux 2.3.0 for mimxrt1051 and mimxrt1052
Adds mcux 2.3.0 drivers and device header files for the mimxrt1051 and
mimxrt1052. Updates several drivers that were already imported for other
SoCs but also apply to the mimxrt1051 and mimxrt1052.

Origin: NXP MCUXpresso SDK 2.3.0
URL: mcux.nxp.com
Maintained-by: External

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-11-15 09:09:58 -06:00
Johann Fischer a14dd6309e cmake: fix build of the entropy drivers
Signed-off-by: Johann Fischer <j.fischer@phytec.de>
2017-11-11 19:01:42 -05:00
Gil Pitney 732b896b1e cmake: Fix ext/hal/ti/simplelink/CMakeLists.txt
After the cmake conversion, the SimpleLink WiFi host
driver would not build, and compiler flags like -Wno-strict-aliasing
were not being applied as they got spliced in before
-Wall rather than after.

This fixes those issues, using the set_source_files_properties()
method as suggeted in the CMakeLists.txt TODO comment.

Signed-off-by: Gil Pitney <gil.pitney@linaro.org>
2017-11-11 10:32:50 -05:00
Kumar Gala 3a5ca91f28 crypto: Update TinyCrypt to 0.2.8
Version 0.2.8 of this library has been released on Aug 29, and this
patch updates the library from version 0.2.7.  A summary of changes
is available at the official repository at:

    https://github.com/01org/tinycrypt/releases/tag/v0.2.8

A number of the changes we already had in tree, so the import to sync
with v0.2.8 is pretty minor.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2017-11-09 16:39:03 -06:00
Sebastian Bøe fc978328b5 cmake: ext/hal/st/stm32cube: Fixed formatting and removed hal_uart
Signed-off-by: Sebastian Boe <sebastian.boe@nordicsemi.no>
2017-11-08 20:00:22 -05:00