rtc: hym8563: add optional clock-output-names property
From: Heiko Stuebner <heiko@...> Date: Sat, 17 May 2014 22:15:36 +0200
Commit-Message
This enables the setting of a custom clock name for the clock provided by the hym8563 rtc. Signed-off-by: Heiko Stuebner <heiko@...>
Patch-Comment
Documentation/devicetree/bindings/rtc/haoyu,hym8563.txt | 3 +++ drivers/rtc/rtc-hym8563.c | 3 +++ 2 files changed, 6 insertions(+)
Statistics
- 6 lines added
- 0 lines removed
Changes
----------- Documentation/devicetree/bindings/rtc/haoyu,hym8563.txt ------------
index 31406fd..5c199ee 100644
@@ -9,6 +9,9 @@ Required properties:
- interrupts: rtc alarm/event interrupt
- #clock-cells: the value should be 0
+Optional properties:
+- clock-output-names: From common clock binding
+
Example:
hym8563: hym8563@51 {
-------------------------- drivers/rtc/rtc-hym8563.c ---------------------------
index e5f13c4..6442b5b 100644
@@ -418,6 +418,9 @@ static struct clk *hym8563_clkout_register_clk(struct hym8563 *hym8563)
init.num_parents = 0;
hym8563->clkout_hw.init = &init;
+ /* optional override of the clockname */
+ of_property_read_string(node, "clock-output-names", &init.name);
+
/* register the clock */
clk = clk_register(&client->dev, &hym8563->clkout_hw);