libsquashfs 1.3.0
A new set of tools and libraries for working with SquashFS images
|
Contains on-disk data structures for data block management. More...
#include "sqfs/predef.h"
Go to the source code of this file.
Data Structures | |
struct | sqfs_fragment_t |
Data structure that makes up the fragment table entries. More... | |
Macros | |
#define | SQFS_META_BLOCK_SIZE 8192 |
#define | SQFS_IS_BLOCK_COMPRESSED(size) (((size) & (1 << 24)) == 0) |
#define | SQFS_ON_DISK_BLOCK_SIZE(size) ((size) & ((1 << 24) - 1)) |
#define | SQFS_IS_SPARSE_BLOCK(size) (SQFS_ON_DISK_BLOCK_SIZE(size) == 0) |
Enumerations | |
enum | SQFS_BLK_FLAGS { SQFS_BLK_DONT_COMPRESS = 0x0001 , SQFS_BLK_ALIGN = 0x0002 , SQFS_BLK_DONT_FRAGMENT = 0x0004 , SQFS_BLK_DONT_DEDUPLICATE = 0x0008 , SQFS_BLK_IGNORE_SPARSE = 0x0010 , SQFS_BLK_DONT_HASH = 0x0020 , SQFS_BLK_IS_SPARSE = 0x0400 , SQFS_BLK_FIRST_BLOCK = 0x0800 , SQFS_BLK_LAST_BLOCK = 0x1000 , SQFS_BLK_IS_FRAGMENT = 0x2000 , SQFS_BLK_FRAGMENT_BLOCK = 0x4000 , SQFS_BLK_IS_COMPRESSED = 0x8000 , SQFS_BLK_USER_SETTABLE_FLAGS = 0x003F , SQFS_BLK_FLAGS_ALL = 0xFC3F } |
Generic flags that tell the processor what to do with a block and flags that the processor sets when it is done with a block. More... | |
Contains on-disk data structures for data block management.
Definition in file block.h.
#define SQFS_IS_BLOCK_COMPRESSED | ( | size | ) | (((size) & (1 << 24)) == 0) |
#define SQFS_IS_SPARSE_BLOCK | ( | size | ) | (SQFS_ON_DISK_BLOCK_SIZE(size) == 0) |
#define SQFS_ON_DISK_BLOCK_SIZE | ( | size | ) | ((size) & ((1 << 24) - 1)) |
enum SQFS_BLK_FLAGS |
Generic flags that tell the processor what to do with a block and flags that the processor sets when it is done with a block.
Enumerator | |
---|---|
SQFS_BLK_DONT_COMPRESS | Only calculate checksum, do NOT compress the data. If set, the blocks of a file will not be compressed by the sqfs_block_processor_t. |
SQFS_BLK_ALIGN | Align the block on disk to device block size. If set, the sqfs_block_processor_t will add padding before the first block of the affected file and after the last block. |
SQFS_BLK_DONT_FRAGMENT | Don't add the tail end of a file to a fragment block. If set, the sqfs_block_processor_t will always generate a final block for a file, even if it is truncated. It will not add the tail end to a fragment block. |
SQFS_BLK_DONT_DEDUPLICATE | Surpress deduplication. If set on fragments or the last block of a file, it is always written to disk, even if a duplicate copy already exists. |
SQFS_BLK_IGNORE_SPARSE | Supress sparse block detection. If set, sparse blocks are no longer checked and flagged as such and are instead processed like normal blocks. |
SQFS_BLK_DONT_HASH | Don't compute block data checksums. |
SQFS_BLK_IS_SPARSE | Set by the sqfs_block_processor_t if it determines a block of a file to be sparse, i.e. only zero bytes. |
SQFS_BLK_FIRST_BLOCK | Set by the sqfs_block_processor_t on the first block of a file. |
SQFS_BLK_LAST_BLOCK | Set by the sqfs_block_processor_t on the last block of a file. |
SQFS_BLK_IS_FRAGMENT | Set by the sqfs_block_processor_t to indicate that a block is a tail end of a file and the block. |
SQFS_BLK_FRAGMENT_BLOCK | Set by the sqfs_block_processor_t on fragment blocks that it generates. |
SQFS_BLK_IS_COMPRESSED | Set by sqfs_block_processor_t if the block was actually compressed. |
SQFS_BLK_USER_SETTABLE_FLAGS | The combination of all flags that are user settable. |