On Fri, 2022-01-14 at 18:39 -0500, Sean Anderson wrote:
Instead of grabbing all clocks in bulk, grab them individually. This will
allow us to get the frequency or otherwise deal with discrete clocks. This
may break some platforms if they use a clock which doesn't use one of the
documented names.
Another approach would be to keep the bulk get and prepare_enable and just
search through the clocks in the bulk data to find the "ref" clock, i.e.
something like:
for (i = 0; i < dwc->num_clks; ++i)
if (!strcmp("ref", dwc->clks[i].id)) {
ref_clk_rate = clk_get_rate(dwc->clks[i].clk);
break;
}
That's probably simpler than all the extra complexity to get each of the clocks
individually and release them in the right order.