devm_clk_hw_...ivider_table(9)
π devm_clk_hw_register_divider_table
okay so this little icon is straight out of the Kernel API Manual, and it's the devres glow-up of "register a table based divider clock with the clock framework." bestie, that's the whole vibe: it's a clock divider, but the lookup table kind, and it's managed for you. π«Ά
π NAME π
devm_clk_hw_register_divider_table β register a table based divider clock with the clock framework (devres variant). that's it, that's the function. devres variant means it's the one that cleans up after itself, iykyk. β¨
πΈ SYNOPSIS πΈ
devm_clk_hw_register_divider_table (dev , name , parent_name , flags ,
reg , shift , width , clk_divider_flags , table , lock );
ten arguments. yes ten. don't panic, we're going through every single one π
π ARGUMENTS π
devβ the device that's registering this clock. like, whose house is this clock living in πnameβ name of this clock. give it a cute one, it deserves it β¨parent_nameβ name of clock's parent. every main character has an origin story πflagsβ framework-specific flags. the framework's rules, not ours πregβ register address to adjust divider. this is where the divider actually lives π₯shiftβ number of bits to shift the bitfield. slide to the left, slide to the right πwidthβ width of the bitfield. how many bits we're working with, periodtclk_divider_flagsβ divider-specific flags for this clock. different flag set, different vibe check πtableβ array of divider/value pairs ending with a div set to0. β οΈ that trailing zero is the terminator bestie β it's how the code knows the list is done, so don't be out here forgetting it πlockβ shared register lock for this clock. sharing is caring, and also prevents chaos π
π SEE ALSO π
okay this list is long and it ate, so let's give it the respect it deserves β the kernel file these live in is ./include/linux/clk-provider.h, and it's giving main character energy. go read all of these, fr fr π¦
clk framework flags(9)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)clk_hw_register_gate_parent_data(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)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)
π reminder: thattablehas to be terminated with a div of0, or the whole thing goes off the rails. no cap, that's the one thing that will bite you.
that's the whole page bestie, you're so welcome π and for the credits moment: this one lives under ./include/linux, dated October 2026 β those are the source/version and date sending their love from the footer. mwah πβ¨
π¦ 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