/* SPDX-License-Identifier: GPL-2.0-or-later */ /* * Copyright (C) International Business Machines Corp., 2000-2003 */ #ifndef _H_JFS_FILSYS #define _H_JFS_FILSYS /* * jfs_filsys.h * * file system (implementation-dependent) constants * * refer to <limits.h> for system wide implementation-dependent constants */ /* * file system option (superblock flag) */ /* directory option */ #define JFS_UNICODE … /* mount time flags for error handling */ #define JFS_ERR_REMOUNT_RO … #define JFS_ERR_CONTINUE … #define JFS_ERR_PANIC … /* Quota support */ #define JFS_USRQUOTA … #define JFS_GRPQUOTA … /* mount time flag to disable journaling to disk */ #define JFS_NOINTEGRITY … /* mount time flag to enable TRIM to ssd disks */ #define JFS_DISCARD … /* commit option */ #define JFS_COMMIT … #define JFS_GROUPCOMMIT … #define JFS_LAZYCOMMIT … #define JFS_TMPFS … /* log logical volume option */ #define JFS_INLINELOG … #define JFS_INLINEMOVE … /* Secondary aggregate inode table */ #define JFS_BAD_SAIT … /* sparse regular file support */ #define JFS_SPARSE … /* DASD Limits F226941 */ #define JFS_DASD_ENABLED … #define JFS_DASD_PRIME … /* big endian flag */ #define JFS_SWAP_BYTES … /* Directory index */ #define JFS_DIR_INDEX … /* platform options */ #define JFS_LINUX … #define JFS_DFS … /* Never implemented */ #define JFS_OS2 … /* case-insensitive name/directory support */ #define JFS_AIX … /* * buffer cache configuration */ /* page size */ #ifdef PSIZE #undef PSIZE #endif #define PSIZE … #define L2PSIZE … #define POFFSET … /* buffer page size */ #define BPSIZE … /* * fs fundamental size * * PSIZE >= file system block size >= PBSIZE >= DISIZE */ #define PBSIZE … #define L2PBSIZE … #define DISIZE … #define L2DISIZE … #define IDATASIZE … #define IXATTRSIZE … #define XTPAGE_SIZE … #define log2_PAGESIZE … #define IAG_SIZE … #define IAG_EXTENT_SIZE … #define INOSPERIAG … #define L2INOSPERIAG … #define INOSPEREXT … #define L2INOSPEREXT … #define IXSIZE … #define INOSPERPAGE … #define L2INOSPERPAGE … #define IAGFREELIST_LWM … #define INODE_EXTENT_SIZE … #define NUM_INODE_PER_EXTENT … #define NUM_INODE_PER_IAG … #define MINBLOCKSIZE … #define L2MINBLOCKSIZE … #define MAXBLOCKSIZE … #define L2MAXBLOCKSIZE … #define MAXFILESIZE … #define JFS_LINK_MAX … /* Minimum number of bytes supported for a JFS partition */ #define MINJFS … #define MINJFSTEXT … /* * file system block size -> physical block size */ #define LBOFFSET(x) … #define LBNUMBER(x) … #define LBLK2PBLK(sb,b) … #define PBLK2LBLK(sb,b) … /* size in byte -> last page number */ #define SIZE2PN(size) … /* size in byte -> last file system block number */ #define SIZE2BN(size, l2bsize) … /* * fixed physical block address (physical block size = 512 byte) * * NOTE: since we can't guarantee a physical block size of 512 bytes the use of * these macros should be removed and the byte offset macros used instead. */ #define SUPER1_B … #define AIMAP_B … #define AITBL_B … #define SUPER2_B … #define BMAP_B … /* * SIZE_OF_SUPER defines the total amount of space reserved on disk for the * superblock. This is not the same as the superblock structure, since all of * this space is not currently being used. */ #define SIZE_OF_SUPER … /* * SIZE_OF_AG_TABLE defines the amount of space reserved to hold the AG table */ #define SIZE_OF_AG_TABLE … /* * SIZE_OF_MAP_PAGE defines the amount of disk space reserved for each page of * the inode allocation map (to hold iag) */ #define SIZE_OF_MAP_PAGE … /* * fixed byte offset address */ #define SUPER1_OFF … #define AIMAP_OFF … /* * Control page of aggregate inode map * followed by 1st extent of map */ #define AITBL_OFF … /* * 1st extent of aggregate inode table */ #define SUPER2_OFF … /* * secondary superblock */ #define BMAP_OFF … /* * block allocation map */ /* * The following macro is used to indicate the number of reserved disk blocks at * the front of an aggregate, in terms of physical blocks. This value is * currently defined to be 32K. This turns out to be the same as the primary * superblock's address, since it directly follows the reserved blocks. */ #define AGGR_RSVD_BLOCKS … /* * The following macro is used to indicate the number of reserved bytes at the * front of an aggregate. This value is currently defined to be 32K. This * turns out to be the same as the primary superblock's byte offset, since it * directly follows the reserved blocks. */ #define AGGR_RSVD_BYTES … /* * The following macro defines the byte offset for the first inode extent in * the aggregate inode table. This allows us to find the self inode to find the * rest of the table. Currently this value is 44K. */ #define AGGR_INODE_TABLE_START … /* * fixed reserved inode number */ /* aggregate inode */ #define AGGR_RESERVED_I … #define AGGREGATE_I … #define BMAP_I … #define LOG_I … #define BADBLOCK_I … #define FILESYSTEM_I … /* per fileset inode */ #define FILESET_RSVD_I … #define FILESET_EXT_I … #define ROOT_I … #define ACL_I … #define FILESET_OBJECT_I … #define FIRST_FILESET_INO … /* * directory configuration */ #define JFS_NAME_MAX … #define JFS_PATH_MAX … /* * file system state (superblock state) */ #define FM_CLEAN … #define FM_MOUNT … #define FM_DIRTY … #define FM_LOGREDO … #define FM_EXTENDFS … #define FM_STATE_MAX … #endif /* _H_JFS_FILSYS */