---
name: "VOP_STRATEGY"
section: "9freebsd"
platform: "linux"
package: "freebsd-manpages"
version: "12.2-2"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/VOP_STRATEGY/9freebsd"
---

# VOP\_STRATEGY(9freebsd)

read or write a file system buffer

## NAME

**VOP\_STRATEGY** – read or write a file system buffer

## SYNOPSIS

**#include \<sys/param.h\>**

**#include \<sys/vnode.h\>**

*int*\

**VOP\_STRATEGY**(*struct vnode \*vp*, *struct buf \*bp*);

## DESCRIPTION

The arguments are:

- *vp*

  The vnode that the buffer is for.

- *bp*

  The buffer to be read or written.

This call either reads or writes data from a file, depending on the value of *bp-\>b\_io.bio\_cmd*.

The call may block.

## RETURN VALUES

Always zero. Errors should be signalled by setting BIO\_ERROR on b\_ioflags field in struct buf, and setting b\_error to the appropriate errno value.

## SEE ALSO

[buf(9)](/buf/9.md), [vnode(9)](/vnode/9.md)

## AUTHORS

This manual page was written by Doug Rabson.
