Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
F
firmware
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
fpletz
firmware
Commits
7a6b17a6
Verified
Commit
7a6b17a6
authored
5 years ago
by
rahix
Browse files
Options
Downloads
Patches
Plain Diff
docs: Cleanup fatfs docs
Signed-off-by:
Rahix
<
rahix@rahix.de
>
parent
4c977d6a
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
epicardium/epicardium.h
+25
-16
25 additions, 16 deletions
epicardium/epicardium.h
with
25 additions
and
16 deletions
epicardium/epicardium.h
+
25
−
16
View file @
7a6b17a6
...
...
@@ -606,11 +606,12 @@ API(API_FILE_TELL, int epic_file_tell(int fd));
/** */
enum
epic_stat_type
{
/** basically NOENT
* although epic_file_stat returns an error for 'none', the type will still be set
* to none additinally.
* This is also used internally to track open FS objects, where we use ``EPICSTAT_NONE``
* to mark free objects.
/**
* Basically ``ENOENT``. Although :c:func:`epic_file_stat` returns an
* error for 'none', the type will still be set to none additionally.
*
* This is also used internally to track open FS objects, where we use
* ``EPICSTAT_NONE`` to mark free objects.
*/
EPICSTAT_NONE
,
/** normal file */
...
...
@@ -623,17 +624,25 @@ enum epic_stat_type {
struct
epic_stat
{
/** Entity Type: file, directory or none */
enum
epic_stat_type
type
;
/* note about padding & placement of uint32_t size:
* to accomodate for future expansion, we want padding at the end of
* this struct. Since sizeof(enum epic_stat_type) can not be
* assumed to be have a certain size,
* we're placing uint32_t size here so we can be sure it will be at
* offset 4, and therefore the layout of the other fields is predictable.
/*
* Note about padding & placement of uint32_t size:
*
* To accomodate for future expansion, we want padding at the end of
* this struct. Since sizeof(enum epic_stat_type) can not be assumed
* to be have a certain size, we're placing uint32_t size here so we
* can be sure it will be at offset 4, and therefore the layout of the
* other fields is predictable.
*/
/** size in bytes */
/** Size in bytes. */
uint32_t
size
;
/** the FAT volume (will be needed later once we distinguish
* between system and user volume)*/
/**
* Which FAT volume this entity resides on.
*
* (will be needed later once we distinguish between system and user volume)
*/
uint8_t
volume
;
uint8_t
_reserved
[
9
];
};
...
...
@@ -647,10 +656,10 @@ _Static_assert(sizeof(struct epic_stat) == 20, "");
/**
* stat path
*
* :param
const
char* filename: path to stat
* :param char* filename: path to stat
* :param epic_stat* stat: pointer to result
*
* :return: `
0
` on success, negative on error
* :return: `
`0`
` on success, negative on error
*/
API
(
API_FILE_STAT
,
int
epic_file_stat
(
const
char
*
path
,
struct
epic_stat
*
stat
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment