diff options
author | Daniel Thompson <daniel.thompson@linaro.org> | 2015-05-11 06:20:06 -0400 |
---|---|---|
committer | Stephen Boyd <sboyd@codeaurora.org> | 2015-05-13 15:32:51 -0400 |
commit | 42801ca46719b189d4090b76268e6db90fc01e3c (patch) | |
tree | a124407b0e4a74ee332ff2c4fc887c077f938c9a | |
parent | dbc3976d9123a00925e3c9893b3f40f58f82636c (diff) |
clk: Update docs after removal of clk-private.h
Currently Documentation/clk.txt describes an obsolete techinique to
statically define struct clk objects.
This capability was removed by b09d6d991025("clk: remove clk-private.h")
and is no longer supported. The documentation describing the feature should
be removed.
Signed-off-by: Daniel Thompson <daniel.thompson@linaro.org>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Michael Turquette <mturquette@linaro.org>
Cc: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
-rw-r--r-- | Documentation/clk.txt | 27 |
1 files changed, 2 insertions, 25 deletions
diff --git a/Documentation/clk.txt b/Documentation/clk.txt index 0e4f90aa1c13..f463bdc37f88 100644 --- a/Documentation/clk.txt +++ b/Documentation/clk.txt | |||
@@ -230,30 +230,7 @@ clk_register(...) | |||
230 | 230 | ||
231 | See the basic clock types in drivers/clk/clk-*.c for examples. | 231 | See the basic clock types in drivers/clk/clk-*.c for examples. |
232 | 232 | ||
233 | Part 5 - static initialization of clock data | 233 | Part 5 - Disabling clock gating of unused clocks |
234 | |||
235 | For platforms with many clocks (often numbering into the hundreds) it | ||
236 | may be desirable to statically initialize some clock data. This | ||
237 | presents a problem since the definition of struct clk should be hidden | ||
238 | from everyone except for the clock core in drivers/clk/clk.c. | ||
239 | |||
240 | To get around this problem struct clk's definition is exposed in | ||
241 | include/linux/clk-private.h along with some macros for more easily | ||
242 | initializing instances of the basic clock types. These clocks must | ||
243 | still be initialized with the common clock framework via a call to | ||
244 | __clk_init. | ||
245 | |||
246 | clk-private.h must NEVER be included by code which implements struct | ||
247 | clk_ops callbacks, nor must it be included by any logic which pokes | ||
248 | around inside of struct clk at run-time. To do so is a layering | ||
249 | violation. | ||
250 | |||
251 | To better enforce this policy, always follow this simple rule: any | ||
252 | statically initialized clock data MUST be defined in a separate file | ||
253 | from the logic that implements its ops. Basically separate the logic | ||
254 | from the data and all is well. | ||
255 | |||
256 | Part 6 - Disabling clock gating of unused clocks | ||
257 | 234 | ||
258 | Sometimes during development it can be useful to be able to bypass the | 235 | Sometimes during development it can be useful to be able to bypass the |
259 | default disabling of unused clocks. For example, if drivers aren't enabling | 236 | default disabling of unused clocks. For example, if drivers aren't enabling |
@@ -264,7 +241,7 @@ are sorted out. | |||
264 | To bypass this disabling, include "clk_ignore_unused" in the bootargs to the | 241 | To bypass this disabling, include "clk_ignore_unused" in the bootargs to the |
265 | kernel. | 242 | kernel. |
266 | 243 | ||
267 | Part 7 - Locking | 244 | Part 6 - Locking |
268 | 245 | ||
269 | The common clock framework uses two global locks, the prepare lock and the | 246 | The common clock framework uses two global locks, the prepare lock and the |
270 | enable lock. | 247 | enable lock. |