With the new clk parenting code, clk_init_data was expanded to include .parent_hws, for clk drivers to directly reference parents by clk_hw. Add a new macro, CLK_FIXED_FACTOR_HW, that can take a struct clk_hw pointer, instead of a string, as its parent.
Showing the changes to include/linux (1 of 1 file). Show all
Unified · Split
| @@ -985,6 +985,17 @@ extern struct of_device_id __clk_of_table; · 984 unmodified lines | |||
| 985 | _flags), \ | 985 | _flags), \ |
| 986 | } | 986 | } |
| 987 | 987 | ||
| 988 | #define CLK_FIXED_FACTOR_HW(_struct, _name, _parent, \ | ||
| 989 | _div, _mult, _flags) \ | ||
| 990 | struct clk_fixed_factor _struct = { \ | ||
| 991 | .div = _div, \ | ||
| 992 | .mult = _mult, \ | ||
| 993 | .hw.init = CLK_HW_INIT_HW(_name, \ | ||
| 994 | _parent, \ | ||
| 995 | &clk_fixed_factor_ops, \ | ||
| 996 | _flags), \ | ||
| 997 | } | ||
| 998 | |||
| 988 | #ifdef CONFIG_OF | 999 | #ifdef CONFIG_OF |
| 989 | int of_clk_add_provider(struct device_node *np, | 1000 | int of_clk_add_provider(struct device_node *np, |
| 990 | struct clk *(*clk_src_get)(struct of_phandle_args *args, | 1001 | struct clk *(*clk_src_get)(struct of_phandle_args *args, |