Commit Graph

164 Commits

Author SHA1 Message Date
Matus Fabo
a390efe798 fix: pin definitions for other boards
fix: re-enabled fatfs r/w test on sdspi
fix: copyright notice
add: pin definitions for esp32c3
fix: Changed fixed spi dma channel to a macro definition
2021-11-16 14:13:25 +01:00
Roland Dobai
766aa57084 Build & config: Remove leftover files from the unsupported "make" build system 2021-11-11 15:32:36 +01:00
Martin Gano
3c4034d36e support for generating FATFS on a host 2021-11-03 13:06:11 +01:00
Jan Procházka
fb22c1f182 fatfs: Implementation of disk_status nad disk_initialize for SD/MMC card
FATFS provides a disk status and disk initialize callback which were not
implemented. Implementation has very low impact on SD/MMC speed and
fixes issues, when trying to open file when SD card was removed from
slot and not deinited.

If disk_status returns STA_NOINIT, it will always continue with
disk_initialize. If that returns 0, it will continue like everything is
working normally. So there has to be the same check as in disk_status.
Return of disk_initialize is always checked like this for STA_NOINIT or
STA_PROTECT so if command fails, we return the STA_NOINIT.

stat = disk_initialize(pdrv);
if (stat & STA_NOINIT) return FR_NOT_READY;
if (stat & STA_PROTECT) return FR_WRITE_PROTECTED;

Closes IDF-4125
2021-11-01 15:11:40 +08:00
Omar Chebib
63b96d7612 FAT: Number of volumes can now be configured through menuconfig
Closes https://github.com/espressif/esp-idf/issues/7513
2021-10-19 12:15:31 +08:00
Adam Múdry
4a6cc1d2a4 vfs/fatfs: fix failed tests by increasing timeout
Default 30s timeout is too low for a case when SD card formatting is triggered,
which could lead to tests failure. Timeout of tests is now set to 60s.

JIRA IDFCI-742
2021-08-25 19:04:34 +08:00
Omar Chebib
bd96484f7b host tests: add missing header files for compiling host tests 2021-07-20 17:44:20 +08:00
Marius Vikhammer
79b5dedeb1 CI: minor testcases fixes and disable some cases that cant run on S3 2021-06-15 13:39:48 +08:00
Jakob Hasse
ef2dba3921 Integrated linux log into fatfs and spiffs host tests 2021-05-28 11:05:55 +08:00
Michael (XIAO Xufeng)
925dacd7fb Merge branch 'bugfix/remove_HSPI_macro_on_c3' into 'master'
spi: remove HSPI macros on esp32c3 and esp32s3

Closes IDF-2535

See merge request espressif/esp-idf!12637
2021-04-08 09:33:18 +00:00
Armando
9b9ea71ff9 spi: remove HSPI macro on esp32c3 and esp32s3 2021-04-06 13:42:49 +08:00
Renz Bagaporo
e6edf34e82 esp32: move esp_clk functions 2021-03-31 19:17:33 +08:00
Renz Bagaporo
4a08264e7a esp_system: split esp_system.h header 2021-03-31 19:13:03 +08:00
aditi_lonkar
6e7780421b fatfs: Fix some memory leak issues by coverity static analyzer. 2021-01-25 03:37:47 +00:00
morris
e9c131e174 fatfs: return EINVAL if truncate length is less than 0 2021-01-13 19:11:48 +08:00
morris
753a929525 global: fix sign-compare warnings 2021-01-12 14:05:08 +08:00
Marius Vikhammer
9c8e4fd4c5 C3: build and run unit tests
Enable building and running of unit tests in CI for C3 as well as fix
related compile errors

Also enables building of C3 test apps
2021-01-11 11:34:37 +08:00
Ivan Grokhotkov
b1c4107275 vfs: zero-initialize struct stat in *_stat and *_fstat handlers
...otherwise some fields will contain garbage values.
This wasn't noticed until HAVE_BLKSIZE got enabled in newlib builds.
2020-12-29 16:18:04 +01:00
Angus Gratton
8fa2cf464a fatfs: Whitespace cleanup 2020-12-24 13:40:01 +11:00
Angus Gratton
61f4be45ec fatfs: Make host sdkconfig compatible 2020-11-17 22:51:07 +00:00
Angus Gratton
6ce34a227e Merge branch 'feature/fatfs_fast_seek' into 'master'
feature/fatfs: enable the usage of fast-seek algorithm

See merge request espressif/esp-idf!9916
2020-11-17 07:17:31 +08:00
Angus Gratton
66fb5a29bb Whitespace: Automated whitespace fixes (large commit)
Apply the pre-commit hook whitespace fixes to all files in the repo.

(Line endings, blank lines at end of file, trailing whitespace)
2020-11-11 07:36:35 +00:00
Felipe Neves
ac6ce5ddbd docs: added some fast-seek documentation to the fatfs.rst 2020-11-06 13:18:16 -03:00
Felipe Neves
93ffc009ef vfs: restrict the fast seek for read-only files
Since the files under fast-seek cannot be expanded with further writes, it does not
make sense to enable fast-seek which may fail in write-mode files
2020-11-05 17:01:50 -03:00
Felipe Neves
32e760adfb fat_vfs: added fast seek capable file operation 2020-11-05 17:01:50 -03:00
Felipe Neves
8815a3dfa0 fatfs: expose FF_USE_FASTSEEK option 2020-11-05 17:01:50 -03:00
Renz Bagaporo
79887fdc6c soc: descriptive part occupy whole component 2020-10-28 07:21:29 +08:00
Renz Bagaporo
21e46d5b3c ci: use actual esp_system headers for host test 2020-10-22 19:42:34 +08:00
Michael (XIAO Xufeng)
1966f00f0b soc: updates caps usage
We should define caps as 1 if true. When use the caps macros, #if and
 #if ! should be used instead of #ifdef/#ifndef.
2020-10-17 16:10:17 +08:00
Ivan Grokhotkov
c330def25a fatfs: fix SPIRAM allocation not used due to Kconfig option name error
Closes https://github.com/espressif/esp-idf/issues/5756
2020-09-14 18:30:31 +02:00
Jakob Hasse
20c068ef3b cmock: added cmock as component
* changing dependencies from unity->cmock
* added component.mk and Makefile.projbuild
* ignore test dir in gen_esp_err_to_name.py
* added some brief introduction of CMock in IDF
2020-09-02 16:38:37 +08:00
Michael (XIAO Xufeng)
5425ef4ee4 hal: extract hal component from soc component 2020-09-01 13:25:32 +08:00
morris
2917651478 esp_rom: extract common ets apis into esp_rom_sys.h 2020-07-27 15:27:01 +08:00
Angus Gratton
62426a6c90 Merge branch 'refactor/use_new_component_registration_functions' into 'master'
CMake: Use new component registration function

See merge request espressif/esp-idf!8068
2020-03-25 08:02:42 +08:00
Renz Bagaporo
3d0967a58a test: declare requirements and include dirs private 2020-03-23 10:58:50 +08:00
Ivan Grokhotkov
8a47f43cef fatfs: handle CONFIG_VFS_FAT_SUPPORT_DIR 2020-03-20 14:03:45 +01:00
michael
d16ad4a67a ci: disable case witout runners 2020-02-15 18:28:25 +08:00
Michael (XIAO Xufeng)
067f3d21c9 sdspi, vfs_fat: allow sharing SPI bus among devices, and mounting multiple SD cards 2020-02-12 15:16:08 +08:00
Michael (XIAO Xufeng)
278634dcbd sdspi: support crc16_be for esp32s2 2020-02-12 15:15:46 +08:00
Renz Christian Bagaporo
1f2e2fe8af soc: separate abstraction, description and implementation 2020-02-11 14:30:42 +05:00
Angus Gratton
ee269ed687 Merge branch 'bugfix/fatfs_corrupted_assert' into 'master'
fatfs: handle FR_INT_ERR as "filesystem corrupted"

Closes IDF-894

See merge request espressif/esp-idf!5912
2020-01-14 08:37:07 +08:00
Angus Gratton
bdf6c00154 Merge branch 'feature/likely_unlikely' into 'master'
Adding likely unlikely macros to hot code paths

Closes IDF-284

See merge request espressif/esp-idf!6368
2020-01-10 14:05:07 +08:00
michael
4220752aed ut: Move tests back from "esp32" subfolder
DISABLED_FOR_TARGETS macros are used

Partly revert "ci: disable unavailable tests for esp32s2beta"

This partly reverts commit 76a3a5fb48.

Partly revert "ci: disable UTs for esp32s2beta without runners"

This partly reverts commit eb158e9a22.

Partly revert "fix unit test and examples for s2beta"

This partly reverts commit 9baa7826be.

Partly revert "efuse: Add support for esp32s2beta"

This partly reverts commit db84ba868c.
2020-01-06 17:13:53 +08:00
Felipe Neves
d059a955ae freertos: removed likely macros from non-port specifics parts of freertos
fatfs: moved esp_compiler header file inside of disk implementation file
2020-01-03 14:42:57 -03:00
Felipe Neves
fc00236d79 components/esp_common: added esp_macros.h that aims to hold useful macros
esp_common/esp_compiler: renamed esp_macros file to a more specific one

esp_common/esp_compiler: removed CONTAINER_OF macro, it was a duplicate

components/freertos: placed likely macros around port and critical sections

component/freertos: placed likely macros on lists module

components/freertos: placed unlikely macros inside of assertion points, they likely wont fail

components/freertos: added likely macros on queue modules

FreeRTOS queues are one of most hot code path, because to queues itself tend to
be used a lot by the applications, besides that, queues are the basic primitive
to form both mutexes and semaphores, The focus here is to place likely
macros inside lowest level send and receive routines, since they're common
from all kobjects: semaphores, queues, mutexes and FR internals (like timer queue)

components/lwip: placed likely/unlikey on net-interfaces code

components/fatfs: added unlikely macros on disk drivers code

components/spiffs: added unlikely macros on low level fs driver

components/freertos: added likely/unlikely macros on timers and ticker

freertos/event_group: placed likely/unlikely macros on hot event group code paths

components/sdmmc: placed likely / unlikely macros on lower level path of sdmmc

components/bt: placed unlikely macros around bt HCI functions calling

components/lwip: added likely/unlikely macros on OS port code section

components/freertos: fix code style on tick handler
2020-01-03 14:42:49 -03:00
Ivan Grokhotkov
28b7f11f93 fatfs: fix unit tests not included in the build
Regression from 9baa7826.
2019-11-15 15:04:57 +01:00
Angus Gratton
8675a818f9 Merge branch 'master' into feature/esp32s2beta_merge 2019-10-22 13:51:49 +11:00
Roland Dobai
19c644f7fd Fix memory leak upon failure of esp_vfs_fat_sdmmc_mount()
Closes https://github.com/espressif/esp-idf/issues/4165
2019-10-10 14:28:43 +00:00
Angus Gratton
adfc06a530 Merge branch 'master' into feature/esp32s2beta_merge 2019-09-20 10:28:37 +10:00
Angus Gratton
fb748bae7f fatfs: Remove esp_vfs_fat_unregister()
Deprecated in ESP-IDF V2.0
2019-09-13 09:44:07 +10:00