summaryrefslogtreecommitdiffstats
path: root/share
diff options
context:
space:
mode:
authortrasz <trasz@FreeBSD.org>2012-10-30 13:05:50 +0000
committertrasz <trasz@FreeBSD.org>2012-10-30 13:05:50 +0000
commita46a7a285c3b3aabd7020465006f4cbb36e10b41 (patch)
treea6d6e02e4057ed6758a25711701983bd98cb6931 /share
parent7d2cc01a2440fb35de1c941ce6bd81249f5a0955 (diff)
downloadFreeBSD-src-a46a7a285c3b3aabd7020465006f4cbb36e10b41.zip
FreeBSD-src-a46a7a285c3b3aabd7020465006f4cbb36e10b41.tar.gz
Document disk_resize(9).
Diffstat (limited to 'share')
-rw-r--r--share/man/man9/Makefile3
-rw-r--r--share/man/man9/disk.911
2 files changed, 12 insertions, 2 deletions
diff --git a/share/man/man9/Makefile b/share/man/man9/Makefile
index dc7a1dd..84c0f56 100644
--- a/share/man/man9/Makefile
+++ b/share/man/man9/Makefile
@@ -614,7 +614,8 @@ MLINKS+=devstat.9 devicestat.9 \
MLINKS+=disk.9 disk_alloc.9 \
disk.9 disk_create.9 \
disk.9 disk_destroy.9 \
- disk.9 disk_gone.9
+ disk.9 disk_gone.9 \
+ disk.9 disk_resize.9
MLINKS+=domain.9 DOMAIN_SET.9 \
domain.9 domain_add.9 \
domain.9 pfctlinput.9 \
diff --git a/share/man/man9/disk.9 b/share/man/man9/disk.9
index d383888..659a40d 100644
--- a/share/man/man9/disk.9
+++ b/share/man/man9/disk.9
@@ -27,7 +27,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd February 18, 2004
+.Dd October 30, 2012
.Dt DISK 9
.Os
.Sh NAME
@@ -43,6 +43,8 @@
.Fn disk_gone "struct disk *disk"
.Ft void
.Fn disk_destroy "struct disk *disk"
+.Ft int
+.Fn disk_resize "struct disk *disk" "int flags"
.Sh DESCRIPTION
The disk storage API permits kernel device drivers providing access to
disk-like storage devices to advertise the device to other kernel
@@ -67,6 +69,13 @@ function,
fill in the fields and call
.Fn disk_create
when the device is ready to service requests.
+.Fn disk_resize
+can be called by the driver after modifying
+.Va d_mediasize
+to notify GEOM about the disk capacity change.
+The
+.Fa flags
+field should be set to either M_WAITOK, or M_NOWAIT.
.Fn disk_gone
orphans all of the providers associated with the drive, setting an error
condition of ENXIO in each one.
OpenPOWER on IntegriCloud