---
name: "rte_bus_vdev.h"
section: "3"
platform: "linux"
package: "dpdk-doc"
version: "24.11.4-0+deb13u1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/rte_bus_vdev.h"
---

# rte\_bus\_vdev.h(3)

## NAME

rte\_bus\_vdev.h

## SYNOPSIS

### Functions

int **rte\_vdev\_add\_custom\_scan** (rte\_vdev\_scan\_callback callback, void \*user\_arg)\
 int **rte\_vdev\_remove\_custom\_scan** (rte\_vdev\_scan\_callback callback, void \*user\_arg)\
 int **rte\_vdev\_init** (const char \*name, const char \*args)\
 int **rte\_vdev\_uninit** (const char \*name)\

## Detailed Description

RTE virtual bus API

Definition in file **rte\_bus\_vdev.h**.

## Function Documentation

### int rte\_vdev\_add\_custom\_scan (rte\_vdev\_scan\_callback callback, void \* user\_arg)

Add a callback to be called on vdev scan before reading the devargs list.

This function cannot be called in a scan callback because of deadlock.

**Parameters**

*callback* The function to be called which can update the devargs list. \
 *user\_arg* An opaque pointer passed to callback.

**Returns**

0 on success, negative on error

### int rte\_vdev\_remove\_custom\_scan (rte\_vdev\_scan\_callback callback, void \* user\_arg)

Remove a registered scan callback.

This function cannot be called in a scan callback because of deadlock.

**Parameters**

*callback* The registered function to be removed. \
 *user\_arg* The associated opaque pointer or (void\*)-1 for any.

**Returns**

0 on success

### int rte\_vdev\_init (const char \* name, const char \* args)

Initialize a driver specified by name.

**Parameters**

*name* The pointer to a driver name to be initialized. \
 *args* The pointer to arguments used by driver initialization.

**Returns**

0 on success, negative on error

### int rte\_vdev\_uninit (const char \* name)

Uninitialize a driver specified by name.

**Parameters**

*name* The pointer to a driver name to be uninitialized.

**Returns**

0 on success, negative on error

## Author

Generated automatically by Doxygen for DPDK from the source code.
