Update the physio man page to better reflect reality.
PR: docs/30603 Reviewed by: phk MFC after: 3 days
This commit is contained in:
parent
551858f0b0
commit
e105123179
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=90265
@ -54,16 +54,12 @@ The
|
||||
.Fn physio
|
||||
is a helper function typically called from character device read and write
|
||||
routines to start I/O on a user process buffer.
|
||||
It calls back on the
|
||||
provided
|
||||
.Fa strategy
|
||||
routine one or more times to complete the transfer described by
|
||||
.Fa uio .
|
||||
The maximum amount of data to transfer with each call to
|
||||
.Fa strategy
|
||||
is determined by the
|
||||
.Fa minphys
|
||||
routine.
|
||||
The maximum amount of data to transfer with each call
|
||||
is determined by:
|
||||
.Bd -literal
|
||||
dev->si_iosize_max
|
||||
.Ed
|
||||
.Pp
|
||||
Since
|
||||
.Fa uio
|
||||
normally describes user space addresses,
|
||||
@ -74,38 +70,11 @@ flag on the process.
|
||||
.Fn physio
|
||||
always awaits the completion of the entire requested transfer before
|
||||
returning, unless an error condition is detected earlier.
|
||||
In all cases,
|
||||
the buffer passed in
|
||||
.Fa bp
|
||||
is locked (marked as
|
||||
.Dq busy )
|
||||
for the duration of the entire transfer.
|
||||
.Pp
|
||||
A break-down of the arguments follows:
|
||||
.Bl -tag -width indent
|
||||
.It Fa strategy
|
||||
The device strategy routine to call for each chunk of data to initiate
|
||||
device I/O.
|
||||
.It Fa bp
|
||||
The buffer to use with the strategy routine.
|
||||
The buffer flags will have
|
||||
.Dv B_BUSY ,
|
||||
and
|
||||
.Dv B_PHYS
|
||||
set when passed to the strategy routine.
|
||||
If
|
||||
.Dv NULL ,
|
||||
a buffer is allocated from a system pool.
|
||||
.It Fa dev
|
||||
The device number identifying the device to interact with.
|
||||
.It Fa flags
|
||||
Direction of transfer; the only valid settings are
|
||||
.Dv B_READ
|
||||
or
|
||||
.Dv B_WRITE .
|
||||
.It Fa minphys
|
||||
A device specific routine called to determine the maximum transfer size
|
||||
that the device's strategy routine can handle.
|
||||
.It Fa uio
|
||||
The description of the entire transfer as requested by the user process.
|
||||
Currently, the results of passing a
|
||||
@ -139,3 +108,11 @@ condition.
|
||||
.Sh SEE ALSO
|
||||
.Xr read 2 ,
|
||||
.Xr write 2
|
||||
.Sh HISTORY
|
||||
The
|
||||
.Xr physio 9
|
||||
manual page is originally from NetBSD with minor changes for applicability
|
||||
with FreeBSD.
|
||||
.Pp
|
||||
The physio(9) call has been completely re-written for providing higher
|
||||
I/O performance, and better paging performance.
|
||||
|
Loading…
Reference in New Issue
Block a user