linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v8 0/7] Per-user clock constraints
@ 2014-09-01 15:29 Tomeu Vizoso
  2014-09-01 15:29 ` [PATCH v8 1/7] clk: Add temporary mapping to the existing API Tomeu Vizoso
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Tomeu Vizoso @ 2014-09-01 15:29 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

in this v8 of the patchset I have rebased on top of friday's linux-next and
have extended the unbalanced checks to also cover prepare/unprepare. I have
dropped the changes I did to remove usage of provider-only API from
kirkwood-cpufreq.c, as Mike and Andrew are taking care of it in a series [0]
that will be hopefully posted soon. This iteration has been tested only on a
Jetson TK1 board.

Follows the original cover letter blurb:

I'm retaking Rabin's patches [1] for splitting the clk API in two: one API for
clk consumers and another for providers. The consumer API uses a clk structure
that just keeps track of the consumer and has a reference to the actual
clk_core struct, which is used internally.

I have kept a patch from Rabin that aims to aid in debugging nested
enable/disable calls, though my personal aim is to allow more than one consumer
to influence the final, effective frequency rate. For now this is limited to
setting floor and ceiling constraints, with the short-term aim of allowing
devfreq and thermal drivers to set floor and ceiling frequencies on the memory
clock, respectively.

For those functions in the consumer clk API that were called from providers, I
have added variants to clk-provider.h that are the same only that accept a
clk_core instead. These functions are prefixed with clk_provider_.

Patch 1/7 just adds a bunch of defines with the goal of having all the renames
in their own commit while preserving git-bisectability, with patch 3/7
containing the rename itself as generated by the Coccinelle script in [2].
Patch 2/7 is needed because sound/soc/mxs/mxs-saif.c calls both the consumer
and the provider API. The actual implementation of the API split comes in patch
4/7. I will be happy to organize the refactoring differently if anybody has a
better idea.

Patch 5/7 warns when there's an unbalanced usage of the enable and disable
APIs, and patch 6/7 adds the API for setting floor and ceiling frequencies, per
consumer. Patch 7/7 will warn when prepare/unprepare are used unbalanced,
printing the code location of the last call to unprepare.

[0] https://git.linaro.org/people/mike.turquette/linux.git/shortlog/refs/heads/clk-next-tomeu-kirkwood-v2
[1] http://thread.gmane.org/gmane.linux.kernel/1402006
[2] http://cgit.collabora.com/git/user/tomeu/linux.git/log/?h=clk-refactoring-8

Thanks,

Tomeu

Tomeu Vizoso (7):
  clk: Add temporary mapping to the existing API
  ASoC: mxs-saif: fix mixed use of public and provider clk API
  clk: Move all drivers to use internal API
  clk: use struct clk only for external API
  clk: per-user clock accounting for debug
  clk: Add floor and ceiling constraints to clock rates
  clk: Warn of unbalanced clk_prepare() calls

[detailed diffstat omitted for brevity sake]

 255 files changed, 2251 insertions(+), 1726 deletions(-)

-- 
1.9.3

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2014-09-04 13:34 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-01 15:29 [PATCH v8 0/7] Per-user clock constraints Tomeu Vizoso
2014-09-01 15:29 ` [PATCH v8 1/7] clk: Add temporary mapping to the existing API Tomeu Vizoso
2014-09-01 15:29 ` [PATCH v8 2/7] ASoC: mxs-saif: fix mixed use of public and provider clk API Tomeu Vizoso
2014-09-01 15:34 ` [PATCH v8 4/7] clk: use struct clk only for external API Tomeu Vizoso
2014-09-01 15:34   ` [PATCH v8 5/7] clk: per-user clock accounting for debug Tomeu Vizoso
2014-09-01 15:34   ` [PATCH v8 6/7] clk: Add floor and ceiling constraints to clock rates Tomeu Vizoso
2014-09-03  0:13     ` Mike Turquette
2014-09-03 14:14       ` Tomeu Vizoso
2014-09-01 15:34   ` [PATCH v8 7/7] clk: Warn of unbalanced clk_prepare() calls Tomeu Vizoso
2014-09-03 23:45   ` [PATCH v8 4/7] clk: use struct clk only for external API Stephen Boyd
2014-09-04 13:34     ` Tomeu Vizoso

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).