mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-02 01:18:26 +03:00
Revert "thin: display highest mapped sector"
This reverts commit fc7dacaa4c
.
Let's put this information into a separate field. It doesn't meet the
definition of the existing field.
This commit is contained in:
parent
42f04a0f77
commit
60befab773
@ -1,6 +1,5 @@
|
||||
Version 2.02.149 -
|
||||
==================================
|
||||
Report highest mapping for thin volume as Meta%.
|
||||
Do not flush thin-pool when checking metadata fullness.
|
||||
Remove spurious error about no value in /sys/dev/block/major:minor/dm/uuid.
|
||||
Fix device mismatch detection for LV if persistent .cache file is used.
|
||||
|
@ -938,10 +938,6 @@ static int _percent_run(struct dev_manager *dm, const char *name,
|
||||
if (!segtype->ops->target_percent)
|
||||
continue;
|
||||
|
||||
/* For thin volume pass device size via 'total_numerator' */
|
||||
if (!seg && segtype_is_thin_volume(segtype))
|
||||
total_numerator = length - 1; /* highest mapped is 0 .. (length - 1) */
|
||||
|
||||
if (!segtype->ops->target_percent(&dm->target_state,
|
||||
&percent, dm->mem,
|
||||
dm->cmd, seg, params,
|
||||
|
@ -613,7 +613,7 @@ static int _thin_add_target_line(struct dev_manager *dm,
|
||||
static int _thin_target_percent(void **target_state __attribute__((unused)),
|
||||
dm_percent_t *percent,
|
||||
struct dm_pool *mem,
|
||||
struct cmd_context *cmd,
|
||||
struct cmd_context *cmd __attribute__((unused)),
|
||||
struct lv_segment *seg,
|
||||
char *params,
|
||||
uint64_t *total_numerator,
|
||||
@ -643,18 +643,15 @@ static int _thin_target_percent(void **target_state __attribute__((unused)),
|
||||
|
||||
*percent = dm_make_percent(s->mapped_sectors, csize);
|
||||
*total_denominator += csize;
|
||||
*total_numerator += s->mapped_sectors;
|
||||
} else {
|
||||
/* Using denominator to pass the mapped info upward? */
|
||||
if (s->highest_mapped_sector > *total_numerator) {
|
||||
log_warn("WARNING: highest mapped sector %s is above device size.",
|
||||
display_size(cmd, s->highest_mapped_sector));
|
||||
s->highest_mapped_sector = *total_numerator;
|
||||
}
|
||||
*percent = dm_make_percent(s->highest_mapped_sector, *total_numerator);
|
||||
/* No lv_segment info here */
|
||||
*percent = DM_PERCENT_INVALID;
|
||||
/* FIXME: Using denominator to pass the mapped info upward? */
|
||||
*total_denominator += s->highest_mapped_sector;
|
||||
}
|
||||
|
||||
*total_numerator += s->mapped_sectors;
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user