Commit graph

61643 commits

Author SHA1 Message Date
Immo Birnbaum ec16d571ff CODEOWNERS: add owner for Xilinx PS GPIO controller driver
Add code ownership for the Xilinx Processor System MIO / EMIO GPIO
controller driver.

Signed-off-by: Immo Birnbaum <Immo.Birnbaum@weidmueller.com>
2022-03-15 08:44:46 -07:00
Immo Birnbaum b9f9d4a835 soc: arm: xilinx_zynq7000: add MMU region for PS GPIO controller
Add a 4k indentity mapping in the MMU for the Processor System GPIO
controller if the parent device node is enabled in the device tree.

Signed-off-by: Immo Birnbaum <Immo.Birnbaum@weidmueller.com>
2022-03-15 08:44:46 -07:00
Immo Birnbaum bbf16d7bd2 dts: bindings: gpio: Bindings for Xilinx PS GPIO controller
Bindings for the Xilinx Processor System GPIO controller, both for the
parent controller device as well as the GPIO pin bank child devices.

Signed-off-by: Immo Birnbaum <Immo.Birnbaum@weidmueller.com>
2022-03-15 08:44:46 -07:00
Immo Birnbaum 9c1af58b2f dts: xilinx: Add PS GPIO controller and banks to Zynq-7000/ZynqMP DTs
Add the parent controller device node plus the child nodes for all
GPIO pin banks managed by the GPIO controller to the device trees
of the Zynq-7000 and ZynqMP SoCs.

Device base addresses, IRQ lines, number of banks, number of pins
per bank and bank descriptions taken from the Zynq-7000 TRM (Xilinx
document ID ug585), the Zynq UltraScale+ TRM (Xilinx document ID
ug1085) and the Zynq UltraScale+ Devices Register Reference (Xilinx
document ID ug1087, web-based document).

Signed-off-by: Immo Birnbaum <Immo.Birnbaum@weidmueller.com>
2022-03-15 08:44:46 -07:00
Immo Birnbaum ca33905248 drivers: gpio: Xilinx PS MIO / EMIO GPIO driver
Driver implementation for the Xilinx Processor System MIO / EMIO GPIO
controller as contained in the Zynq-7000 and ZynqMP (UltraScale) SoCs.

The driver is split up into source and header for a parent controller
device and source and header for 1..n child GPIO pin bank devices.
The parent device driver takes care of IRQ handling, the GPIO pin bank
driver provides pin / bank access according to the API defined by the
GPIO subsystem.

More than one device for this type of GPIO controller is required as
it provides access to a number of GPIO pins well in excess of the 32
pins addressable by the current GPIO API (whereever parameters or
return values come in the form of a bit mask):

- Zynq-7000: 54 MIO GPIO pins, 64 EMIO GPIO pins in 4 banks.
- ZynqMP:    78 MIO GPIO pins, 96 EMIO GPIO pins in 6 banks.

Signed-off-by: Immo Birnbaum <Immo.Birnbaum@weidmueller.com>
2022-03-15 08:44:46 -07:00
Henrik Brix Andersen cc95910957 MAINTAINERS: remove myself from the riscv collaborator group
Remove myself from the RISC-V collaborator group due to lack of time.

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2022-03-15 11:32:47 -04:00
Hake Huang 084e6dfbd2 dts: binding: rename pinmux to gpr
rename pinmux to gpr
different from pinmux and io settings gpr will do more IO
settings.

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
2022-03-15 10:12:57 -05:00
Hake Huang 8dda841e91 board: pinctrl: board config for RT1060
enable pin control for RT1060 EVK.

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2022-03-15 10:12:57 -05:00
Hake Huang 8c5a4fc3b0 drivers: sai: add pinctrl support in mcux sai
enable i2s pinctrl

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
2022-03-15 10:12:57 -05:00
Hake Huang 40f3ab9f72 drivers: uart: add pinctrl support in mcux lpuart
enable pinctrl in lpuart driver, and clean up driver instance definition
macros

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
2022-03-15 10:12:57 -05:00
Hake Huang 3fc6353b36 drivers: pinctrl: add mcux_rt pinctrl driver
Add pinctrl driver for rt1xxx

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2022-03-15 10:12:57 -05:00
Hake Huang e4793b902d dts: imx_rt: add pinctrl and gpr for rt1xxx
add dtsi settings for rt series
dtsi use gpr to replace pinmux
nxp iomuxc has gpr which has more settings than mux and io settings
current solution is to export gpr separately and access then directly

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2022-03-15 10:12:57 -05:00
Hake Huang 6be3085e73 soc: add pinctrl header file definition for RT series
Pinctrl requires header file with Z_PINCTRL_STATE_PINS_INIT macro
defined. Add header file for mcux RT pinctrl implementation.
Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2022-03-15 10:12:57 -05:00
Hake Huang c93689db2f dts: bindings: add pinctrl node to sai and lpuart
enable pinctrl in i2s and lpuart driver bindings

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2022-03-15 10:12:57 -05:00
Hake Huang a6e8c3d3e1 dts: bindings: add pinctrl binding for nxp mcux rt1xxx
Add dts binding for rt1xxx pinctrl driver settings. A binding file is
present for the pinctrl node itself, and for the pinctrl child node that
defines all pinmux options

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2022-03-15 10:12:57 -05:00
Daniel DeGrasse 678f334aed west.yml: Update to pull in pinctrl header from NXP HAL
NXP hal will define constants for pinmux options in RT pinctrl
implementation. Update hal revision to pull in dtsi file.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2022-03-15 10:12:57 -05:00
Anas Nashif 460b37fbe1 kernel: SMP is Symmetric multiprocessing
Fix kconfig for SMP and use correct terminology for SMP.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2022-03-15 11:07:29 -04:00
Gerard Marull-Paretas 893b941938 doc: guides: dts: improve device section
- Move to 1st option DEVICE_DT_GET
- Make device_get_binding 2nd choice
- Extend details on differences between DEVICE_DT_GET/device_get_binding
- Extend the troubleshooting section.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2022-03-15 15:45:55 +01:00
Andrzej Głąbek 222d42c22a modules: hal_nordic: Improve reservation of resources for BT_CTLR
Instead of including from nrfx_glue.h a specific Zephyr Bluetooth
controller header file that defines PPI and GPIOTE resources to be
reserved for exclusive use by the controller, include a file with
only a fixed name and expect the chosen Bluetooth controller to
provide the location of this file in include paths. This way, when
a different Bluetooth controller implementation is used downstream,
a different file can be easily pointed to.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2022-03-15 14:59:35 +01:00
Anas Nashif be7a91fd54 MAINTAINERS: area updates
- Introduce formatted ouptut area
- fix BT controller paths for tests.
- fix BT mesh paths for tests.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2022-03-15 09:43:03 -04:00
Przemyslaw Bida 5c94549023 logging: fix msg2 creation in __LOG_VA
This commit fixes invoking of z_log_msg2_runtime_vcreate with wrong
param. This function requires to be called with dynamic or static
source based on CONFIG_LOG_RUNTIME_FILTERING.

Signed-off-by: Przemyslaw Bida <przemyslaw.bida@nordicsemi.no>
2022-03-15 12:20:03 +01:00
Benedikt Schmidt 09d2199589 stm32: adc: use ADC properties to configure temp and vref channels
Use the devicetree properties to determine if the dedicated temperature or
voltage reference channels should be configured for the ADC.
Fixes #43750.

Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
2022-03-15 10:50:52 +01:00
Benedikt Schmidt 0907e35bef dts: arm: stm32: introduce ADC properties for temp and vref channel
Introduce ADC properties which indicated if the ADC instances have
dedicated channels for the internal temperature sensor or voltage
reference.

Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
2022-03-15 10:50:52 +01:00
Martin Jäger 565fc4d29c doc: release-notes: mention API change for lorawan_send
The message type parameter was changed to the more explicit enum.
Existing code with unconfirmed message type has to be updated.

Signed-off-by: Martin Jäger <martin@libre.solar>
2022-03-15 10:37:36 +01:00
Martin Jäger b6a907dd89 lorawan: make unconfirmed message type explicit
The enum did not contain an entry for unconfirmed messages. Instead, it
was only mentioned in the comment that 0 is the default for
unconfirmed messages.

This commit adds LORAWAN_MSG_UNCONFIRMED to the enum and changes the
parameter in the lorawan_send function to enum lorawan_message_type.

Signed-off-by: Martin Jäger <martin@libre.solar>
2022-03-15 10:37:36 +01:00
Marin Jurjević 2a4e47a912 net: lwm2m: fix registration update event in queue mode
When queue mode is enabled, state machine will enter state
ENGINE_REGISTRATION_DONE_RX_OFF. This state needs to be
taken into account during registration update to send
correct event.

Signed-off-by: Marin Jurjević <marin.jurjevic@hotmail.com>
2022-03-15 10:06:22 +01:00
Jamie McCrae 21cd3f2d39 boards: arm: BT510: Move button1 to button0
This prevents build issues with some sample applications e.g. system_off

Signed-off-by: Jamie McCrae <jamie.mccrae@lairdconnect.com>
2022-03-15 10:06:10 +01:00
Jamie McCrae 0c91db8981 boards: arm: BT510: Disable peripherals by default in defconfig
Some non-essential peripherals peripherals including various sensors
were enabled by default in the defconfig file when they shouldn't be

Signed-off-by: Jamie McCrae <jamie.mccrae@lairdconnect.com>
2022-03-15 10:06:10 +01:00
Jamie McCrae 59f496a034 boards: arm: BT510: Switch to enhanced peripheral drivers
This switches from UART to UARTE and from TWI to TWIM

Signed-off-by: Jamie McCrae <jamie.mccrae@lairdconnect.com>
2022-03-15 10:06:10 +01:00
Jamie McCrae a7ca58b184 boards: arm: BT510: Add active low flags to GPIO
This specifies the flags for active low GPIO inputs

Signed-off-by: Jamie McCrae <jamie.mccrae@lairdconnect.com>
2022-03-15 10:06:10 +01:00
Jamie McCrae 4bf6c5d5ec boards: arm: BT510: Disable SAO pull-up on lis2dh
This reduces power consumption by disabling the internal pull up
resistor on the SAO line of the lis2dh sensor

Signed-off-by: Jamie McCrae <jamie.mccrae@lairdconnect.com>
2022-03-15 10:06:10 +01:00
Frank Terbeck 1f0b1403f5 stm32,i2c: Fix large I2C transactions
The stm32's I2C peripheral has a maximum transmission size. Larger trans-
action, that I2C itself allows, can be achieved be using the peripheral's
reload-mode.

In order to do that, st's low-lever drivers need to be informed according-
ly. The previous iteration of the code mishandled the next_msg_flags para-
meter, causing the issue to manifest itself.

This refactors the inner loop of i2c_stm32_transfer() into its own func-
tion. This passes the message parameter by value in order to be able to
mutate its state while keeping the original datum from the user intact
during the entire procedure.

Fixes #43235

Signed-off-by: Frank Terbeck <ft@bewatermyfriend.org>
2022-03-15 10:05:48 +01:00
Jordan Yates ad959bc2bb wifi: esp_at: claim net_context in rx
Claim the net_context mutext associated with a socket before claiming
the socket mutex. The receive callback claims the net_context mutex
internally, which will now always succeed immediately.

The TX path claims the net_context mutex before the socket mutex, and if
we don't use the same order, we can end up in a deadlock.

Fixes #43470.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
2022-03-15 10:05:36 +01:00
Yong Cong Sin ce3e1e7e29 net: http: Calculate body_frag_len
Calculate the body_frag_length if any part of the body is found
in the http response.

Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
2022-03-15 10:05:21 +01:00
Yong Cong Sin 49c2d8a635 net: http: Rename body_start to body_frag_start
Following #42026, the body_start pointer now points to the
start of the body fragment in the recv_buffer as long as there
is body in it, either entirely or partially.

Rename the body_start to body_frag_start to better reflect
what it represents.

Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
2022-03-15 10:05:21 +01:00
Lukasz Majewski d7cd42699b fs: littlefs: sample: Generate fname[12] strings after mount
The littlefs_mount() function sets the mount point for block devices,
so fname[12] shall be generated after calling it.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
2022-03-15 10:01:54 +01:00
Lukasz Majewski 2c8a7e7757 fs: littlefs: Extend sample program to test block devices
Up till now, the littlefs sample program was only supporting the flash
medium. However, it would be also welcome to be able to test reading and
writing data from littlefs stored on block devices - like SD card.

In this case we do use the block API, to read and write data to it.
To achieve this goal - the CONFIG_APP_LITTLEFS_STORAGE_BLK_SDMMC define
has been introduced.

One can change the disk mount point by defining board specific
CONFIG_SDMMC_VOLUME_NAME.

The test for nucleo board equipped with SD card shall be built with:
west build -p always -b nucleo_h743zi ./zephyr/samples/subsys/fs/littlefs \
 -DCONF_FILE=prj_blk.conf

Moreover, the README.rst has been extended to describe running this
test on block devices.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
2022-03-15 10:01:54 +01:00
Lukasz Majewski 7710f5ef61 fs: littlefs: sample: Move littlefs_flash_erase() to flash mount
The littlefs_flash_erase() function shall be called from flash specific
littlefs_mount function. This allows removal of the stub function
when block device support is added.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
2022-03-15 10:01:54 +01:00
Lukasz Majewski 447ebe34d9 fs: littlefs: Introduce CONFIG_APP_LITTLEFS_STORAGE_FLASH define
This KConfig define (by default defined) is necessary to extend the
littlefs test functionality to support other test scenarios - for
example running it on device with block device (i.e. SD card) backend.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
2022-03-15 10:01:54 +01:00
Lukasz Majewski 663a4bbcb8 fs: littlefs: sample: Add test with binary pattern file modification
This commit extends the littlefs test to use binary pattern file.

This file has the 0x55 and 0xAA patterns (to avoid fast wear leveling)
written alternately with special "marks" bytes on each eight position.
Those values are incremented each time the board boots. One can adjust
the size of this file with the TEST_FILE_SIZE define.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
2022-03-15 10:01:54 +01:00
Lukasz Majewski dd25b6405c fs: littlefs: sample: Move flash initialization code to its own function
The code for potential erasing the flash area has been moved to the
separate function.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
2022-03-15 10:01:54 +01:00
Lukasz Majewski 982a739bb1 fs: littlefs: sample: Move value increment test to separate function
The code responsible for incrementing the in-file value has been moved
to the separate function for better readability and reusage.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
2022-03-15 10:01:54 +01:00
Lukasz Majewski f6204e607c fs: littlefs: sample: Move listing directory code to its own function
The code for presenting content of the directory, has been moved to the
separate function to be easily reusable.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
2022-03-15 10:01:54 +01:00
Lukasz Majewski ab314c3378 fs: littlefs: sample: Replace calls to printk with LOG_PRINTK
Replace calls to printk with LOG_PRINTK to use the logging Zephyr
infrastructure. After this change it would be possible to set the
logging mode (to e.g. reduce the verbosity of output and final size
of the binary).

Signed-off-by: Lukasz Majewski <lukma@denx.de>
2022-03-15 10:01:54 +01:00
Yong Cong Sin 4bcd33bb35 tests: net: all: Add shell MQTT backend
Test the compilation of shell MQTT backend.

Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
2022-03-15 10:01:12 +01:00
Yong Cong Sin 74a0ae01bc shell: Add MQTT backend
Add MQTT backed for shell module.

Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
2022-03-15 10:01:12 +01:00
Andrzej Głąbek f66142c535 boards: arm: nrf: Add missing ram and flash sizes in a few nRF DKs
Definitions of several nRF DK boards are missing flash and ram sizes.
This commit adds those missing entries.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2022-03-15 09:59:13 +01:00
Andrzej Głąbek 6014be589e drivers: nrf_qspi_nor: Exit DPD at driver initialization
It may happen that after the flash chip was previously put into
the Deep Power Down mode, the system was reset but the flash chip
was not. Consequently, the flash chip can be in the DPD mode when
the QSPI driver is initialized. Some flash chips will just exit
the DPD mode on the first CS pulse, but some need to receive the
dedicated command to do it and they will not respond to any other
commands including those that the driver need to perform to complete
its initialization ("Read status register" and "Read JEDEC ID").
This commit adds sending of the "Release from Deep Power Down"
command right after initialization of the QSPI interface to avoid
the problem described above.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2022-03-15 09:58:46 +01:00
Daniel Leung e186ebc314 wifi: fix build error on wifi_winc1500_nm_bsp_internal.h
Previous commit 579ca90e25 to
build wifi drivers as a library changed the include path for
the WINC1500 driver, which results in the include path being
local to the library. However, the Atmel HAL requires
wifi_winc1500_nm_bsp_internal.h to in the search path. So
change the include path to be global.

Fixes #43456

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2022-03-14 22:04:54 -04:00
Juha Heiskanen 0b38be9d3a net: lwm2m: Inteagrate LwM2M new API's
Remove local path to string and string to path functionality
and use utility library API.

Signed-off-by: Juha Heiskanen <juha.heiskanen@nordicsemi.no>
2022-03-14 22:04:32 -04:00