Commit d8cdda3e authored by Artem Bityutskiy's avatar Artem Bityutskiy

UBIFS: re-arrange variables in ubifs_info

This is a cosmetic patch which re-arranges variables in 'struct ubifs_info'
so that all boolean-like variables which are only changed during mounting or
re-mounting to R/W mode are places together. Then they are turned into
bit-fields, which makes the structure a little bit smaller.
Signed-off-by: default avatarArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
parent 3c0eee3f
...@@ -1166,22 +1166,22 @@ struct ubifs_debug_info; ...@@ -1166,22 +1166,22 @@ struct ubifs_debug_info;
* @rp_uid: reserved pool user ID * @rp_uid: reserved pool user ID
* @rp_gid: reserved pool group ID * @rp_gid: reserved pool group ID
* *
* @empty: if the UBI device is empty * @empty: %1 if the UBI device is empty
* @need_recovery: %1 if the file-system needs recovery
* @replaying: %1 during journal replay
* @remounting_rw: %1 while re-mounting from R/O mode to R/W mode
* @always_chk_crc: always check CRCs (while mounting and remounting to R/W
* mode)
* @replay_tree: temporary tree used during journal replay * @replay_tree: temporary tree used during journal replay
* @replay_list: temporary list used during journal replay * @replay_list: temporary list used during journal replay
* @replay_buds: list of buds to replay * @replay_buds: list of buds to replay
* @cs_sqnum: sequence number of first node in the log (commit start node) * @cs_sqnum: sequence number of first node in the log (commit start node)
* @replay_sqnum: sequence number of node currently being replayed * @replay_sqnum: sequence number of node currently being replayed
* @need_recovery: file-system needs recovery
* @replaying: set to %1 during journal replay
* @unclean_leb_list: LEBs to recover when re-mounting R/O mounted FS to R/W * @unclean_leb_list: LEBs to recover when re-mounting R/O mounted FS to R/W
* mode * mode
* @rcvrd_mst_node: recovered master node to write when re-mounting R/O mounted * @rcvrd_mst_node: recovered master node to write when re-mounting R/O mounted
* FS to R/W mode * FS to R/W mode
* @size_tree: inode size information for recovery * @size_tree: inode size information for recovery
* @remounting_rw: set while re-mounting from R/O mode to R/W mode
* @always_chk_crc: always check CRCs (while mounting and remounting to R/W
* mode)
* @mount_opts: UBIFS-specific mount options * @mount_opts: UBIFS-specific mount options
* *
* @dbg: debugging-related information * @dbg: debugging-related information
...@@ -1402,19 +1402,19 @@ struct ubifs_info { ...@@ -1402,19 +1402,19 @@ struct ubifs_info {
gid_t rp_gid; gid_t rp_gid;
/* The below fields are used only during mounting and re-mounting */ /* The below fields are used only during mounting and re-mounting */
int empty; unsigned int empty:1;
unsigned int need_recovery:1;
unsigned int replaying:1;
unsigned int remounting_rw:1;
unsigned int always_chk_crc:1;
struct rb_root replay_tree; struct rb_root replay_tree;
struct list_head replay_list; struct list_head replay_list;
struct list_head replay_buds; struct list_head replay_buds;
unsigned long long cs_sqnum; unsigned long long cs_sqnum;
unsigned long long replay_sqnum; unsigned long long replay_sqnum;
int need_recovery;
int replaying;
struct list_head unclean_leb_list; struct list_head unclean_leb_list;
struct ubifs_mst_node *rcvrd_mst_node; struct ubifs_mst_node *rcvrd_mst_node;
struct rb_root size_tree; struct rb_root size_tree;
int remounting_rw;
int always_chk_crc;
struct ubifs_mount_opts mount_opts; struct ubifs_mount_opts mount_opts;
#ifdef CONFIG_UBIFS_FS_DEBUG #ifdef CONFIG_UBIFS_FS_DEBUG
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment