diff options
Diffstat (limited to 'firmware/include/file_internal.h')
-rw-r--r-- | firmware/include/file_internal.h | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/firmware/include/file_internal.h b/firmware/include/file_internal.h index acec81206e..e7edb3a441 100644 --- a/firmware/include/file_internal.h +++ b/firmware/include/file_internal.h | |||
@@ -136,8 +136,9 @@ enum fildes_and_obj_flags | |||
136 | FF_NOISO = 0x00200000, /* do not decode ISO filenames to UTF-8 */ | 136 | FF_NOISO = 0x00200000, /* do not decode ISO filenames to UTF-8 */ |
137 | FF_PROBE = 0x00400000, /* only test existence; don't open */ | 137 | FF_PROBE = 0x00400000, /* only test existence; don't open */ |
138 | FF_CACHEONLY = 0x00800000, /* succeed only if in dircache */ | 138 | FF_CACHEONLY = 0x00800000, /* succeed only if in dircache */ |
139 | FF_SELFINFO = 0x01000000, /* return info on self as well */ | 139 | FF_INFO = 0x01000000, /* return info on self */ |
140 | FF_MASK = 0x01ff0000, | 140 | FF_PARENTINFO = 0x02000000, /* return info on parent */ |
141 | FF_MASK = 0x03ff0000, | ||
141 | }; | 142 | }; |
142 | 143 | ||
143 | /** Common data structures used throughout **/ | 144 | /** Common data structures used throughout **/ |
@@ -244,18 +245,16 @@ static inline void filestr_unlock(struct filestr_base *stream) | |||
244 | /* structure to return detailed information about what you opened */ | 245 | /* structure to return detailed information about what you opened */ |
245 | struct path_component_info | 246 | struct path_component_info |
246 | { | 247 | { |
247 | const char *name; /* pointer to name within 'path' (OUT) */ | 248 | const char *name; /* OUT: pointer to name within 'path' */ |
248 | size_t length; /* length of component within 'path' */ | 249 | size_t length; /* OUT: length of component within 'path' */ |
249 | file_size_t filesize; /* size of the opened file (0 if dir) */ | 250 | file_size_t filesize; /* OUT: size of the opened file (0 if dir) */ |
250 | unsigned int attr; /* attributes of this component */ | 251 | unsigned int attr; /* OUT: attributes of this component */ |
251 | struct file_base_info *prefixp; /* base info to check as prefix | 252 | struct file_base_info info; /* OUT: base info on file |
252 | (IN if FF_CHECKPREFIX) */ | 253 | (FF_INFO) */ |
253 | union { | 254 | struct file_base_info parentinfo; /* OUT: base parent directory info |
254 | struct file_base_info parentinfo; /* parent directory base info of file | 255 | (FF_PARENTINFO) */ |
255 | (if not FF_SELFINFO) */ | 256 | struct file_base_info *prefixp; /* IN: base info to check as prefix |
256 | struct file_base_info info; /* base info of file itself | 257 | (FF_CHECKPREFIX) */ |
257 | (if FF_SELFINFO) */ | ||
258 | }; | ||
259 | }; | 258 | }; |
260 | 259 | ||
261 | int open_stream_internal(const char *path, unsigned int callflags, | 260 | int open_stream_internal(const char *path, unsigned int callflags, |