Lines Matching full:sel
13 #define selector_clear_exists(sel) ((sel)->width = 0) argument
46 struct bcm_clk_sel *sel; in clk_requires_trigger() local
52 sel = &peri->sel; in clk_requires_trigger()
53 if (sel->parent_count && selector_exists(sel)) in clk_requires_trigger()
76 struct bcm_clk_sel *sel; in peri_clk_data_offsets_valid() local
140 sel = &peri->sel; in peri_clk_data_offsets_valid()
141 if (selector_exists(sel)) { in peri_clk_data_offsets_valid()
142 if (sel->offset > limit) { in peri_clk_data_offsets_valid()
144 __func__, name, sel->offset, limit); in peri_clk_data_offsets_valid()
283 static bool sel_valid(struct bcm_clk_sel *sel, const char *field_name, in sel_valid() argument
286 if (!bitfield_valid(sel->shift, sel->width, field_name, clock_name)) in sel_valid()
289 if (sel->parent_count) { in sel_valid()
301 max_sel = sel->parent_sel[sel->parent_count - 1]; in sel_valid()
302 limit = (1 << sel->width) - 1; in sel_valid()
307 sel->width); in sel_valid()
313 selector_clear_exists(sel); in sel_valid()
314 kfree(sel->parent_sel); in sel_valid()
315 sel->parent_sel = NULL; in sel_valid()
398 struct bcm_clk_sel *sel; in peri_clk_data_valid() local
429 sel = &peri->sel; in peri_clk_data_valid()
430 if (selector_exists(sel)) { in peri_clk_data_valid()
431 if (!sel_valid(sel, "selector", name)) in peri_clk_data_valid()
434 } else if (sel->parent_count > 1) { in peri_clk_data_valid()
601 clk_sel_setup(const char **clocks, struct bcm_clk_sel *sel, in clk_sel_setup() argument
635 sel->parent_count = parent_count; in clk_sel_setup()
636 sel->parent_sel = parent_sel; in clk_sel_setup()
641 static void clk_sel_teardown(struct bcm_clk_sel *sel, in clk_sel_teardown() argument
644 kfree(sel->parent_sel); in clk_sel_teardown()
645 sel->parent_sel = NULL; in clk_sel_teardown()
646 sel->parent_count = 0; in clk_sel_teardown()
656 clk_sel_teardown(&data->sel, init_data); in peri_clk_teardown()
670 return clk_sel_setup(data->clocks, &data->sel, init_data); in peri_clk_setup()