Commit graph

41120 commits

Author SHA1 Message Date
Kumar Gala
2db8518c9d dts/binding/sensor: Fix ST sensors irq-gpios property being required
Change binding for ST sensors property 'irq-gpios' to optional for the
cases of in which its obvious from the driver that the property is
optional (there's an ifdef based on the #define
DT_INST_0_ST_LIS2DH_IRQ_GPIOS_*).

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-09-07 10:25:02 -05:00
Johann Fischer
1dace68a69 sample: cfb: enable test for the shield ssd1306_128x64
Enable test for the shield ssd1306_128x64.

Signed-off-by: Johann Fischer <j.fischer@phytec.de>
2019-09-07 17:15:51 +02:00
Johann Fischer
eea99367e4 shields: add generic shield for SSD1306 based 128x64 displays
Add generic shield for SSD1306 based 128x64 pixel
monochrome displays.

Signed-off-by: Johann Fischer <j.fischer@phytec.de>
2019-09-07 17:15:51 +02:00
Johann Fischer
fe0edb7595 samples: cfb: remove FRDM-K64F board config and overlay
Remove FRDM-K64F board config and overlay from cfb sample.

Signed-off-by: Johann Fischer <j.fischer@phytec.de>
2019-09-07 17:15:51 +02:00
Johann Fischer
817d042009 boards: frdm_k64f: add arduino i2c node
Add arduino i2c node.

Signed-off-by: Johann Fischer <j.fischer@phytec.de>
2019-09-07 17:15:51 +02:00
Frank Li
a55620e281 drivers: ssd1306: Write data from any coordinate
Support write data from any coordinate.
ssd1306 can work with lvgl

Signed-off-by: Frank Li <lgl88911@163.com>
2019-09-07 17:15:41 +02:00
Vinayak Kariappa Chettimada
a28eba9897 Bluetooth: controller: Fix data PDU leak during ctrl PDU defer
Fix a bug where in tx data PDU enqueued, while a ctrl PDU is
deferred due to Encryption setup being in progress, is
leaked causing HCI Tx Buffer Overflow crash.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2019-09-07 17:10:22 +02:00
Vinayak Kariappa Chettimada
af5bcf354a Bluetooth: controller: Fix start encryption in progress check
Fix check in start encryption to disallow new encryption
setup while there is one already in progress.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2019-09-07 17:10:22 +02:00
Vinayak Kariappa Chettimada
7872b733d1 Bluetooth: controller: Fix Re-encryption procedure
Fix MIC failure on re-encryption procedure when responding
at the same time to peer initiated feature request.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2019-09-07 17:10:22 +02:00
Vinayak Kariappa Chettimada
46d5554664 Bluetooth: controller: Fix ENC_REQ PDU retransmission
Fix dropped ENC_REQ PDU when retransmitting, if slave was
not listening or nack-ed it.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2019-09-07 17:10:22 +02:00
Vinayak Kariappa Chettimada
6991d09977 Bluetooth: controller: Fix control tx queue handling
Fix control tx queue handling to correctly pause control PDU
responses during encryption setup.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2019-09-07 17:10:22 +02:00
Vinayak Kariappa Chettimada
1d978e8856 Bluetooth: controller: Add data length procedure queueing
Added implementation to cache Data Length Procedure when
another control procedure is in progress.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2019-09-07 17:10:22 +02:00
Vinayak Kariappa Chettimada
2e365424f0 Bluetooth: controller: Defer encryption setup if in conn update
Workaround, defer peer initiated encryption while local
initiated procedure with instant is not complete. Peer
master has sent CONN_UPDATE_IND in response to
CONN_PARAM_REQ, and also has initiated a Encryption Setup
thereafter. In this case, avoid corruption of the connection
update context by deferring the Encryption Setup.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2019-09-07 17:10:22 +02:00
Vinayak Kariappa Chettimada
3f695f7823 Bluetooth: controller: Fix cmd disallowed and collision disconnects
Fix implementation to correctly cache the control procedures
initiatable by local and peer. And, fix feature exchange and
version information procedures from being disallowed by
having then as cached requests to the controller.

Relates to #15256.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2019-09-07 17:10:22 +02:00
Sebastian Bøe
6212ec9612 cmake: Cache the 'toolchain-is-ok' test as well
All compiler flag checks are cached for build-time performance reasons
except for the test that tests the toolchain itself.

It is believed that this test was left uncached because at the time,
there was not enough trust in the caching mechanism. But time has
shown that the caching mechanism is safe. So cache this test as well.

This improves build-time performance and also reduces noise in the
logs.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2019-09-07 10:25:12 -04:00
Carles Cufi
4a504446d7 west: flash: Fix exception on build folder guessing
When guessing the build folder, the current path might not exist at all,
leading to an uncaught exception when trying to list its folders. Fix
this by making sure the path exists at all first.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2019-09-07 10:24:17 -04:00
Daniel Leung
ea438d0a9b xtensa: asm2: add code for double exception vector
This adds a simple infinite loop when double exception is raised.
Without this, if double exception occurs, it would execute
arbitrary code.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-09-07 10:21:16 -04:00
Daniel Leung
04ae38085c intel_s1000: implement z_soc_irq_is_enabled()
This provides an implemention for z_soc_irq_is_enabled()
as it is needed for multi-level interrupts.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-09-07 10:20:51 -04:00
Daniel Leung
984002de6d xtensa: rename z_arch_irq_is_enabled for multi-level interrupts
This follows the z_arch_irq_en-/dis-able() so that the SoC
definitions are responsible for functions related to multi-level
interrupts.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-09-07 10:20:51 -04:00
Daniel Leung
460e3c0094 drivers/interrupt_controller: rv32m1_intmux: add get_line_state
This implements the new API to query whether a particular IRQ
line is enabled.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-09-07 10:20:51 -04:00
Daniel Leung
635aadc9a9 drivers/interrupt_controller: dw_ictl: add get_line_state()
This implements the new API to query whether a particular IRQ
line is enabled.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-09-07 10:20:51 -04:00
Daniel Leung
958f2d5295 drivers/interrupt_controller: cavs_ictl: add get_line_state()
This implements the new API to query whether a particular IRQ
line is enabled.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-09-07 10:20:51 -04:00
Daniel Leung
d3e3552f65 irq_nextlevel: add API to query if an IRQ line is enabled
There is an API to query if any IRQ is enabled but there is
none to query individual IRQ line. So add one.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-09-07 10:20:51 -04:00
Sebastian Bøe
71281292fb cmake: Suppress west module logging
The log from CMake invocation's are now dominated by west
modules. This noise can hide important warnings.

To fix this we drop the logging.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2019-09-07 10:20:01 -04:00
Tobias Svehagen
86592e97f3 usb: cdc_acm: Fix compiler warning
Compiler warns about unused function when CONFIG_UART_LINE_CTRL is not
set.

Signed-off-by: Tobias Svehagen <tobias.svehagen@gmail.com>
2019-09-07 10:19:27 -04:00
Marti Bolivar
146580e555 scripts: west_commands: verify minimum cmake version
A recent developer experience study has pointed out that it's very
common for people to miss that the minimum cmake version required by
zephyr is higher than that which is commonly packaged by Linux
distributions.

Since this is a serious usability issue, it's worth adding extra
checking from zcmake.py to make sure that west commands which run
cmake always print a sensible error message if the cmake version used
is too old. Make that happen.

Signed-off-by: Marti Bolivar <marti.bolivar@nordicsemi.no>
2019-09-07 10:08:23 -04:00
Charles E. Youse
6767563f94 arch/x86: remove support for IAMCU ABI
This ABI is no longer required by any targets and is deprecated.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-09-07 10:07:42 -04:00
Charles E. Youse
37929b3428 arch/x86_64: do not modify CR8 in interrupt path
Currently, the interrupt service code manually raises the CPU task
priority to the priority level of the vector being serviced to defer
any lower-priority interrupts. This is unnecessary; the local APIC
is aware that an interrupt is in-service and accounts for its priority
when deciding whether to issue an overriding interrupt to the CPU.

Signed-off-by: Charles E. Youse <charles@gnuless.org>
2019-09-07 10:06:13 -04:00
Sebastian Bøe
48f97ecf46 cmake: Error-out when 'project' is invoked too early
Error-out when 'project' is invoked before boilerplate.cmake is
included. This is not supported and causes obscure errors.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2019-09-07 10:05:17 -04:00
Ulf Magnusson
270d535fb4 kconfig: modules: Trivial cleanup
A lot of the Kconfig stuff gets copied around, so encourage a clean
compact style:

 - Reduce license header spam

 - Fix some broken indentation

 - Turn a meaningless 'menuconfig' into a 'config'

 - Remove a redundant QMSI menu

 - Unscrunch comments: #Foo -> # Foo

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-09-07 10:04:04 -04:00
Alberto Escolar Piedras
3817cc6fdd native_posix & nrf52_bsim: Add z_arch_irq_connect_dynamic()
Add support for CONFIG_DYNAMIC_INTERRUPTS
in both native_posix and the nrf52_bsim

Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com>
2019-09-07 10:03:19 -04:00
Kumar Gala
8e38764255 subsys/fs/littlefs: Protect littlefs Kconfig options
Move the inclusion of the littefs Kconfig options inside the
'if FILESYSTEM' block so we don't leak Kconfig symbols if FILESYSTEM
support isn't enabled.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-09-07 10:02:15 -04:00
Sebastian Bøe
11f9acb830 cmake: Drop old deprecation warning
Drop the old deprecation warning about
ZEPHYR_TOOLCHAIN_CAPABILITY_CACHE. Sufficient time has passed to allow
users to migrate.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2019-09-07 10:01:52 -04:00
Daniel Leung
863548cf19 doc: mailbox: fix typos and clarify meaning of struct field
This fixes some typos. Also fix the meaning of a struct field
where the confusion caused by copy-and-paste from another
field.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-09-07 10:01:34 -04:00
Kamil Piszczek
2c43dede04 settings: adding missing header
Added missing header in the Settings private include.

Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
2019-09-07 10:01:09 -04:00
Carles Cufi
8645cc2b94 doc: cmake: Fix PYTHONPATH on Windows
Correctly set the separator as a semicolon on Windows when
constructing the PYTHONPATH environment variable so that CMake
doesn't intepret it and swallow it.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2019-09-07 10:00:45 -04:00
Andrew Boie
90e6536053 kernel: fix default z_arch_cpu_halt()
k_cpu_idle() re-enables interrupts. Just spin
instead.

Fixes: #18973

Signed-off-by: Andrew Boie <andrewboie@gmail.com>
2019-09-07 09:57:40 -04:00
Tomasz Bursztyka
0d37373196 soc/arm: Add the watchdog DTS fixup for mec1501
This is required to get the watchdog test and sample working since the
required wdt device name macro is generic there.

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2019-09-07 09:56:58 -04:00
Tomasz Bursztyka
939fc26c2e drivers/watchdog: Add support for Microchip XEC device
Such watchdog timer is found on mec1501.
It comes with a support of dbg stall feature and interrupt support.

It does not support multistaging.

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-09-07 09:56:58 -04:00
Tomasz Bursztyka
e83f4fad29 dts/arm: Add support for the watchdog in MEC1501hsz
It has one instance of this watchdog.

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2019-09-07 09:56:58 -04:00
Tomasz Bursztyka
bed0e2203b dts/bindings: Add the representation for Microchip's XEC watchdog timer
Such watchdog is found on MEC150x for instance.

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2019-09-07 09:56:58 -04:00
Kumar Gala
ec3a8ce41b doc: Release notes for v2.1 - initial (empty) draft
Get things started for Zephyr 2.1 release notes.
Individual PRs will update their appropriate sections.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-09-07 08:51:31 -05:00
Anas Nashif
4132ee3a05 ci: do not export BSIM env vars if bsim is not available
When running run_ci.sh locally with:

 ./scripts/ci/run_ci.sh -l -b master -R upstream/master..

we export BSIM_OUT_PATH unconditionally which causes sanitycheck to fail
on nrf52_bsim (it depends on BSIM_OUT_PATH variable).

Check if the path defined in BSIM_OUT_PATH is available and unset env.
variable if it is not.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-09-07 09:04:40 -04:00
Joakim Andersson
0790fdf0d7 Bluetooth: host: Add bt_conn_foreach API to iterate all connections
Add iterator function to iterate over all connection objects.
Make type a bitmap so that it can be used as a bitmask to select which
conns to receive foreach callback.
Use foreach function internally where possible.

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2019-09-07 15:53:26 +03:00
Trond Einar Snekvik
b2463a7126 Bluetooth: Mesh: Move model_find to public header
Allows models to find each other without direct access to the
composition data.

Signed-off-by: Trond Einar Snekvik <Trond.Einar.Snekvik@nordicsemi.no>
2019-09-07 15:51:25 +03:00
Trond Einar Snekvik
9a3ff5cdff Bluetooth: Mesh: Add prov input_complete to shell
Notifies the user that the callback fired.

Signed-off-by: Trond Einar Snekvik <Trond.Einar.Snekvik@nordicsemi.no>
2019-09-07 15:51:09 +03:00
Trond Einar Snekvik
c91d0646a6 Bluetooth: Mesh: Add prov input_complete cb
Allows the user to pass a provisioning input complete callback to the
provisioning module, letting the application stop displaying its output
OOB value when the other party finishes their OOB input.

Signed-off-by: Trond Einar Snekvik <Trond.Einar.Snekvik@nordicsemi.no>
2019-09-07 15:51:09 +03:00
Morten Priess
fddd786dfe bluetooth: host: Configurable HCI stack sizes
Made BT_HCI_TX_STACK_SIZE configurable and added BT_HCI_ECC_STACK_SIZE.
These changes are necessary to allow vendors to adjust for other
achitectures.

Signed-off-by: Morten Priess <mtpr@oticon.com>
2019-09-07 15:50:43 +03:00
Carles Cufi
aa960c9d6e Bluetooth: log: Rework BT_ASSERT
Rework the BT_ASSERT infrastructure with the following changes:

- Transition from LOG() macros to printk()
- Allow the BT_ASSERT() macro to map directly to stancard __ASSERT()
- Allow printing of the assert reason to be disabled
- Switch from k_oops() to k_panic() configurable

There are 2 reasons for using printk() instead of LOG():

- BT_ERR uses deferred logging by default, which is problematic with
ASSERTs
- The __ASSERT() macro in Zephyr uses printk()

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2019-09-07 15:50:23 +03:00
Joakim Andersson
6d08a30838 Bluetooth: SMP: Add missing static to internal function
Add missing static to internal SMP function

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2019-09-07 15:49:34 +03:00