CMSIS2000
0.0.7
|
Go to the source code of this file.
Macros | |
#define | ABORT(fs, res) { fp->flag |= FA__ERROR; LEAVE_FF(fs, res); } |
#define | BPB_BkBootSec 50 /* Offset of backup boot sector (2) */ |
#define | BPB_BytsPerSec 11 /* Sector size [byte] (2) */ |
#define | BPB_ExtFlags 40 /* Extended flags (2) */ |
#define | BPB_FATSz16 22 /* FAT size [sector] (2) */ |
#define | BPB_FATSz32 36 /* FAT size [sector] (4) */ |
#define | BPB_FSInfo 48 /* Offset of FSInfo sector (2) */ |
#define | BPB_FSVer 42 /* File system version (2) */ |
#define | BPB_HiddSec 28 /* Number of special hidden sectors (4) */ |
#define | BPB_Media 21 /* Media descriptor (1) */ |
#define | BPB_NumFATs 16 /* Number of FAT copies (1) */ |
#define | BPB_NumHeads 26 /* Number of heads (2) */ |
#define | BPB_RootClus 44 /* Root dir first cluster (4) */ |
#define | BPB_RootEntCnt 17 /* Number of root dir entries for FAT12/16 (2) */ |
#define | BPB_RsvdSecCnt 14 /* Size of reserved area [sector] (2) */ |
#define | BPB_SecPerClus 13 /* Cluster size [sector] (1) */ |
#define | BPB_SecPerTrk 24 /* Track size [sector] (2) */ |
#define | BPB_TotSec16 19 /* Volume size [sector] (2) */ |
#define | BPB_TotSec32 32 /* Volume size [sector] (4) */ |
#define | BS_55AA 510 /* Boot sector signature (2) */ |
#define | BS_BootSig 38 /* Extended boot signature (1) */ |
#define | BS_BootSig32 66 /* Extended boot signature (1) */ |
#define | BS_DrvNum 36 /* Physical drive number (2) */ |
#define | BS_DrvNum32 64 /* Physical drive number (2) */ |
#define | BS_FilSysType 54 /* File system type (1) */ |
#define | BS_FilSysType32 82 /* File system type (1) */ |
#define | BS_jmpBoot 0 /* Jump instruction (3) */ |
#define | BS_OEMName 3 /* OEM name (8) */ |
#define | BS_VolID 39 /* Volume serial number (4) */ |
#define | BS_VolID32 67 /* Volume serial number (4) */ |
#define | BS_VolLab 43 /* Volume label (8) */ |
#define | BS_VolLab32 71 /* Volume label (8) */ |
#define | DDE 0xE5 /* Deleted directory entry mark in DIR_Name[0] */ |
#define | DEF_NAMEBUF BYTE sfn[12] |
#define | DIR_Attr 11 /* Attribute (1) */ |
#define | DIR_CrtDate 16 /* Created date (2) */ |
#define | DIR_CrtTime 14 /* Created time (2) */ |
#define | DIR_CrtTimeTenth 13 /* Created time sub-second (1) */ |
#define | DIR_FileSize 28 /* File size (4) */ |
#define | DIR_FstClusHI 20 /* Higher 16-bit of first cluster (2) */ |
#define | DIR_FstClusLO 26 /* Lower 16-bit of first cluster (2) */ |
#define | DIR_LstAccDate 18 /* Last accessed date (2) */ |
#define | DIR_Name 0 /* Short file name (11) */ |
#define | DIR_NTres 12 /* NT flag (1) */ |
#define | DIR_WrtDate 24 /* Modified date (2) */ |
#define | DIR_WrtTime 22 /* Modified time (2) */ |
#define | ENTER_FF(fs) |
#define | FREE_BUF() |
#define | FSI_Free_Count 488 /* FSI: Number of free clusters (4) */ |
#define | FSI_LeadSig 0 /* FSI: Leading signature (4) */ |
#define | FSI_Nxt_Free 492 /* FSI: Last allocated cluster (4) */ |
#define | FSI_StrucSig 484 /* FSI: Structure signature (4) */ |
#define | INIT_BUF(dobj) (dobj).fn = sfn |
#define | IsDBCS1(c) 0 |
#define | IsDBCS2(c) 0 |
#define | IsDigit(c) (((c)>='0')&&((c)<='9')) |
#define | IsLower(c) (((c)>='a')&&((c)<='z')) |
#define | IsUpper(c) (((c)>='A')&&((c)<='Z')) |
#define | LDIR_Attr 11 /* LFN attribute (1) */ |
#define | LDIR_Chksum 13 /* Sum of corresponding SFN entry */ |
#define | LDIR_FstClusLO 26 /* Filled by zero (0) */ |
#define | LDIR_Ord 0 /* LFN entry order and LLE flag (1) */ |
#define | LDIR_Type 12 /* LFN type (1) */ |
#define | LEAVE_FF(fs, res) return res |
#define | LLE 0x40 /* Last long entry flag in LDIR_Ord */ |
#define | MBR_Table 446 /* MBR: Partition table offset (2) */ |
#define | MIN_FAT16 4086 /* Minimum number of clusters for FAT16 */ |
#define | MIN_FAT32 65526 /* Minimum number of clusters for FAT32 */ |
#define | NDDE 0x05 /* Replacement of the character collides with DDE */ |
#define | NS 11 /* Index of name status byte in fn[] */ |
#define | NS_BODY 0x08 /* Lower case flag (body) */ |
#define | NS_DOT 0x20 /* Dot entry */ |
#define | NS_EXT 0x10 /* Lower case flag (ext) */ |
#define | NS_LAST 0x04 /* Last segment */ |
#define | NS_LFN 0x02 /* Force to create LFN entry */ |
#define | NS_LOSS 0x01 /* Out of 8.3 format */ |
#define | SS(fs) ((fs)->ssize) /* Variable sector size */ |
#define | SZ_DIR 32 /* Size of a directory entry */ |
#define | SZ_PTE 16 /* MBR: Size of a partition table entry */ |
Functions | |
static BYTE | check_fs (FATFS *fs, DWORD sect) |
static int | chk_chr (const char *str, int chr) |
static FRESULT | chk_mounted (const TCHAR **path, FATFS **rfs, BYTE wmode) |
DWORD | clust2sect (FATFS *fs, DWORD clst) |
static DWORD | create_chain (FATFS *fs, DWORD clst) |
static FRESULT | create_name (DIR *dj, const TCHAR **path) |
static FRESULT | dir_alloc (DIR *dj, UINT nent) |
static FRESULT | dir_find (DIR *dj) |
static FRESULT | dir_next (DIR *dj, int stretch) |
static FRESULT | dir_read (DIR *dj, int vol) |
static FRESULT | dir_register (DIR *dj) |
static FRESULT | dir_remove (DIR *dj) |
static FRESULT | dir_sdi (DIR *dj, WORD idx) |
FRESULT | f_chmod (const TCHAR *path, BYTE value, BYTE mask) |
FRESULT | f_close (FIL *fp) |
FRESULT | f_getfree (const TCHAR *path, DWORD *nclst, FATFS **fatfs) |
FRESULT | f_lseek (FIL *fp, DWORD ofs) |
FRESULT | f_mkdir (const TCHAR *path) |
FRESULT | f_mount (BYTE vol, FATFS *fs) |
FRESULT | f_open (FIL *fp, const TCHAR *path, BYTE mode) |
FRESULT | f_opendir (DIR *dj, const TCHAR *path) |
FRESULT | f_read (FIL *fp, void *buff, UINT btr, UINT *br) |
FRESULT | f_readdir (DIR *dj, FILINFO *fno) |
FRESULT | f_rename (const TCHAR *path_old, const TCHAR *path_new) |
FRESULT | f_stat (const TCHAR *path, FILINFO *fno) |
FRESULT | f_sync (FIL *fp) |
FRESULT | f_truncate (FIL *fp) |
FRESULT | f_unlink (const TCHAR *path) |
FRESULT | f_utime (const TCHAR *path, const FILINFO *fno) |
FRESULT | f_write (FIL *fp, const void *buff, UINT btw, UINT *bw) |
static FRESULT | follow_path (DIR *dj, const TCHAR *path) |
DWORD | get_fat (FATFS *fs, DWORD clst) |
static void | get_fileinfo (DIR *dj, FILINFO *fno) |
static DWORD | ld_clust (FATFS *fs, BYTE *dir) |
static int | mem_cmp (const void *dst, const void *src, UINT cnt) |
static void | mem_cpy (void *dst, const void *src, UINT cnt) |
static void | mem_set (void *dst, int val, UINT cnt) |
static FRESULT | move_window (FATFS *fs, DWORD sector) |
FRESULT | put_fat (FATFS *fs, DWORD clst, DWORD val) |
static FRESULT | remove_chain (FATFS *fs, DWORD clst) |
static void | st_clust (BYTE *dir, DWORD cl) |
static FRESULT | sync_fs (FATFS *fs) |
static FRESULT | sync_window (FATFS *fs) |
static FRESULT | validate (void *obj) |
Variables | |
static WORD | Fsid |
#define BPB_BkBootSec 50 /* Offset of backup boot sector (2) */ |
#define BPB_BytsPerSec 11 /* Sector size [byte] (2) */ |
Definition at line 401 of file ff.c.
Referenced by chk_mounted().
#define BPB_FATSz16 22 /* FAT size [sector] (2) */ |
Definition at line 408 of file ff.c.
Referenced by chk_mounted().
#define BPB_FATSz32 36 /* FAT size [sector] (4) */ |
Definition at line 418 of file ff.c.
Referenced by chk_mounted().
#define BPB_FSInfo 48 /* Offset of FSInfo sector (2) */ |
Definition at line 422 of file ff.c.
Referenced by chk_mounted().
#define BPB_HiddSec 28 /* Number of special hidden sectors (4) */ |
#define BPB_NumFATs 16 /* Number of FAT copies (1) */ |
Definition at line 404 of file ff.c.
Referenced by chk_mounted().
#define BPB_RootClus 44 /* Root dir first cluster (4) */ |
Definition at line 421 of file ff.c.
Referenced by chk_mounted().
#define BPB_RootEntCnt 17 /* Number of root dir entries for FAT12/16 (2) */ |
Definition at line 405 of file ff.c.
Referenced by chk_mounted().
#define BPB_RsvdSecCnt 14 /* Size of reserved area [sector] (2) */ |
Definition at line 403 of file ff.c.
Referenced by chk_mounted().
#define BPB_SecPerClus 13 /* Cluster size [sector] (1) */ |
Definition at line 402 of file ff.c.
Referenced by chk_mounted().
#define BPB_TotSec16 19 /* Volume size [sector] (2) */ |
Definition at line 406 of file ff.c.
Referenced by chk_mounted().
#define BPB_TotSec32 32 /* Volume size [sector] (4) */ |
Definition at line 412 of file ff.c.
Referenced by chk_mounted().
#define BS_55AA 510 /* Boot sector signature (2) */ |
Definition at line 435 of file ff.c.
Referenced by check_fs(), chk_mounted(), and sync_fs().
#define BS_FilSysType 54 /* File system type (1) */ |
Definition at line 417 of file ff.c.
Referenced by check_fs().
#define BS_FilSysType32 82 /* File system type (1) */ |
Definition at line 428 of file ff.c.
Referenced by check_fs().
#define DDE 0xE5 /* Deleted directory entry mark in DIR_Name[0] */ |
Definition at line 456 of file ff.c.
Referenced by create_name(), dir_alloc(), dir_find(), dir_read(), dir_remove(), and get_fileinfo().
#define DEF_NAMEBUF BYTE sfn[12] |
Definition at line 489 of file ff.c.
Referenced by f_chmod(), f_mkdir(), f_open(), f_opendir(), f_readdir(), f_rename(), f_stat(), f_unlink(), and f_utime().
#define DIR_Attr 11 /* Attribute (1) */ |
Definition at line 438 of file ff.c.
Referenced by dir_find(), dir_read(), f_chmod(), f_mkdir(), f_open(), f_opendir(), f_rename(), f_sync(), f_unlink(), follow_path(), and get_fileinfo().
#define DIR_CrtTime 14 /* Created time (2) */ |
#define DIR_FileSize 28 /* File size (4) */ |
Definition at line 448 of file ff.c.
Referenced by f_open(), f_sync(), and get_fileinfo().
#define DIR_FstClusHI 20 /* Higher 16-bit of first cluster (2) */ |
Definition at line 444 of file ff.c.
Referenced by ld_clust(), and st_clust().
#define DIR_FstClusLO 26 /* Lower 16-bit of first cluster (2) */ |
Definition at line 447 of file ff.c.
Referenced by ld_clust(), and st_clust().
#define DIR_LstAccDate 18 /* Last accessed date (2) */ |
#define DIR_Name 0 /* Short file name (11) */ |
Definition at line 437 of file ff.c.
Referenced by dir_find(), dir_read(), and f_mkdir().
#define DIR_NTres 12 /* NT flag (1) */ |
Definition at line 439 of file ff.c.
Referenced by dir_register(), and get_fileinfo().
#define DIR_WrtDate 24 /* Modified date (2) */ |
Definition at line 446 of file ff.c.
Referenced by f_utime(), and get_fileinfo().
#define DIR_WrtTime 22 /* Modified time (2) */ |
#define ENTER_FF | ( | fs | ) |
Definition at line 133 of file ff.c.
Referenced by chk_mounted(), and validate().
#define FREE_BUF | ( | ) |
Definition at line 491 of file ff.c.
Referenced by f_chmod(), f_mkdir(), f_open(), f_opendir(), f_readdir(), f_rename(), f_stat(), f_unlink(), and f_utime().
#define FSI_Free_Count 488 /* FSI: Number of free clusters (4) */ |
Definition at line 431 of file ff.c.
Referenced by chk_mounted(), and sync_fs().
#define FSI_LeadSig 0 /* FSI: Leading signature (4) */ |
Definition at line 429 of file ff.c.
Referenced by chk_mounted(), and sync_fs().
#define FSI_Nxt_Free 492 /* FSI: Last allocated cluster (4) */ |
Definition at line 432 of file ff.c.
Referenced by chk_mounted(), and sync_fs().
#define FSI_StrucSig 484 /* FSI: Structure signature (4) */ |
Definition at line 430 of file ff.c.
Referenced by chk_mounted(), and sync_fs().
#define INIT_BUF | ( | dobj | ) | (dobj).fn = sfn |
Definition at line 490 of file ff.c.
Referenced by f_chmod(), f_mkdir(), f_open(), f_opendir(), f_readdir(), f_rename(), f_stat(), f_unlink(), and f_utime().
#define IsDBCS1 | ( | c | ) | 0 |
Definition at line 373 of file ff.c.
Referenced by create_name(), and get_fileinfo().
#define IsDBCS2 | ( | c | ) | 0 |
Definition at line 374 of file ff.c.
Referenced by create_name(), and get_fileinfo().
#define IsLower | ( | c | ) | (((c)>='a')&&((c)<='z')) |
Definition at line 354 of file ff.c.
Referenced by create_name().
#define IsUpper | ( | c | ) | (((c)>='A')&&((c)<='Z')) |
Definition at line 353 of file ff.c.
Referenced by create_name(), and get_fileinfo().
#define LDIR_Chksum 13 /* Sum of corresponding SFN entry */ |
Definition at line 452 of file ff.c.
Referenced by dir_find(), and dir_read().
#define LEAVE_FF | ( | fs, | |
res | |||
) | return res |
Definition at line 134 of file ff.c.
Referenced by f_chmod(), f_close(), f_getfree(), f_lseek(), f_mkdir(), f_open(), f_opendir(), f_read(), f_readdir(), f_rename(), f_stat(), f_sync(), f_truncate(), f_unlink(), f_utime(), and f_write().
#define MBR_Table 446 /* MBR: Partition table offset (2) */ |
Definition at line 433 of file ff.c.
Referenced by chk_mounted().
#define MIN_FAT16 4086 /* Minimum number of clusters for FAT16 */ |
Definition at line 391 of file ff.c.
Referenced by chk_mounted().
#define MIN_FAT32 65526 /* Minimum number of clusters for FAT32 */ |
Definition at line 392 of file ff.c.
Referenced by chk_mounted().
#define NDDE 0x05 /* Replacement of the character collides with DDE */ |
Definition at line 457 of file ff.c.
Referenced by create_name(), and get_fileinfo().
#define NS 11 /* Index of name status byte in fn[] */ |
Definition at line 380 of file ff.c.
Referenced by create_name(), dir_find(), dir_register(), f_chmod(), f_mkdir(), f_rename(), f_unlink(), f_utime(), and follow_path().
#define NS_BODY 0x08 /* Lower case flag (body) */ |
Definition at line 384 of file ff.c.
Referenced by create_name(), dir_register(), and get_fileinfo().
#define NS_DOT 0x20 /* Dot entry */ |
Definition at line 386 of file ff.c.
Referenced by create_name(), dir_register(), f_chmod(), f_mkdir(), f_rename(), f_unlink(), f_utime(), and follow_path().
#define NS_EXT 0x10 /* Lower case flag (ext) */ |
Definition at line 385 of file ff.c.
Referenced by create_name(), dir_register(), and get_fileinfo().
#define NS_LAST 0x04 /* Last segment */ |
Definition at line 383 of file ff.c.
Referenced by create_name(), and follow_path().
#define NS_LFN 0x02 /* Force to create LFN entry */ |
Definition at line 382 of file ff.c.
Referenced by create_name(), and dir_register().
#define NS_LOSS 0x01 /* Out of 8.3 format */ |
Definition at line 381 of file ff.c.
Referenced by create_name(), dir_find(), and dir_register().
#define SS | ( | fs | ) | ((fs)->ssize) /* Variable sector size */ |
Definition at line 119 of file ff.c.
Referenced by chk_mounted(), dir_next(), dir_sdi(), f_getfree(), f_lseek(), f_mkdir(), f_read(), f_write(), get_fat(), and put_fat().
#define SZ_DIR 32 /* Size of a directory entry */ |
Definition at line 454 of file ff.c.
Referenced by chk_mounted(), dir_next(), dir_register(), dir_sdi(), f_mkdir(), and f_rename().
#define SZ_PTE 16 /* MBR: Size of a partition table entry */ |
Definition at line 434 of file ff.c.
Referenced by chk_mounted().
Definition at line 2041 of file ff.c.
References BS_55AA, BS_FilSysType, BS_FilSysType32, disk_read(), FATFS::drv, LD_DWORD, LD_WORD, RES_OK, and FATFS::win.
Referenced by chk_mounted().
|
static |
Definition at line 575 of file ff.c.
Referenced by create_name().
Definition at line 2067 of file ff.c.
References _FS_READONLY, _VOLUMES, BPB_BytsPerSec, BPB_FATSz16, BPB_FATSz32, BPB_FSInfo, BPB_NumFATs, BPB_RootClus, BPB_RootEntCnt, BPB_RsvdSecCnt, BPB_SecPerClus, BPB_TotSec16, BPB_TotSec32, BS_55AA, check_fs(), FATFS::csize, FATFS::database, FATFS::dirbase, disk_initialize(), disk_ioctl(), disk_read(), disk_status(), FATFS::drv, ENTER_FF, FATFS::fatbase, FR_DISK_ERR, FR_INVALID_DRIVE, FR_NO_FILESYSTEM, FR_NOT_ENABLED, FR_NOT_READY, FR_OK, FR_WRITE_PROTECTED, FATFS::free_clust, FS_FAT12, FS_FAT16, FS_FAT32, FATFS::fs_type, FATFS::fsi_flag, FSI_Free_Count, FSI_LeadSig, FSI_Nxt_Free, FATFS::fsi_sector, FSI_StrucSig, Fsid, FATFS::fsize, GET_SECTOR_SIZE, FATFS::id, if(), FATFS::last_clust, LD2PD, LD2PT, LD_DWORD, LD_WORD, MBR_Table, MIN_FAT16, MIN_FAT32, FATFS::n_fatent, FATFS::n_fats, FATFS::n_rootdir, RES_OK, SS, FATFS::ssize, STA_NOINIT, STA_PROTECT, SZ_DIR, SZ_PTE, FATFS::volbase, FATFS::wflag, FATFS::win, and FATFS::winsect.
Referenced by f_chmod(), f_getfree(), f_mkdir(), f_open(), f_opendir(), f_rename(), f_stat(), f_unlink(), and f_utime().
Definition at line 824 of file ff.c.
References FATFS::csize, FATFS::database, and FATFS::n_fatent.
Referenced by dir_next(), dir_sdi(), f_lseek(), f_mkdir(), f_read(), f_rename(), f_write(), and remove_chain().
Definition at line 1001 of file ff.c.
References FR_DISK_ERR, FR_OK, FATFS::free_clust, FATFS::fsi_flag, get_fat(), FATFS::last_clust, FATFS::n_fatent, and put_fat().
Referenced by dir_next(), f_lseek(), f_mkdir(), and f_write().
Definition at line 1687 of file ff.c.
References _MAX_LFN, chk_chr(), DDE, ff_convert(), ff_wtoupper(), DIR::fn, FR_INVALID_NAME, FR_OK, IsDBCS1, IsDBCS2, IsLower, IsUpper, mem_set(), NDDE, NS, NS_BODY, NS_DOT, NS_EXT, NS_LAST, NS_LFN, and NS_LOSS.
Referenced by follow_path().
Definition at line 1205 of file ff.c.
References DDE, DIR::dir, dir_next(), dir_sdi(), FR_OK, DIR::fs, move_window(), and DIR::sect.
Referenced by dir_register().
Definition at line 1445 of file ff.c.
References AM_LFN, AM_MASK, AM_VOL, DDE, DIR::dir, DIR_Attr, DIR_Name, dir_next(), dir_sdi(), DIR::fn, FR_NO_FILE, FR_OK, DIR::fs, DIR::index, LDIR_Chksum, mem_cmp(), move_window(), NS, NS_LOSS, and DIR::sect.
Referenced by dir_register(), and follow_path().
Definition at line 1136 of file ff.c.
References DIR::clust, clust2sect(), create_chain(), FATFS::csize, DIR::dir, FR_DENIED, FR_DISK_ERR, FR_INT_ERR, FR_NO_FILE, FR_OK, DIR::fs, get_fat(), DIR::index, mem_set(), FATFS::n_fatent, FATFS::n_rootdir, DIR::sect, SS, sync_window(), SZ_DIR, FATFS::wflag, FATFS::win, and FATFS::winsect.
Referenced by dir_alloc(), dir_find(), dir_read(), dir_register(), dir_remove(), and f_readdir().
Definition at line 1506 of file ff.c.
References _FS_RPATH, AM_LFN, AM_MASK, AM_VOL, DDE, DIR::dir, DIR_Attr, DIR_Name, dir_next(), FR_NO_FILE, FR_OK, DIR::fs, DIR::index, LDIR_Chksum, move_window(), and DIR::sect.
Referenced by f_readdir(), and f_unlink().
Definition at line 1564 of file ff.c.
References _FS_RPATH, DIR::dir, dir_alloc(), dir_find(), dir_next(), DIR_NTres, dir_sdi(), DIR::fn, FR_DENIED, FR_INVALID_NAME, FR_NO_FILE, FR_OK, DIR::fs, DIR::index, mem_cpy(), mem_set(), move_window(), NS, NS_BODY, NS_DOT, NS_EXT, NS_LFN, NS_LOSS, DIR::sect, SZ_DIR, and FATFS::wflag.
Referenced by f_mkdir(), f_open(), and f_rename().
Definition at line 1642 of file ff.c.
References DDE, DIR::dir, dir_next(), dir_sdi(), FR_INT_ERR, FR_NO_FILE, FR_OK, DIR::fs, DIR::index, move_window(), DIR::sect, and FATFS::wflag.
Referenced by f_rename(), and f_unlink().
Definition at line 1088 of file ff.c.
References DIR::clust, clust2sect(), FATFS::csize, DIR::dir, FATFS::dirbase, FR_DISK_ERR, FR_INT_ERR, FR_OK, DIR::fs, FS_FAT32, FATFS::fs_type, get_fat(), DIR::index, FATFS::n_fatent, FATFS::n_rootdir, DIR::sclust, DIR::sect, SS, SZ_DIR, and FATFS::win.
Referenced by dir_alloc(), dir_find(), dir_register(), dir_remove(), f_opendir(), f_readdir(), f_unlink(), and follow_path().
Definition at line 3414 of file ff.c.
References _FS_RPATH, AM_ARC, AM_HID, AM_RDO, AM_SYS, chk_mounted(), DEF_NAMEBUF, DIR::dir, DIR_Attr, DIR::fn, follow_path(), FR_INVALID_NAME, FR_OK, FREE_BUF, DIR::fs, INIT_BUF, LEAVE_FF, NS, NS_DOT, sync_fs(), and FATFS::wflag.
Definition at line 2708 of file ff.c.
References f_sync(), FR_OK, FIL::fs, LEAVE_FF, and validate().
Referenced by load_file_from_external_source_to().
Definition at line 3157 of file ff.c.
References chk_mounted(), FATFS::fatbase, FR_DISK_ERR, FR_INT_ERR, FR_OK, FATFS::free_clust, FS_FAT12, FS_FAT16, FS_FAT32, FATFS::fs_type, FATFS::fsi_flag, get_fat(), LD_DWORD, LD_WORD, LEAVE_FF, move_window(), FATFS::n_fatent, SS, and FATFS::win.
Definition at line 2877 of file ff.c.
References _FS_READONLY, ABORT, FIL::buf, FIL::clust, clust2sect(), create_chain(), CREATE_LINKMAP, FATFS::csize, disk_read(), disk_write(), FATFS::drv, FIL::dsect, FA__DIRTY, FA__ERROR, FA__WRITTEN, FA_WRITE, FIL::flag, FIL::fptr, FR_DISK_ERR, FR_INT_ERR, FR_NOT_ENOUGH_CORE, FR_OK, FIL::fs, FIL::fsize, get_fat(), if(), LEAVE_FF, FATFS::n_fatent, RES_OK, FIL::sclust, SS, and validate().
Definition at line 3341 of file ff.c.
References _FS_RPATH, AM_DIR, chk_mounted(), clust2sect(), create_chain(), FATFS::csize, DEF_NAMEBUF, DIR::dir, DIR_Attr, DIR_Name, dir_register(), DIR_WrtTime, FATFS::dirbase, DIR::fn, follow_path(), FR_DENIED, FR_DISK_ERR, FR_EXIST, FR_INT_ERR, FR_INVALID_NAME, FR_NO_FILE, FR_OK, FREE_BUF, DIR::fs, FS_FAT32, FATFS::fs_type, get_fattime(), INIT_BUF, LEAVE_FF, mem_cpy(), mem_set(), NS, NS_DOT, remove_chain(), DIR::sclust, SS, st_clust(), ST_DWORD, sync_fs(), sync_window(), SZ_DIR, FATFS::wflag, FATFS::win, and FATFS::winsect.
Definition at line 2268 of file ff.c.
References _VOLUMES, FR_INT_ERR, FR_INVALID_DRIVE, FR_OK, and FATFS::fs_type.
Referenced by load_file_from_external_source_to().
Definition at line 2308 of file ff.c.
References AM_DIR, AM_RDO, chk_mounted(), DEF_NAMEBUF, DIR::dir, DIR_Attr, DIR_CrtTime, DIR_FileSize, FIL::dir_ptr, dir_register(), FIL::dir_sect, FIL::dsect, FA__WRITTEN, FA_CREATE_ALWAYS, FA_CREATE_NEW, FA_OPEN_ALWAYS, FA_READ, FA_WRITE, FIL::flag, follow_path(), FIL::fptr, FR_DENIED, FR_EXIST, FR_INT_ERR, FR_INVALID_NAME, FR_INVALID_OBJECT, FR_NO_FILE, FR_OK, FR_TOO_MANY_OPEN_FILES, FREE_BUF, FIL::fs, DIR::fs, FIL::fsize, get_fattime(), FATFS::id, FIL::id, INIT_BUF, FATFS::last_clust, ld_clust(), LD_DWORD, LEAVE_FF, move_window(), remove_chain(), FIL::sclust, st_clust(), ST_DWORD, FATFS::wflag, and FATFS::winsect.
Referenced by load_file_from_external_source_to().
Definition at line 3035 of file ff.c.
References AM_DIR, chk_mounted(), DEF_NAMEBUF, DIR::dir, DIR_Attr, dir_sdi(), follow_path(), FR_INVALID_OBJECT, FR_NO_FILE, FR_NO_PATH, FR_OK, FREE_BUF, DIR::fs, FATFS::id, DIR::id, INIT_BUF, ld_clust(), LEAVE_FF, and DIR::sclust.
Definition at line 2440 of file ff.c.
References ABORT, FIL::buf, FIL::clust, clust2sect(), FATFS::csize, disk_read(), disk_write(), FATFS::drv, FIL::dsect, FA__DIRTY, FA__ERROR, FA_READ, FIL::flag, FIL::fptr, FR_DENIED, FR_DISK_ERR, FR_INT_ERR, FR_OK, FIL::fs, FIL::fsize, get_fat(), LEAVE_FF, mem_cpy(), move_window(), RES_OK, FIL::sclust, SS, validate(), FATFS::wflag, FATFS::win, and FATFS::winsect.
Referenced by check_size_and_header(), and load_uboot_file().
Definition at line 3082 of file ff.c.
References DEF_NAMEBUF, dir_next(), dir_read(), dir_sdi(), FR_NO_FILE, FR_OK, FREE_BUF, DIR::fs, get_fileinfo(), INIT_BUF, LEAVE_FF, DIR::sect, and validate().
Definition at line 3497 of file ff.c.
References _FS_RPATH, AM_ARC, AM_DIR, chk_mounted(), clust2sect(), DEF_NAMEBUF, DIR::dir, DIR_Attr, dir_register(), dir_remove(), FATFS::dirbase, DIR::fn, follow_path(), FR_EXIST, FR_INT_ERR, FR_INVALID_NAME, FR_NO_FILE, FR_OK, FREE_BUF, DIR::fs, FS_FAT32, FATFS::fs_type, INIT_BUF, ld_clust(), LEAVE_FF, mem_cpy(), move_window(), NS, NS_DOT, DIR::sclust, st_clust(), sync_fs(), SZ_DIR, FATFS::wflag, and FATFS::win.
Definition at line 3124 of file ff.c.
References chk_mounted(), DEF_NAMEBUF, DIR::dir, follow_path(), FR_INVALID_NAME, FR_OK, FREE_BUF, DIR::fs, get_fileinfo(), INIT_BUF, and LEAVE_FF.
Definition at line 2660 of file ff.c.
References AM_ARC, FIL::buf, DIR_Attr, DIR_FileSize, DIR_LstAccDate, FIL::dir_ptr, FIL::dir_sect, DIR_WrtTime, disk_write(), FATFS::drv, FIL::dsect, FA__DIRTY, FA__WRITTEN, FIL::flag, FR_DISK_ERR, FR_OK, FIL::fs, FIL::fsize, get_fattime(), LEAVE_FF, move_window(), RES_OK, FIL::sclust, st_clust(), ST_DWORD, ST_WORD, sync_fs(), validate(), and FATFS::wflag.
Referenced by f_close().
Definition at line 3224 of file ff.c.
References FIL::clust, FA__ERROR, FA__WRITTEN, FA_WRITE, FIL::flag, FIL::fptr, FR_DENIED, FR_DISK_ERR, FR_INT_ERR, FR_OK, FIL::fs, FIL::fsize, get_fat(), LEAVE_FF, FATFS::n_fatent, put_fat(), remove_chain(), FIL::sclust, and validate().
Definition at line 3272 of file ff.c.
References _FS_RPATH, AM_DIR, AM_RDO, chk_mounted(), DEF_NAMEBUF, DIR::dir, DIR_Attr, dir_read(), dir_remove(), dir_sdi(), endif(), DIR::fn, follow_path(), FR_DENIED, FR_INT_ERR, FR_INVALID_NAME, FR_NO_FILE, FR_OK, FREE_BUF, DIR::fs, INIT_BUF, ld_clust(), LEAVE_FF, mem_cpy(), NS, NS_DOT, remove_chain(), DIR::sclust, and sync_fs().
Definition at line 3456 of file ff.c.
References _FS_RPATH, chk_mounted(), DEF_NAMEBUF, DIR::dir, DIR_WrtDate, DIR_WrtTime, FILINFO::fdate, DIR::fn, follow_path(), FR_INVALID_NAME, FR_OK, FREE_BUF, DIR::fs, FILINFO::ftime, INIT_BUF, LEAVE_FF, NS, NS_DOT, ST_WORD, sync_fs(), and FATFS::wflag.
Definition at line 2541 of file ff.c.
References ABORT, FIL::buf, FIL::clust, clust2sect(), create_chain(), FATFS::csize, disk_read(), disk_write(), FATFS::drv, FIL::dsect, FA__DIRTY, FA__ERROR, FA__WRITTEN, FA_WRITE, FIL::flag, FIL::fptr, FR_DENIED, FR_DISK_ERR, FR_INT_ERR, FR_OK, FIL::fs, FIL::fsize, LEAVE_FF, mem_cpy(), move_window(), RES_OK, FIL::sclust, SS, sync_window(), validate(), FATFS::wflag, FATFS::win, and FATFS::winsect.
Definition at line 1979 of file ff.c.
References _FS_RPATH, AM_DIR, create_name(), DIR::dir, DIR_Attr, dir_find(), dir_sdi(), DIR::fn, FR_NO_FILE, FR_NO_PATH, FR_OK, DIR::fs, ld_clust(), NS, NS_DOT, NS_LAST, and DIR::sclust.
Referenced by f_chmod(), f_mkdir(), f_open(), f_opendir(), f_rename(), f_stat(), f_unlink(), and f_utime().
Definition at line 842 of file ff.c.
References FATFS::fatbase, FS_FAT12, FS_FAT16, FS_FAT32, FATFS::fs_type, LD_DWORD, LD_WORD, move_window(), FATFS::n_fatent, SS, and FATFS::win.
Referenced by create_chain(), dir_next(), dir_sdi(), f_getfree(), f_lseek(), f_read(), f_truncate(), and remove_chain().
Definition at line 1897 of file ff.c.
References _USE_LFN, DDE, DIR::dir, DIR_Attr, DIR_FileSize, DIR_NTres, DIR_WrtDate, DIR_WrtTime, FILINFO::fattrib, FILINFO::fdate, ff_convert(), FILINFO::fname, FILINFO::fsize, FILINFO::ftime, IsDBCS1, IsDBCS2, IsUpper, LD_DWORD, LD_WORD, NDDE, NS_BODY, NS_EXT, and DIR::sect.
Referenced by f_readdir(), and f_stat().
Definition at line 1239 of file ff.c.
References DIR_FstClusHI, DIR_FstClusLO, FS_FAT32, FATFS::fs_type, and LD_WORD.
Referenced by f_open(), f_opendir(), f_rename(), f_unlink(), and follow_path().
|
static |
Definition at line 565 of file ff.c.
Referenced by dir_find().
|
static |
Definition at line 539 of file ff.c.
Referenced by dir_register(), f_mkdir(), f_read(), f_rename(), f_unlink(), and f_write().
|
static |
Definition at line 556 of file ff.c.
Referenced by create_name(), dir_next(), dir_register(), f_mkdir(), and sync_fs().
Definition at line 758 of file ff.c.
References disk_read(), FATFS::drv, FR_DISK_ERR, FR_OK, RES_OK, sync_window(), FATFS::win, and FATFS::winsect.
Referenced by dir_alloc(), dir_find(), dir_read(), dir_register(), dir_remove(), f_getfree(), f_open(), f_read(), f_rename(), f_sync(), f_write(), get_fat(), and put_fat().
Definition at line 885 of file ff.c.
References FATFS::fatbase, FR_INT_ERR, FR_OK, FS_FAT12, FS_FAT16, FS_FAT32, FATFS::fs_type, LD_DWORD, move_window(), FATFS::n_fatent, SS, ST_DWORD, ST_WORD, FATFS::wflag, and FATFS::win.
Referenced by create_chain(), f_truncate(), and remove_chain().
Definition at line 948 of file ff.c.
References clust2sect(), FATFS::csize, CTRL_ERASE_SECTOR, disk_ioctl(), FATFS::drv, FR_DISK_ERR, FR_INT_ERR, FR_OK, FATFS::free_clust, FATFS::fsi_flag, get_fat(), FATFS::n_fatent, and put_fat().
Referenced by f_mkdir(), f_open(), f_truncate(), and f_unlink().
Definition at line 1256 of file ff.c.
References DIR_FstClusHI, DIR_FstClusLO, and ST_WORD.
Referenced by f_mkdir(), f_open(), f_rename(), and f_sync().
Definition at line 784 of file ff.c.
References BS_55AA, CTRL_SYNC, disk_ioctl(), disk_write(), FATFS::drv, FR_DISK_ERR, FR_OK, FATFS::free_clust, FS_FAT32, FATFS::fs_type, FATFS::fsi_flag, FSI_Free_Count, FSI_LeadSig, FSI_Nxt_Free, FATFS::fsi_sector, FSI_StrucSig, FATFS::last_clust, mem_set(), RES_OK, ST_DWORD, ST_WORD, sync_window(), FATFS::win, and FATFS::winsect.
Referenced by f_chmod(), f_mkdir(), f_rename(), f_sync(), f_unlink(), and f_utime().
Definition at line 732 of file ff.c.
References disk_write(), FATFS::drv, FATFS::fatbase, FR_DISK_ERR, FR_OK, FATFS::fsize, FATFS::n_fats, RES_OK, FATFS::wflag, FATFS::win, and FATFS::winsect.
Referenced by dir_next(), f_mkdir(), f_write(), move_window(), and sync_fs().
|
static |
Definition at line 2235 of file ff.c.
References disk_status(), FATFS::drv, ENTER_FF, FR_INVALID_OBJECT, FR_NOT_READY, FR_OK, FIL::fs, FATFS::fs_type, FATFS::id, FIL::id, and STA_NOINIT.
Referenced by f_close(), f_lseek(), f_read(), f_readdir(), f_sync(), f_truncate(), and f_write().
|
static |
Definition at line 476 of file ff.c.
Referenced by chk_mounted().