rtc: hym8563: add optional clock-output-names property
Subsystems (2)
PATCH 1/1 rtc: hym8563: add optional clock-output-names property
This enables the setting of a custom clock name for the clock provided by the hym8563 rtc.
Signed-off-by Heiko Stuebner <[email protected]>
--- Documentation/devicetree/bindings/rtc/haoyu,hym8563.txt | 3 +++ drivers/rtc/rtc-hym8563.c | 3 +++ 2 files changed, 6 insertions(+)
Documentation/devicetree/bindings/rtc/haoyu,hym8563.txt +3 -0
@@ -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 +3 -0
@@ -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);
Signature · 1 line
1.9.0
Quoting Heiko Stübner (2014-05-18 15:40:07)
Quoted 4 lines
This enables the setting of a custom clock name for the clock provided by the hym8563 rtc.
Signed-off-by Heiko Stuebner <[email protected]>
Annoying nitpick: would be nice to see the example updated to use clock-output-names. But it's not a deal breaker.
Reviewed-by Mike Turquette <[email protected]>
Regards,
Mike
Quoted 37 lines
--- Documentation/devicetree/bindings/rtc/haoyu,hym8563.txt | 3 +++ drivers/rtc/rtc-hym8563.c | 3 +++ 2 files changed, 6 insertions(+)Documentation/devicetree/bindings/rtc/haoyu,hym8563.txt +3
-0@@ -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 +3
-0@@ -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);Signature · 1 line
1.9.0