phy_clear_bits(9)
π phy_clear_bits(9) β Kernel API Manual, bestie edition π
okay so picture this: you're deep in the kernel, you're living in phy_clear_bits(9) land, and the manual is literally called Kernel API Manual. yeah. that's the vibe. let's get into it β¨
πΈ NAME πΈ
phy_clear_bits β the convenience function for clearing bits in a PHY register. that's it. that's the whole gig. lowkey iconic for how simple it is π«Ά
β¨ SYNOPSIS β¨
int phy_clear_bits (struct phy_device *phydev , u32 regnum , u16 val );
she takes three things and hands you back an int. no cap, that's the whole signature π
π¦ ARGUMENTS π¦
phydevβ thephy_devicestruct. your main character, fr fr. this is the device you're messing with π§regnumβ register number to write. this is where you're going π«valβ bits to clear. this is what you're yeeting out of there π
π₯ SEE ALSO π₯
okay bestie, buckle up, because this list is long and I am obsessed with how thorough it is. every single one of these, no skipping, periodt π
First up, the kernel file itself β that's Kernel file ./include/linux/phy.h, and the whole squad that lives near it:
enum phy_interface_t(9)phy_modes(9)rgmii_clock(9)struct mdio_bus_stats(9)struct mii_bus(9)mdiobus_alloc(9)enum phy_state(9)struct phy_c45_device_ids(9)struct phy_oatc14_sqi_capability(9)struct phy_device(9)struct phy_tdr_config(9)enum link_inband_signalling(9)struct phy_plca_cfg(9)struct phy_plca_status(9)struct phy_led(9)struct phy_mse_capability(9)struct phy_mse_snapshot(9)struct phy_driver(9)phy_id_compare(9)phy_id_compare_vendor(9)phy_id_compare_model(9)phydev_id_compare(9)phy_is_started(9)phy_driver_is_genphy(9)phy_disable_eee_mode(9)phy_can_wakeup(9)phy_may_wakeup(9)phy_read(9)__phy_read(9)phy_write(9)__phy_write(9)__phy_modify_changed(9)phy_read_mmd_poll_timeout(9)__phy_set_bits(9)__phy_clear_bits(9)phy_set_bits(9)__phy_set_bits_mmd(9)__phy_clear_bits_mmd(9)phy_set_bits_mmd(9)phy_clear_bits_mmd(9)phy_interrupt_is_valid(9)phy_polling_mode(9)phy_has_hwtstamp(9)phy_has_rxtstamp(9)phy_has_tsinfo(9)phy_has_txtstamp(9)phy_is_default_hwtstamp(9)phy_on_sfp(9)phy_interface_mode_is_rgmii(9)phy_interface_mode_is_8023z(9)phy_interface_is_rgmii(9)phy_is_pseudo_fixed_link(9)phy_module_driver(9)
likeβ¦ fifty-three entries. she ate and left no crumbs π ngl if you read all of these you're basically a PHY scholar at this point π
real talk though: phy_clear_bits is your convenience wrapper β the manual says so right in the NAME section β so if you're reaching for it, you probably already know what you're doing. slay π
and that's the whole page, bestie!! this icon came from ./include/linux and the version stamp on it is October 2026 β so when you cite it, cite it with love π bye pookie, go clear some bits π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms