if (inlinedata_fs && (inode->i_flags & EXT4_INLINE_DATA_FL)) {
size_t size;
__u32 dotdot;
- unsigned int rec_len;
+ unsigned int rec_len2;
struct ext2_dir_entry de;
if (ext2fs_inline_data_size(ctx->fs, pctx->ino, &size))
dotdot = ext2fs_le32_to_cpu(dotdot);
de.inode = ext2fs_le32_to_cpu(de.inode);
de.rec_len = ext2fs_le16_to_cpu(de.rec_len);
- ext2fs_get_rec_len(ctx->fs, &de, &rec_len);
+ ext2fs_get_rec_len(ctx->fs, &de, &rec_len2);
if (dotdot >= ctx->fs->super->s_inodes_count ||
(dotdot < EXT2_FIRST_INO(ctx->fs->super) &&
dotdot != EXT2_ROOT_INO) ||
de.inode >= ctx->fs->super->s_inodes_count ||
(de.inode < EXT2_FIRST_INO(ctx->fs->super) &&
de.inode != 0) ||
- rec_len > EXT4_MIN_INLINE_DATA_SIZE -
+ rec_len2 > EXT4_MIN_INLINE_DATA_SIZE -
EXT4_INLINE_DATA_DOTDOT_SIZE)
return;
/* device files never have a "system.data" entry */
sizeof(struct process_inode_block), process_inode_cmp);
clear_problem_context(&pctx);
for (i=0; i < process_inode_count; i++) {
- pctx.inode = ctx->stashed_inode = &inodes_to_process[i].inode;
+ pctx.inode = ctx->stashed_inode =
+ (struct ext2_inode *) &inodes_to_process[i].inode;
pctx.ino = ctx->stashed_ino = inodes_to_process[i].ino;
#if 0
* inodes, so it's OK to pass NULL to
* ext2fs_file_acl_block() here.
*/
- ret = ext2fs_file_acl_block(0, &(ib_a->inode)) -
- ext2fs_file_acl_block(0, &(ib_b->inode));
+ ret = ext2fs_file_acl_block(0, ext2fs_const_inode(&ib_a->inode)) -
+ ext2fs_file_acl_block(0, ext2fs_const_inode(&ib_b->inode));
if (ret == 0)
ret = ib_a->ino - ib_b->ino;
return ret;
#define JFS_FEATURE_INCOMPAT_CSUM_V2 0x00000008
#define JFS_FEATURE_INCOMPAT_CSUM_V3 0x00000010
+/* Features known to this kernel version: */
+#define JFS_KNOWN_COMPAT_FEATURES 0
+#define JFS_KNOWN_ROCOMPAT_FEATURES 0
+#define JFS_KNOWN_INCOMPAT_FEATURES (JFS_FEATURE_INCOMPAT_REVOKE|\
+ JFS_FEATURE_INCOMPAT_ASYNC_COMMIT|\
+ JFS_FEATURE_INCOMPAT_64BIT|\
+ JFS_FEATURE_INCOMPAT_CSUM_V2|\
+ JFS_FEATURE_INCOMPAT_CSUM_V3)
+
+
+
+#if (defined(E2FSCK_INCLUDE_INLINE_FUNCS) || !defined(NO_INLINE_FUNCS))
+#ifdef E2FSCK_INCLUDE_INLINE_FUNCS
+#if (__STDC_VERSION__ >= 199901L)
+#define _INLINE_ extern inline
+#else
+#define _INLINE_ inline
+#endif
+#else /* !E2FSCK_INCLUDE_INLINE FUNCS */
+#if (__STDC_VERSION__ >= 199901L)
+#define _INLINE_ inline
+#else /* not C99 */
+#ifdef __GNUC__
+#define _INLINE_ extern __inline__
+#else /* For Watcom C */
+#define _INLINE_ extern inline
+#endif /* __GNUC__ */
+#endif /* __STDC_VERSION__ >= 199901L */
+#endif /* INCLUDE_INLINE_FUNCS */
+
/* journal feature predicate functions */
#define JFS_FEATURE_COMPAT_FUNCS(name, flagname) \
-static inline int jfs_has_feature_##name(journal_t *j) \
+_INLINE_ int jfs_has_feature_##name(journal_t *j) \
{ \
return ((j)->j_format_version >= 2 && \
((j)->j_superblock->s_feature_compat & \
ext2fs_cpu_to_be32(JFS_FEATURE_COMPAT_##flagname)) != 0); \
} \
-static inline void jfs_set_feature_##name(journal_t *j) \
+_INLINE_ void jfs_set_feature_##name(journal_t *j) \
{ \
(j)->j_superblock->s_feature_compat |= \
ext2fs_cpu_to_be32(JFS_FEATURE_COMPAT_##flagname); \
} \
-static inline void jfs_clear_feature_##name(journal_t *j) \
+_INLINE_ void jfs_clear_feature_##name(journal_t *j) \
{ \
(j)->j_superblock->s_feature_compat &= \
~ext2fs_cpu_to_be32(JFS_FEATURE_COMPAT_##flagname); \
}
#define JFS_FEATURE_RO_COMPAT_FUNCS(name, flagname) \
-static inline int jfs_has_feature_##name(journal_t *j) \
+ _INLINE_ int jfs_has_feature_##name(journal_t *j) \
{ \
return ((j)->j_format_version >= 2 && \
((j)->j_superblock->s_feature_ro_compat & \
ext2fs_cpu_to_be32(JFS_FEATURE_RO_COMPAT_##flagname)) != 0); \
} \
-static inline void jfs_set_feature_##name(journal_t *j) \
+_INLINE_ void jfs_set_feature_##name(journal_t *j) \
{ \
(j)->j_superblock->s_feature_ro_compat |= \
ext2fs_cpu_to_be32(JFS_FEATURE_RO_COMPAT_##flagname); \
} \
-static inline void jfs_clear_feature_##name(journal_t *j) \
+_INLINE_ void jfs_clear_feature_##name(journal_t *j) \
{ \
(j)->j_superblock->s_feature_ro_compat &= \
~ext2fs_cpu_to_be32(JFS_FEATURE_RO_COMPAT_##flagname); \
}
#define JFS_FEATURE_INCOMPAT_FUNCS(name, flagname) \
-static inline int jfs_has_feature_##name(journal_t *j) \
+_INLINE_ int jfs_has_feature_##name(journal_t *j) \
{ \
return ((j)->j_format_version >= 2 && \
((j)->j_superblock->s_feature_incompat & \
ext2fs_cpu_to_be32(JFS_FEATURE_INCOMPAT_##flagname)) != 0); \
} \
-static inline void jfs_set_feature_##name(journal_t *j) \
+_INLINE_ void jfs_set_feature_##name(journal_t *j) \
{ \
(j)->j_superblock->s_feature_incompat |= \
ext2fs_cpu_to_be32(JFS_FEATURE_INCOMPAT_##flagname); \
} \
-static inline void jfs_clear_feature_##name(journal_t *j) \
+_INLINE_ void jfs_clear_feature_##name(journal_t *j) \
{ \
(j)->j_superblock->s_feature_incompat &= \
~ext2fs_cpu_to_be32(JFS_FEATURE_INCOMPAT_##flagname); \
JFS_FEATURE_INCOMPAT_FUNCS(csum2, CSUM_V2)
JFS_FEATURE_INCOMPAT_FUNCS(csum3, CSUM_V3)
-/* Features known to this kernel version: */
-#define JFS_KNOWN_COMPAT_FEATURES 0
-#define JFS_KNOWN_ROCOMPAT_FEATURES 0
-#define JFS_KNOWN_INCOMPAT_FEATURES (JFS_FEATURE_INCOMPAT_REVOKE|\
- JFS_FEATURE_INCOMPAT_ASYNC_COMMIT|\
- JFS_FEATURE_INCOMPAT_64BIT|\
- JFS_FEATURE_INCOMPAT_CSUM_V2|\
- JFS_FEATURE_INCOMPAT_CSUM_V3)
-
-#if (defined(E2FSCK_INCLUDE_INLINE_FUNCS) || !defined(NO_INLINE_FUNCS))
-#ifdef E2FSCK_INCLUDE_INLINE_FUNCS
-#if (__STDC_VERSION__ >= 199901L)
-#define _INLINE_ extern inline
-#else
-#define _INLINE_ inline
-#endif
-#else /* !E2FSCK_INCLUDE_INLINE FUNCS */
-#if (__STDC_VERSION__ >= 199901L)
-#define _INLINE_ inline
-#else /* not C99 */
-#ifdef __GNUC__
-#define _INLINE_ extern __inline__
-#else /* For Watcom C */
-#define _INLINE_ extern inline
-#endif /* __GNUC__ */
-#endif /* __STDC_VERSION__ >= 199901L */
-#endif /* INCLUDE_INLINE_FUNCS */
-
/*
* helper functions to deal with 32 or 64bit block numbers.
*/
-static inline size_t journal_tag_bytes(journal_t *journal)
+_INLINE_ size_t journal_tag_bytes(journal_t *journal)
{
size_t sz;
return sz - sizeof(__u32);
}
-static inline int journal_has_csum_v2or3(journal_t *journal)
+_INLINE_ int journal_has_csum_v2or3(journal_t *journal)
{
if (jfs_has_feature_csum2(journal) || jfs_has_feature_csum3(journal))
return 1;
return 0;
}
-#undef _INLINE_
-#endif
-static inline int tid_gt(tid_t x, tid_t y) EXT2FS_ATTR((unused));
-static inline int tid_geq(tid_t x, tid_t y) EXT2FS_ATTR((unused));
+_INLINE_ int tid_gt(tid_t x, tid_t y) EXT2FS_ATTR((unused));
+_INLINE_ int tid_geq(tid_t x, tid_t y) EXT2FS_ATTR((unused));
/* Comparison functions for transaction IDs: perform comparisons using
* modulo arithmetic so that they work over sequence number wraps. */
-static inline int tid_gt(tid_t x, tid_t y)
+_INLINE_ int tid_gt(tid_t x, tid_t y)
{
int difference = (x - y);
return (difference > 0);
}
-static inline int tid_geq(tid_t x, tid_t y)
+_INLINE_ int tid_geq(tid_t x, tid_t y)
{
int difference = (x - y);
return (difference >= 0);
}
+#undef _INLINE_
+#endif
+
extern int journal_blocks_per_page(struct inode *inode);
/*