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

# device\_get\_ivars(9)

access bus private variables

## NAME

**device\_get\_ivars**, **device\_set\_ivars** – access bus private variables

## SYNOPSIS

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

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

*void \**\

**device\_get\_ivars**(*device\_t dev*);

*void*\

**device\_set\_ivars**(*device\_t dev*, *void \*ivar*);

## DESCRIPTION

The **device\_get\_ivars**() function returns the bus-specific instance variables of a device.

The **device\_set\_ivars**() function sets the bus-specific instance variables of a device.

Typically, only bus drivers will use these functions. The kernel assumes that the bus driver will manage this memory, and no automatic memory allocation or deallocation happens. Client drivers should access ivars through the [BUS\_READ\_IVAR(9)](/BUS_READ_IVAR/9.md) interface instead.

## SEE ALSO

[device(9)](/device/9.md)

## AUTHORS

This manual page was written by Doug Rabson.
