diff options
author | Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> | 2009-03-05 10:17:53 -0500 |
---|---|---|
committer | Eric Miao <eric.miao@marvell.com> | 2009-03-19 04:20:39 -0400 |
commit | c68ffddabcaaa64c6ea681d2944cbda50a8654ea (patch) | |
tree | 902543d60f5731206b4aaa0a58be7d17a6b06881 /arch/arm/mach-pxa/clock.c | |
parent | d1b95607e1dde59e2ffae661732c8da34aba445c (diff) |
[ARM] pxa: make second argument of clk_add_alias a name instead of the device
clk_add_alias is commonly called for platform devices that are not yet
registered in the device tree. Thus the clock alias is associated with
NULL device name. Fix this by passing the device name instead of just
device pointer.
Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Diffstat (limited to 'arch/arm/mach-pxa/clock.c')
-rw-r--r-- | arch/arm/mach-pxa/clock.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm/mach-pxa/clock.c b/arch/arm/mach-pxa/clock.c index 40b774084514..db52d2c4791d 100644 --- a/arch/arm/mach-pxa/clock.c +++ b/arch/arm/mach-pxa/clock.c | |||
@@ -87,7 +87,7 @@ void clks_register(struct clk_lookup *clks, size_t num) | |||
87 | clkdev_add(&clks[i]); | 87 | clkdev_add(&clks[i]); |
88 | } | 88 | } |
89 | 89 | ||
90 | int clk_add_alias(char *alias, struct device *alias_dev, char *id, | 90 | int clk_add_alias(const char *alias, const char *alias_dev_name, char *id, |
91 | struct device *dev) | 91 | struct device *dev) |
92 | { | 92 | { |
93 | struct clk *r = clk_get(dev, id); | 93 | struct clk *r = clk_get(dev, id); |
@@ -96,7 +96,7 @@ int clk_add_alias(char *alias, struct device *alias_dev, char *id, | |||
96 | if (!r) | 96 | if (!r) |
97 | return -ENODEV; | 97 | return -ENODEV; |
98 | 98 | ||
99 | l = clkdev_alloc(r, alias, alias_dev ? dev_name(alias_dev) : NULL); | 99 | l = clkdev_alloc(r, alias, alias_dev_name); |
100 | clk_put(r); | 100 | clk_put(r); |
101 | if (!l) | 101 | if (!l) |
102 | return -ENODEV; | 102 | return -ENODEV; |