clk_hw_regis..._parent_data(9)
π clk_hw_regis..._parent_data(9) π
okay so real talk, bestie β this is a page from the Kernel API Manual, and the function name is so long it literally got truncated to clk_hw_regis..._parent_data. iconic behavior tbh. anyway, let's get into it π«Ά
β¨ NAME β¨
clk_hw_register_gate_parent_data β registers a gate clock with the clock framework. that's it, that's the whole vibe. you're making a gate clock and telling the clock framework about it π
πΈ SYNOPSIS πΈ
clk_hw_register_gate_parent_data (dev , name , parent_data , flags , reg
, bit_idx , clk_gate_flags , lock );
eight arguments. EIGHT. not me counting them like a spreadsheet π ok let's go through every single one, no skipping, periodt.
π ARGUMENTS π
devβ the device that is registering this clock. it's the one signing the paperwork, basically the main character here πnameβ name of this clock. give it a cute one, it's gonna live in the framework forever πparent_dataβ parent clk data. it's thestruct clk_parent_datasituation, aka where this clock gets its ancestry from π§¬flagsβ framework-specific flags for this clock. the generic ones, not the gate-y ones β those come later, keep scrolling πregβ register address to control gating of this clock. this is where the on/off switch physically lives π₯bit_idxβ which bit in the register controls gating of this clock. one specific bit. choose wisely π―clk_gate_flagsβ gate-specific flags for this clock. yes, different fromflags. yes, you need both. i don't make the rules β¨lockβ shared register lock for this clock. it's the group-chat mute button so nobody touches the register at the same time π
π¦ SEE ALSO π¦
okay this list is LONG, so buckle up β every single reference, coming at you πΈ
first up, the kernel file itself: ./include/linux/clk-provider.h, plus clk framework flags(9) β and then the whole extended family:
struct clk_rate_request(9)struct clk_duty(9)struct clk_spread_spectrum(9)struct clk_ops(9)struct clk_parent_data(9)struct clk_init_data(9)struct clk_hw(9)struct clk_fixed_rate(9)clk_hw_register_fixed_rate(9)devm_clk_hw_register_fixed_rate(9)devm_clk_hw_register_fixed_rate_parent_data(9)clk_hw_register_fixed_rate_parent_hw(9)clk_hw_register_fixed_rate_parent_data(9)clk_hw_register_fixed_rate_with_accuracy(9)clk_hw_register_fixed_rate_with_accuracy_parent_hw(9)clk_hw_register_fixed_rate_with_accuracy_parent_data(9)clk_hw_register_fixed_rate_parent_accuracy(9)struct clk_gate(9)clk_hw_register_gate(9)clk_hw_register_gate_parent_hw(9)devm_clk_hw_register_gate(9)devm_clk_hw_register_gate_parent_hw(9)devm_clk_hw_register_gate_parent_data(9)struct clk_divider(9)clk_register_divider(9)clk_hw_register_divider(9)clk_hw_register_divider_parent_hw(9)clk_hw_register_divider_parent_data(9)clk_hw_register_divider_table(9)clk_hw_register_divider_table_parent_hw(9)clk_hw_register_divider_table_parent_data(9)devm_clk_hw_register_divider(9)devm_clk_hw_register_divider_parent_hw(9)devm_clk_hw_register_divider_parent_data(9)devm_clk_hw_register_divider_table(9)struct clk_mux(9)struct clk_fixed_factor(9)devm_clk_hw_register_fixed_factor_parent_hw(9)struct clk_fractional_divider(9)struct clk_multiplier(9)clk_hw_get_dev(9)clk_hw_get_of_node(9)
like i said. LONG. but now you know the whole clock-provider friend group π«Ά
lowkey a flex that you made it to the bottom of a kernel API page. your brain is huge, no cap πβ¨
and that's a wrap, bestie! this gem lives in ./include/linux and the page is dated October 2026 β so go forth, register those gate clocks, and slay π
ππ¦
π¦ 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