>> >> On 7/25/2012 9:16 PM, Karicheri, Muralidharan wrote: >> > All, >> > >> > >> > >> > I am working to migrate DaVinci platforms to common clock framework. >> > While doing so I would need your support in terms of answering any >> > questions that I have, reviewing patches and testing. I have started >> > with DM6446 and I got the following questions to you. Could someone >> > clarify this for me? >> > >> > >> > >> > 1. davinci_clk_disable_unused(). From the description of the function >> > header, I understand this was added to disable lpsc modules that are >> > left enabled by the bootloader. So it appears that this is a hack. >> >> I wouldn't call it a hack. Reducing dependency on bootloader is a >> desirable feature. >> >> > Ideally bootloader needs to disable all of the modules before it enters >> > the kernel and this function shouldn’t have been there. Can someone >> > clarify if this is still needed? >> >> As you said that's in ideal world. Even if the latest bootloader had the >> code in place to do this, I suspect many would be stuck with old >> bootloaders on their boards so this is still required. >>
Agreed. But to support this, I think I need to enhance the clk API interface. There is a function is_enabled() that can be implemented by the driver ( clk-psc in our case), but how do we know if a clock is in use or not. So a new API needs to be added is_inuse() or such which returns the enabled count. Once we have this, we should be able to implement davinci_clk_disable_unused() with common clock framework. I will send an RFC for this enhancement if this is not available already. >> > >> > 2. In dm644x.c, for dsp_clk, usecount is set to 1 with a comment >> > “REVISIT how to disable”. This is true for timer2_clk as well as >> > vicp_clk. I see similar things on other DaVinci platforms. Have someone >> > investigated why this hack is required? Any volunteers to debug and root >> > cause this? In common clock framework, we wouldn’t be able to support >> > this hack and has to be debugged and fixed. Any comments? >> >> I have no idea why these were put in. If you drop these hacks on >> existing kernel, do you see any issues? vicp_clk sounds like a video >> clock. Cc Manju and Prabhakar for comment on that. As I have said before, I need your team's help to test this on DM devices. I have a DM6446 that I can use to do a boot test. I have most of the code ready for DM644x and will start testing this next week. >> >> Thanks, >> Sekhar _______________________________________________ Davinci-linux-open-source mailing list Davinci-linux-open-source@linux.davincidsp.com http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source