Commit Graph

266 Commits

Author SHA1 Message Date
Dong Heng
779a29fea5 boards/Kconfig: set BOARD_ASSERT_RESET_VALUE default value to be 1
The board code should separate the reset reason, so it had better
make "BOARD_ASSERT_RESET_VALUE" not be equal to "EXIT_SUCCESS".
2021-11-16 10:44:54 -03:00
Dong Heng
92eedd93a7 risc-v/esp32c3: Fix reset triggering crash nested when crash 2021-11-16 10:44:54 -03:00
Abdelatif Guettouche
a01cb867ce esp32c3_rom.ld: Add some of the string.h functions to the linker
script.

These functions are strongly declared and thus will be used instead of
any other implementation.  Furthermore, necessary Kconfig options are
selected to avoid building those function from NuttX's C library.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-11-13 11:54:42 -03:00
Xiang Xiao
0aeb132d15 board: Run ./tools/refresh.sh --silent all
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-10 09:16:35 +01:00
Abdelatif Guettouche
044508c979 boards/esp32c3-devkit: Add a defconfig for the USB CDC Console.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-11-09 09:22:57 -03:00
Xiang Xiao
3847539f3d board: Run ./tools/refresh.sh --silent all
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-07 13:19:15 +01:00
ChenWen
440787c0c1 risc-v/esp32c3: Fix Wi-Fi & BLE coexist issue
1. Wi-Fi and BLE use common PHY functions.
  2. Fix Wi-Fi & BLE coexist adapter error.
  3. Update esp-wireless-drivers-3rdparty, provide coexist protection for connection.
2021-11-04 11:02:05 -03:00
Eero Nurkkala
8e43f39141 mpfs: cache: provide L1/L2 cache enablers
E51 may configure the L1 and L2 caches. Once configured,
no reconfiguration is possible after hardware reset is
issued.

L2 is 16-way set associative with write-back policy. The
size 2 MB, from which 1 MB is utilized with the values
provided here. That's a total of 8 ways. The rest of the
L2 is left out for the bootloader usage.

mpfs_enable_cache() first checks the bootloader usage
doesn't overlap with the cache itself, thus providing a
set of functional values.

Signed-off-by: Eero Nurkkala <eero.nurkkala@offcode.fi>
2021-11-04 11:00:55 -03:00
Jani Paalijarvi
a16a9f80e2 mpfs: i2c: Add support for adaptive I2C bus frequency
Select the closest possible frequency which is smaller
than or equal to requested in I2C msg
2021-11-02 04:10:08 -05:00
Abdelatif Guettouche
860370284e esp32c3_dma: Remove the DMA test included in the driver along with its
defconfig.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-11-01 13:49:59 -05:00
Gustavo Henrique Nihei
c9d784a238 boards/esp32c3-devkit: Port SPI Flash FS fixes from ESP32
This commit brings 3 fixes/improvements applied to the Kconfig options
for SPI Flash file system support on board bring-up:
- (925e8f9) Optionally mount SPI Flash MTD on bring-up
- (f74c6f7) Transform SPI Flash FS deps into reverse deps
- (9056cab) Select MTD_SMART if SmartFS is selected for SPI Flash MTD

Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-10-25 21:45:20 -05:00
Gustavo Henrique Nihei
18f785c7b7 risc-v/esp32c3: Removed unused definitions
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-10-25 21:45:20 -05:00
Gustavo Henrique Nihei
06bb85d8a5 risc-v/esp32c3: Rename MTD-related configs to become more intuitive
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-10-25 21:45:20 -05:00
Gustavo Henrique Nihei
211f899b62 risc-v/esp32c3: Refactor and reorganize Partition Table related configs
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-10-25 16:34:58 -03:00
Eero Nurkkala
c7cf9fd9d2 mpfs: board Make.defs: add bootloader linker option
Use the linker script used with bootloaders that start
from the eNVM.

Signed-off-by: Eero Nurkkala <eero.nurkkala@offcode.fi>
2021-10-21 22:40:26 -05:00
Eero Nurkkala
ad76b6733c mpfs: boards: add ld-envm.script
This configuration is used when flashing nuttx as a bootloader
in the eNVM region.

Signed-off-by: Eero Nurkkala <eero.nurkkala@offcode.fi>
2021-10-21 22:40:26 -05:00
Eero Nurkkala
3b330089d5 mpfs: ddr: add DDR training
This adds DDR training. The training has a small chance of failing,
and then the training is restarted.

DDR training cannot be done meaningfully while the software is
in DDR. If the system is intended to run from eNVM, like a
bootloader, the linker script should be tuned to utilize the envm
region as follows:

  envm (rx)   : ORIGIN = 0x20220100, LENGTH = 128K - 256
  l2lim (rwx) : ORIGIN = 0x08000000, LENGTH = 1024k

256 bytes are reserved for the system; The fixed block may be
installed from the 'hart-software-services' -repository:
https://github.com/polarfire-soc/hart-software-services.git

For example, the 256-byte image: hss-envm-wrapper-bm1-dummySbic.bin
may be prepended on the nuttx bootloader image in the following
manner:

 cat hss-envm-wrapper-bm1-dummySbic.bin > nuttx_bootloader.bin
 cat nuttx.bin >> nuttx_bootloader.bin
 riscv64-unknown-elf-objcopy -I binary -O ihex --change-section-lma
  *+0x20220000 nuttx_bootloader.bin flashable_image.hex

This provides an image 'flashable_image.hex' that may be flashed on
the eNVM region via Microsemi Libero tool.

Signed-off-by: Eero Nurkkala <eero.nurkkala@offcode.fi>
2021-10-21 22:40:26 -05:00
Abdelatif Guettouche
9235d6605b boards/esp32&esp32c3: Remove crypto accelerators' defconfigs.
Since the tests were removed from the drivers, there is no need for
these defconfigs anymore.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-19 18:41:57 -03:00
Abdelatif Guettouche
55e8b17974 boards/risc-v/esp32c3: Remove the flash encryption test.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-19 18:41:57 -03:00
Abdelatif Guettouche
e424241d09 arch/risc-v/esp32c3: Remove the bignum test from the driver.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-19 18:41:57 -03:00
Abdelatif Guettouche
91cb9dafaf arch/risc-v/esp32c3: Remove the RSA test from the driver.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-19 18:41:57 -03:00
Abdelatif Guettouche
652d77efd2 arch/risc-v/esp32c3: Remove the SHA test from the driver.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-19 18:41:57 -03:00
Abdelatif Guettouche
5d1c01aea7 arch/risc-v/esp32c3: Remove the AES test from the driver.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-19 18:41:57 -03:00
Matheus Castello
5c15fe6ec1 boards: k210: Add initial gpio user space support
Signed-off-by: Matheus Castello <matheus@castello.eng.br>
2021-10-17 17:29:59 +09:00
Matheus Castello
1bc3ab513d boards: risc-v: k210: Fix -march and -mabi
-march=rv64gc -mabi=lp64 does not resolve lib paths for
riscv64-unknown-elf-gcc resulting in lib not found errors.
Changing it to -march=rv64imafc -mabi=lp64f that is the default
used in Sipeed repositories.

Signed-off-by: Matheus Castello <matheus@castello.eng.br>
2021-10-14 15:50:20 +09:00
jsun
c58fddb915 Open ble controller adaptation code
N/A

Signed-off-by: jsun <jsun@bouffalolab.com>
2021-10-08 02:30:27 -07:00
Gustavo Henrique Nihei
0a1b3c1331 risc-v/esp32c3-devkit: Add BLE defconfig
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-10-05 08:45:40 -03:00
Gustavo Henrique Nihei
47e804b167 risc-v/esp32c3: Make BLE adapter code compliant to nxstyle
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-10-05 08:45:40 -03:00
Abdelatif Guettouche
ee20d0f545 esp32c3_rom.ld: Add a strong declaration to some libgcc function that
are ROM resident.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-01 10:09:04 -03:00
Gustavo Henrique Nihei
548f2b6eab boards/esp32c3-devkit: Add mcuboot_confirm defconfig
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-27 18:22:29 -07:00
Gustavo Henrique Nihei
3c63cb522c risc-v/esp32c3: Enable booting from MCUboot bootloader
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-27 18:22:29 -07:00
Alan C. Assis
f9b322567c boards/esp32c3: Remove "return ret" from bringup 2021-09-21 10:34:55 -03:00
Alan C. Assis
63a17f5cdd esp32c3-devkit: Add board profile to use LVGL on GC9A01 display 2021-09-18 20:58:30 -05:00
Janne Rosberg
e022ea1283 mpfs/icicle/configs/hwtest: enable SD card 2021-09-18 12:18:09 -03:00
Eero Nurkkala
812f504c16 mpfs: emmcsd: add Kconfig/Makefile and board files
Add necessary Kconfig, Make.defs, Makefile and board
file changes.

Signed-off-by: Eero Nurkkala <eero.nurkkala@offcode.fi>
2021-09-18 12:18:09 -03:00
Peter Bee
a7a3d8bec7 boards/esp32c3: add ESP32C3 LCD drivers
Add board driver for ST7735, ST7789 and GC9A01

Signed-off-by: Peter Bee <bijunda1@xiaomi.com>
2021-09-17 09:35:10 -03:00
Alan C. Assis
099e9fb4f7 boards: Remove -nostartfiles -nodefaultlibs from LDFLAGS 2021-09-13 08:58:25 +08:00
Janne Rosberg
d361a9ded8 boards/icicle: add hwtest config
This config enables all peripherals and some tools.
Also useful for CI build check.
2021-09-11 23:33:01 +08:00
Sara Souza
acf18bd82d risc-v/esp32-c3: refactor the Wi-Fi board logic.
This commit moves the Wi-Fi initialization to
Wi-Fi specific file and to spiflash initialization.

It also reserves one partition for Wi-Fi use and for general use,
and makes it possible to me mounted by several FS.
2021-09-09 20:14:04 +08:00
Sara Souza
11068fad1b risc-v/esp32-c3: Enable the allocation of multiple MTD SPI Flash partitions 2021-09-09 20:14:04 +08:00
Gustavo Henrique Nihei
310a2dd0e4 tools/esp32c3: Create option for merging all binaries into a single file
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-08 12:16:52 +02:00
Alin Jerpelea
9d870e1502 defconfig: allow use of BSD components
several configs are used for testing and need the BSD components

more information about license can be found here
https://www.apache.org/legal/resolved.html#category-a

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-09-02 09:00:43 -03:00
Alin Jerpelea
2ab9e7fef0 Revert "esp32: remove FS_SPIFFS from defconfigs"
This reverts commit 35a004bdd0.
2021-09-02 09:00:43 -03:00
Alin Jerpelea
35a004bdd0 esp32: remove FS_SPIFFS from defconfigs
FS_SPIFFS uses BSD license and should not be enabled by default

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-08-30 22:39:04 +08:00
Xiang Xiao
e3ab1179fa board: Enable CONFIG_LIBCXXABI when CONFIG_LIBCXX is enabled
to avoid link libsupc++.a which is provided by toolchain

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-08-28 17:13:43 -03:00
Alin Jerpelea
a43650648e risc-V: remove ble defconfigs
By default the components with BSD license should be disabled

NOTE:
the BLUETOOTH components was enabled in a non bluetooth config

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-08-27 02:56:22 +08:00
Antti Vähälummukka
6eb73ced51 arch/risc-v/src/mpfs: Add CorePWM driver
Add a driver for CorePWM block, which can be instantiated on PolarFire SOC FPGA

This supports 2 CorePWM blocks on the FPGA. One CorePWM block provides 8 PWM output signals
2021-08-20 08:56:30 -03:00
Xiang Xiao
b12f588140 Rename CONFIG_LIB_BOARDCTL to CONFIG_BOARDCTL
since boardctl isn't a libc feature

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-08-06 13:58:26 +02:00
Xiang Xiao
5025fbef8d Rename LIB_ to LIBC_ for all libc Kconfig
follow other libc component naming convention

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-08-05 19:45:24 +02:00
Xiang Xiao
007adc7736 Replace all __attribute__((section(x)) with locate_data(x)
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-07-29 21:55:21 -03:00