summaryrefslogtreecommitdiffstats
path: root/sys/dev/vinum/vinumioctl.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/vinum/vinumioctl.c')
-rw-r--r--sys/dev/vinum/vinumioctl.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/sys/dev/vinum/vinumioctl.c b/sys/dev/vinum/vinumioctl.c
index 3eaab40..b626b1e 100644
--- a/sys/dev/vinum/vinumioctl.c
+++ b/sys/dev/vinum/vinumioctl.c
@@ -384,10 +384,18 @@ vinumioctl(dev_t dev,
return EIO; /* I/O error */
switch (cmd) {
- case DIOCGDINFO: /* get disk label */
+ case DIOCGDVIRGIN: /* get disk label */
get_volume_label(vol->name, vol->plexes, vol->size, (struct disklabel *) data);
break;
+ case DIOCGMEDIASIZE:
+ *(off_t *)data = vol->size << DEV_BSHIFT;
+ break;
+
+ case DIOCGSECTORSIZE:
+ *(u_int *)data = DEV_BSIZE;
+ break;
+
/*
* We don't have this stuff on hardware,
* so just pretend to do it so that
OpenPOWER on IntegriCloud