---
name: "phy_write"
section: "9"
platform: "linux"
package: "linux-manual-2.6.26"
version: "2.6.26-29"
release: "Debian 5.0 (Lenny)"
platforms: ["linux"]
url: "https://new.carta.tech/phy_write"
---

# phy\_write(9)

Convenience function for writing a given PHY register

## NAME

phy\_write - Convenience function for writing a given PHY register

## SYNOPSIS

**int phy\_write(struct phy\_device \*** *phydev***, u16** *regnum***, u16** *val***);**

## ARGUMENTS

*phydev*

the phy\_device struct

*regnum*

register number to write

*val*

value to write to *regnum*

## NOTE

MUST NOT be called from interrupt context, because the bus read/write functions may wait for an interrupt to conclude the operation.

## COPYRIGHT
