From: Tomi Valkeinen <tomi.valkeinen@ti.com>
To: Archit Taneja <archit@ti.com>
Cc: linux-omap@vger.kernel.org, linux-fbdev@vger.kernel.org
Subject: Re: [PATCH 08/14] OMAPDSS: DSS: add new clock calculation code
Date: Wed, 20 Mar 2013 15:28:39 +0000 [thread overview]
Message-ID: <5149D5A7.204@ti.com> (raw)
In-Reply-To: <5149D30F.2010801@ti.com>
[-- Attachment #1: Type: text/plain, Size: 1947 bytes --]
On 2013-03-20 17:17, Archit Taneja wrote:
> On Friday 08 March 2013 05:22 PM, Tomi Valkeinen wrote:
>> Add new way to iterate over DSS clock divisors. dss_div_calc() provides
>> a generic way to go over all the divisors, within given clock range.
>> dss_div_calc() will call a callback function for each divider set,
>> making the function reusable for all use cases.
>>
>> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
>> ---
>> drivers/video/omap2/dss/dss.c | 36
>> ++++++++++++++++++++++++++++++++++++
>> drivers/video/omap2/dss/dss.h | 3 +++
>> 2 files changed, 39 insertions(+)
>>
>> diff --git a/drivers/video/omap2/dss/dss.c
>> b/drivers/video/omap2/dss/dss.c
>> index 054c2a2..21a3dc8 100644
>> --- a/drivers/video/omap2/dss/dss.c
>> +++ b/drivers/video/omap2/dss/dss.c
>> @@ -473,6 +473,42 @@ int dss_calc_clock_rates(struct dss_clock_info
>> *cinfo)
>> return 0;
>> }
>>
>> +bool dss_div_calc(unsigned long fck_min, dss_div_calc_func func, void
>> *data)
>> +{
>> + int fckd, fckd_start, fckd_stop;
>> + unsigned long fck;
>> + unsigned long fck_hw_max;
>> + unsigned long fckd_hw_max;
>> + unsigned long prate;
>> +
>> + if (dss.dpll4_m4_ck == NULL) {
>> + /* XXX can we change the clock on omap2? */
>
> We can change dss_fclk1 on omap2, and the cclock2420_data.c and
> cclock2430_data.c have clksel structs which allow a set of dividers. The
> dividers are not continuous though, 1 to 12 and 16 are allowed. So we
> might need to change the code here a bit, if we want to change the clock
> in the first place.
Ok, good to know. Note that the comment is copied from the old code. I
think I tried changing the clock on N800 with clk_set_rate long ago, but
I didn't get it to work. Things might have changed, but, well, I don't
think we should spend time on omap2 code. I'm sure we'll get a patch if
somebody needs it =).
Tomi
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 899 bytes --]
next prev parent reply other threads:[~2013-03-20 15:28 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-08 11:52 [PATCH 00/14] OMAPDSS: new clock calculation + DSI VM Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 01/14] OMAPDSS: DISPC: store core clk rate Tomi Valkeinen
2013-03-20 11:20 ` Archit Taneja
2013-03-20 11:36 ` Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 02/14] OMAPDSS: DSI: fix wrong unsigned long long use Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 03/14] OMAPDSS: DSI: simplify dsi configuration Tomi Valkeinen
2013-03-20 11:36 ` Archit Taneja
2013-03-20 11:44 ` Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 04/14] OMAPDSS: DSI: get line buffer size at probe Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 05/14] OMAPDSS: DSI: add enum omap_dss_dsi_trans_mode Tomi Valkeinen
2013-03-20 11:42 ` Archit Taneja
2013-03-08 11:52 ` [PATCH 06/14] OMAPDSS: DSI remove unneeded clk source setup code Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 07/14] OMAPDSS: DISPC: add new clock calculation code Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 08/14] OMAPDSS: DSS: " Tomi Valkeinen
2013-03-20 15:29 ` Archit Taneja
2013-03-20 15:28 ` Tomi Valkeinen [this message]
2013-03-21 6:26 ` Archit Taneja
2013-03-21 8:13 ` Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 09/14] OMAPDSS: DSI: " Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 10/14] OMAPDSS: SDI: use " Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 11/14] OMAPDSS: DPI: " Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 12/14] OMAPDSS: DSI: " Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 13/14] OMAPDSS: remove unused old " Tomi Valkeinen
2013-03-08 11:52 ` [PATCH 14/14] OMAPDSS: remove dsi videomode from dssdev Tomi Valkeinen
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=5149D5A7.204@ti.com \
--to=tomi.valkeinen@ti.com \
--cc=archit@ti.com \
--cc=linux-fbdev@vger.kernel.org \
--cc=linux-omap@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).