Commit graph

109 commits

Author SHA1 Message Date
Ivan Grokhotkov 6185e722c3 Revert "Merge branch 'feature/vfs_select' into 'master'"
This reverts merge request !2074
2018-04-20 11:51:41 +08:00
Roland Dobai 6852d653bd Allow VFS file descriptors in select() 2018-04-17 11:25:30 +02:00
Roland Dobai 33480d1a2c Enable -Wwrite-strings when compiling IDF's own C files 2018-04-10 08:53:33 +02:00
Angus Gratton 53234ef2bc Merge branch 'refactor/rtc_split_module' into 'master'
bugfix(rtc): make sure peripherals (DAC, HALL) are turned off before conversion.

See merge request idf/esp-idf!1848
2018-04-04 09:00:58 +08:00
Ivan Grokhotkov d7c8866896 Merge branch 'test/support_multi_stage_unit_test_case' into 'master'
unit-test-app: support multi stage unit test case

See merge request idf/esp-idf!2139
2018-04-03 18:20:16 +08:00
He Yin Ling fee844d22c unit-test-app: support multi stages test 2018-03-30 11:38:49 +08:00
Michael (Xiao Xufeng) cef8baf424 bugfix(rtc): make sure peripherals (DAC, HALL) are turned off before conversion.
refactor structure of ``rtc_module.c`` to make it more clearly.

Closes https://github.com/espressif/esp-idf/issues/1517
2018-03-28 17:10:01 +08:00
Anton Maklakov f3d61015f7 build: Fix problems with building kconfig and generating sdkconfig
We had some problems:
    simultaneous compiling of kconfig in the same tree;
    attempt to use menuconfig in some examples and ut in batch mode (w/o interactive console)

Also increase debug abilities in CI:
    force non-interactive building;
    add variable DEBUG_SHELL to toggle verbosity of scripts
2018-03-28 10:39:20 +08:00
houchenyao 5b8a9478a3 CI: new CI ut framework, and can run it in local PC 2018-02-05 06:58:22 +00:00
houchenyao cb3c88fb2f unit-test-app: use '-' to show test history 2018-02-05 06:58:22 +00:00
Ivan Grokhotkov 82aeb18c3f Merge branch 'test/UT_master_slave_mode' into 'master'
unit-test-app: support multiple devices test cases

See merge request !1220
2017-12-11 15:22:51 +08:00
houchenyao 7a31b93fa3 unit-test-app: support multiple devices test cases:
current unit-test-app don't support test components need to communicate
with each other (like GPIO, SPI ...). Now we add multiple devices mode
to unit test app, support writing and running test with multiple DUTs.

please refer to `docs/api-guides/unit-tests.rst` for detail.
2017-12-07 13:57:26 +08:00
Ivan Grokhotkov 2b92119840 Merge branch 'bugfix/freertos_check_task_waiting_termination' into 'master'
Freertos Task Deletion backport and FPU documentation

See merge request !1591
2017-12-07 11:55:10 +08:00
Darian Leung 38afa32cfb freertos/fix SMP bug with Idle task clean up
This commit backports vTaskDelete() behavior from FreeRTOS v9.0.0  which
allows for the immediate freeing of task memory if the task being deleted
is not currently running and not pinned to the other core. This commit also
fixes a bug in prvCheckTasksWaitingTermination which prevented the
Idle Task from cleaning up all tasks awaiting deletion. Each iteration of the Idle
Task should traverse the xTasksWaitingTermination list and clean up all tasks
not pinned to the other core. The previous implementation would cause
prvCheckTasksWaitingTermination to return when encountering a task
pinned to the other core whilst traversing the xTasksWaitingTermination list.

The test case for vTaskDelete() has been updated to test for the bugfix and
backported deletion behavior.
2017-12-05 18:13:56 +08:00
Ivan Grokhotkov f0547d58e4 esp_timer: add documentation, expose profiling option in Kconfig 2017-11-29 11:44:46 +08:00
Ivan Grokhotkov 067c0e1ffe Merge branch 'bugfix/cpp_unit_tests_not_executed_by_ci' into 'master'
CI: fix C++ unit test cases not executed by CI

See merge request !1589
2017-11-27 12:48:12 +08:00
Angus Gratton 02304ad83e Merge branch 'feature/freertos_backported_functions' into 'master'
freertos/backport and test v9.0.0 functions

See merge request !1515
2017-11-24 08:49:59 +08:00
He Yin Ling dd371289aa CI: fix C++ unit test cases not executed by CI 2017-11-23 17:14:23 +08:00
Darian Leung c1d101dd41 freertos/backport and test v9.0.0 functions
This commit backports the following features from FreeRTOS v9.0.0
- uxSemaphoreGetCount()
- vTimerSetTimerId(), xTimerGetPeriod(), xTimerGetExpiryTime()
- xTimerCreateStatic()
- xEventGroupCreateStatic()
- uxSemaphoreGetCount()

Functions backported previously
- xTaskCreateStatic()
- xQueueCreateStatic()
- xSemaphoreCreateBinaryStatic(), xSemaphoreCreateCountingStatic()
- xSemaphoreCreateMutexStatic(), xSemaphoreCreateRecursiveMutexStatic()
- pcQueueGetName()
- vTaskSetThreadLocalStoragePointer()
- pvTaskGetThreadLocalStoragePointer()

Unit tests were also written for the functions above (except for pcQueueGetName
which is tested in a separate Queue Registry MR). The original tlsp and del cb test case
was deleted and integrated into the test cases of this MR.
2017-11-23 14:18:09 +08:00
Ivan Grokhotkov 6e1453e864 Merge branch 'feature/bot' into 'master'
CI: support customize test with @bot

See merge request !1502
2017-11-21 18:43:56 +08:00
Ivan Grokhotkov 2eae440646 unit-test-app: reduce startup delay, clean up 2017-11-20 17:51:27 +08:00
Ivan Grokhotkov 5117364c13 unit-test-app: don't print the list of tests by default
This reduces unit-test-app startup time when there are a lot of tests
included, speeding up unit tests in CI.
2017-11-20 17:51:27 +08:00
Alexey Gerenkov 692a890232 esp32: Adds Stack Smashing Protection Feature
These changes add posibility to enable GCC stack protector via menuconfig
for all source files in project.
2017-11-17 12:08:36 +03:00
He Yin Ling 9395a702ef test: check and collect performance via CI 2017-11-16 17:48:30 +08:00
Darian Leung d1853dbbc0 FreeRTOS/make Queue Registry and Run Time Stats configurable
This commit makes the configQUEUE_REGISTRY_SIZE and
configGENERATE_RUN_TIME_STATS configurable in menuconfig.

- configQUEUE_REGISTRY_SIZE can now be set in menuconfig.
- The functions vQueueAddToRegistry() and vQueueUnregisterQueue() were made
  SMP compatbile
- pcQueueGetName() was backported from FreeRTOS v9.0.0
- Added test case for Queue Registry functions

- configGENERATE_RUN_TIME_STATS can now be enabled in menuconfig. CCOUNT or
  esp_timer can be selected as the FreeRTOS run time clock in menuconfig as
  well, although CCOUNT will overflow quickly.
- Run time stats collection (in vTaskSwitchContext) and generation (in
  uxTaskGetSystemState) have been made SMP compatible. Therefore
  vTaskGetRunTimeStats() now displays the run time usage of each task as a
  percentage of total runtime of both CPUs

Squash
2017-11-14 15:50:31 +08:00
Ivan Grokhotkov 7632c6a80c Merge branch 'test/UT_reset_check' into 'master'
Test/ut reset check

See merge request !1086
2017-11-10 11:30:46 +08:00
houchenyao f80824a2d8 test: support test for UT cases expect to reset 2017-11-07 12:19:39 +08:00
Ivan Grokhotkov 6b420b2452 unit tests: add psram configuration 2017-11-06 11:23:15 +08:00
Angus Gratton 2c72223a4e Merge branch 'bugfix/protect_spiflash_regions' into 'master'
spi_flash: Abort on writes to dangerous regions (bootloader, partition table, app)

See merge request !1452
2017-11-04 12:40:21 +08:00
Angus Gratton 670733df9f spi_flash: Abort on writes to dangerous regions (bootloader, partition table, app)
Can be disabled or made into a failure result in kconfig if needed.
2017-11-03 15:52:27 -07:00
Ivan Grokhotkov 849ad9b37b tools/unit-test-app: fix build warning 2017-11-03 15:49:09 +08:00
Ivan Grokhotkov 59b7d98fec Merge branch 'feature/dfs' into 'master'
Dynamic frequency scaling

See merge request !1189
2017-10-22 12:34:11 +08:00
Darian Leung a6854b72cd freertos/make trace facility configurable
This commit makes configUSE_TRACE_FACILITY and
configUSE_STATS_FORMATTING_FUNCTIONS configurable in kconfig. Test cases fro the
functions enabled by the two configurations above have also been added.

Test cases for the following functions have been added...

- uxTaskGetSystemState()
- uxTaskGetTaskNumber()
- vTaskSetTaskNumber()

- xEventGroupClearBitsFromISR()
- xEventGroupSetBitsFromISR()
- uxEventGroupGetNumber()

- uxQueueGetQueueNumber()
- vQueueSetQueueNumber()
- ucQueueGetQueueType()

Test cases for the following functions were not required...

- prvListTaskWithinSingleList()
- prvWriteNameToBuffer()
- vTaskList()
2017-10-20 15:17:17 +08:00
Ivan Grokhotkov 90bbcbcdc0 unit tests: fix warnings, build with -Werror
- libsodium: silence warnings
- unit tests: fix warnings
- spiram: fix warnings
- ringbuf test: enable by default, reduce delays
2017-10-19 21:35:23 +08:00
He Yin Ling 0a5b678e58 CI: support test UT with different config by CI 2017-10-19 21:35:20 +08:00
Ivan Grokhotkov 3d150be4e1 unit-test-app: new targets for building different configurations 2017-10-19 21:35:19 +08:00
Ivan Grokhotkov bfeecd2b56 freertos: deprecate XT_CLOCK_FREQ
- freertos: add deprecated definition for XT_CLOCK_FREQ
- flash_ops: don't use XT_CLOCK_FREQ
- unity: don't use XT_CLOCK_FREQ
- hw_random: don't use XT_CLOCK_FREQ
- core_dump: don't use XT_CLOCK_FREQ
- app_trace: don't use XT_CLOCK_FREQ
- xtensa_init: init xt_tick_divisor
2017-10-18 14:19:19 +08:00
Ivan Grokhotkov 2b3325b1ab unit tests: fix ref_clock value obtained due to overflow 2017-10-18 14:19:15 +08:00
Angus Gratton 69e92ee320 unit tests: If heap tracing is enabled in sdkconfig, leak trace each test 2017-10-17 15:29:25 +08:00
Angus Gratton 6f07e0797d Unit tests: If a test fails due to corrupting memory, don't print a misleading source file name 2017-10-17 14:46:08 +08:00
Angus Gratton 0a52dbccca Merge branch 'bugfix/spi_reset_race' into 'master'
periph_ctrl: Refactor to add periph_module_reset(), avoid potential race in SPI DMA workaround

See merge request !1349
2017-10-13 08:51:36 +08:00
Angus Gratton 5d8bd1aa9e Merge branch 'bugfix/libsodium_mbedtls_sha' into 'master'
libsodium: Fix mbedTLS SHA256 & SHA512 implementation, make optional

See merge request !1329
2017-10-13 08:50:24 +08:00
Angus Gratton acff3c9c59 libsodium: Fix mbedTLS SHA256 & SHA512 implementation, make optional
* Only direct invocation of cypto_hash_sha256 & crypto_hash_sha512 produced correct output.
* Some remaining header file mixups, so changed approach to wrapping the state structures.
* Fixes https://github.com/espressif/esp-idf/issues/1044 (crypto_sign problems)
* Add option to disable mbedTLS implementation for SHA256 & SHA512 in libsodium
2017-10-06 11:51:55 +11:00
Angus Gratton 0dd9b899b7 periph_ctrl: Refactor to add periph_module_reset(), avoid potential race in SPI DMA workaround
Also refactor use of direct clock access in unit test ref_clock (probably not a real issue)
2017-10-02 17:48:16 +11:00
michael 7370f2913d test: update the format of TEST_ASSERT macro series in `unity.c` 2017-09-27 19:56:46 +08:00
Ivan Grokhotkov 01c0c4b661 unit-test-app: initialize partition table info before starting the test 2017-09-19 10:39:44 +08:00
me-no-dev dd87deb278 Add SPIFFS Component to IDF 2017-09-11 19:56:40 +03:00
Angus Gratton 1c7b8aa3a5 Heap tracing support 2017-09-07 16:32:05 +10:00
Angus Gratton 64bfdf56bb Unit tests: enable comprehensive heap poisoning checks 2017-09-07 16:32:05 +10:00
Angus Gratton 5222428dde unit tests: Check heap integrity after each test, check for obvious leaks 2017-09-07 16:32:05 +10:00