Commit graph

41161 commits

Author SHA1 Message Date
Kumar Gala
9784f800a6 i2c: Rename CONFIG_I2C_[0..5]_NAME -> DT_I2C_[0..5]_NAME
Now that everything is DT based for I2C drivers we can rename the
CONFIG_I2C_[0..5]_NAME define to DT_I2C_[0..5]_NAME.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-10-23 11:31:32 -05:00
Kumar Gala
669e0f3b32 i2c: Move how we set HAS_DTS_I2C
Now that all I2C drivers utilize DTS we can select HAS_DTS_I2C in a
common place and don't need to do it per driver.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-10-23 11:31:32 -05:00
Kumar Gala
7e96ca5d80 i2c: Remove non DTS Kconfig params
All drivers utilize DTS now so we can remove the Kconfig params related
to !HAS_DTS_I2C.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-10-23 11:31:32 -05:00
Kumar Gala
9599c2d510 tests: boards: altera_max10: Use DT define for I2C device name
Move to using DT define instead of a Kconfig param, also remove unused
I2C Kconfig params for this test.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-10-23 11:31:32 -05:00
Sebastian Bøe
5c57abcc48 cmake: dt: Reconfigure when DTS dependencies change
When DT sources change CMake must be run again. CMake is currently
detecting changes to DT source files that we manually specify, but not
sources that are included through use of the preprocessor.

This patch makes the preprocessor output the includes used and adds
them to the 'CMAKE_CONFIGURE_DEPENDS' property.

This fixes #16791.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2019-10-23 17:54:41 +02:00
Sebastian Bøe
c5dd84a316 cmake: Added function for parsing gcc dependency metadata
Added a function that can parse the dependency information given when
invoking gcc with the argument '-M'. This could be used to manually
add dependencies detected when preprocessing a file.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2019-10-23 17:54:41 +02:00
Radoslaw Koppel
ecf06debe6 Bluetooth: UUID: Implement UUID 128 encoder
This commit adds an macro to allow UUID 128
to be written in more user-friendly form.
UUID in 128 bit form requires an array creation.
To complicate the whole thing - it requires the array to start from LSB,
so using the readable form, we have to write it down backwards.

Old way to declare example UUID 6E400001-B5A3-F393-E0A9-E50E24DCCA9E:
 0x9E, 0xCA, 0xDC, 0x24, 0x0E, 0xE5, 0xA9, 0xE0,
 0x93, 0xF3, 0xA3, 0xB5, 0x01, 0x00, 0x40, 0x6E

A form provided by this commit:
 BT_UUID_128_ENCODE(0x6E400001, 0xB5A3, 0xF393, 0xE0A9, 0xE50E24DCCA9E)

Signed-off-by: Radoslaw Koppel <radoslaw.koppel@nordicsemi.no>
2019-10-23 18:49:13 +03:00
Kumar Gala
ceffca2c42 boards: arm: mps2: Add LED & Buttons to board dts
Update board dts files to add User LED and Button support.  Also update
the board yaml file to say the boards support gpio.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-10-23 10:26:56 -05:00
Kumar Gala
28d060513c arm: mps2: Convert gpio to use device tree
Add binding for arm,mps2-fpgaio-gpio and update device tree and change
FPGA GPIO init code to utilize device tree defines.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-10-23 10:26:56 -05:00
Kumar Gala
ff031032bf dts: binding: gpio: add ngpios property
Add ngpios property that conveys the number of gpios supported on a
given controller.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-10-23 10:26:56 -05:00
Maureen Helm
65d9f541a7 boards: mimxrt1050_evk: Configure default sdhc instance at board level
Configures the default instance of the sdhc driver for the
mimxrt1050_evk board so applications don't have to configure it
explicitly. Similarly, enables the gpio instance required by the sdhc
driver.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2019-10-23 09:49:05 -05:00
Maureen Helm
f8cfe453fd soc: nxp_imx: Configure default sdhc driver at the soc series level
Configures the default sdhc driver for the imx rt soc series so
applications don't have to configure it explicitly.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2019-10-23 09:49:05 -05:00
Maureen Helm
efa099e1f5 disk: Configure default sdhc volume name for fatfs
Configures the default sdhc disk volume name to "SD" when fatfs is
enabled. This prevents applications from having to configure it
explicitly.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2019-10-23 09:49:05 -05:00
Anas Nashif
529791dff7 ztest: add missing headers
Recent changes to architecture headers did not address ztest headers due
to this bug in sanitycheck. Fixing them now.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-10-23 10:47:22 -04:00
Anas Nashif
a5984ab1c6 sanitycheck: fail on warnings
Missed adding extra cflags to fail on warning. Adding those back.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-10-23 10:47:22 -04:00
Maksim Masalski
11faaacd1e tests/posix/common: Fix miscalibrated timing test
This test seems a little confused.
Adjust the calibration to allow 110ms sleeps to avoid error
during automated testing.

Signed-off-by: Maksim Masalski <maksim.masalski@intel.com>
2019-10-23 14:45:40 +02:00
Martí Bolívar
34ca048d4b scripts: use compatible release specifiers in requirements.txt
Using exact versions for our PyPI dependencies (i.e. requirements.txt
lines that look like "dependency==X.Y.Z") is rude since we're asking
users to install these dependencies outside of any virtual
environment. This causes conflicts with other packages which may
depend on the same things as us.

Use inclusive ordered comparison (>=) release specifiers instead:

https://www.python.org/dev/peps/pep-0440/#inclusive-ordered-comparison

If this causes problems for individual packages, we can refine them
using compatible release specifiers (~=):

https://www.python.org/dev/peps/pep-0440/#compatible-release

Signed-off-by: Martí Bolívar <marti.bolivar@nordicsemi.no>
2019-10-23 14:43:06 +02:00
Peter A. Bigot
452d3dea7a subsys/fs: correct misinterpretation of Zephyr API
The Zephyr fs readdir abstraction returns OK with a zero-length file
name when the last directory entry has been found.  The loop to build
multiple entries instead checked for a non-file entry type.

Correct the loop exit condition.

Signed-off-by: Peter A. Bigot <pab@pabigot.com>
2019-10-23 07:59:01 -04:00
Peter A. Bigot
9b993bef6b subsys/fs/fatfs: correct misinterpretation of FatFs API
The FatFs f_readdir function returns OK with a zero-length file name
when the last directory entry has been found.  The Zephyr wrapper
unconditionally accessed fields that are left uninitialized in that
situation, propagating garbage values to the caller.

Avoid referencing uninitialized fields of the output structure in this
case.

Signed-off-by: Peter A. Bigot <pab@pabigot.com>
2019-10-23 07:59:01 -04:00
Ulf Magnusson
2d083765e9 fs: nvs: kconfig: Remove unused NVS_PROTECT_FLASH symbol
Unused since commit 7d2e59813f ("subsys: fs/nvs: Rewrite for improved
robustness").

Found with a script.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-10-23 06:45:07 -05:00
Yannis Damigos
edb57a51d7 i2c_ll_stm32.c: Use macro to add I2C5 instance
Use macro to add I2C5 instance

Signed-off-by: Yannis Damigos <giannis.damigos@gmail.com>
2019-10-23 06:43:56 -05:00
Jukka Rissanen
50f30919df samples: net: Add a multithreaded dumb HTTP server
This adds a multithreaded dumb HTTP server sample application similar
to dumb_http_server with following differences

* support both IPv4 and IPv6 simultaneously
* support multiple incoming connections
* support TLS connections
* ignore POSIX compatibility

This app can be used for testing. Note that the app will always
serve a same static HTML page to caller regardless of HTTP request
parameters.

Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
2019-10-23 14:43:25 +03:00
Andrzej Głąbek
83708567c9 modules: hal_nordic: Update nrfx to version 1.8.1
Update nrfx to the recently released version. See
https://github.com/NordicSemiconductor/nrfx/blob/v1.8.1/CHANGELOG.md
for a list of changes that this version introduces.

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

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2019-10-23 11:09:37 +02:00
David B. Kinder
cc1b94c388 doc: fix display of monospaced text links
Links to doxygen-generated API content are displayed as monospaced code
spans in the text, but have no indication that they're are clickable
links.  Tweak the CSS to color the monospaced text the same as regular
links in the text (blue) and after visited (purple).  This might also
help us notice doxygen API references that aren't creating links (and
should).

Fixes: #20032
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-10-23 08:59:49 +02:00
Andrei Gansari
b5ed5af8c8 tests: schedule_api adapt to slow ticks
This test case is has a tolerance of 1ms, but systems with a tick slower
than 1000 ticks/sec may spil outside the 1ms tolerance.
Tolerance adapts to system's ticks/sec, e.g. QEMU targets have
100ticks/sec -> tolerance is 10ms.

Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
2019-10-22 23:06:41 -04:00
Andrei Gansari
65fbfbbbff tests: scheduler_api removed MPS2 workaround
CONFIG_SOC_SERIES_MPS2 specific test workaround is removed
to use systick drives as tickless.

Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
2019-10-22 23:06:41 -04:00
Andrei Gansari
e0d7e880f2 boards: MPS2 targets enabled icount
Set qemu parameter for MPS2 targets: -icount auto

Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
2019-10-22 23:06:41 -04:00
Andrei Gansari
2adccabf6a drivers: remove arm's qemu systick workaround
Removed workarounds in systick driver as they prevent normal usage in
TICKLESS systems. Driver still behaved like an interrupt based ticker.

Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
2019-10-22 23:06:41 -04:00
Steven Wang
3cb03efd9c tests: move test timeutil into "unit" directory.
We don't have to build an image for running test timeutil. We
can just build a native app to test it. So move it into "unit"
directory.

Also, add 64-bit support for unit testing framework.

Signed-off-by: Steven Wang <steven.l.wang@linux.intel.com>
2019-10-22 23:05:34 -04:00
Ulf Magnusson
41a0e762ed lib: cmsis_v1: kconfig: Remove unused CMSIS_MAX_THREAD_COUNT symbol
Added in commit ccd1c21824 ("lib/cmsis_rtos_v1: Implement support for
thread APIs"), then never used.

Found with a script.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-10-22 23:02:16 -04:00
David B. Kinder
2d56a69735 doc: add v1.14.1 docs to version pick list
Update conf.py to add the v1.14.1 release docs to the master docs
version pick list, and remove the original v1.14.0.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-10-22 22:59:59 -04:00
Maksim Masalski
9f26f7d3d4 tests: updated names for the kernel tests
After run Sanitycheck script I found out that test cases
had the same test case name in the test result .xml file.
For board itodk in .xml file was duplicated kernel.common test.
To get rid of it, I decided to change test cases names
for the kernel tests, contained name kernel.common.
Now only one test has kernel.common test name,
and will be no duplicated test cases names in the future.

Signed-off-by: Maksim Masalski <maksim.masalski@intel.com>
2019-10-22 22:55:35 -04:00
Peter Bigot
040b1d676e samples: sensor: lps22hb: add sample
Copy and rename from hts221.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2019-10-22 17:56:56 -05:00
Stephanos Ioannidis
5806787ae1 tests: kernel: Fix incorrect interrupt controller type inference.
The current implementation of kernel interrupt tests incorrectly
infers NVIC, which is specific to Cortex-M, from CONFIG_ARM.

This commit fixes such incorrect NVIC inferences by using
CONFIG_CPU_CORTEX_M instead of CONFIG_ARM.

Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
2019-10-22 15:07:52 -07:00
Ulf Magnusson
66682a2ee9 drivers: dma: kconfig: Remove unused DMA_1/2_IRQ_PRI symbols
Added in commit bb36c0af86 ("dma: Add possibility for up to 3 DMA
Controllers") in February 2017, then never used.

Found with a script.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-10-22 23:41:01 +02:00
Dominik Ermel
37ef7655ec west.yml: Update reference to TinyCBOR
Reviewed here: https://github.com/zephyrproject-rtos/tinycbor/pull/8

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2019-10-22 15:55:18 -05:00
Olof Kindgren
d09614ab59 drivers: spi: Add simple_spi driver
Add support for the OpenCores simple_spi controller

Signed-off-by: Olof Kindgren <olof.kindgren@gmail.com>
2019-10-22 15:54:03 -05:00
Peter Bigot
4d97252cdf doc: dts: describe nexus node magic required for shield gpio translation
Document why and how we use the devicetree nexus map properties to
preserve devicetree flag specifications.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2019-10-22 14:40:41 -05:00
Peter Bigot
f8bfc7e175 devicetree: tree-wide: add nexus map properties for arduino headers
We need to be able to specify GPIO flags in devicetree without that
preventing translation from the Arduino specifier to the host GPIO
specifier.  Set up to ignore the low 6 bits of the flags field when
matching the child specifier, and to copy those bits to the parent
specifier.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2019-10-22 14:40:41 -05:00
Carles Cufi
485e22b4f0 dts: bindings: Fix u-blox misspelling
Spell ublox correctly.

Fixes #19867.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2019-10-22 14:34:09 -05:00
Ulf Magnusson
d5ff890547 sensor: bmg160: Use BMG160_THREAD_PRIORITY instead of ignoring it
The value of BMG160_THREAD_PRIORITY has never been used after the symbol
was added. Use it.

The value defaults to 10 in Kconfig too, so this is a no-op in itself.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-10-22 14:32:55 -05:00
Ulf Magnusson
79d82f6805 xtensa: kconfig: Remove unused XTENSA_OMIT_HIGH_INTERRUPTS symbol
Unused since commit 6fd6b7e50a ("xtensa: remove legacy arch
implementation").

Found with a script.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-10-22 14:31:46 -05:00
Johann Fischer
85697f32bd drivers: ssd16xx: fix GPIO controller name for BUSY pin
Fix GPIO controller name for BUSY pin.

Signed-off-by: Johann Fischer <j.fischer@phytec.de>
2019-10-22 14:13:25 -05:00
Stephane D'Alu
2dad6f75f4 display/ssd1306: build time selection of reversed display
Resolves: #19871

Signed-off-by: Stephane D'Alu <sdalu@sdalu.com>
2019-10-22 14:11:33 -05:00
Anas Nashif
e645d9ffd5 scripts: add script for listing closed bugs
Script to be used when creating a release. For regular releases this can
be called this way:

$ list_issues.py -f issues.md -s 2019-09-01

Will list all closed issues since september 1st, 2019 and will create a
markdown file with all issues that can be added as is to the release
notes.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-10-22 15:11:09 -04:00
Alberto Escolar Piedras
831c3327d9 CODEOWNERS: Add owner for valgrind suppression file
The valgrind suppression file did not have an owner
That file is only usefull for POSIX arch based boards

=> Adding myself as owner of the file

Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com>
2019-10-22 13:56:13 -05:00
Ulf Magnusson
677f1e6db9 kconfig: Turn pointless/confusing 'menuconfig's into 'config's
Defining a symbol with 'menuconfig' just tells the menuconfig to display
any dependent symbols that immediately follow it in a separate menu.
'menuconfig' has no effect on symbol values.

Making a symbol that doesn't have any dependent symbols after it a
'menuconfig' should be avoided, because then you end up with an empty
menu, which is shown as e.g.

    [*] Enable foo ---

This is how it would be shown if there were children but they all
happened to be invisible as well.

With a regular 'config', it turns into

    [*] Enable foo

Change all pointless 'menuconfig's to 'config's.

See the section on 'menuconfig' on the Kconfig - Tips and Best Practices
page as well.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-10-22 13:53:06 -05:00
Alexander Wachter
91818d2c07 drivers: sensors: ens210: fix fractional part calculation
This commit fixes the calculation of the fractional part
for both values.

Signed-off-by: Alexander Wachter <alexander.wachter@student.tugraz.at>
2019-10-22 13:48:12 -05:00
Andrzej Puzdrowski
9ac3755612 settings: (NVS) fetch sector size from driver
NVS back-end initialization should fetch size of the flash erase blocks
from the flash API instead of DT. This allows to work well when used
storage partition is not located in embedded memory.

NVS back-end sector multiplier configuration was set to 8K as
DT value for native posix targets
flash sector sizes is 1 B, while its flash driver supports 8k.

Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
2019-10-22 10:52:36 -05:00
Ulf Magnusson
53c688292a drivers: sensor: ens210: Fix broken CONFIG_ENS210_CRC_CHECK checks
The CONFIG_* prefix was missing, making the #ifdefs always false.

Found with a script (CONFIG_ENS210_CRC_CHECK was unused).

Also make ens210_crc7() static. Guessing it's unused outside this file.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-10-22 09:44:46 -05:00