That is only if the write is to a file within a partition mounted
as an FFS file system. vn_write() contains the VOP_WRITE switch, which
will switch to the write implementation based on the vnode type. VOP_WRITE
calls through the function hanging off the vnode in the vnode op
vector at the offset specified by vop_write_desc (record defined in
sys/compile/GENERIC/vnode_if.c -- generated by a perl script from
sys/kern/vnode_if.src during kernel build). Finding out which write
implementation is actually hanging off the vnode for the raw device is
left as an exercise for the reader.

-Chris


On Tue, 19 Sep 2000, Marc Tardif wrote:

> >From The Design and Implementation of the 4.4BSD Operating System, the
> write(2) system call must go through vn_write(), ffs_write(),
> ffs_balloc(), cluster(), bio() and finally dev() which performs the actual
> disk write. Considering all this block-oriented overhead, how can dd(1)
> which calls write(2), perform raw io on devices such as /dev/rwd0? Doesn't
> write(2) confine the process to block io by its very nature?
> 
> 
> 
> To Unsubscribe: send mail to [EMAIL PROTECTED]
> with "unsubscribe freebsd-hackers" in the body of the message
> 



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message

Reply via email to