Skip to content

Commit ffafde4

Browse files
author
Gao Xiang
committed
erofs: update documentation
Some on-disk structures, fields have been renamed in v5.4, the corresponding document should be updated as well. Also fix misrespresentation of file time and words about fixed-sized output compression, data inline, etc. Link: https://lore.kernel.org/r/20191207025509.6614-1-hsiangkao@aol.com/ Signed-off-by: Gao Xiang <gaoxiang25@huawei.com>
1 parent 926d165 commit ffafde4

1 file changed

Lines changed: 14 additions & 13 deletions

File tree

‎Documentation/filesystems/erofs.txt‎

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ Here is the main features of EROFS:
2424
- Metadata & data could be mixed by design;
2525

2626
- 2 inode versions for different requirements:
27-
v1 v2
27+
compact (v1) extended (v2)
2828
Inode metadata size: 32 bytes 64 bytes
2929
Max file size: 4 GB 16 EB (also limited by max. vol size)
3030
Max uids/gids: 65536 4294967296
31-
File creation time: no yes (64 + 32-bit timestamp)
31+
File change time: no yes (64 + 32-bit timestamp)
3232
Max hardlinks: 65536 4294967296
3333
Metadata reserved: 4 bytes 14 bytes
3434

@@ -39,7 +39,7 @@ Here is the main features of EROFS:
3939
- Support POSIX.1e ACLs by using xattrs;
4040

4141
- Support transparent file compression as an option:
42-
LZ4 algorithm with 4 KB fixed-output compression for high performance;
42+
LZ4 algorithm with 4 KB fixed-sized output compression for high performance.
4343

4444
The following git tree provides the file system user-space tools under
4545
development (ex, formatting tool mkfs.erofs):
@@ -85,7 +85,7 @@ All data areas should be aligned with the block size, but metadata areas
8585
may not. All metadatas can be now observed in two different spaces (views):
8686
1. Inode metadata space
8787
Each valid inode should be aligned with an inode slot, which is a fixed
88-
value (32 bytes) and designed to be kept in line with v1 inode size.
88+
value (32 bytes) and designed to be kept in line with compact inode size.
8989

9090
Each inode can be directly found with the following formula:
9191
inode offset = meta_blkaddr * block_size + 32 * nid
@@ -117,10 +117,10 @@ may not. All metadatas can be now observed in two different spaces (views):
117117
|-> aligned with 4B
118118

119119
Inode could be 32 or 64 bytes, which can be distinguished from a common
120-
field which all inode versions have -- i_advise:
120+
field which all inode versions have -- i_format:
121121

122122
__________________ __________________
123-
| i_advise | | i_advise |
123+
| i_format | | i_format |
124124
|__________________| |__________________|
125125
| ... | | ... |
126126
| | | |
@@ -129,12 +129,13 @@ may not. All metadatas can be now observed in two different spaces (views):
129129
|__________________| 64 bytes
130130

131131
Xattrs, extents, data inline are followed by the corresponding inode with
132-
proper alignes, and they could be optional for different data mappings,
133-
_currently_ there are totally 3 valid data mappings supported:
132+
proper alignment, and they could be optional for different data mappings.
133+
_currently_ total 4 valid data mappings are supported:
134134

135-
1) flat file data without data inline (no extent);
136-
2) fixed-output size data compression (must have extents);
137-
3) flat file data with tail-end data inline (no extent);
135+
0 flat file data without data inline (no extent);
136+
1 fixed-sized output data compression (with non-compacted indexes);
137+
2 flat file data with tail packing data inline (no extent);
138+
3 fixed-sized output data compression (with compacted indexes, v5.3+).
138139

139140
The size of the optional xattrs is indicated by i_xattr_count in inode
140141
header. Large xattrs or xattrs shared by many different files can be
@@ -182,8 +183,8 @@ introduce another on-disk field at all.
182183

183184
Compression
184185
-----------
185-
Currently, EROFS supports 4KB fixed-output clustersize transparent file
186-
compression, as illustrated below:
186+
Currently, EROFS supports 4KB fixed-sized output transparent file compression,
187+
as illustrated below:
187188

188189
|---- Variant-Length Extent ----|-------- VLE --------|----- VLE -----
189190
clusterofs clusterofs clusterofs

0 commit comments

Comments
 (0)