---
name: "BUF_REFCNT"
section: "9"
platform: "linux"
package: "freebsd-manpages"
version: "6.0-5"
release: "Debian 4.0 (Etch)"
platforms: ["linux"]
url: "https://new.carta.tech/BUF_REFCNT"
---

# BUF\_REFCNT(9)

returns the reference count on a buffer's lock

## NAME

**BUF\_REFCNT** – returns the reference count on a buffer's lock

## SYNOPSIS

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

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

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

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

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

*int*\

**BUF\_REFCNT**(*struct buf \*bp*);

## DESCRIPTION

The **BUF\_REFCNT**() function returns the reference count on a buffer's lock.

Its argument is:

- *bp*

  The buffer whose lock reference count is to be returned.

## SEE ALSO

[buf(9)](/buf/9.md), [BUF\_LOCK(9)](/BUF_LOCK/9.md), [BUF\_TIMELOCK(9)](/BUF_TIMELOCK/9.md), [BUF\_UNLOCK(9)](/BUF_UNLOCK/9.md), [lockcount(9)](/lockcount/9.md)

## AUTHORS

This manual page was written by Chad David ⟨davidc@acns.ab.ca⟩.
