usb4_port_retimer_nvm_write(9)
π usb4_port_retimer_nvm_write(9) β kernel API manual, bestie edition
okay so real talk, this is a page from the Kernel API Manual, section 9 (that's the kernel-functions girly pop section π«), and it's about writing bytes into a retimer's NVM. yes, that NVM. the flash-y one. slay.
π NAME π
usb4_port_retimer_nvm_write β write to retimer NVM
like, the whole vibe of this function is "put data in the retimer's non-volatile memory." that's it. that's the tweet. π
β¨ SYNOPSIS β¨
int usb4_port_retimer_nvm_write (struct tb_port *port , u8 index ,
unsigned int address , const void *buf , size_t size );
look at her. four args, returns an int. iconic behavior honestly.
π¦ ARGUMENTS π¦
portβ the USB4 port. your main character. the port we're doing all this for πindexβ retimer index. which retimer bestie we talking about, pick a numberaddressβ byte address where to start the write. where the pen goes down on the paper ποΈbufβ data to write. the payload. the goods π¦sizeβ size in bytes, how much to write. no cap, this many bytes exactly
π₯ DESCRIPTION π₯
Writes size bytes from buf to the retimer NVM. literally just yeets your buffer into the retimer's non-volatile memory, size bytes of it, starting from address.
and the reason you'd ever do this? NVM upgrade. that's the use case. that's the moment. firmware glow-up szn β¨π§
π RETURN π
0β if the data was written successfully. we love a clean zero, she ate π«Ά-ENODEVβ if there is no retimer atindex. nobody home. empty seat. π- Negative errno β in case of an error. any negative errno, it's giving "something went wrong" energy π
π SEE ALSO π
kernel file ./drivers/thunderbolt/usb4.c β and a truly enormous friend group, in order, no skips:
usb4_switch_check_wakes(9)usb4_switch_setup(9)usb4_switch_configuration_valid(9)usb4_switch_read_uid(9)usb4_switch_drom_read(9)usb4_switch_lane_bonding_possible(9)usb4_switch_set_wake(9)usb4_switch_set_sleep(9)usb4_switch_nvm_sector_size(9)usb4_switch_nvm_read(9)usb4_switch_nvm_set_offset(9)usb4_switch_nvm_write(9)usb4_switch_nvm_authenticate(9)usb4_switch_nvm_authenticate_status(9)usb4_switch_credits_init(9)usb4_switch_query_dp_resource(9)usb4_switch_alloc_dp_resource(9)usb4_switch_dealloc_dp_resource(9)usb4_port_index(9)usb4_switch_map_pcie_down(9)usb4_switch_map_usb3_down(9)usb4_switch_add_ports(9)usb4_switch_remove_ports(9)usb4_port_unlock(9)usb4_port_hotplug_enable(9)usb4_port_reset(9)usb4_port_configure(9)usb4_port_unconfigure(9)usb4_port_configure_xdomain(9)usb4_port_unconfigure_xdomain(9)usb4_port_sb_read(9)usb4_port_sb_write(9)usb4_port_router_offline(9)usb4_port_router_online(9)usb4_port_enumerate_retimers(9)usb4_port_clx_supported(9)usb4_port_asym_supported(9)usb4_port_asym_set_link_width(9)usb4_port_asym_start(9)usb4_port_margining_caps(9)usb4_port_hw_margin(9)usb4_port_sw_margin(9)usb4_port_sw_margin_errors(9)usb4_port_retimer_set_inbound_sbtx(9)usb4_port_retimer_unset_inbound_sbtx(9)usb4_port_retimer_is_last(9)usb4_port_retimer_is_cable(9)usb4_port_retimer_nvm_sector_size(9)usb4_port_retimer_nvm_set_offset(9)usb4_port_retimer_nvm_authenticate(9)usb4_port_retimer_nvm_authenticate_status(9)usb4_port_retimer_nvm_read(9)usb4_usb3_port_max_link_rate(9)usb4_usb3_port_allocated_bandwidth(9)usb4_usb3_port_allocate_bandwidth(9)usb4_usb3_port_release_bandwidth(9)usb4_dp_port_set_cm_id(9)usb4_dp_port_bandwidth_mode_supported(9)usb4_dp_port_bandwidth_mode_enabled(9)usb4_dp_port_set_cm_bandwidth_mode_supported(9)usb4_dp_port_group_id(9)usb4_dp_port_set_group_id(9)usb4_dp_port_nrd(9)usb4_dp_port_set_nrd(9)usb4_dp_port_granularity(9)usb4_dp_port_set_granularity(9)usb4_dp_port_set_estimated_bandwidth(9)usb4_dp_port_allocated_bandwidth(9)usb4_dp_port_allocate_bandwidth(9)usb4_dp_port_requested_bandwidth(9)usb4_pci_port_set_ext_encapsulation(9)usb4_pci_port_ltssm_state(9)
that's the whole group chat. every single one. iykyk π
lowkey reminder: this is a kernel-internal function page, so it's all "here's what the function does" β not "type this into your shell." no userland command here, bestie, just API lore π§ββοΈ
πΈ that's the page!! source: ./drivers/thunderbolt, dated October 2026, and the manual id on the tin is literally usb4_port_retimer_nvm_write(9) β go off, section 9 π periodt β¨π
π«Ά
π¦ 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