MFC r281698:
Do not report stripe size if it is equal to sector size.
This commit is contained in:
parent
613943f9f1
commit
01924a30ae
@ -712,7 +712,8 @@ vtblk_alloc_disk(struct vtblk_softc *sc, struct virtio_blk_config *blkcfg)
|
||||
dp->d_fwheads = blkcfg->geometry.heads;
|
||||
}
|
||||
|
||||
if (virtio_with_feature(dev, VIRTIO_BLK_F_TOPOLOGY)) {
|
||||
if (virtio_with_feature(dev, VIRTIO_BLK_F_TOPOLOGY) &&
|
||||
blkcfg->topology.physical_block_exp > 0) {
|
||||
dp->d_stripesize = dp->d_sectorsize *
|
||||
(1 << blkcfg->topology.physical_block_exp);
|
||||
dp->d_stripeoffset = (dp->d_stripesize -
|
||||
|
Loading…
Reference in New Issue
Block a user