---
name: "of_mdio_find_bus"
section: "9"
platform: "linux"
package: "linux-manual-4.9"
version: "4.9.228-1"
release: "Debian 9 (Stretch)"
platforms: ["linux"]
url: "https://new.carta.tech/of_mdio_find_bus"
---

# of\_mdio\_find\_bus(9)

Given an mii\_bus node, find the mii\_bus.

## NAME

of\_mdio\_find\_bus - Given an mii\_bus node, find the mii\_bus.

## SYNOPSIS

**struct mii\_bus \* of\_mdio\_find\_bus(struct device\_node \*** *mdio\_bus\_np***);**

## ARGUMENTS

*mdio\_bus\_np*

Pointer to the mii\_bus.

## DESCRIPTION

Returns a reference to the mii\_bus, or NULL if none found. The embedded struct device will have its reference count incremented, and this must be put once the bus is finished with.

Because the association of a device\_node and mii\_bus is made via **of\_mdiobus\_register**, the mii\_bus cannot be found before it is registered with **of\_mdiobus\_register**.

## COPYRIGHT
