/littlefs-3.7.0-3.6.0/tests/ |
D | test_entries.toml | 21 lfs_file_t file; 22 lfs_file_open(&lfs, &file, path, 25 lfs_file_write(&lfs, &file, wbuffer, size) => size; 26 lfs_file_size(&lfs, &file) => size; 27 lfs_file_close(&lfs, &file) => 0; 30 lfs_file_open(&lfs, &file, path, 33 lfs_file_write(&lfs, &file, wbuffer, size) => size; 34 lfs_file_size(&lfs, &file) => size; 35 lfs_file_close(&lfs, &file) => 0; 38 lfs_file_open(&lfs, &file, path, [all …]
|
D | test_seek.toml | 2 # simple file seek 16 lfs_file_t file; 17 lfs_file_open(&lfs, &file, "kitty", 23 lfs_file_write(&lfs, &file, buffer, size); 25 lfs_file_close(&lfs, &file) => 0; 29 lfs_file_open(&lfs, &file, "kitty", LFS_O_RDONLY) => 0; 34 lfs_file_read(&lfs, &file, buffer, size) => size; 36 pos = lfs_file_tell(&lfs, &file); 40 lfs_file_seek(&lfs, &file, pos, LFS_SEEK_SET) => pos; 41 lfs_file_read(&lfs, &file, buffer, size) => size; [all …]
|
D | test_truncate.toml | 10 lfs_file_t file; 11 lfs_file_open(&lfs, &file, "baldynoop", 18 lfs_file_write(&lfs, &file, buffer, lfs_min(size, LARGESIZE-j)) 21 lfs_file_size(&lfs, &file) => LARGESIZE; 23 lfs_file_close(&lfs, &file) => 0; 27 lfs_file_open(&lfs, &file, "baldynoop", LFS_O_RDWR) => 0; 28 lfs_file_size(&lfs, &file) => LARGESIZE; 30 lfs_file_truncate(&lfs, &file, MEDIUMSIZE) => 0; 31 lfs_file_size(&lfs, &file) => MEDIUMSIZE; 33 lfs_file_close(&lfs, &file) => 0; [all …]
|
D | test_files.toml | 7 lfs_file_t file; 8 lfs_file_open(&lfs, &file, "hello", 13 lfs_file_write(&lfs, &file, buffer, size) => size; 14 lfs_file_close(&lfs, &file) => 0; 18 lfs_file_open(&lfs, &file, "hello", LFS_O_RDONLY) => 0; 19 lfs_file_read(&lfs, &file, buffer, size) => size; 21 lfs_file_close(&lfs, &file) => 0; 34 lfs_file_t file; 35 lfs_file_open(&lfs, &file, "avacado", 44 lfs_file_write(&lfs, &file, buffer, chunk) => chunk; [all …]
|
D | test_alloc.toml | 45 lfs_file_t file; 46 lfs_file_open(&lfs, &file, path, LFS_O_RDONLY) => 0; 50 lfs_file_read(&lfs, &file, buffer, size) => size; 53 lfs_file_close(&lfs, &file) => 0; 76 lfs_file_t file; 77 lfs_file_open(&lfs, &file, path, 86 lfs_file_write(&lfs, &file, buffer, size) => size; 88 lfs_file_close(&lfs, &file) => 0; 96 lfs_file_t file; 97 lfs_file_open(&lfs, &file, path, LFS_O_RDONLY) => 0; [all …]
|
D | test_move.toml | 10 lfs_file_t file; 11 lfs_file_open(&lfs, &file, "a/hello", LFS_O_CREAT | LFS_O_WRONLY) => 0; 12 lfs_file_write(&lfs, &file, "hola\n", 5) => 5; 13 lfs_file_write(&lfs, &file, "bonjour\n", 8) => 8; 14 lfs_file_write(&lfs, &file, "ohayo\n", 6) => 6; 15 lfs_file_close(&lfs, &file) => 0; 48 lfs_file_open(&lfs, &file, "a/hello", LFS_O_RDONLY) => LFS_ERR_NOENT; 49 lfs_file_open(&lfs, &file, "b/hello", LFS_O_RDONLY) => LFS_ERR_NOENT; 50 lfs_file_open(&lfs, &file, "c/hello", LFS_O_RDONLY) => 0; 52 lfs_file_read(&lfs, &file, buffer, 5) => 5; [all …]
|
D | test_powerloss.toml | 13 lfs_file_t file; 14 lfs_file_open(&lfs, &file, "notebook/paper", 20 lfs_file_write(&lfs, &file, buffer, size) => size; 21 lfs_file_sync(&lfs, &file) => 0; 23 lfs_file_close(&lfs, &file) => 0; 26 lfs_file_open(&lfs, &file, "notebook/paper", LFS_O_RDONLY) => 0; 28 lfs_file_read(&lfs, &file, rbuffer, size) => size; 31 lfs_file_close(&lfs, &file) => 0; 55 lfs_file_open(&lfs, &file, "notebook/paper", LFS_O_RDONLY) => 0; 57 lfs_file_read(&lfs, &file, rbuffer, size) => size; [all …]
|
D | test_attrs.toml | 7 lfs_file_t file; 8 lfs_file_open(&lfs, &file, "hello/hello", LFS_O_WRONLY | LFS_O_CREAT) => 0; 9 lfs_file_write(&lfs, &file, "hello", strlen("hello")) => strlen("hello"); 10 lfs_file_close(&lfs, &file); 75 lfs_file_open(&lfs, &file, "hello/hello", LFS_O_RDONLY) => 0; 76 lfs_file_read(&lfs, &file, buffer, sizeof(buffer)) => strlen("hello"); 78 lfs_file_close(&lfs, &file); 88 lfs_file_t file; 89 lfs_file_open(&lfs, &file, "hello/hello", LFS_O_WRONLY | LFS_O_CREAT) => 0; 90 lfs_file_write(&lfs, &file, "hello", strlen("hello")) => strlen("hello"); [all …]
|
D | test_compat.toml | 169 lfsp_file_t file; 171 sprintf(name, "file%03d", i); 172 lfsp_file_open(&lfsp, &file, name, 180 lfsp_file_write(&lfsp, &file, chunk, CHUNK) => CHUNK; 182 lfsp_file_close(&lfsp, &file) => 0; 211 sprintf(name, "file%03d", i); 221 lfs_file_t file; 223 sprintf(name, "file%03d", i); 224 lfs_file_open(&lfs, &file, name, LFS_O_RDONLY) => 0; 227 lfs_file_read(&lfs, &file, chunk, CHUNK) => CHUNK; [all …]
|
D | test_exhaustion.toml | 31 lfs_file_t file; 32 lfs_file_open(&lfs, &file, path, 37 lfs_ssize_t res = lfs_file_write(&lfs, &file, &c, 1); 40 int err = lfs_file_close(&lfs, &file); 47 int err = lfs_file_close(&lfs, &file); 62 lfs_file_t file; 63 lfs_file_open(&lfs, &file, path, LFS_O_RDONLY) => 0; 67 lfs_file_read(&lfs, &file, &r, 1) => 1; 71 lfs_file_close(&lfs, &file) => 0; 121 lfs_file_t file; [all …]
|
D | test_badblocks.toml | 39 lfs_file_t file; 40 lfs_file_open(&lfs, &file, (char*)buffer, 45 lfs_file_write(&lfs, &file, buffer, size) => size; 48 lfs_file_close(&lfs, &file) => 0; 68 lfs_file_t file; 69 lfs_file_open(&lfs, &file, (char*)buffer, LFS_O_RDONLY) => 0; 74 lfs_file_read(&lfs, &file, rbuffer, size) => size; 78 lfs_file_close(&lfs, &file) => 0; 119 lfs_file_t file; 120 lfs_file_open(&lfs, &file, (char*)buffer, [all …]
|
D | test_superblocks.toml | 109 lfs_file_t file; 110 lfs_file_open(&lfs, &file, "dummy", 112 lfs_file_close(&lfs, &file) => 0; 123 lfs_file_t file; 124 lfs_file_open(&lfs, &file, "dummy", 126 lfs_file_close(&lfs, &file) => 0; 153 lfs_file_t file; 154 lfs_file_open(&lfs, &file, "dummy", 156 lfs_file_close(&lfs, &file) => 0; 196 lfs_file_t file; [all …]
|
D | test_evil.toml | 73 lfs_file_t file; 74 lfs_file_open(&lfs, &file, "dir_here/file_here", 76 lfs_file_open(&lfs, &file, "dir_here/file_here", 83 defines.SIZE = [10, 1000, 100000] # faked file size 88 // make a file 90 lfs_file_t file; 91 lfs_file_open(&lfs, &file, "file_here", 93 lfs_file_close(&lfs, &file) => 0; 96 // change the file pointer to be invalid 100 // make sure id 1 == our file [all …]
|
D | test_relocations.toml | 11 lfs_file_t file; 12 lfs_file_open(&lfs, &file, "padding", LFS_O_CREAT | LFS_O_WRONLY) => 0; 16 lfs_file_write(&lfs, &file, buffer, 512) => 512; 18 lfs_file_close(&lfs, &file) => 0; 28 lfs_file_open(&lfs, &file, path, LFS_O_CREAT | LFS_O_WRONLY) => 0; 29 lfs_file_close(&lfs, &file) => 0; 89 lfs_file_t file; 90 lfs_file_open(&lfs, &file, "padding", LFS_O_CREAT | LFS_O_WRONLY) => 0; 94 lfs_file_write(&lfs, &file, buffer, 512) => 512; 96 lfs_file_close(&lfs, &file) => 0; [all …]
|
D | test_interspersed.toml | 80 lfs_file_t file; 81 lfs_file_open(&lfs, &file, path, 84 lfs_file_write(&lfs, &file, &alphas[j], 1) => 1; 86 lfs_file_close(&lfs, &file); 91 lfs_file_t file; 92 lfs_file_open(&lfs, &file, "zzz", LFS_O_WRONLY | LFS_O_CREAT) => 0; 94 lfs_file_write(&lfs, &file, (const void*)"~", 1) => 1; 95 lfs_file_sync(&lfs, &file) => 0; 101 lfs_file_close(&lfs, &file); 119 lfs_file_open(&lfs, &file, "zzz", LFS_O_RDONLY) => 0; [all …]
|
/littlefs-3.7.0-3.6.0/ |
D | lfs.c | 556 static lfs_ssize_t lfs_file_flushedwrite(lfs_t *lfs, lfs_file_t *file, 558 static lfs_ssize_t lfs_file_rawwrite(lfs_t *lfs, lfs_file_t *file, 560 static int lfs_file_rawsync(lfs_t *lfs, lfs_file_t *file); 561 static int lfs_file_outline(lfs_t *lfs, lfs_file_t *file); 562 static int lfs_file_flush(lfs_t *lfs, lfs_file_t *file); 584 static lfs_ssize_t lfs_file_flushedread(lfs_t *lfs, lfs_file_t *file, 586 static lfs_ssize_t lfs_file_rawread(lfs_t *lfs, lfs_file_t *file, 588 static int lfs_file_rawclose(lfs_t *lfs, lfs_file_t *file); 589 static lfs_soff_t lfs_file_rawsize(lfs_t *lfs, lfs_file_t *file); 3012 static int lfs_file_rawopencfg(lfs_t *lfs, lfs_file_t *file, argument [all …]
|
D | SPEC.md | 238 _every_ type of metadata, including file entries, directory fields, and 284 3. **Id (10-bits)** - File id associated with the tag. Each file in a metadata 285 block gets a unique id which is used to associate tags with that file. The 287 file, such as directory and global metadata. 299 Creates a new file with this id. Note that files in a metadata block 310 Deletes the file with this id. An inverse to create, this tag moves over 317 Associates the id with a file name and file type. 319 The data contains the file name stored as an ASCII string (may be expanded to 322 The chunk field in this tag indicates an 8-bit file type which can be one of 326 can not be reassigned without deleting the file. [all …]
|
D | lfs.h | 554 int lfs_file_open(lfs_t *lfs, lfs_file_t *file, 571 int lfs_file_opencfg(lfs_t *lfs, lfs_file_t *file, 581 int lfs_file_close(lfs_t *lfs, lfs_file_t *file); 587 int lfs_file_sync(lfs_t *lfs, lfs_file_t *file); 593 lfs_ssize_t lfs_file_read(lfs_t *lfs, lfs_file_t *file, 603 lfs_ssize_t lfs_file_write(lfs_t *lfs, lfs_file_t *file, 611 lfs_soff_t lfs_file_seek(lfs_t *lfs, lfs_file_t *file, 618 int lfs_file_truncate(lfs_t *lfs, lfs_file_t *file, lfs_off_t size); 625 lfs_soff_t lfs_file_tell(lfs_t *lfs, lfs_file_t *file); 631 int lfs_file_rewind(lfs_t *lfs, lfs_file_t *file); [all …]
|
/littlefs-3.7.0-3.6.0/benches/ |
D | bench_file.toml | 14 // first write the file 15 lfs_file_t file; 17 lfs_file_open(&lfs, &file, "file", 25 lfs_file_write(&lfs, &file, buffer, CHUNK_SIZE) => CHUNK_SIZE; 27 lfs_file_write(&lfs, &file, buffer, CHUNK_SIZE) => CHUNK_SIZE; 28 lfs_file_close(&lfs, &file) => 0; 30 // then read the file 32 lfs_file_open(&lfs, &file, "file", LFS_O_RDONLY) => 0; 40 lfs_file_seek(&lfs, &file, i_*CHUNK_SIZE, LFS_SEEK_SET) 42 lfs_file_read(&lfs, &file, buffer, CHUNK_SIZE) => CHUNK_SIZE; [all …]
|
D | bench_dir.toml | 18 sprintf(name, "file%08x", i); 19 lfs_file_t file; 20 lfs_file_open(&lfs, &file, name, 28 lfs_file_write(&lfs, &file, buffer, CHUNK_SIZE) => CHUNK_SIZE; 31 lfs_file_close(&lfs, &file) => 0; 42 sprintf(name, "file%08x", i_); 43 lfs_file_t file; 44 lfs_file_open(&lfs, &file, name, LFS_O_RDONLY) => 0; 48 lfs_file_read(&lfs, &file, buffer, CHUNK_SIZE) => CHUNK_SIZE; 54 lfs_file_close(&lfs, &file) => 0; [all …]
|
/littlefs-3.7.0-3.6.0/scripts/ |
D | perfbd.py | 120 def __new__(cls, file='', function='', line=0, argument 123 return super().__new__(cls, file, function, int(Int(line)), 128 return PerfBdResult(self.file, self.function, self.line, 260 file = os.path.abspath(files.get(op_file, '?')) 261 lines.append((file, op_line, op_addr)) 262 line_at.append((op_addr, file, op_line)) 279 for file, line, addr in lines: 280 if len(lines_) == 0 or lines_[-1][0] != file or lines[-1][1] != line: 281 lines_.append((file, line, addr)) 287 for addr, file, line in line_at: [all …]
|
D | data.py | 119 def __new__(cls, file='', function='', size=0): argument 120 return super().__new__(cls, file, function, 124 return DataResult(self.file, self.function, 162 file = re.sub('(\.o)?$', '.c', path, 1) 184 file, func, 277 file = defs[r.function] 279 _, file = max( 285 file = r.file 290 os.path.abspath(file) == os.path.abspath(s) 297 os.path.abspath(file)]) == os.getcwd(): [all …]
|
D | code.py | 119 def __new__(cls, file='', function='', size=0): argument 120 return super().__new__(cls, file, function, 124 return CodeResult(self.file, self.function, 162 file = re.sub('(\.o)?$', '.c', path, 1) 184 file, func, 277 file = defs[r.function] 279 _, file = max( 285 file = r.file 290 os.path.abspath(file) == os.path.abspath(s) 297 os.path.abspath(file)]) == os.getcwd(): [all …]
|
D | structs.py | 113 def __new__(cls, file='', struct='', size=0): argument 114 return super().__new__(cls, file, struct, 118 return StructResult(self.file, self.struct, 211 file = files.get(s_file, '?') 212 results_.append(StructResult(file, s_name, s_size)) 221 file = files.get(s_file, '?') 222 results_.append(StructResult(file, s_name, s_size)) 234 os.path.abspath(r.file) == os.path.abspath(s) 241 os.path.abspath(r.file)]) == os.getcwd(): 245 if not internal and not r.file.endswith('.h'): [all …]
|
D | perf.py | 132 def __new__(cls, file='', function='', line=0, argument 135 return super().__new__(cls, file, function, int(Int(line)), 140 return PerfResult(self.file, self.function, self.line, 352 file = os.path.abspath(files.get(op_file, '?')) 353 lines.append((file, op_line, op_addr)) 354 line_at.append((op_addr, file, op_line)) 371 for file, line, addr in lines: 372 if len(lines_) == 0 or lines_[-1][0] != file or lines[-1][1] != line: 373 lines_.append((file, line, addr)) 379 for addr, file, line in line_at: [all …]
|