From: "Leo L. Schwab" <lschwab@tapwave.com>
To: linux-pm <linux-pm@lists.osdl.org>
Subject: Clock Policy Goes Where?
Date: Thu, 23 Jun 2005 13:54:11 -0700 [thread overview]
Message-ID: <42BB2173.2010101@tapwave.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 1577 bytes --]
. I'm working on an implementation of the ARM clock API for the Freescale
i.MX1 (which is very crufty right now and only works on Zodiacs so there's
not much point in asking for it (unless you want to critique it; I could use
the feedback)), and I find myself wondering where the default clock settings
should come from.
Looking at the clock API for the TI OMAP (arch/arm/mach-omap/clock.c), I
see a table of available clock frequencies. The init code finds the fastest
one and sets it. Then it clk_use()s three other clocks. Doesn't that
constitute a policy decision? If so, where should this policy reside?
The reason I ask is because my first crack at a clock driver implementation
had the clocks being disabled/spun down until a client showed up. This
seems fine until you discover that the serial console gets initialized *way*
before the clock and serial drivers; that the UART clocks are effectively
already in use, which in turn depend on PERCLK1, which in turn depends on
SYSPLL. OTOH, if you don't have the serial console configured, then you
don't have to worry about any of that.
All of which is a long-winded way of observing that the initial state of
the clocks appears to this novice's eye to be policy-dependent. In the case
of the serial console, the policy is encoded in the kernel config and can be
easily, if hackishly, handled. Handling of other policies is less obvious
(sticking them all in the kernel config seems wrong). I would prefer to do
The Right Thing here. Can anyone offer insights on this issue?
Schwab
[-- Attachment #2: Type: text/plain, Size: 0 bytes --]
next reply other threads:[~2005-06-23 20:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-23 20:54 Leo L. Schwab [this message]
2005-06-24 13:18 ` Clock Policy Goes Where? tony
2005-06-24 21:26 ` Leo L. Schwab
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=42BB2173.2010101@tapwave.com \
--to=lschwab@tapwave.com \
--cc=linux-pm@lists.osdl.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