]> git.ipfire.org Git - thirdparty/mdadm.git/commit - Detail.c
Fix the used device size in mdadm -D output.
authorNeilBrown <neilb@suse.de>
Sun, 1 Feb 2009 23:03:20 +0000 (10:03 +1100)
committerNeilBrown <neilb@suse.de>
Sun, 1 Feb 2009 23:03:20 +0000 (10:03 +1100)
commita1236192111a8425e6c6d81c44103e9f4a2f465c
treec7adf978c8f0f620c0a971fab741e5ba9ee24b98
parent2df1f269113c687e0c23fad2ca9bcf3c4dcbb382
Fix the used device size in mdadm -D output.

As get_component_size() returns the number of used sectors of a device
we need halve before pringing as K, and shift the value by 9, not 10,
before passing to human_size.

Thanks to Andre Noll <maan@systemlinux.org> for identifying problem
(and a slightly different version of this patch)

Signed-off-by: NeilBrown <neilb@suse.de>
Detail.c