summaryrefslogtreecommitdiff
path: root/super1.c
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2009-12-21 10:23:26 -0700
committerDan Williams <dan.j.williams@intel.com>2009-12-21 10:23:26 -0700
commitb7528a20cca58c973771d94d7d2b8ef74bcf582d (patch)
treec49e951944dfe3aa7a8659453f7874ac041f98cc /super1.c
parente1516be1db121e6f462b41a739106e33461a733a (diff)
downloadmdadm-b7528a20cca58c973771d94d7d2b8ef74bcf582d.tar.gz
Introduce MaxSector
Replace occurrences of ~0ULL to make it clear we are talking about maximal resync/recovery position. Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'super1.c')
-rw-r--r--super1.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/super1.c b/super1.c
index 2c992a4..85bb598 100644
--- a/super1.c
+++ b/super1.c
@@ -659,9 +659,9 @@ static int update_super1(struct supertype *st, struct mdinfo *info,
switch(__le32_to_cpu(sb->level)) {
case 5: case 4: case 6:
/* need to force clean */
- if (sb->resync_offset != ~0ULL)
+ if (sb->resync_offset != MaxSector)
rv = 1;
- sb->resync_offset = ~0ULL;
+ sb->resync_offset = MaxSector;
}
}
if (strcmp(update, "assemble")==0) {
@@ -855,7 +855,7 @@ static int init_super1(struct supertype *st, mdu_array_info_t *info,
sb->utime = sb->ctime;
sb->events = __cpu_to_le64(1);
if (info->state & (1<<MD_SB_CLEAN))
- sb->resync_offset = ~0ULL;
+ sb->resync_offset = MaxSector;
else
sb->resync_offset = 0;
sb->max_dev = __cpu_to_le32((1024- sizeof(struct mdp_superblock_1))/