Commit Graph

17 Commits

Author SHA1 Message Date
KonstantinKondrashov
e72061695e all: Removes unnecessary newline character in logs
Closes https://github.com/espressif/esp-idf/issues/11465
2023-06-09 03:31:21 +08:00
Martin Gaňo
41742c2369 fatfs: enabled reading sector size and sectors count from boot sector in rawflash 2022-09-29 16:16:36 +02:00
Martin Vychodil
7f884dc966 Merge branch 'fix/ff_sdmmc_status_check_optional' into 'master'
fatfs: Add option to mock ff_sdmmc_status output to increase IO speed

Closes IDF-4788

See merge request espressif/esp-idf!18300
2022-06-13 14:42:12 +08:00
Adam Múdry
8af790da45 fatfs: Add mock option to ff_sdmmc_status function to increase IO speed
Adds `disk_status_check_enable` field to `esp_vfs_fat_mount_config_t` struct to control if ff_sdmmc_status is mocked or not.
2022-06-09 20:09:32 +00:00
Ivan Grokhotkov
a28828a6f4
fatfs: re-enable TRIM support for SPI mode
Previously this didn't work because MMC_ERASE implementation for SPI
didn't wait for the busy status indication.
2022-05-30 15:39:01 +02:00
Vamshi Gajjela
964592e189 fatfs: Add trim ioctl call, set FF_USE_TRIM as default option.
FF_USE_TRIM is set by default with this commit. Fatfs invokes disk_ioctl
with CTRL_TRIM to erase the sectors calling sdmmc_erase_sectors to choose the right
argument for the erase operation based on media type.
2022-03-05 16:35:37 +05:30
Adam Múdry
bb8587a139 fatfs: Update to version 0.14b
Updated FATFS to 0.14b from 0.13c and patched for ESP32
2022-02-21 14:54:55 +01:00
Omar Chebib
1bad4f18ed FATFS: fix system crash when mounting more than 2 volumes
* Fixes https://github.com/espressif/esp-idf/issues/7513
2021-12-20 03:16:18 +00: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
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
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
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
8f6606141a fatfs: create separate ffsystem.c for host side testing 2019-06-25 23:07:07 +08:00
Ivan Grokhotkov
66bdeca603 fatfs: update diskio and vfs for FatFS changes
- do to not rely on integer.h types
- ffsystem.c does not define ff_memcalloc, replace with ff_memalloc +
  memset.
2019-06-25 23:05:16 +08:00
Ivan Grokhotkov
e181a40c9f fatfs: separate IDF-specific files from the original FatFS code
This is a breaking change: applications which used diskio.h to
call ff_diskio_register, will now need to include diskio_impl.h.
Including diskio.h will include the original diskio.h header from
FatFS library.
2019-06-25 23:05:16 +08:00