summaryrefslogtreecommitdiff
path: root/firmware
diff options
context:
space:
mode:
Diffstat (limited to 'firmware')
-rw-r--r--firmware/common/file.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/firmware/common/file.c b/firmware/common/file.c
index a5d9443aeb..9d18c613bf 100644
--- a/firmware/common/file.c
+++ b/firmware/common/file.c
@@ -24,6 +24,15 @@
24#include "dir.h" 24#include "dir.h"
25#include "debug.h" 25#include "debug.h"
26 26
27/*
28 These functions provide a roughly POSIX-compatible file IO API.
29
30 Since the fat32 driver only manages sectors, we maintain a one-sector
31 cache for each open file. This way we can provide byte access without
32 having to re-read the sector each time.
33 The penalty is the RAM used for the cache and slightly more complex code.
34*/
35
27#define MAX_OPEN_FILES 4 36#define MAX_OPEN_FILES 4
28 37
29struct filedesc { 38struct filedesc {