Lines Matching +full:multi +full:- +full:cluster
1 /* SPDX-License-Identifier: GPL-2.0-only OR Apache-2.0 */
3 * EROFS (Enhanced ROM File System) on-disk format definition
5 * Copyright (C) 2017-2018 HUAWEI, Inc.
55 /* erofs on-disk super block (currently 128 bytes) */
58 __le32 checksum; /* crc32c to avoid unexpected on-disk overlap */
64 __le64 inos; /* total valid ino # (== f_files - f_favail) */
71 __u8 uuid[16]; /* 128-bit uuid for volume */
91 * EROFS inode datalayout (i_format in on-disk inode):
92 * 0 - uncompressed flat inode without tail-packing inline data:
93 * 1 - compressed inode with non-compact indexes:
94 * 2 - uncompressed flat inode with tail-packing inline data:
95 * 3 - compressed inode with compact indexes:
96 * 4 - chunk-based inode with (optional) multi-device support:
97 * 5~7 - reserved
122 #define EROFS_I_ALL ((1 << EROFS_I_ALL_BIT) - 1)
126 /* with chunk indexes or just a 4-byte blkaddr array */
132 /* 32-byte on-disk inode */
134 /* 64-byte on-disk inode */
152 /* for chunk-based files, it contains the summary info */
156 /* 32-byte reduced form of an ondisk inode */
160 /* 1 header + n-1 * 4 bytes inline xattr to keep continuity */
168 __le32 i_ino; /* only used for 32-bit stat compatibility */
174 /* 64-byte complete form of an ondisk inode */
178 /* 1 header + n-1 * 4 bytes inline xattr to keep continuity */
185 __le32 i_ino; /* only used for 32-bit stat compatibility */
196 * erofs_xattr_ibody_header(1) + (n - 1) * 4 bytes
199 * /-----------------------\
201 * +-----------------------+
203 * for read-only fs, no need to introduce h_refcount
206 __le32 h_name_filter; /* bit value 1 indicates not-present */
252 sizeof(__u32) * (le16_to_cpu(i_xattr_icount) - 1); in erofs_xattr_ibody_size()
260 e->e_name_len + le16_to_cpu(e->e_value_size)); in erofs_xattr_entry_size()
264 #define EROFS_NULL_ADDR -1
266 /* 4-byte block address array */
269 /* 8-byte inode chunk indexes */
272 __le16 device_id; /* back-end storage id (with bits masked) */
292 /* maximum supported encoded size of a physical compressed cluster */
295 /* maximum supported decoded size of a physical compressed cluster */
306 #define Z_EROFS_ALL_COMPR_ALGS ((1 << Z_EROFS_COMPRESSION_MAX) - 1)
333 u8 windowlog; /* windowLog - ZSTD_WINDOWLOG_ABSOLUTEMIN(10) */
340 * bit 0 : COMPACTED_2B indexes (0 - off; 1 - on)
341 * e.g. for 4k logical cluster size, 4B if compacted 2B is off;
343 * bit 1 : HEAD1 big pcluster (0 - off; 1 - on)
344 * bit 2 : HEAD2 big pcluster (0 - off; 1 - on)
345 * bit 3 : tailpacking inline pcluster (0 - off; 1 - on)
346 * bit 4 : interlaced plain pcluster (0 - off; 1 - on)
347 * bit 5 : fragment pcluster (0 - off; 1 - on)
369 * bit 0-3 : algorithm type of head 1 (logical cluster type 01);
370 * bit 4-7 : algorithm type of head 2 (logical cluster type 11).
374 * bit 0-2 : logical cluster bits - 12, e.g. 0 for 4096;
375 * bit 3-6 : reserved;
382 * On-disk logical cluster type:
383 * 0 - literal (uncompressed) lcluster
384 * 1,3 - compressed lcluster (for HEAD lclusters)
385 * 2 - compressed lcluster (for NONHEAD lclusters)
388 * 0 - literal (uncompressed) lcluster,
393 * 1,3 - compressed lcluster (for HEAD lclusters)
398 * 2 - compressed lcluster (for NONHEAD lclusters)
413 #define Z_EROFS_LI_LCLUSTER_TYPE_MASK (Z_EROFS_LCLUSTER_TYPE_MAX - 1)
419 * D0_CBLKCNT will be marked _only_ at the 1st non-head lcluster to store the
435 * [0] - distance to its HEAD lcluster
436 * [1] - distance to the next HEAD lcluster
445 /* check the EROFS on-disk layout strictly at compile time */