internal.h (7e508f2ca8bbda8cabbd4753bc727a7f66837a12) | internal.h (cd913c76f489def1a388e3a5b10df94948ede3f5) |
---|---|
1/* SPDX-License-Identifier: GPL-2.0-only */ 2/* 3 * Copyright (C) 2017-2018 HUAWEI, Inc. 4 * https://www.huawei.com/ 5 * Copyright (C) 2021, Alibaba Cloud 6 */ 7#ifndef __EROFS_INTERNAL_H 8#define __EROFS_INTERNAL_H --- 37 unchanged lines hidden (view full) --- 46typedef u64 erofs_off_t; 47/* data type for filesystem-wide blocks number */ 48typedef u32 erofs_blk_t; 49 50struct erofs_device_info { 51 char *path; 52 struct block_device *bdev; 53 struct dax_device *dax_dev; | 1/* SPDX-License-Identifier: GPL-2.0-only */ 2/* 3 * Copyright (C) 2017-2018 HUAWEI, Inc. 4 * https://www.huawei.com/ 5 * Copyright (C) 2021, Alibaba Cloud 6 */ 7#ifndef __EROFS_INTERNAL_H 8#define __EROFS_INTERNAL_H --- 37 unchanged lines hidden (view full) --- 46typedef u64 erofs_off_t; 47/* data type for filesystem-wide blocks number */ 48typedef u32 erofs_blk_t; 49 50struct erofs_device_info { 51 char *path; 52 struct block_device *bdev; 53 struct dax_device *dax_dev; |
54 u64 dax_part_off; |
|
54 55 u32 blocks; 56 u32 mapped_blkaddr; 57}; 58 59struct erofs_mount_opts { 60#ifdef CONFIG_EROFS_FS_ZIP 61 /* current strategy of how to use managed cache */ --- 42 unchanged lines hidden (view full) --- 104 105 /* pseudo inode to manage cached pages */ 106 struct inode *managed_cache; 107 108 struct erofs_sb_lz4_info lz4; 109#endif /* CONFIG_EROFS_FS_ZIP */ 110 struct erofs_dev_context *devs; 111 struct dax_device *dax_dev; | 55 56 u32 blocks; 57 u32 mapped_blkaddr; 58}; 59 60struct erofs_mount_opts { 61#ifdef CONFIG_EROFS_FS_ZIP 62 /* current strategy of how to use managed cache */ --- 42 unchanged lines hidden (view full) --- 105 106 /* pseudo inode to manage cached pages */ 107 struct inode *managed_cache; 108 109 struct erofs_sb_lz4_info lz4; 110#endif /* CONFIG_EROFS_FS_ZIP */ 111 struct erofs_dev_context *devs; 112 struct dax_device *dax_dev; |
113 u64 dax_part_off; |
|
112 u64 total_blocks; 113 u32 primarydevice_blocks; 114 115 u32 meta_blkaddr; 116#ifdef CONFIG_EROFS_FS_XATTR 117 u32 xattr_blkaddr; 118#endif 119 u16 device_id_mask; /* valid bits of device id to be used */ --- 133 unchanged lines hidden (view full) --- 253} 254 255#define EROFS_FEATURE_FUNCS(name, compat, feature) \ 256static inline bool erofs_sb_has_##name(struct erofs_sb_info *sbi) \ 257{ \ 258 return sbi->feature_##compat & EROFS_FEATURE_##feature; \ 259} 260 | 114 u64 total_blocks; 115 u32 primarydevice_blocks; 116 117 u32 meta_blkaddr; 118#ifdef CONFIG_EROFS_FS_XATTR 119 u32 xattr_blkaddr; 120#endif 121 u16 device_id_mask; /* valid bits of device id to be used */ --- 133 unchanged lines hidden (view full) --- 255} 256 257#define EROFS_FEATURE_FUNCS(name, compat, feature) \ 258static inline bool erofs_sb_has_##name(struct erofs_sb_info *sbi) \ 259{ \ 260 return sbi->feature_##compat & EROFS_FEATURE_##feature; \ 261} 262 |
261EROFS_FEATURE_FUNCS(zero_padding, incompat, INCOMPAT_ZERO_PADDING) | 263EROFS_FEATURE_FUNCS(lz4_0padding, incompat, INCOMPAT_LZ4_0PADDING) |
262EROFS_FEATURE_FUNCS(compr_cfgs, incompat, INCOMPAT_COMPR_CFGS) 263EROFS_FEATURE_FUNCS(big_pcluster, incompat, INCOMPAT_BIG_PCLUSTER) 264EROFS_FEATURE_FUNCS(device_table, incompat, INCOMPAT_DEVICE_TABLE) 265EROFS_FEATURE_FUNCS(sb_chksum, compat, COMPAT_SB_CHKSUM) 266 267/* atomic flag definitions */ 268#define EROFS_I_EA_INITED_BIT 0 269#define EROFS_I_Z_INITED_BIT 1 --- 302 unchanged lines hidden --- | 264EROFS_FEATURE_FUNCS(compr_cfgs, incompat, INCOMPAT_COMPR_CFGS) 265EROFS_FEATURE_FUNCS(big_pcluster, incompat, INCOMPAT_BIG_PCLUSTER) 266EROFS_FEATURE_FUNCS(device_table, incompat, INCOMPAT_DEVICE_TABLE) 267EROFS_FEATURE_FUNCS(sb_chksum, compat, COMPAT_SB_CHKSUM) 268 269/* atomic flag definitions */ 270#define EROFS_I_EA_INITED_BIT 0 271#define EROFS_I_Z_INITED_BIT 1 --- 302 unchanged lines hidden --- |