Ivan Grokhotkov [Wed, 14 Sep 2016 17:59:42 +0000 (01:59 +0800)]
components/esp32: clean up cpu_start
Move CPU region protection setup into soc/cpu.h
change tabs to spaces
remove unused extern declarations
use RTC_WDTCONFIG0 instead of numeric address (still need to fix BB reg)
Ivan Grokhotkov [Wed, 14 Sep 2016 16:53:33 +0000 (00:53 +0800)]
components/log: add implementation, update a few components to use it
This also removes logging implementation from bootloader and replaces it
with the one provided by the log component. Some occurrences of printf
and ets_printf have been changed to ESP_LOGx APIs.
Only modify headers in soc/ .
Pass compiling under esp-idf-tests/merge_soc_tmp/merge_for_soc_headers branch.(only change some names of register and INUM).
Ivan Grokhotkov [Wed, 14 Sep 2016 04:19:43 +0000 (12:19 +0800)]
Merge branch master into feature/logging
* branch master: (51 commits)
fix typos
callback: add a void* pointer with each callback
header: callbacks use "void *" as arguments
header: format and fix typos
add wifi api comments
add wifi api comments
components/spi_flash: call SPIUnlock only once
components/spi_flash: improve comments and readability
esp32 cpu_start: Include rom/uart.h, remove inline ROM function declarations
bootloader: Add bootloader Kconfig
Fix bug where nesting vTaskEnterCritical calls would not re-enable interrupts after vTaskExitCritical sections.
installed gitlab key in global before_script, don't need to overwrite in template before_script
ci: Use github repo for wifi libraries on master branch, gitlab repo otherwise
components/esp32,spi_flash: update some comments
components/esp32: remove dependency of WIFI_ENABLED on FREERTOS_UNICORE
esp32/lib: Bump WiFi revision
update ci: build ssc with idf submodule wifi lib
components/esp32: add inter-processor call API and implement spi_flash through it
add MACRO to get flash pad number from efuse value
add comments to register read/write operations
...
Merge branch 'bugfix/add_tx_flowcontrol' into 'master'
lwip: add socket tx flow control
This fix is used to solve wifi q full issue:
1. When wifi tx q is full, set tx_enable to false
2. When wifi tx q decrease 1/2 max length, set tx_enable to true again
3. esp_wifi_tx_enable return whether tx_enable is true
4. If esp_wifi_tx_enable return false, socket will be blocked
Ivan Grokhotkov [Tue, 13 Sep 2016 10:14:22 +0000 (18:14 +0800)]
Merge branch 'bugfix/spi_flash_unlock_once' into 'master'
components/spi_flash: call SPIUnlock once
This fixes the performance impact for spi_flash_write and spi_flash_erase.
With this change, NVS init in single core mode takes about 50ms (compared to >2seconds before that).
For dual core mode, we still spend on average 2ms for each spi_flash_ operation due to synchronization between CPUs, so NVS startup time is about 2 seconds in dual core mode.
Ivan Grokhotkov [Tue, 13 Sep 2016 07:16:36 +0000 (15:16 +0800)]
components/spi_flash: call SPIUnlock only once
This fixes the performance impact for spi_flash_write and spi_flash_erase.
With this change, NVS init in single core mode takes about 50ms (compared to >2seconds before that).
Ivan Grokhotkov [Tue, 13 Sep 2016 05:58:54 +0000 (13:58 +0800)]
Merge branch 'feature/dualcore_spi_flash_api' into 'master'
Dual core compatible spi flash APIs
Implementation of spi flash APIs which work in dual core mode.
This also includes other changes:
- fixes to FreeRTOS tasks.c made by Jeroen and me — these were originally made to fix issues with high priority tasks seen in WiFi stack, but were required to get stuff in ipc.c working as well
- initial base idea with two high-priority tasks was separated into a separate API — esp_ipc.h. That API allows one to run a function on the other CPU from a high-priority task. Because we don't have preemption across CPUs, this is currently not very fast: it requires on average half a tick until the second CPU switches to the high priority task. Currently that API can be either blocking, or non-blocking with queue length of 1. I haven't yet found a use case for arbitrary sized queue of IPC requests. Anyone who needs that can trivially add that later by replacing a binary semaphore with a generic queue.
With these changes i can run application with WiFi stack and NVS on both cores.
Merge branch 'feature/add_rom_comments' into 'master'
header files: modify rom code header files and soc header files
1. timer reg file for both time group 0 and time group 1, not only timer group 0
2. fix bug that io mux header file mismatch with chip
3. fix bug that some BASE address not correct
4. add some static function to eagle.fpga32.rom.addr.v7.ld
5. add interrupts usage table
6. add some comments for rom code functions
jack [Wed, 31 Aug 2016 13:53:23 +0000 (21:53 +0800)]
header files: modify rom code and soc header files
1. timer reg file for both time group 0 and time group 1, not only timer group 0
2. fix bug that io mux header file mismatch with chip
3. fix bug that some BASE address not correct
4. add some static function to eagle.fpga32.rom.addr.v7.ld
5. add interrupts usage table
6. add some comments for rom code functions
Ivan Grokhotkov [Fri, 9 Sep 2016 09:14:16 +0000 (17:14 +0800)]
Merge branch 'master' into feature/dualcore_spi_flash_api
* master: (130 commits)
lwip: Define LWIP_ESP8266 in port lwipopts.h not gcc command line
CI: Build the esp-idf-template with the matching branch name, if it exists
README: Add Resources section with some links
Rename README.buildenv to docs/build_system.rst and ReST-ify it
Eclipse docs: Easier to just replace entire PATH, msys32 has everything we need to build/flash
test_build_system: Print ESP_IDF_TEMPLATE_GIT for easier debugging
Name component makefiles component.mk instead of Makefile
Eclipse doc: Add troubleshooting note about Makefile directories
eclipse_make.sh: Fix printing of make directory
Move bin/eclipse_windows_make.sh to tools/windows_eclipse_make.sh
Eclipse docs: Prepend IDF paths to beginning of PATH
Set default SPI flash access mode to DIO
FreeRTOS: temporary solution for memory canaries and memory debug
tcpip_adapter: fix dhcp client work flow
event: not post got ip event if static is invalid
tcpip_adapter: typedef clean up
event: post got ip event when use static ip
tcpip_adapter: use dhcp callback to post got ip event
dhcp: add dhcp callback
lwip: remove netif_reg_addr_change_cb
...
update ci config file with 2 changes:
1. add build SSC and do sanity test config
2. add tags to each job as sanity test need to be executed on special runner
Build system: Allow components to add to the global CFLAGS via Makefile.projbuild
Used by mbedTLS to set MBEDTLS_CONFIG_FILE in all components.
This change sets CFLAGS/etc at the project level and then exports those
variables for components, rather than setting them independently each time
a component Makefile is invoked.
Eclipse fixes, including renaming component Makefiles to component.mk
Some changes after following up some Eclipse problems with @nilay .
Biggest thing is renaming all component Makefiles to component.mk. This requires changes to all esp-idf projects, ie:
* https://github.com/espressif/esp-idf-template/compare/bugfix/docs_eclipse?expand=1
* http://gitlab.espressif.cn/idf/esp-idf-tests/tree/update/component_makefiles
... this fixes Eclipse weirdness and also means the only "Makefile"s in the project are the ones you should run make against.
If this MR is merged then I'll also merge these, email all developers about the breaking change and post on esp32.com.