dgrp_t et_group_next;
/* Scanned inode number */
ext2_ino_t et_inode_number;
- char et_log_buf[2048];
int et_log_length;
+ char et_log_buf[2048];
};
#endif
ext2_ino_t stashed_ino;
struct ext2_inode *stashed_inode;
- /* if @global_ctx is null, this field is unused */
-#ifdef HAVE_PTHREAD
- struct e2fsck_thread thread_info;
-#endif
-
/*
* Location of the lost and found directory
*/
/* Fast commit replay state */
struct e2fsck_fc_replay_state fc_replay_state;
#ifdef HAVE_PTHREAD
- __u32 fs_num_threads;
+ /* if @global_ctx is null, this field is unused */
+ struct e2fsck_thread thread_info;
+ __u32 pfs_num_threads;
+ __u32 mmp_update_thread;
+ int fs_need_locking;
/* serialize fix operation for multiple threads */
- pthread_mutex_t fs_fix_mutex;
+ pthread_rwlock_t fs_fix_rwlock;
/* protect block_found_map, block_dup_map */
pthread_rwlock_t fs_block_map_rwlock;
+ struct e2fsck_thread_info *infos;
#endif
};
extern void e2fsck_pass1(e2fsck_t ctx);
extern void e2fsck_pass1_dupblocks(e2fsck_t ctx, char *block_buf);
+extern void e2fsck_pass1_check_lock(e2fsck_t ctx);
+extern void e2fsck_pass1_check_unlock(e2fsck_t ctx);
extern void e2fsck_pass2(e2fsck_t ctx);
extern void e2fsck_pass3(e2fsck_t ctx);
extern void e2fsck_pass4(e2fsck_t ctx);
int check_init_orphan_file(e2fsck_t ctx);
/* util.c */
-#define E2FSCK_MAX_THREADS (65536)
+#define E2FSCK_MAX_THREADS (65535)
extern void *e2fsck_allocate_memory(e2fsck_t ctx, unsigned long size,
const char *description);
extern int ask(e2fsck_t ctx, const char * string, int def);