Abdelatif Guettouche
19a096cdfe
arch/xtensa/esp32_tim_lowerhalf.c: Use device specific locks.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-16 00:01:23 -07:00
Gustavo Henrique Nihei
ff705586bb
xtensa/esp32s2: Provide SPI Flash parameters to MCUboot build
...
Also unify bootloader config creation to reduce duplication.
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-10-15 23:55:10 -07:00
Gustavo Henrique Nihei
4d5e0f8fe1
xtensa/esp32: Provide SPI Flash parameters to MCUboot build
...
Also unify bootloader config creation to reduce duplication.
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-10-15 23:55:10 -07:00
Abdelatif Guettouche
a7d8d9dd98
esp32s2/tie.h: Run the file though detab.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-14 07:39:54 -03:00
Abdelatif Guettouche
6d246eb18f
esp32s2/tie.h: The old tie.h file was from ESP32 which doesn't apply to
...
ESP32-S2. This commit gets the correct S2 tie.h file
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-14 07:39:54 -03:00
Abdelatif Guettouche
217fd97fd3
xtensa_coproc.S: Correctly save/restore coprocessor0 state.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-14 07:39:54 -03:00
Abdelatif Guettouche
7420f245bc
xtensa_context.S: Save and restore SCOMPARE1 when necessary.
...
SCOMPARE1 is used by some atomic instructions and need to be preserved
during a context switch.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-10-14 06:32:17 -03:00
Alan C. Assis
867c6d0636
esp32: Add initial support to Bluetooth Low Energy
...
Co-authored-by: saramonteiro <saramonteirosouza44@gmail.com>
Co-authored-by: Gustavo Henrique Nihei <gustavonihei@gmail.com>
2021-10-04 15:10:37 -03:00
Abdelatif Guettouche
d22b4ec539
espxx_rng.c: Add "/" at the beginning of paths for consistency.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-30 13:50:25 -03:00
Abdelatif Guettouche
5c6a30c00b
esp32_rng.c: Remove the initialization guard. The init function is
...
called only once during startup.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-30 13:50:25 -03:00
Abdelatif Guettouche
6a262c5203
esp32_rng.c: Remove unused functions.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-30 13:50:25 -03:00
Sara Souza
8a142f474e
xtensa/esp32-s2/rttimer: Disable alarm before setting a new value and enabling it
2021-09-28 21:02:57 -03:00
Alin Jerpelea
15a37c5a5a
arch: Omni Hoverboards: update licenses to Apache
...
Gregory Nutt has submitted the SGA
Omni Hoverboards has submitted the SGA
David Sidrane has submitted the ICLA
Mateusz Szafoni has submitted the ICLA
Sebastien Lorquet has submitted the ICLA
Paul Alexander Patience has submitted the ICLA
as a result we can migrate the licenses to Apache.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-09-28 04:37:38 -07:00
Gustavo Henrique Nihei
a5f9e29d78
xtensa/esp32s2: Enable support for "make bootloader" target
...
This enables the provisioning of the bootloader binaries through the
build system.
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-27 18:21:53 -07:00
Gustavo Henrique Nihei
800678ca78
xtensa/esp32s2: Enable booting from MCUboot bootloader
...
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-27 18:21:53 -07:00
Abdelatif Guettouche
5336704c77
esp32_start.c: Initialize the SPI RAM before enabling its cache.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-27 05:13:51 -07:00
Gustavo Henrique Nihei
c23986ec63
xtensa/esp32: Select ARCH_HAVE_BOOTLOADER for ESP32 chips
...
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-24 10:48:19 -07:00
Gustavo Henrique Nihei
4ac3044cc3
xtensa/esp32: Enable build system to download or build bins from source
...
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-23 20:52:25 -07:00
Abdelatif Guettouche
f2f2040c44
esp32_spiram/psram/himem: Add and fix the files' sections.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-23 02:49:11 -07:00
Abdelatif Guettouche
3d8a6fb676
esp32_spiram.c: Remove esp_himem_reserved_area_size from esp32_spiram.c
...
file. This function is already defined in esp_himem and is used only
when that file is built. We don't need another weak function.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-23 02:49:11 -07:00
Abdelatif Guettouche
2834d2a46f
esp32_spiflash.c/esp32_spiram.c: Remove some unused macros/functions/variables.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-23 02:49:11 -07:00
Sara Souza
962059f843
xtensa/esp32-s2: Adds oneshot device driver support
2021-09-22 22:53:54 -03:00
Sara Souza
fba6fa2dc1
xtensa/esp32-s2: Adds support to rt_timer and systimer to ESP32-S2.
2021-09-22 17:18:24 -03:00
Sara Souza
2cd4f4af79
xtensa/esp32-s2: Adds freerun timer wrapper
2021-09-22 09:38:10 -03:00
Gustavo Henrique Nihei
eca1f86294
arch/xtensa: Remove CODE qualifier for Xtensa-specific files
...
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-22 08:16:01 -03:00
Gustavo Henrique Nihei
e13dd7dab9
arch/xtensa: Remove FAR qualifier for Xtensa-specific files
...
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-22 08:16:01 -03:00
Gustavo Henrique Nihei
58f87ef443
xtensa/esp32: Fix wrong position for ++ operator on I2C driver
...
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-22 08:16:01 -03:00
Abdelatif Guettouche
9f4d7e4767
xtensa_dumpstate.c: Fix the name of the TCB variable when dumping the
...
backtrace.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-21 09:22:28 -03:00
Abdelatif Guettouche
15b68b9abb
esp32_spiflash.c: Correctly disable APP's CPU cache.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-17 17:43:45 -03:00
Gustavo Henrique Nihei
b33ccd01cf
xtensa/esp32: Make the semaphore timeout on I2C configurable
...
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-09-16 14:07:26 -03:00
zhuyanlin
7947e50f06
xtensa:backtrace: flush to stack when in interrupt
...
The registers may be in window during interrupt.
Flush window stack to stack first.
And fix warning in build.
Signed-off-by: zhuyanlin <zhuyanlin1@xiaomi.com>
2021-09-16 10:53:35 -05:00
zhuyanlin
cdb441cc3f
arch:xtensa:dumpstate: use sched_dumpstack
...
Use sched_dumpstack instead. The backtrace infomation like
xtensa_user_panic: User Exception: EXCCAUSE=0009 task: hello
xtensa_registerdump: PC: 202b32b8 PS: 00060030
xtensa_registerdump: A0: a02acb87 A1: 20998d10 A2: ffffaaaa A3: 12345678
xtensa_registerdump: A4: a02ba26c A5: 209949c0 A6: 20990994 A7: 00000258
xtensa_registerdump: A8: a02b32af A9: 20998cb0 A10: 0000000f A11: 209949a0
xtensa_registerdump: A12: a02be95c A13: 20994980 A14: 00000003 A15: 209949d0
xtensa_registerdump: SAR: 00000000 CAUSE: 00000009 VADDR: ffffaaaa
xtensa_registerdump: LBEG: 00000000 LEND: 00000000 LCNT: 00000000
xtensa_registerdump: TMP0: 202b1512 TMP1: 20998af0
sched_dumpstack: [BackTrace| 3|0]: 0x202acbae 0x202b232e 0x202b1912 0x202b19f5 0x202b24f1 0x202b152f 0x40023 0x202b32b0
sched_dumpstack: [BackTrace| 3|1]: 0x202acb87 0x202a86a4
Signed-off-by: zhuyanlin <zhuyanlin1@xiaomi.com>
2021-09-16 10:32:38 +08:00
zhuyanlin
6e0f84dc88
arch:xtensa: add up_backtrace support
...
Up_backtrace can be backtrace from task or interrupt.
Signed-off-by: zhuyanlin <zhuyanlin1@xiaomi.com>
2021-09-16 10:32:38 +08:00
zhuyanlin
3acdbef60d
xtensa:arch: force up_getsp to inline
...
Up_getsp may be not inline in gcc, thus get the sp
is up_getsp function's sp, not the caller function.
Signed-off-by: zhuyanlin <zhuyanlin1@xiaomi.com>
2021-09-16 10:32:38 +08:00
zhuyanlin
583dce0b98
arch:xtensa: remove WSBITS/WBBITS to core.h
...
Remove WSBITS/WBBITS macro to core.h as may be used by
arch common code.
Signed-off-by: zhuyanlin <zhuyanlin1@xiaomi.com>
2021-09-16 10:32:38 +08:00
Sara Souza
83a9c2b24b
xtensa/irq.h: Fixes the routine that clears the processor interrupt
2021-09-13 17:01:49 -03:00
zhuyanlin
8e6fbe700e
xtensa:dcache_clean: use DCACHE_LINZESIZE instead of DCACHE_SIZE
...
Clean_dcache use DCACHE_LINZESIZE instead of DCACHE_SIZE in addr loop
Signed-off-by: zhuyanlin <zhuyanlin1@xiaomi.com>
2021-09-13 14:38:57 +08:00
Abdelatif Guettouche
4ef859924b
esp32_serial.c: Release the spinlock before calling uart_xmitchars, this
...
functions will call esp32_txint again which leads to deadlock since
esp32_txint has already locked the spinlock.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-09 19:35:17 +09:00
Abdelatif Guettouche
b5bb1fb8a3
esp32_serial.c: Replace critical section by a device specific spin lock.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-09 19:35:17 +09:00
Abdelatif Guettouche
f47d28c108
esp32_serial.c: Don't fake an interrupt when interrupts are not
...
suppressed.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-09-08 09:27:08 -03:00
zhuyanlin
26b4bb3075
xtensa:cache: fix typo error
...
use addr instead of add
2021-09-08 11:19:02 +02:00
zhuyanlin
7b5c39a9d3
arch:xtensa: add xtensa_cache code support
...
Add xtensa_cache code support
2021-09-07 13:33:31 +08:00
zhuyanlin
d6fe0f18f5
arch:xtensa: add XTENSA_CACHE config support
...
Add support for XTENSA_HAVE_ICACHE & XTENSA_HAVE_DACHE
2021-09-07 13:33:31 +08:00
Sara Souza
26397c6695
xtensa/esp32: Wi-Fi board logic refactoring.
...
This commit removes the initialization of the Wi-Fi partition
from the Wi-Fi board logic and moves it to the SPI Flash board code.
It creates 2 different partition (one for Wi-Fi and one for general
use).
It also allows these partitions to be mounted over several FSs.
2021-09-04 14:30:02 +08:00
zhuyanlin
fd9ce0137e
arch:xtensa: add xtensa mpu support
...
Add support for Xtensa Memory Protect Unit.
Change-Id: I27e2f05daae24429ef7513d843b4f217daeefa0d
2021-09-02 09:17:26 -03:00
Sara Souza
8081228556
xtensa/esp32-s2: Adds support to the timer driver
...
Only one more support for ESP32-S2 chip.
2021-09-01 14:10:01 -03:00
Xiang Xiao
b0c782255c
libxx: Change CXX_LIBSUPCXX to LIBSUPCXX
...
align with other Kconfig(e.g. LIBCXXABI, LIBCXX, UCLIBCXX)
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-08-28 17:14:48 -03:00
zhuyanlin
9ea7676731
arch:xtensa: rename XCHAL_INT_NLEVELS to XCHAL_NUM_INTLEVELS
...
The name used in Tensilica support file core-isa.h for all vendors is
`XCHAL_NUM_INTLEVELS`.
Use a new name may be confused by newer porting xtensa arch.
Change-Id: Ie108d3fdfcc02c81f0eacfca852a1cfc9eea17de
2021-08-28 21:51:45 +02:00
Abdelatif Guettouche
1385ea7673
arch/esp32: Properly handle GPIO interrupt in SMP.
...
The PRO CPU and APP CPU have different peripherals for GPIO interrupts.
Each CPU needs to allocate an interrupt and attach it to its GPIO
peripheral.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-08-27 13:24:00 +09:00
Kapil Gupta
ec99e11f5e
esp32/softap: Enable the WPA2 by default to ask user password
...
Signed-off-by: Kapil Gupta <kapil.gupta@espressif.com>
Co-author: Alan Carvalho de Assis <alan.carvalho@espressif.com>
2021-08-26 13:26:57 +08:00