From: skannan@codeaurora.org (Saravana Kannan)
To: linux-arm-kernel@lists.infradead.org
Subject: [RFC PATCH] clk: add extension API
Date: Thu, 31 May 2012 14:12:20 -0700 [thread overview]
Message-ID: <4FC7DEB4.3000208@codeaurora.org> (raw)
In-Reply-To: <20120531082309.GP8026@tbergstrom-lnx.Nvidia.com>
On 05/31/2012 01:23 AM, Peter De Schrijver wrote:
> On Thu, May 31, 2012 at 05:29:54AM +0200, Saravana Kannan wrote:
>> On 05/30/2012 12:40 PM, Mike Turquette wrote:
>>> On 20120530-01:52, 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.
>>>>
>>>
>>> I also wonder if exposing some of these knobs should be done in the
>>> basic clock types. Meaning that instead of having additional calls in
>>> the clk.h API those calls could be exposed by the basic clock types that
>>> map to the actions.
>>>
>>> The question that needs to be answered is this: do generic drivers need
>>> access to these additional functions (clk.h) or just the platform code
>>> which implements some of the clock logic (basic clock types&
>>> platform-speciic clock types).
>>
>> One of the main reason for the common clock framework is so that each
>> platform doesn't have it's own extension and have mostly similar code
>> repeat all over the place. So, having clock APIs outside of clk.h
>> doesn't make sense when we look at the direction we want the code base
>> to proceed in.
>
> I don't think this will lead to 'mostly similar code repeat all over the
> place'. I don't know of any intree SoC which has a similar requirement.
> So which code duplication would this cause?
It's not clear what you plan to use this API for. So, I can't really
answer if any intree SoC needs it. But if this is about reset signals,
it's definitely needed for MSM too. I was planning on bringing this up
after the basic clock API implementation in the clock framework is
usable for MSM.
-Saravana
--
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
WARNING: multiple messages have this Message-ID (diff)
From: Saravana Kannan <skannan@codeaurora.org>
To: Peter De Schrijver <pdeschrijver@nvidia.com>
Cc: Mike Turquette <mturquette@ti.com>,
Stephen Boyd <sboyd@codeaurora.org>,
Russell King <linux@arm.linux.org.uk>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>
Subject: Re: [RFC PATCH] clk: add extension API
Date: Thu, 31 May 2012 14:12:20 -0700 [thread overview]
Message-ID: <4FC7DEB4.3000208@codeaurora.org> (raw)
In-Reply-To: <20120531082309.GP8026@tbergstrom-lnx.Nvidia.com>
On 05/31/2012 01:23 AM, Peter De Schrijver wrote:
> On Thu, May 31, 2012 at 05:29:54AM +0200, Saravana Kannan wrote:
>> On 05/30/2012 12:40 PM, Mike Turquette wrote:
>>> On 20120530-01:52, 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.
>>>>
>>>
>>> I also wonder if exposing some of these knobs should be done in the
>>> basic clock types. Meaning that instead of having additional calls in
>>> the clk.h API those calls could be exposed by the basic clock types that
>>> map to the actions.
>>>
>>> The question that needs to be answered is this: do generic drivers need
>>> access to these additional functions (clk.h) or just the platform code
>>> which implements some of the clock logic (basic clock types&
>>> platform-speciic clock types).
>>
>> One of the main reason for the common clock framework is so that each
>> platform doesn't have it's own extension and have mostly similar code
>> repeat all over the place. So, having clock APIs outside of clk.h
>> doesn't make sense when we look at the direction we want the code base
>> to proceed in.
>
> I don't think this will lead to 'mostly similar code repeat all over the
> place'. I don't know of any intree SoC which has a similar requirement.
> So which code duplication would this cause?
It's not clear what you plan to use this API for. So, I can't really
answer if any intree SoC needs it. But if this is about reset signals,
it's definitely needed for MSM too. I was planning on bringing this up
after the basic clock API implementation in the clock framework is
usable for MSM.
-Saravana
--
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
next prev parent reply other threads:[~2012-05-31 21:12 UTC|newest]
Thread overview: 58+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-29 9:58 [RFC PATCH] clk: add extension API Peter De Schrijver
2012-05-29 9:58 ` Peter De Schrijver
2012-05-30 8:52 ` Stephen Boyd
2012-05-30 8:52 ` Stephen Boyd
2012-05-30 19:40 ` Mike Turquette
2012-05-30 19:40 ` Mike Turquette
2012-05-30 20:28 ` Stephen Boyd
2012-05-30 20:28 ` Stephen Boyd
2012-05-31 19:09 ` Mike Turquette
2012-05-31 19:09 ` Mike Turquette
2012-05-31 3:29 ` Saravana Kannan
2012-05-31 3:29 ` Saravana Kannan
2012-05-31 8:23 ` Peter De Schrijver
2012-05-31 8:23 ` Peter De Schrijver
2012-05-31 21:12 ` Saravana Kannan [this message]
2012-05-31 21:12 ` Saravana Kannan
2012-05-31 7:51 ` Peter De Schrijver
2012-05-31 7:51 ` Peter De Schrijver
2012-05-31 8:18 ` Felipe Balbi
2012-05-31 8:18 ` Felipe Balbi
2012-05-31 8:31 ` Peter De Schrijver
2012-05-31 8:31 ` Peter De Schrijver
2012-05-31 8:54 ` Felipe Balbi
2012-05-31 8:54 ` Felipe Balbi
2012-05-31 9:05 ` Peter De Schrijver
2012-05-31 9:05 ` Peter De Schrijver
2012-05-31 9:26 ` Felipe Balbi
2012-05-31 9:26 ` Felipe Balbi
2012-05-31 9:43 ` Peter De Schrijver
2012-05-31 9:43 ` Peter De Schrijver
2012-05-31 9:46 ` Felipe Balbi
2012-05-31 9:46 ` Felipe Balbi
2012-05-31 9:57 ` Peter De Schrijver
2012-05-31 9:57 ` Peter De Schrijver
2012-05-31 10:01 ` Felipe Balbi
2012-05-31 10:01 ` Felipe Balbi
2012-05-31 12:50 ` Cousson, Benoit
2012-05-31 12:50 ` Cousson, Benoit
2012-05-31 13:04 ` Mark Brown
2012-05-31 13:04 ` Mark Brown
2012-05-31 13:07 ` Cousson, Benoit
2012-05-31 13:07 ` Cousson, Benoit
2012-05-31 13:11 ` Mark Brown
2012-05-31 13:11 ` Mark Brown
2012-05-31 12:00 ` Mark Brown
2012-05-31 12:00 ` Mark Brown
2012-05-31 9:04 ` Stephen Boyd
2012-05-31 9:04 ` Stephen Boyd
2012-05-31 9:10 ` Peter De Schrijver
2012-05-31 9:10 ` Peter De Schrijver
2012-05-30 9:28 ` Rajendra Nayak
2012-05-30 9:28 ` Rajendra Nayak
2012-05-31 19:19 ` Mike Turquette
2012-05-31 19:19 ` Mike Turquette
2012-06-06 12:07 ` Peter De Schrijver
2012-06-06 12:07 ` Peter De Schrijver
2012-05-31 16:42 ` Stephen Warren
2012-05-31 16:42 ` Stephen Warren
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4FC7DEB4.3000208@codeaurora.org \
--to=skannan@codeaurora.org \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.