Commit Graph

972 Commits (16dacb73c0052fb7ce70792aa233948a35c33a35)

Author SHA1 Message Date
cyliangtw 89077b1d8b fulfill astyle 2020-04-07 18:32:36 +08:00
cyliangtw fd7b160fd1 esp8266 support baud-rate switch 2020-04-07 17:27:57 +08:00
Kimmo Vaisanen a1a98ab527 Lora: Move drivers to own COMPONENT -directories
To enable building only when driver is enabled with components_add -setting
in json configuration.
2020-04-06 11:47:42 +03:00
Kimmo Vaisanen a16a35246b Lora: Add driver implementation inside DEVICE_SPI flag
These drivers uses SPI to communicate with radio so SPI must be present
when compiling these.
2020-04-06 08:26:29 +03:00
Arto Kinnunen 64d879b540 Update Atmel 802.15.4 RF driver
Update to version v3.1.0.
2020-04-03 16:02:05 +03:00
Arto Kinnunen 78abc43c32 Update S2LP 802.15.4 RF driver
Update driver to version 1.0.2
2020-04-03 16:01:08 +03:00
Martin Kojtal 5539d65017
Merge pull request #12638 from tymoteuszblochmobica/testall
Enable storage tests to all targets
2020-04-03 09:00:18 +02:00
Tymoteusz Bloch 2ca832c673 Enable storage tests to all targets 2020-04-01 12:04:36 +02:00
Kimmo Vaisanen 6ca66e23df Lora: Fix line endings 2020-04-01 12:50:24 +03:00
Kimmo Vaisanen 9bb7e9a605 Add 'components/lora/' from commit '0f7efe3ad17c6c619843b8391b3035149f358260'
git-subtree-dir: components/lora
git-subtree-mainline: a6ef9db8dc
git-subtree-split: 0f7efe3ad1
2020-04-01 12:50:10 +03:00
Martin Kojtal 7a0a168ded
Merge pull request #12681 from mtomczykmobica/IOTSTOR-990
SPIFBlockDevice doesn't play nice on shared SPI bus #11732.
2020-04-01 08:54:01 +02:00
Michal Paszta 195fdc17d3 ESP8266: initialize ESP before setting DHCP or static IP address 2020-03-31 21:56:32 +03:00
Michal Paszta 9f347c56c4 ESP8266: static address and dhcp added 2020-03-31 08:26:50 +03:00
Marcin Tomczyk 699a68968c [IOTSTOR-990] SPIFBlockDevice doesn't play nice on shared SPI bus. Back to use select and deselect, use correct spi constructor 2020-03-30 06:40:39 -07:00
Martin Kojtal 451bd061bd
Merge pull request #12670 from michalpasztamobica/esp8266_netmask_gateway
ESP8266: Fix typo: gateway to netmask
2020-03-30 11:36:02 +02:00
Hugues Kamba 0d626e04b9 TFM: Remove ARM Compiler 5 considerations
ARM Compiler 5 is no longer actively supported and was superseded in
Mbed OS by ARM Compiler 6.
2020-03-26 11:32:47 +00:00
Michal Paszta cf2ba1d37d ESP8266: SNTP config only runs when enabled 2020-03-25 10:47:26 +02:00
Marcin Tomczyk 116a8a75b6 [IOTSTOR-990] SPIFBlockDevice doesn't play nice on shared SPI bus. Fix by use valid constructor SPI 2020-03-24 01:22:59 -07:00
Michal Paszta 8175e32717 Add get_time function for ESP8266
get_time function allows access to SNTP functionalities of ESP8266
2020-03-23 19:20:48 +02:00
Michal Paszta 2b9210cd33 ESP8266: Fix typo: gateway to netmask 2020-03-23 14:25:15 +02:00
Anna Bridge 5aab4c4f11
Merge pull request #12524 from VeijoPesonen/sfdp_split_4
Bugfix: Concurrent SFDP header address init fixed
2020-03-06 13:57:07 +00:00
Martin Kojtal 22f3bc4ae7
Merge pull request #12436 from mprse/fpga_remove_gpio_pinmaps
Remove GPIO pin-maps used for FPGA testing
2020-03-04 13:24:05 +00:00
Veijo Pesonen 2605ce629d QSPIFBlockDevice: removes dead code 2020-03-02 11:02:09 +02:00
Veijo Pesonen 7c692f5196 SPIFBlockDevice: Refactor vendor specific workarounds
To follow the same convention as with QSPIFBlockDevice there was need to
create a separate function for handling vendor specific workarounds.
2020-03-02 11:14:01 +02:00
Veijo Pesonen 98dbebb3ed SFDP: Refactor Sector Map Parameter Table parsing
Doxygen documentation was updated.

Code reorganized to make it more readable.

Moves SFDP specific bits out from Q/SPIFBlockDevices.
2020-03-02 11:07:03 +02:00
Veijo Pesonen 4f9fcf8df8 Bugfix: Concurrent SFDP header address init fixed
After switching from local variables to shared info structure JEDEC
Basic Flash Parameter Table and Sector Map Parameter Table addresses
and sizes must be protected by a mutex. Theoretically multiple calls
to Q/SPIFBlockDevice might occur.
2020-03-02 11:05:15 +02:00
Veijo Pesonen c84deff782 SFDP: consolidates check for addressability
Takes implementations found from SPIFBlockDevice and QSPIFBlockDevice
and makes those as part of the SFDP module.
2020-03-02 11:04:05 +02:00
Veijo Pesonen 2ce3bed910 SFDP: consolidates device density detection
Combines implementations found from SPIFBlockDevice and QSPIFBlockDevice
and makes it as part of the SFDP module.
2020-03-02 11:02:09 +02:00
Martin Kojtal 1f36b1cf09
Merge pull request #12450 from VeijoPesonen/sfdp_split_bptbl_2
SFDP: consolidation of SFDP parsing [3/n]
2020-02-27 17:08:14 +00:00
Martin Kojtal fc5f3259de
Merge pull request #12458 from GaborAbonyi/add_musca_b1_platform
Add Musca B1 target
2020-02-27 13:53:58 +00:00
Stephan Brunner f67b8aa0eb
Fix initialization order for I2CEEBlockDevice 2020-02-26 18:18:22 +01:00
Veijo Pesonen ca704a4b3d SFDP: consolidates erase region search
Merges erase region search found from SPIFBlockDevice and
QSPIFBlockDevice. Moves the implementation within the SFDP
component
2020-02-26 12:41:34 +02:00
Martin Kojtal 732692cd77
Merge pull request #12475 from VeijoPesonen/purge_rspif
Proposal to remove SPIFReducedBlockDevice
2020-02-25 15:23:23 +00:00
Veijo Pesonen ca52ca9277 Q/SPIFBlockDevice: removes dead code 2020-02-25 16:12:18 +02:00
Martin Kojtal 1c12083949
Merge pull request #12426 from VeijoPesonen/sfdp_split_bptbl
SFDP: consolidation of SFDP parsing [2/n]
2020-02-25 13:57:23 +00:00
Martin Kojtal 18ad99a883
Merge pull request #12481 from artokin/nanostack_release_for_mbed_os_6
Nanostack release for Mbed OS 6
2020-02-25 10:08:59 +00:00
Veijo Pesonen b575df072f Removes RSPIF block device driver
The driver is not needed by the bootloader anymore.
2020-02-24 16:01:14 +02:00
Przemyslaw Stekiel f6acb51893 Update find_ports() FPGA testing utility function to loop through the form factor pins instead the pin-map
This change is required to fully remove gpio pin-maps which were already added for FPGA testing.
One use case of adding gpio pinmap was that pin-map must have the specific format - must be ended with NC pin. Functions that deal with pin-maps loops through the pin-map until NC pin is encountered.
Also, our FPGA testing utility function to find pins for testing does that. When gpio pinmaps are fully removed we will have one generic gpio pinmap which provides Arduino pins: D0, D1, D2, etc. (only Arduino form factor is supported at the moment).
In some cases may happen that an arduino pin is not connected (e.g. KW24D: D4 == NC). As a result we will have NC not only at the end, but also in the middle of the gpio pin-map.
In this case find_ports() function will finish processing pin-map to early (when first NC is encountered).
The proposition is to change the find_ports() FPGA testing utility function to loop through form factor pins (instead pin-map) and then check if the pin is not NC and is available on the specific pin-map before using it for testing.
2020-02-24 14:44:33 +01:00
Anna Bridge 8c17270306
Merge pull request #12480 from 0xc0170/fix_spdx
Fix SPDX identifiers and licenses (excluding features and targets)
2020-02-21 16:34:30 +00:00
Gabor Abonyi a5b15a75be Add ioctl platform service
Define weak functions that the platforms can overwrite

Change-Id: I3d6f3e59a9c5b88456875a495fa6decc1337683e
Signed-off-by: Devaraj Ranganna <devaraj.ranganna@arm.com>
Signed-off-by: Gabor Abonyi <gabor.abonyi@arm.com>
2020-02-21 14:31:42 +01:00
Martin Kojtal 8f1bf967d3
Merge pull request #11942 from michalpasztamobica/remove_deprecated_apis
IPCore String-based API removal
2020-02-21 12:14:06 +00:00
Martin Kojtal a18259abb9
Merge pull request #12446 from boomer41/i2cee-add-eight-bit-address
Add Eight-Bit-Addressing mode to I2CEEBlockDevice.
2020-02-21 12:12:16 +00:00
Martin Kojtal c0ed178830 component storage: fix SPDX identifiers 2020-02-21 07:01:09 +00:00
Martin Kojtal c43f808f3d component psa: fix SPDX identifiers 2020-02-21 07:01:08 +00:00
Martin Kojtal 01e273ee04 component mcr20: fix SPDX identifiers 2020-02-21 07:01:07 +00:00
Martin Kojtal b9e00de2d9 psa: fix licenses + SPDX 2020-02-21 07:01:05 +00:00
Martin Kojtal ab76e0a59e component storage: fix SPDX identifiers 2020-02-21 07:01:04 +00:00
Martin Kojtal 7789ecae16 component wifi: fix SPDX identifier 2020-02-21 07:01:03 +00:00
Arto Kinnunen a5d85bd927 RF802.11.4 S2LP driver sync with dev repository
Sync with version v1.0.1 in development repository.
2020-02-20 17:11:06 +02:00
Veijo Pesonen d3b65d5e2b QSPIFBlockDevice: refactoring _sfdp_parse_basic_param_table 2020-02-20 09:46:40 +02:00
Veijo Pesonen 6a60574cf5 SFDP: consolidates sfdp_detect_erase_types_inst_and_size 2020-02-20 09:46:40 +02:00
Veijo Pesonen 2da963b8de Q/SPIFBlockDevice: unifies _sfdp_detect_erase_types_inst_and_size functions 2020-02-20 09:46:40 +02:00
Veijo Pesonen 7d1886ecae SFDP: consolidation of sfdp_detect_page_size 2020-02-20 09:46:40 +02:00
Veijo Pesonen 8a076d4b1f SPIFBlockDevice: refactoring usage of SFDP data 2020-02-20 09:46:40 +02:00
Veijo Pesonen 6d77d0d1f9 SPIFBlockDevice: Consolidates internal SFDP header information 2020-02-20 09:46:40 +02:00
Veijo Pesonen fe49c9ce16 Q/SPIF: Abstracts SFDP table reading functionality from device 2020-02-20 09:46:40 +02:00
Stephan Brunner 440fa4985b
Remove paging and sync from I2CEEBlockDevice::read(), as it is not needed 2020-02-19 18:23:46 +01:00
Martin Kojtal 829a3cded3
Merge pull request #12318 from VeijoPesonen/sfdp_split_smptbl
SFDP: Move Sector Map Parameter Table parsing under SFDP module
2020-02-19 15:49:40 +00:00
Martin Kojtal 69a0542ade
Merge pull request #12453 from jeromecoutant/PR_TRACEGROUP
STM32 TRACE_GROUP update
2020-02-19 14:33:17 +00:00
Martin Kojtal 4ce25266fa
Merge pull request #12427 from DavidLin1577/patch-1
Minor optimisation to  mcr20a-rf-driver code
2020-02-19 12:54:41 +00:00
Stephan Brunner 4d0c3463a0
Fix Code style and reorder class members to get besser packing 2020-02-19 12:49:28 +01:00
Stephan Brunner 3741440b77
Fix typo and clarify documentation 2020-02-19 11:58:07 +01:00
Stephan Brunner 532f3786a0
Remove overcomplicated code from I2CEEBlockDevice 2020-02-18 19:13:50 +01:00
David Lin f1c479651f
Minor optimisation to mcr20a-rf-driver code
This is a minor optimisation to the mcr20a-rf-driver code:

Note that function parameter is pointer. The code is more readable when 'NULL' instead of using '0'.
2020-02-18 20:00:00 +08:00
Stephan Brunner 7c589ae172
Fix astyle 2020-02-17 23:04:23 +01:00
Stephan Brunner 76a177fafa
Use pageSize-constant instead of hardcoded value 2020-02-17 21:25:47 +01:00
Stephan Brunner 267d8cc223
Preserve original size as it is modified inside the handler function.
The value is const reference bound inside do_paged and must not be
modified, it is used inside the paging loop.
2020-02-17 20:57:58 +01:00
Stephan Brunner e850984715
Correctly check return codes from bytewise write function of I2C. 2020-02-17 20:50:49 +01:00
Stephan Brunner 52aed22978 Refactor paged_handler to directly give the paged device address. 2020-02-17 20:49:43 +01:00
Stephan Brunner 8d1978e05c
I2CEEBlockDevice: Add paging to eight bit mode 2020-02-17 20:22:18 +01:00
jeromecoutant f000b87911 STM32 TRACE_GROUP update
Only 4 characters is allowed
2020-02-17 16:38:42 +01:00
Stephan Brunner cd34860bd0 Add Eight-Bit-Adressing mode to I2CEEBlockDevice.
When dealing with EEPROMs without a 16 bit adressing, the current
implementation does not work, as it writes a 16 bit address to the chip.
This may cause undefined behaviour.
This change adds a new constructor argument to enable this new eight-bit
mode. It defaults to false to not break existing code.
This constructor argument should actually never be necessary to manually
set, except when dealing with cheap devices.
2020-02-16 12:54:51 +01:00
jeromecoutant c9aead485b STMOD_CELLULAR: add DISCO_L562_QE support 2020-02-14 17:49:41 +01:00
David Lin 57d3a14e0f
Minor optimisation to mcr20a-rf-driver code
This is a minor optimisation to the mcr20a-rf-driver code:
1. The function parameter is 'uint8_t *byteArray',  (byteArray == NULL) instead of using (byteArray == 0). The code is more readable.
2020-02-13 22:35:57 +08:00
Martin Kojtal bde0f5660b
Merge pull request #12392 from GaborAbonyi/psa_crypto_fix
Fix psa_key_management_operations
2020-02-12 13:11:27 +00:00
Martin Kojtal d3078a39b1
Merge pull request #12379 from mprse/STDIO_UART_restricted_all
Add STDIO UART as restricted for FPGA testing for all targets and support for restricting GPIO
2020-02-11 10:20:25 +00:00
Martin Kojtal 8c51f4f163
Merge pull request #12395 from boomer41/fix-i2ceepromblockdevice
Fix I2CEEBlockdevice
2020-02-10 14:28:11 +00:00
Martin Kojtal deb4995dae
Merge pull request #12150 from Patater/update-tls-crypto-20191220
Update Mbed TLS and Mbed Crypto to latest as of 2019-12-20
2020-02-10 13:04:12 +00:00
Stephan Brunner d7f3fcc3d3
Add error check for _sync() in I2CEEBlockDevice::read 2020-02-10 10:31:41 +01:00
Przemyslaw Stekiel 0d9a54f92e Provide pinmap_uart_restricted_peripherals() function under DEVICE_SERIAL 2020-02-10 08:17:55 +01:00
Stephan Brunner 97c00f1a22 Fix I2CEEBlockDevice read()
When reading a data block, the returned error codes from the I2C subsystem
are different from normal single byte operations. We have to verify that
the read-function for multiple bytes does return zero, because it
returns "readBytes != expectedLength".

Additionally, sync before trying to read from the eeprom as slow devices
may not yet be ready to return data, especially with low-priced ones
used with fast controllers.
2020-02-07 22:57:04 +01:00
Gabor Abonyi c94b3e41ee Fix psa_key_management_operations
At these locations, psa_key_attribute variables are used without
initialisation. The function getting it (psa_get_key_attributes),
is freeing attributes->domain_parameters, which can contain random
address from the stack.

Signed-off-by: Gabor Abonyi <gabor.abonyi@arm.com>
2020-02-07 16:23:20 +01:00
Martin Kojtal d847f9f164
Merge pull request #12305 from kivaisan/remove_multi_athandler_support_v2
Cellular: Remove support for multiple ATHandlers
2020-02-07 11:00:41 +00:00
Przemyslaw Stekiel 3c0982d939 Add pinmap_gpio_restricted_pins() to provide list of restricted GPIO pins
This is a special case since targets do not provide by default GPIO pin-maps.
This extension is required for FPGA GPIO tests - if some pins have limitations (e.g. fixed pull-up) we need to skip these pins while testing.
To do that we were adding a dummy pin-map with commented out pins that can't be tested because of the limitations.
This solution is redundant and the proposition is to provide a list of restricted gpio pins if required (by default weak implementation is provided with an empty list).

This mechanism will be backward compatible, so the old method with dummy gpio pinmap will also work. The switch from dummy pin-maps to pinmap_gpio_restricted_pins() will be performed in separate commits/PRs.
2020-02-07 10:45:02 +01:00
Przemyslaw Stekiel 54f4777e64 Add STDIO UART as restricted for FPGA testing for all targets
Substantiation for this is that the STDIO UART peripheral is used by Mbed, so it should never be tested.

Also solve the potential problem with accidenty skipped peripherals in FPGA testing. Currently, we have a one `pinmap_restricted_peripherals()` function for all interfaces (UART, I2C, SPI, etc.).
The problem can be encountered if different interfaces have the same peripheral ids (e.g. `UART_0` = 0, `SPI_0` = 0). In this case, if `UART_0` is on the restricted list, then SPI tests will be also skipped for `SPI_0`.
The good news is that usually, the peripheral ids are the base addresses of the peripheral's register set, but we can't rely on this. It is also good that `pinmap_restricted_peripherals()` at this moment is only required for STDIO UART (Nuvoton and STM).

To solve this issue we will change name of `pinmap_restricted_peripherals()` to `pinmap_uart_restricted_peripherals()`, make STDIO UART restricted by default for all targets and update FPGA test utilily functions to use `pinmap_uart_restricted_peripherals()` to skip only uart peripherals.
In the future if needed we can consider to add support to restrict peripherals of other interfaces(SPI, I2C, etc).
2020-02-07 10:45:02 +01:00
Veijo Pesonen ba71b09902 astyle fixes 2020-02-07 09:52:12 +02:00
Veijo Pesonen 4f4ef6069e SFDP: Sector Map Parameter Table naming improvements 2020-02-07 09:52:12 +02:00
Veijo Pesonen f51600c089 SPIFBlockDevice: drops unnecessary wrapper function 2020-02-07 09:52:12 +02:00
Veijo Pesonen 57722666a1 SPIFBlockDevice: Consolidates SFDP info data
This far all SFDP Sector Map Table related data has been found in small
pieces inside SPIFBlockDevice. Purpose was to consolidate the data
under one SFDP structure where all the information gathered from
SFDP tables is stored.

More generic version of a function used for parsing a Sector Map Table
was taken into use to avoid duplicate code. The implementation taken
into use is the one which got split from QSPIFBlockDevice and resides
now under the SFDP module.
2020-02-07 09:52:11 +02:00
Veijo Pesonen 83c0fdf19f QSPIFBlockDevice: Sector Map Table parsing moved under SFDP 2020-02-07 09:52:11 +02:00
Veijo Pesonen 7518a35da3 SFDP: data structures got refactored 2020-02-07 09:52:11 +02:00
Veijo Pesonen 6108f384fb QSPIFBlockDevice: Consolidates SFDP info data
This far all SFDP Sector Map Table related data has been found in small
pieces inside QSPIFBlockDevice. Purpose was to consolidate the data
under one SFDP structure where all the information gathered from
SFDP tables is stored.

Parsing a Sector Map Table was made more generic so that later it can be
moved under SFDP module. Once that is done it can be shared with
SPIFBlockDevice to avoid code duplication.
2020-02-07 09:52:11 +02:00
Veijo Pesonen cba5bfc790 QSPIFBlockDevice: Reads Sector Map Table by using a SFDP Reader cb 2020-02-07 09:52:11 +02:00
Veijo Pesonen 4e1fb07633 SFDP: reorganizes internal info structure 2020-02-07 09:52:11 +02:00
Veijo Pesonen 6a6904043c QSPIFBlockDevice: drops unnecessary wrapper function 2020-02-07 09:52:11 +02:00
Michal Paszta 458957d399 IPCore deprecated string-based API removal
String-based functions should be replaced with an explicit DNS hostname resolution and a SocketAddress-based API.
2020-02-06 11:27:49 +02:00
Martin Kojtal 952799ccc8
Merge pull request #12270 from VeijoPesonen/bugfix_sfdp_parse_sfdp_headers
BUGFIX: SFDP Sector Map Table Parameter ID LSB is 0x81
2020-02-06 08:48:16 +00:00
Martin Kojtal acece11e7a
Merge pull request #12320 from mtomczykmobica/ONME-3433
ONME-3433 ESP8266 driver support for UDP get - modified ESP8266 drive…
2020-02-06 08:10:00 +00:00
Martin Kojtal 32675cc6ac
Merge pull request #11874 from fkjagodzinski/armc6_build-enable_lto_for_release
ARMC6: Add a build profile extension with the link-time optimizer enabled
2020-02-05 14:42:16 +00:00
Martin Kojtal b33573ed27
Merge pull request #12317 from NXPmicro/MXRT_FlashSupport
MXRT1050 Flash support
2020-02-04 15:25:22 +00:00