diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-05 21:39:18 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-05 21:39:18 -0400 |
| commit | 19bc2eec3cbf9a282b592749a93ec9027d352bf2 (patch) | |
| tree | bc7cff4dfebf2b256e62280bb006a494e967d4b2 /include | |
| parent | 9712d3c377a9868355ea9a611aca3c54f88dc576 (diff) | |
| parent | e44df332f30bf3040c60c1ed6674d1431fdb48b9 (diff) | |
Merge tag 'clk-for-linus-3.15' of git://git.linaro.org/people/mike.turquette/linux
Pull clock framework changes from Mike Turquette:
"The clock framework changes for 3.15 look similar to past pull
requests. Mostly clock driver updates, more Device Tree support in
the form of common functions useful across platforms and a handful of
features and fixes to the framework core"
* tag 'clk-for-linus-3.15' of git://git.linaro.org/people/mike.turquette/linux: (86 commits)
clk: shmobile: fix setting paretn clock rate
clk: shmobile: rcar-gen2: fix lb/sd0/sd1/sdh clock parent to pll1
clk: Fix minor errors in of_clk_init() function comments
clk: reverse default clk provider initialization order in of_clk_init()
clk: sirf: update copyright years to 2014
clk: mmp: try to use closer one when do round rate
clk: mmp: fix the wrong calculation formula
clk: mmp: fix wrong mask when calculate denominator
clk: st: Adds quadfs clock binding
clk: st: Adds clockgen-vcc and clockgen-mux clock binding
clk: st: Adds clockgen clock binding
clk: st: Adds divmux and prediv clock binding
clk: st: Support for A9 MUX clocks
clk: st: Support for ClockGenA9/DDR/GPU
clk: st: Support for QUADFS inside ClockGenB/C/D/E/F
clk: st: Support for VCC-mux and MUX clocks
clk: st: Support for PLLs inside ClockGenA(s)
clk: st: Support for DIVMUX and PreDiv Clocks
clk: support hardware-specific debugfs entries
clk: s2mps11: Use of_get_child_by_name
...
Diffstat (limited to 'include')
| -rw-r--r-- | include/dt-bindings/clock/hi3620-clock.h | 5 | ||||
| -rw-r--r-- | include/dt-bindings/clock/hip04-clock.h | 35 | ||||
| -rw-r--r-- | include/linux/clk-provider.h | 8 | ||||
| -rw-r--r-- | include/linux/clk.h | 14 |
4 files changed, 62 insertions, 0 deletions
diff --git a/include/dt-bindings/clock/hi3620-clock.h b/include/dt-bindings/clock/hi3620-clock.h index 6eaa6a45e110..21b9d0e2eb0c 100644 --- a/include/dt-bindings/clock/hi3620-clock.h +++ b/include/dt-bindings/clock/hi3620-clock.h | |||
| @@ -147,6 +147,11 @@ | |||
| 147 | #define HI3620_MMC_CLK3 217 | 147 | #define HI3620_MMC_CLK3 217 |
| 148 | #define HI3620_MCU_CLK 218 | 148 | #define HI3620_MCU_CLK 218 |
| 149 | 149 | ||
| 150 | #define HI3620_SD_CIUCLK 0 | ||
| 151 | #define HI3620_MMC_CIUCLK1 1 | ||
| 152 | #define HI3620_MMC_CIUCLK2 2 | ||
| 153 | #define HI3620_MMC_CIUCLK3 3 | ||
| 154 | |||
| 150 | #define HI3620_NR_CLKS 219 | 155 | #define HI3620_NR_CLKS 219 |
| 151 | 156 | ||
| 152 | #endif /* __DTS_HI3620_CLOCK_H */ | 157 | #endif /* __DTS_HI3620_CLOCK_H */ |
diff --git a/include/dt-bindings/clock/hip04-clock.h b/include/dt-bindings/clock/hip04-clock.h new file mode 100644 index 000000000000..695e61cd1523 --- /dev/null +++ b/include/dt-bindings/clock/hip04-clock.h | |||
| @@ -0,0 +1,35 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (c) 2013-2014 Hisilicon Limited. | ||
| 3 | * Copyright (c) 2013-2014 Linaro Limited. | ||
| 4 | * | ||
| 5 | * Author: Haojian Zhuang <haojian.zhuang@linaro.org> | ||
| 6 | * | ||
| 7 | * This program is free software; you can redistribute it and/or modify | ||
| 8 | * it under the terms of the GNU General Public License as published by | ||
| 9 | * the Free Software Foundation; either version 2 of the License, or | ||
| 10 | * (at your option) any later version. | ||
| 11 | * | ||
| 12 | * This program is distributed in the hope that it will be useful, | ||
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 15 | * GNU General Public License for more details. | ||
| 16 | * | ||
| 17 | * You should have received a copy of the GNU General Public License along | ||
| 18 | * with this program; if not, write to the Free Software Foundation, Inc., | ||
| 19 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. | ||
| 20 | * | ||
| 21 | */ | ||
| 22 | |||
| 23 | #ifndef __DTS_HIP04_CLOCK_H | ||
| 24 | #define __DTS_HIP04_CLOCK_H | ||
| 25 | |||
| 26 | #define HIP04_NONE_CLOCK 0 | ||
| 27 | |||
| 28 | /* fixed rate & fixed factor clocks */ | ||
| 29 | #define HIP04_OSC50M 1 | ||
| 30 | #define HIP04_CLK_50M 2 | ||
| 31 | #define HIP04_CLK_168M 3 | ||
| 32 | |||
| 33 | #define HIP04_NR_CLKS 64 | ||
| 34 | |||
| 35 | #endif /* __DTS_HIP04_CLOCK_H */ | ||
diff --git a/include/linux/clk-provider.h b/include/linux/clk-provider.h index 939533da93a7..511917416fb0 100644 --- a/include/linux/clk-provider.h +++ b/include/linux/clk-provider.h | |||
| @@ -32,6 +32,7 @@ | |||
| 32 | #define CLK_GET_ACCURACY_NOCACHE BIT(8) /* do not use the cached clk accuracy */ | 32 | #define CLK_GET_ACCURACY_NOCACHE BIT(8) /* do not use the cached clk accuracy */ |
| 33 | 33 | ||
| 34 | struct clk_hw; | 34 | struct clk_hw; |
| 35 | struct dentry; | ||
| 35 | 36 | ||
| 36 | /** | 37 | /** |
| 37 | * struct clk_ops - Callback operations for hardware clocks; these are to | 38 | * struct clk_ops - Callback operations for hardware clocks; these are to |
| @@ -127,6 +128,12 @@ struct clk_hw; | |||
| 127 | * separately via calls to .set_parent and .set_rate. | 128 | * separately via calls to .set_parent and .set_rate. |
| 128 | * Returns 0 on success, -EERROR otherwise. | 129 | * Returns 0 on success, -EERROR otherwise. |
| 129 | * | 130 | * |
| 131 | * @debug_init: Set up type-specific debugfs entries for this clock. This | ||
| 132 | * is called once, after the debugfs directory entry for this | ||
| 133 | * clock has been created. The dentry pointer representing that | ||
| 134 | * directory is provided as an argument. Called with | ||
| 135 | * prepare_lock held. Returns 0 on success, -EERROR otherwise. | ||
| 136 | * | ||
| 130 | * | 137 | * |
| 131 | * The clk_enable/clk_disable and clk_prepare/clk_unprepare pairs allow | 138 | * The clk_enable/clk_disable and clk_prepare/clk_unprepare pairs allow |
| 132 | * implementations to split any work between atomic (enable) and sleepable | 139 | * implementations to split any work between atomic (enable) and sleepable |
| @@ -165,6 +172,7 @@ struct clk_ops { | |||
| 165 | unsigned long (*recalc_accuracy)(struct clk_hw *hw, | 172 | unsigned long (*recalc_accuracy)(struct clk_hw *hw, |
| 166 | unsigned long parent_accuracy); | 173 | unsigned long parent_accuracy); |
| 167 | void (*init)(struct clk_hw *hw); | 174 | void (*init)(struct clk_hw *hw); |
| 175 | int (*debug_init)(struct clk_hw *hw, struct dentry *dentry); | ||
| 168 | }; | 176 | }; |
| 169 | 177 | ||
| 170 | /** | 178 | /** |
diff --git a/include/linux/clk.h b/include/linux/clk.h index 0dd91148165e..fb5e097d8f72 100644 --- a/include/linux/clk.h +++ b/include/linux/clk.h | |||
| @@ -78,8 +78,22 @@ struct clk_notifier_data { | |||
| 78 | unsigned long new_rate; | 78 | unsigned long new_rate; |
| 79 | }; | 79 | }; |
| 80 | 80 | ||
| 81 | /** | ||
| 82 | * clk_notifier_register: register a clock rate-change notifier callback | ||
| 83 | * @clk: clock whose rate we are interested in | ||
| 84 | * @nb: notifier block with callback function pointer | ||
| 85 | * | ||
| 86 | * ProTip: debugging across notifier chains can be frustrating. Make sure that | ||
| 87 | * your notifier callback function prints a nice big warning in case of | ||
| 88 | * failure. | ||
| 89 | */ | ||
| 81 | int clk_notifier_register(struct clk *clk, struct notifier_block *nb); | 90 | int clk_notifier_register(struct clk *clk, struct notifier_block *nb); |
| 82 | 91 | ||
| 92 | /** | ||
| 93 | * clk_notifier_unregister: unregister a clock rate-change notifier callback | ||
| 94 | * @clk: clock whose rate we are no longer interested in | ||
| 95 | * @nb: notifier block which will be unregistered | ||
| 96 | */ | ||
| 83 | int clk_notifier_unregister(struct clk *clk, struct notifier_block *nb); | 97 | int clk_notifier_unregister(struct clk *clk, struct notifier_block *nb); |
| 84 | 98 | ||
| 85 | /** | 99 | /** |
