Messages in this thread | | | Date | Thu, 31 May 2012 12:10:40 +0300 | From | Peter De Schrijver <> | Subject | Re: [RFC PATCH] clk: add extension API |
| |
On Thu, May 31, 2012 at 11:04:36AM +0200, Stephen Boyd wrote: > On 5/31/2012 12:51 AM, Peter De Schrijver wrote: > > On Wed, May 30, 2012 at 10:52:31AM +0200, Stephen Boyd wrote: > >> On 5/29/2012 2:58 AM, Peter De Schrijver wrote: > >>> Add an extension API for clocks. This allows clocktypes to provide extensions > >>> for features which are uncommon and cannot be easily mapped onto normal clock > >>> framework concecpts. eg: resetting blocks, configuring clock phase etc. > >> This seems rather generic. Why not add more specific APIs/concepts like > >> clk_reset(), clk_set_phase(), etc.? If they don't map, maybe we should > >> make them map. > >> > > Some of those might be very SoC specific. Eg OMAP doesn't need software > > controlled modulereset. I don't think we should add a new function to the > > clock framework for clock related features which only exist in a single > > SoC or family. Ideally we could use inheritance to add methods to derived > > clocktypes, but that's not really possible in C unfortunately. > > Most likely your hardware is not that special and the functionality you > think exists only on your SoC actually exists on 5 others. MSM needs > software resets too and we also associate them with each clock (there > can be many clocks for one device and one reset for each clock). We use > them mostly for the power domain code (looks like tegra and omap do the > same thing albeit slightly differently). > > What do you plan to support under this API?
Anything which isn't available on other SoCs. If it is available, then we could indeed add another method. I guess this will need to be decided on a case by case basis.
Cheers,
Peter.
| |