Commit Graph

46244 Commits

Author SHA1 Message Date
Martin Jäger b7a6087769 drivers: ipm: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger 53af1aab62 drivers: timer: stm32_lptim: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger 00ac525603 drivers: dma: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger 3ef8451e82 drivers: counter: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger 92e16191ac drivers: gpio: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger c512a908c8 drivers: spi: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger f8710aa722 drivers: i2s: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger 42eb8d7336 drivers: i2c: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger fc1c284c9c drivers: pwm: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger 39d388287f drivers: hwinfo: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger 505861e822 drivers: entropy: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger 9f23196121 soc: arm: stm32: hsem: use generic LL headers
Include generic header stm32_ll_hsem.h from stm_hsem.h (which is used
by multiple drivers) instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger d73bfcbdc8 drivers: iwdg: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger c3c3073c95 drivers: wwdg: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger f31fa1e61e drivers: dac: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Martin Jäger 7f68c0aa2c drivers: adc: stm32: use generic LL headers
Use generic LL headers instead of depending on soc.h.

Signed-off-by: Martin Jäger <martin@libre.solar>
2020-11-30 15:50:03 +01:00
Antonio Tessarolo 38566ef482 Driver i2c_imx: changed read and write transmission size type
imx_msg transmission size type is uint32_t:
changed imx_read and imx_write signature accordingly.
Removed also two unused variables.

Signed-off-by: Antonio Tessarolo <anthonytexdev@gmail.com>
2020-11-30 15:49:38 +01:00
Antonio Tessarolo 0a2456c0eb i2c_imx: Fix system fault when there is no data to send
When there is no data to send (e.g. i2c message with NULL buffer and
len=0), i2c_imx driver locks itself in isr handling forever.
So if there is no data to send, only device's address must be written
on bus. This fixes i2c_shell's scan command on both imx7 and imx6sx.

Signed-off-by: Antonio Tessarolo <anthonytexdev@gmail.com>
2020-11-30 15:49:38 +01:00
Asger Munk Nielsen fbee6cc933 Bluetooth: controller: Create HCI stubs for CIG/CIS and ISO
Put infrastructure for the following HCI commands/events in place:
* LE Read ISO Link Quality command
* LE Read ISO TX Sync command
* LE Set Host Feature Command

Signed-off-by: Asger Munk Nielsen <asmk@oticon.com>
2020-11-30 15:49:30 +01:00
Erik Larson c47c115c28 drivers: gpio: gpio_cc13xx_cc26xx: Add drive strength configurability
Add support for the GPIO_DS_ALT_LOW and GPIO_DS_ALT_HIGH gpio flags.

Fixes #30219

Signed-off-by: Erik Larson <erik@statropy.com>
2020-11-30 15:49:20 +01:00
Dominik Ermel 25ac7e03a6 samples: mgmr: smp_svr: Extend sample sanity check configurations
Configurations for additional smp_svr sanity builds have been added
to limit possibility of getting not compilable smp_svr sample.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2020-11-30 15:48:59 +01:00
Alexander Kozhinov 2b2b5398e7 dts: arm: st: h7: stm32h745
add description to SRAM regions

Signed-off-by: Alexander Kozhinov <AlexanderKozhinov@yandex.com>
2020-11-30 15:48:49 +01:00
Lingao Meng 1b65fd066f Bluetooth: Mesh: Fix Friend node estalished
Since first poll request send by lpn use friend security
credentials, so, friend nodes should be able to decrypt with
friend security, even if they have not yet established a friendship.

Signed-off-by: Lingao Meng <menglingao@xiaomi.com>
2020-11-30 12:32:37 +02:00
Lingao Meng 084574b470 Bluetooth: Mesh: Fix Friend node handle Key update
When friend node key refresh phase to stage_1, there
are need to add friend update message to friend queue,
but, when friend KR phase to stage_2, must add friend
update to queue.

Signed-off-by: Lingao Meng <menglingao@xiaomi.com>
2020-11-30 12:32:37 +02:00
Lingao Meng 325288d531 Bluetooth: Mesh: Fix friend node cache message
Friend node cache segment message for lpn, message with
sequence number can't change, since could cause lpn replay
attack.

Signed-off-by: Lingao Meng <menglingao@xiaomi.com>
2020-11-30 12:32:37 +02:00
Wolfgang Puffitsch 6aa16e01dd Bluetooth: controller: hci: Fix naming for ISO path setup parameters
Fix field names of bt_hci_cp_le_setup_iso_path in le_setup_iso_path to
make CIS central/periphal compile and adjust parameter names for
ll_setup_iso_path accordingly.

Signed-off-by: Wolfgang Puffitsch <wopu@demant.com>
2020-11-28 07:36:16 -05:00
Peter Bigot bc33ef4d42 drivers: flash: nrf_qspi_nor: remove multithreading dependency
Replace semaphores with an atomic ready flag when used without
multithreading enabled.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-11-28 07:20:27 -05:00
Torsten Rasmussen ca08cc0d02 sanitycheck: check existence of testcase_extra.conf
Running sanitycheck for multiple platforms but only request coverage
on a single platform fails, example:
  sanitycheck --enable-coverage --coverage-platform nrf52840dk_nrf52840
  -p nrf52840dk_nrf52840 -p nrf52dk_nrf52832 -T <sample>

This happens because `testcase_extra.conf` will only be created if the
current platform is included in the list of coverage platforms.

The error in the example above that would be seen is:
  File not found:
      <...>/sanitycheck/testcase_extra.conf
This commit now uses the existence of `testcase_extra.conf` which is
created in the method `create_overlay()` before appending
the conf file to the list of overlay files.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
2020-11-28 07:19:15 -05:00
Peter Bigot f13eb90705 samples: nrf: battery: fix reference to ADC node
The sample referenced the ADC through an alias that either never
existed or (more likely) has since been removed.  Use the node label
instead.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2020-11-27 20:26:45 -05:00
Trond Einar Snekvik 7986f94275 kernel: Add K_DELAYED_WORK_DEFINE
Adds a K_DELAYED_WORK_DEFINE, matching the K_WORK_DEFINE macro, with
accompanying Z_DELAYED_WORK_INITIALIZER macro.

Makes k_delayed_work_init a static inline function, like its K_WORK
counterpart.

Signed-off-by: Trond Einar Snekvik <Trond.Einar.Snekvik@nordicsemi.no>
2020-11-27 20:08:30 -05:00
Anas Nashif 4b59312a94 kernel: init: move banner handling
Move banner and boot delay handling out of init.c
The code for banner was all over the place in init.c making it
unreadable.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2020-11-27 20:08:14 -05:00
Anas Nashif de69edbf42 kernel: move xip code to dedicated file
No functional changes, just moving the XIP code out and build it only
when XIP is enabled.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2020-11-27 20:08:14 -05:00
Guennadi Liakhovetski 5cc05aad9f cavs: fix clock frequencies for cAVS v1.8, v2.0 and v2.5
SOF uses different SSP clock rates on different cAVS versions. Frequency
tables are provided in platform_ssp_freq[] arrays in clk.c for each
version and the default entry is selected by the SSP_DEFAULT_IDX index.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2020-11-27 20:07:59 -05:00
Carles Cufi cd97cffa79 actions: manifest: Update to latest action revision
The manifest GitHub action now optionally takes a checked out tree in
order to find the merge base of the pull request branch. Provide this to
avoid artifacts in edge cases.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2020-11-27 20:12:46 +01:00
Carles Cufi ebf2e76740 drivers: console: Fix path to mcumgr header
The mcumgr header files are now in include/mgmt/mcumgr/, so reflect this
change in the UART console implementation.

Fixes #30261.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2020-11-27 18:18:50 +01:00
Emil Gydesen e39ae14f9b actions: Add labels for Bluetooth Controller/Host
Automatically assign the Bluetooth Controller and
Bluetooth Host labels to changes in the controller and
host respecitvely. For this, both Mesh and the Gatt services
will be considered part of the host.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2020-11-27 09:58:34 -05:00
Tomasz Bursztyka 9bf3c62a4a drivers/pcie: Fix function that looks up for mbar
An address might be made for 64bit though it's lower 32 bits are made of
0. Also Simplifying the overall by removing a useless variable.

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2020-11-27 09:58:08 -05:00
Krzysztof Chruscinski 3ed8083dc1 kernel: Cleanup logger setup in kernel files
Most of kernel files where declaring os module without providing
log level. Because of that default log level was used instead of
CONFIG_KERNEL_LOG_LEVEL.

Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
2020-11-27 09:56:34 -05:00
Anas Nashif 82a6a467ec sanitycheck: do not try platforms not in hardware map
Get list of connected hardware and filter tests to only be run on
connected hardware in cases where no platform was specified when runn
the tests.  If the platform does not exist in the hardware map, just
skip it.

Fixes #29166

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2020-11-27 09:29:59 -05:00
Ioannis Glaropoulos 018d2b2325 boards: arm: nRF5340: add a note about required nRF CL tools
Add a note in the documentation regarding the required
nRF Command Line Tools for properly working with the
nRF5340 DK.

Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
2020-11-27 14:48:13 +02:00
Jan Kowalewski 83b6fa20fe west.yml: bump hal_quicklogic module
This commit bumps module SHA to the newest one

Signed-off-by: Jan Kowalewski <jkowalewski@antmicro.com>
2020-11-26 18:47:18 +01:00
Krzysztof Chruscinski 751bdf483b drivers: serial: nrfx: Skip poll out when device is not active
Added early return from uart_poll_out when uart device is not in
active state. Poll_out is used from many contexts by multiple users
and currently here is no mechanism in power management to disable
them (console, logger when going to inactive power state.

Additionally, moved setting new state when disactivating the device to
ensure that no poll_out will happen after disabling the UARTE.

Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
2020-11-26 19:08:01 +02:00
Carles Cufi f97b07bc3f actions: Enable new manifest workflow
The manifest workflow uses the manifest action to detect changes in the
west manifest. It then analyzes the changes and posts labels and a
comment in table format accordingly.

It is meant to be used as a helper bot for developers submitting changes
to modules, reducing the need for manual work and oversight and
automating common operations.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2020-11-26 12:07:23 -05:00
Vinayak Kariappa Chettimada 8bf3ee9f98 Bluetooth: controller: Fix skipped single-shot ticker failure callback
A single-shot ticker in requested state beyond the elapsed
duration or skipped due to collision shall generate an
operation callback with failure status.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2020-11-26 15:47:02 +01:00
Morten Priess 2d0107ab27 Bluetooth: controller: Fix ticker collision update race
In the case where a BLE connection ticker node collides and does not
trigger a callback to ULL, and at the same time the same node receives a
ticker update request, the update causes the node to be scheduled for
execution a second time. This has the consequence of event_counter going
out of sync, and BLE connection is ultimately lost.

The solution is to mark collsions and re-scheduled nodes as expired, and
use the increased lazy count to identify its state instead of req/ack.

Signed-off-by: Morten Priess <mtpr@oticon.com>
2020-11-26 15:47:02 +01:00
Wolfgang Puffitsch 44fa773340 tests: Bluetooth: Add tests for reading codec and controller delay info
Exercise HCI commands to read codec and controller delay information.

Signed-off-by: Wolfgang Puffitsch <wopu@demant.com>
2020-11-26 15:46:17 +01:00
Wolfgang Puffitsch 1547108b19 Bluetooth: controller: HCI commands to read codecs and controller delay
Implement HCI commands to read information about supported codecs and
controller delay.
* Read Local Supported Codecs command (v1 and v2)
* Read Local Supported Codec Capabilities command
* Read Local Supported Controller Delay command

The following functions are implemented as "weak" symbols and should
be overridden to fill in vendor-specific information into the above
commands.
* hci_vendor_read_std_codecs
* hci_vendor_read_vs_codecs
* hci_vendor_read_codec_capabilities
* hci_vendor_read_ctlr_delay

Signed-off-by: Wolfgang Puffitsch <wopu@demant.com>
2020-11-26 15:46:17 +01:00
Wolfgang Puffitsch 9437a6a08d Bluetooth: hci: Add definitions for codec and controller delay info
Add defines and structs for reading information about supported codes,
codec capabilities and controller delays. Return parameter structs for
commands that return multiple variable-length fields only model the
fixed-length fields to minimize inconsistencies.

Signed-off-by: Wolfgang Puffitsch <wopu@demant.com>
2020-11-26 15:46:17 +01:00
Torsten Rasmussen c08ef381c8 bintools: append ; to > to ensure a space
Ensure > is an independent argument.
The ; will ensure that the `>` and `outfile` are given as two arguments
and thus ensure correct behavior in all cases.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
2020-11-26 14:20:03 +01:00
Watson Zeng 249aa62c27 arch: arc: fix for hs eret has no copy of pc in interrupt entry
According to the PRMs of both ARC EM & ARC HS families on entry
to Fast IRQ handler ARC hardware saves PC (Program Counter) value
of where processor was right before jumping to the IRQ handler into
2 registers: ILINK & ERET.

But it turned out in case of ARC HS (at least in configuration with
Fast IRQs & 1 register bank) only ILINK was populated with the
previous PC, while in Zephyr we relied on what we read out of ERET.
That lead to funny issues when CPU returned from IRQ handling
to some unexpected location.

And now with that precious knowledge we're switching to return
address recovery from ILINK so that with both families of ARC
processors (EM & HS) we may get reliably good results.

The wrapper is few cycles shorter/faster as well, as we may shave off
another extra instruction for transferring ERET value from its AUX reg
to a scratch core register to be later stored in the memory.

+----+---------------+---------------+--------------+
|    | FIRQ          | RIRQ          | RIRQ(Secure) |
+----+---------------+---------------+--------------+
| HS | ILINK=PC      | ILINK=PC      | NULL         |
+----+---------------+---------------+--------------+
| EM | ILINK=ERET=PC | ILINK=ERET=PC | ILINK=PC     |
+----+---------------+---------------+--------------+

Signed-off-by: Watson Zeng <zhiwei@synopsys.com>
2020-11-26 14:19:28 +01:00