---
name: "device_unregister"
section: "9"
platform: "linux"
package: "linux-manual-3.16"
version: "3.16.56-1+deb8u1"
release: "Debian 8 (Jessie)"
platforms: ["linux"]
url: "https://new.carta.tech/device_unregister"
---

# device\_unregister(9)

unregister device from system.

## NAME

device\_unregister - unregister device from system.

## SYNOPSIS

**void device\_unregister(struct device \*** *dev***);**

## ARGUMENTS

*dev*

device going away.

## DESCRIPTION

We do this in two parts, like we do **device\_register**. First, we remove it from all the subsystems with **device\_del**, then we decrement the reference count via **put\_device**. If that is the final reference count, the device will be cleaned up via **device\_release** above. Otherwise, the structure will stick around until the final reference to the device is dropped.

## COPYRIGHT
