of_pci_get_slot_power_limit(9)
π of_pci_get_slot_power_limit(9) β Kernel API Manual energy β¨
okay so bestie, welcome to the Kernel API Manual entry for of_pci_get_slot_power_limit(9) β yes the whole thing, no skips, we are doing this properly π«Ά
πΈ NAME πΈ
of_pci_get_slot_power_limit β literally just parses the "slot-power-limit-milliwatt" property π that's the whole vibe, no cap.
β¨ SYNOPSIS β¨
u32 of_pci_get_slot_power_limit (struct device_node *node , u8
*slot_power_limit_value , u8 *slot_power_limit_scale );
yep that's the whole signature, look at her go π
π ARGUMENTS π
nodeβ the device tree node that's holding the slot power limit info. this is the main character of the call fr fr πslot_power_limit_valueβ a pointer to where the value should get stored, inPCIe Slot Capabilities Registerformat. so like, that exact format, not whatever format, okay? πslot_power_limit_scaleβ same deal but for the scale β pointer to where the scale goes, also inPCIe Slot Capabilities Registerformat π
π¦ DESCRIPTION π¦
So what does she actually do? She returns the slot power limit in milliwatts β‘ and if the slot_power_limit_value and slot_power_limit_scale pointers are non-NULL, she fills in the value and the scale using the format that the PCIe Slot Capabilities Register uses. iykyk π§
and if the property is not found or is invalid? she returns 0. that's it. nothing dramatic, just a cool zero π
π SEE ALSO π
the Kernel file ./drivers/pci/of.c is right here bestie, plus the whole friend group π«Ά:
pci_set_of_node(9)of_pci_get_devfn(9)of_pci_parse_bus_range(9)of_get_pci_domain_nr(9)of_pci_preserve_config(9)of_pci_check_probe_only(9)devm_of_pci_get_host_bridge_resources(9)of_irq_parse_pci(9)of_irq_parse_and_map_pci(9)of_pci_supply_present(9)of_pci_get_max_link_speed(9)of_pci_get_equalization_presets(9)
and that's the page!! π sign-off time: this lil slice of lore lives in ./drivers/pci, dated October 2026, and the header is of_pci_get_slot_power_limit(9) in case you forgot already π β go read the source, slay, 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