mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
md: don't reference gendisk in getgeo
Using ->array_sectors rather than get_capacity() is more direct and is a step towards relaxing the tight connection between mddev and gendisk. Signed-off-by: NeilBrown <neilb@suse.de>
This commit is contained in:
parent
490773268c
commit
49ce6cea85
1 changed files with 1 additions and 1 deletions
|
@ -5556,7 +5556,7 @@ static int md_getgeo(struct block_device *bdev, struct hd_geometry *geo)
|
|||
|
||||
geo->heads = 2;
|
||||
geo->sectors = 4;
|
||||
geo->cylinders = get_capacity(mddev->gendisk) / 8;
|
||||
geo->cylinders = mddev->array_sectors / 8;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue