aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Lunn <andrew@lunn.ch>2012-07-27 10:45:25 -0400
committerAndrew Lunn <andrew@lunn.ch>2012-07-27 10:45:25 -0400
commit89fb2d77d5daa821e3868ea59963f28249974840 (patch)
tree6cc80209a208133000c203cf9a9f61dd42fd53a9
parent4297103560b4c5aba904e4711e982a039619f1f6 (diff)
parent778435045a416da71f1757a80e37200a5ea5af70 (diff)
Merge branch 'v3.5-rc7-fixes' into v3.5-rc7-dt-v3
Merge in branch already pulled. Fulfils dependancies needed by this patchset.
-rw-r--r--Documentation/devicetree/bindings/mtd/orion-nand.txt4
-rw-r--r--arch/arm/boot/dts/kirkwood-dns320.dts2
-rw-r--r--arch/arm/boot/dts/kirkwood-dns325.dts2
-rw-r--r--arch/arm/boot/dts/kirkwood-dreamplug.dts2
-rw-r--r--arch/arm/boot/dts/kirkwood-ib62x0.dts2
-rw-r--r--arch/arm/boot/dts/kirkwood-iconnect.dts2
-rw-r--r--arch/arm/boot/dts/kirkwood.dtsi6
-rw-r--r--arch/arm/mach-dove/common.c4
-rw-r--r--arch/arm/mach-kirkwood/common.c70
-rw-r--r--drivers/crypto/mv_cesa.c4
-rw-r--r--drivers/mmc/host/mvsdio.c4
-rw-r--r--drivers/mtd/nand/orion_nand.c6
-rw-r--r--drivers/net/ethernet/marvell/mv643xx_eth.c6
-rw-r--r--drivers/rtc/rtc-mv.c2
-rw-r--r--drivers/usb/host/ehci-orion.c4
-rw-r--r--sound/soc/kirkwood/kirkwood-i2s.c8
16 files changed, 98 insertions, 30 deletions
diff --git a/Documentation/devicetree/bindings/mtd/orion-nand.txt b/Documentation/devicetree/bindings/mtd/orion-nand.txt
index b2356b7d2fa4..2d6ab660e603 100644
--- a/Documentation/devicetree/bindings/mtd/orion-nand.txt
+++ b/Documentation/devicetree/bindings/mtd/orion-nand.txt
@@ -1,7 +1,7 @@
1NAND support for Marvell Orion SoC platforms 1NAND support for Marvell Orion SoC platforms
2 2
3Required properties: 3Required properties:
4- compatible : "mrvl,orion-nand". 4- compatible : "marvell,orion-nand".
5- reg : Base physical address of the NAND and length of memory mapped 5- reg : Base physical address of the NAND and length of memory mapped
6 region 6 region
7 7
@@ -24,7 +24,7 @@ nand@f4000000 {
24 ale = <1>; 24 ale = <1>;
25 bank-width = <1>; 25 bank-width = <1>;
26 chip-delay = <25>; 26 chip-delay = <25>;
27 compatible = "mrvl,orion-nand"; 27 compatible = "marvell,orion-nand";
28 reg = <0xf4000000 0x400>; 28 reg = <0xf4000000 0x400>;
29 29
30 partition@0 { 30 partition@0 {
diff --git a/arch/arm/boot/dts/kirkwood-dns320.dts b/arch/arm/boot/dts/kirkwood-dns320.dts
index dc09a735b04a..9a33077130e8 100644
--- a/arch/arm/boot/dts/kirkwood-dns320.dts
+++ b/arch/arm/boot/dts/kirkwood-dns320.dts
@@ -4,7 +4,7 @@
4 4
5/ { 5/ {
6 model = "D-Link DNS-320 NAS (Rev A1)"; 6 model = "D-Link DNS-320 NAS (Rev A1)";
7 compatible = "dlink,dns-320-a1", "dlink,dns-320", "dlink,dns-kirkwood", "mrvl,kirkwood-88f6281", "mrvl,kirkwood"; 7 compatible = "dlink,dns-320-a1", "dlink,dns-320", "dlink,dns-kirkwood", "marvell,kirkwood-88f6281", "marvell,kirkwood";
8 8
9 memory { 9 memory {
10 device_type = "memory"; 10 device_type = "memory";
diff --git a/arch/arm/boot/dts/kirkwood-dns325.dts b/arch/arm/boot/dts/kirkwood-dns325.dts
index c2a5562525d2..16734c1b5dfe 100644
--- a/arch/arm/boot/dts/kirkwood-dns325.dts
+++ b/arch/arm/boot/dts/kirkwood-dns325.dts
@@ -4,7 +4,7 @@
4 4
5/ { 5/ {
6 model = "D-Link DNS-325 NAS (Rev A1)"; 6 model = "D-Link DNS-325 NAS (Rev A1)";
7 compatible = "dlink,dns-325-a1", "dlink,dns-325", "dlink,dns-kirkwood", "mrvl,kirkwood-88f6281", "mrvl,kirkwood"; 7 compatible = "dlink,dns-325-a1", "dlink,dns-325", "dlink,dns-kirkwood", "marvell,kirkwood-88f6281", "marvell,kirkwood";
8 8
9 memory { 9 memory {
10 device_type = "memory"; 10 device_type = "memory";
diff --git a/arch/arm/boot/dts/kirkwood-dreamplug.dts b/arch/arm/boot/dts/kirkwood-dreamplug.dts
index a5376b84227f..78b0f06a09a2 100644
--- a/arch/arm/boot/dts/kirkwood-dreamplug.dts
+++ b/arch/arm/boot/dts/kirkwood-dreamplug.dts
@@ -4,7 +4,7 @@
4 4
5/ { 5/ {
6 model = "Globalscale Technologies Dreamplug"; 6 model = "Globalscale Technologies Dreamplug";
7 compatible = "globalscale,dreamplug-003-ds2001", "globalscale,dreamplug", "mrvl,kirkwood-88f6281", "mrvl,kirkwood"; 7 compatible = "globalscale,dreamplug-003-ds2001", "globalscale,dreamplug", "marvell,kirkwood-88f6281", "marvell,kirkwood";
8 8
9 memory { 9 memory {
10 device_type = "memory"; 10 device_type = "memory";
diff --git a/arch/arm/boot/dts/kirkwood-ib62x0.dts b/arch/arm/boot/dts/kirkwood-ib62x0.dts
index ada0f0c23085..f59dcf6dc45f 100644
--- a/arch/arm/boot/dts/kirkwood-ib62x0.dts
+++ b/arch/arm/boot/dts/kirkwood-ib62x0.dts
@@ -4,7 +4,7 @@
4 4
5/ { 5/ {
6 model = "RaidSonic ICY BOX IB-NAS62x0 (Rev B)"; 6 model = "RaidSonic ICY BOX IB-NAS62x0 (Rev B)";
7 compatible = "raidsonic,ib-nas6210-b", "raidsonic,ib-nas6220-b", "raidsonic,ib-nas6210", "raidsonic,ib-nas6220", "raidsonic,ib-nas62x0", "mrvl,kirkwood-88f6281", "mrvl,kirkwood"; 7 compatible = "raidsonic,ib-nas6210-b", "raidsonic,ib-nas6220-b", "raidsonic,ib-nas6210", "raidsonic,ib-nas6220", "raidsonic,ib-nas62x0", "marvell,kirkwood-88f6281", "marvell,kirkwood";
8 8
9 memory { 9 memory {
10 device_type = "memory"; 10 device_type = "memory";
diff --git a/arch/arm/boot/dts/kirkwood-iconnect.dts b/arch/arm/boot/dts/kirkwood-iconnect.dts
index 1ba75d4adecc..026a1f82d813 100644
--- a/arch/arm/boot/dts/kirkwood-iconnect.dts
+++ b/arch/arm/boot/dts/kirkwood-iconnect.dts
@@ -4,7 +4,7 @@
4 4
5/ { 5/ {
6 model = "Iomega Iconnect"; 6 model = "Iomega Iconnect";
7 compatible = "iom,iconnect-1.1", "iom,iconnect", "mrvl,kirkwood-88f6281", "mrvl,kirkwood"; 7 compatible = "iom,iconnect-1.1", "iom,iconnect", "marvell,kirkwood-88f6281", "marvell,kirkwood";
8 8
9 memory { 9 memory {
10 device_type = "memory"; 10 device_type = "memory";
diff --git a/arch/arm/boot/dts/kirkwood.dtsi b/arch/arm/boot/dts/kirkwood.dtsi
index 926528b81baa..f95dbc190ab6 100644
--- a/arch/arm/boot/dts/kirkwood.dtsi
+++ b/arch/arm/boot/dts/kirkwood.dtsi
@@ -1,7 +1,7 @@
1/include/ "skeleton.dtsi" 1/include/ "skeleton.dtsi"
2 2
3/ { 3/ {
4 compatible = "mrvl,kirkwood"; 4 compatible = "marvell,kirkwood";
5 5
6 ocp@f1000000 { 6 ocp@f1000000 {
7 compatible = "simple-bus"; 7 compatible = "simple-bus";
@@ -28,7 +28,7 @@
28 }; 28 };
29 29
30 rtc@10300 { 30 rtc@10300 {
31 compatible = "mrvl,kirkwood-rtc", "mrvl,orion-rtc"; 31 compatible = "marvell,kirkwood-rtc", "marvell,orion-rtc";
32 reg = <0x10300 0x20>; 32 reg = <0x10300 0x20>;
33 interrupts = <53>; 33 interrupts = <53>;
34 }; 34 };
@@ -39,7 +39,7 @@
39 cle = <0>; 39 cle = <0>;
40 ale = <1>; 40 ale = <1>;
41 bank-width = <1>; 41 bank-width = <1>;
42 compatible = "mrvl,orion-nand"; 42 compatible = "marvell,orion-nand";
43 reg = <0x3000000 0x400>; 43 reg = <0x3000000 0x400>;
44 chip-delay = <25>; 44 chip-delay = <25>;
45 /* set partition map and/or chip-delay in board dts */ 45 /* set partition map and/or chip-delay in board dts */
diff --git a/arch/arm/mach-dove/common.c b/arch/arm/mach-dove/common.c
index 9493076fc594..4db5de54b6a7 100644
--- a/arch/arm/mach-dove/common.c
+++ b/arch/arm/mach-dove/common.c
@@ -101,8 +101,8 @@ void __init dove_ehci1_init(void)
101 ****************************************************************************/ 101 ****************************************************************************/
102void __init dove_ge00_init(struct mv643xx_eth_platform_data *eth_data) 102void __init dove_ge00_init(struct mv643xx_eth_platform_data *eth_data)
103{ 103{
104 orion_ge00_init(eth_data, 104 orion_ge00_init(eth_data, DOVE_GE00_PHYS_BASE,
105 DOVE_GE00_PHYS_BASE, IRQ_DOVE_GE00_SUM, 0); 105 IRQ_DOVE_GE00_SUM, IRQ_DOVE_GE00_ERR);
106} 106}
107 107
108/***************************************************************************** 108/*****************************************************************************
diff --git a/arch/arm/mach-kirkwood/common.c b/arch/arm/mach-kirkwood/common.c
index f261cd242643..c9201539ffbd 100644
--- a/arch/arm/mach-kirkwood/common.c
+++ b/arch/arm/mach-kirkwood/common.c
@@ -67,6 +67,14 @@ void __init kirkwood_map_io(void)
67 * CLK tree 67 * CLK tree
68 ****************************************************************************/ 68 ****************************************************************************/
69 69
70static void enable_sata0(void)
71{
72 /* Enable PLL and IVREF */
73 writel(readl(SATA0_PHY_MODE_2) | 0xf, SATA0_PHY_MODE_2);
74 /* Enable PHY */
75 writel(readl(SATA0_IF_CTRL) & ~0x200, SATA0_IF_CTRL);
76}
77
70static void disable_sata0(void) 78static void disable_sata0(void)
71{ 79{
72 /* Disable PLL and IVREF */ 80 /* Disable PLL and IVREF */
@@ -75,6 +83,14 @@ static void disable_sata0(void)
75 writel(readl(SATA0_IF_CTRL) | 0x200, SATA0_IF_CTRL); 83 writel(readl(SATA0_IF_CTRL) | 0x200, SATA0_IF_CTRL);
76} 84}
77 85
86static void enable_sata1(void)
87{
88 /* Enable PLL and IVREF */
89 writel(readl(SATA1_PHY_MODE_2) | 0xf, SATA1_PHY_MODE_2);
90 /* Enable PHY */
91 writel(readl(SATA1_IF_CTRL) & ~0x200, SATA1_IF_CTRL);
92}
93
78static void disable_sata1(void) 94static void disable_sata1(void)
79{ 95{
80 /* Disable PLL and IVREF */ 96 /* Disable PLL and IVREF */
@@ -107,23 +123,38 @@ static void disable_pcie1(void)
107 } 123 }
108} 124}
109 125
110/* An extended version of the gated clk. This calls fn() before 126/* An extended version of the gated clk. This calls fn_en()/fn_dis
111 * disabling the clock. We use this to turn off PHYs etc. */ 127 * before enabling/disabling the clock. We use this to turn on/off
128 * PHYs etc. */
112struct clk_gate_fn { 129struct clk_gate_fn {
113 struct clk_gate gate; 130 struct clk_gate gate;
114 void (*fn)(void); 131 void (*fn_en)(void);
132 void (*fn_dis)(void);
115}; 133};
116 134
117#define to_clk_gate_fn(_gate) container_of(_gate, struct clk_gate_fn, gate) 135#define to_clk_gate_fn(_gate) container_of(_gate, struct clk_gate_fn, gate)
118#define to_clk_gate(_hw) container_of(_hw, struct clk_gate, hw) 136#define to_clk_gate(_hw) container_of(_hw, struct clk_gate, hw)
119 137
138static int clk_gate_fn_enable(struct clk_hw *hw)
139{
140 struct clk_gate *gate = to_clk_gate(hw);
141 struct clk_gate_fn *gate_fn = to_clk_gate_fn(gate);
142 int ret;
143
144 ret = clk_gate_ops.enable(hw);
145 if (!ret && gate_fn->fn_en)
146 gate_fn->fn_en();
147
148 return ret;
149}
150
120static void clk_gate_fn_disable(struct clk_hw *hw) 151static void clk_gate_fn_disable(struct clk_hw *hw)
121{ 152{
122 struct clk_gate *gate = to_clk_gate(hw); 153 struct clk_gate *gate = to_clk_gate(hw);
123 struct clk_gate_fn *gate_fn = to_clk_gate_fn(gate); 154 struct clk_gate_fn *gate_fn = to_clk_gate_fn(gate);
124 155
125 if (gate_fn->fn) 156 if (gate_fn->fn_dis)
126 gate_fn->fn(); 157 gate_fn->fn_dis();
127 158
128 clk_gate_ops.disable(hw); 159 clk_gate_ops.disable(hw);
129} 160}
@@ -135,7 +166,7 @@ static struct clk __init *clk_register_gate_fn(struct device *dev,
135 const char *parent_name, unsigned long flags, 166 const char *parent_name, unsigned long flags,
136 void __iomem *reg, u8 bit_idx, 167 void __iomem *reg, u8 bit_idx,
137 u8 clk_gate_flags, spinlock_t *lock, 168 u8 clk_gate_flags, spinlock_t *lock,
138 void (*fn)(void)) 169 void (*fn_en)(void), void (*fn_dis)(void))
139{ 170{
140 struct clk_gate_fn *gate_fn; 171 struct clk_gate_fn *gate_fn;
141 struct clk *clk; 172 struct clk *clk;
@@ -159,11 +190,14 @@ static struct clk __init *clk_register_gate_fn(struct device *dev,
159 gate_fn->gate.flags = clk_gate_flags; 190 gate_fn->gate.flags = clk_gate_flags;
160 gate_fn->gate.lock = lock; 191 gate_fn->gate.lock = lock;
161 gate_fn->gate.hw.init = &init; 192 gate_fn->gate.hw.init = &init;
162 gate_fn->fn = fn; 193 gate_fn->fn_en = fn_en;
194 gate_fn->fn_dis = fn_dis;
163 195
164 /* ops is the gate ops, but with our disable function */ 196 /* ops is the gate ops, but with our enable/disable functions */
165 if (clk_gate_fn_ops.disable != clk_gate_fn_disable) { 197 if (clk_gate_fn_ops.enable != clk_gate_fn_enable ||
198 clk_gate_fn_ops.disable != clk_gate_fn_disable) {
166 clk_gate_fn_ops = clk_gate_ops; 199 clk_gate_fn_ops = clk_gate_ops;
200 clk_gate_fn_ops.enable = clk_gate_fn_enable;
167 clk_gate_fn_ops.disable = clk_gate_fn_disable; 201 clk_gate_fn_ops.disable = clk_gate_fn_disable;
168 } 202 }
169 203
@@ -187,11 +221,12 @@ static struct clk __init *kirkwood_register_gate(const char *name, u8 bit_idx)
187 221
188static struct clk __init *kirkwood_register_gate_fn(const char *name, 222static struct clk __init *kirkwood_register_gate_fn(const char *name,
189 u8 bit_idx, 223 u8 bit_idx,
190 void (*fn)(void)) 224 void (*fn_en)(void),
225 void (*fn_dis)(void))
191{ 226{
192 return clk_register_gate_fn(NULL, name, "tclk", 0, 227 return clk_register_gate_fn(NULL, name, "tclk", 0,
193 (void __iomem *)CLOCK_GATING_CTRL, 228 (void __iomem *)CLOCK_GATING_CTRL,
194 bit_idx, 0, &gating_lock, fn); 229 bit_idx, 0, &gating_lock, fn_en, fn_dis);
195} 230}
196 231
197static struct clk *ge0, *ge1; 232static struct clk *ge0, *ge1;
@@ -208,18 +243,18 @@ void __init kirkwood_clk_init(void)
208 ge0 = kirkwood_register_gate("ge0", CGC_BIT_GE0); 243 ge0 = kirkwood_register_gate("ge0", CGC_BIT_GE0);
209 ge1 = kirkwood_register_gate("ge1", CGC_BIT_GE1); 244 ge1 = kirkwood_register_gate("ge1", CGC_BIT_GE1);
210 sata0 = kirkwood_register_gate_fn("sata0", CGC_BIT_SATA0, 245 sata0 = kirkwood_register_gate_fn("sata0", CGC_BIT_SATA0,
211 disable_sata0); 246 enable_sata0, disable_sata0);
212 sata1 = kirkwood_register_gate_fn("sata1", CGC_BIT_SATA1, 247 sata1 = kirkwood_register_gate_fn("sata1", CGC_BIT_SATA1,
213 disable_sata1); 248 enable_sata1, disable_sata1);
214 usb0 = kirkwood_register_gate("usb0", CGC_BIT_USB0); 249 usb0 = kirkwood_register_gate("usb0", CGC_BIT_USB0);
215 sdio = kirkwood_register_gate("sdio", CGC_BIT_SDIO); 250 sdio = kirkwood_register_gate("sdio", CGC_BIT_SDIO);
216 crypto = kirkwood_register_gate("crypto", CGC_BIT_CRYPTO); 251 crypto = kirkwood_register_gate("crypto", CGC_BIT_CRYPTO);
217 xor0 = kirkwood_register_gate("xor0", CGC_BIT_XOR0); 252 xor0 = kirkwood_register_gate("xor0", CGC_BIT_XOR0);
218 xor1 = kirkwood_register_gate("xor1", CGC_BIT_XOR1); 253 xor1 = kirkwood_register_gate("xor1", CGC_BIT_XOR1);
219 pex0 = kirkwood_register_gate_fn("pex0", CGC_BIT_PEX0, 254 pex0 = kirkwood_register_gate_fn("pex0", CGC_BIT_PEX0,
220 disable_pcie0); 255 NULL, disable_pcie0);
221 pex1 = kirkwood_register_gate_fn("pex1", CGC_BIT_PEX1, 256 pex1 = kirkwood_register_gate_fn("pex1", CGC_BIT_PEX1,
222 disable_pcie1); 257 NULL, disable_pcie1);
223 audio = kirkwood_register_gate("audio", CGC_BIT_AUDIO); 258 audio = kirkwood_register_gate("audio", CGC_BIT_AUDIO);
224 kirkwood_register_gate("tdm", CGC_BIT_TDM); 259 kirkwood_register_gate("tdm", CGC_BIT_TDM);
225 kirkwood_register_gate("tsu", CGC_BIT_TSU); 260 kirkwood_register_gate("tsu", CGC_BIT_TSU);
@@ -241,6 +276,11 @@ void __init kirkwood_clk_init(void)
241 orion_clkdev_add("0", "pcie", pex0); 276 orion_clkdev_add("0", "pcie", pex0);
242 orion_clkdev_add("1", "pcie", pex1); 277 orion_clkdev_add("1", "pcie", pex1);
243 orion_clkdev_add(NULL, "kirkwood-i2s", audio); 278 orion_clkdev_add(NULL, "kirkwood-i2s", audio);
279
280 /* Marvell says runit is used by SPI, UART, NAND, TWSI, ...,
281 * so should never be gated.
282 */
283 clk_prepare_enable(runit);
244} 284}
245 285
246/***************************************************************************** 286/*****************************************************************************
diff --git a/drivers/crypto/mv_cesa.c b/drivers/crypto/mv_cesa.c
index 1cc6b3f3e262..a4faa893199c 100644
--- a/drivers/crypto/mv_cesa.c
+++ b/drivers/crypto/mv_cesa.c
@@ -1098,6 +1098,10 @@ err_unreg_ecb:
1098 crypto_unregister_alg(&mv_aes_alg_ecb); 1098 crypto_unregister_alg(&mv_aes_alg_ecb);
1099err_irq: 1099err_irq:
1100 free_irq(irq, cp); 1100 free_irq(irq, cp);
1101 if (!IS_ERR(cp->clk)) {
1102 clk_disable_unprepare(cp->clk);
1103 clk_put(cp->clk);
1104 }
1101err_thread: 1105err_thread:
1102 kthread_stop(cp->queue_th); 1106 kthread_stop(cp->queue_th);
1103err_unmap_sram: 1107err_unmap_sram:
diff --git a/drivers/mmc/host/mvsdio.c b/drivers/mmc/host/mvsdio.c
index 3b9136c1a475..a61cb5fca22d 100644
--- a/drivers/mmc/host/mvsdio.c
+++ b/drivers/mmc/host/mvsdio.c
@@ -839,6 +839,10 @@ out:
839 if (r) 839 if (r)
840 release_resource(r); 840 release_resource(r);
841 if (mmc) 841 if (mmc)
842 if (!IS_ERR_OR_NULL(host->clk)) {
843 clk_disable_unprepare(host->clk);
844 clk_put(host->clk);
845 }
842 mmc_free_host(mmc); 846 mmc_free_host(mmc);
843 847
844 return ret; 848 return ret;
diff --git a/drivers/mtd/nand/orion_nand.c b/drivers/mtd/nand/orion_nand.c
index 513dc88a05ca..fc5a868c436e 100644
--- a/drivers/mtd/nand/orion_nand.c
+++ b/drivers/mtd/nand/orion_nand.c
@@ -183,6 +183,10 @@ static int __init orion_nand_probe(struct platform_device *pdev)
183 return 0; 183 return 0;
184 184
185no_dev: 185no_dev:
186 if (!IS_ERR(clk)) {
187 clk_disable_unprepare(clk);
188 clk_put(clk);
189 }
186 platform_set_drvdata(pdev, NULL); 190 platform_set_drvdata(pdev, NULL);
187 iounmap(io_base); 191 iounmap(io_base);
188no_res: 192no_res:
@@ -214,7 +218,7 @@ static int __devexit orion_nand_remove(struct platform_device *pdev)
214 218
215#ifdef CONFIG_OF 219#ifdef CONFIG_OF
216static struct of_device_id orion_nand_of_match_table[] = { 220static struct of_device_id orion_nand_of_match_table[] = {
217 { .compatible = "mrvl,orion-nand", }, 221 { .compatible = "marvell,orion-nand", },
218 {}, 222 {},
219}; 223};
220#endif 224#endif
diff --git a/drivers/net/ethernet/marvell/mv643xx_eth.c b/drivers/net/ethernet/marvell/mv643xx_eth.c
index f0f06b2bc28b..4fbba57b8ff4 100644
--- a/drivers/net/ethernet/marvell/mv643xx_eth.c
+++ b/drivers/net/ethernet/marvell/mv643xx_eth.c
@@ -2983,6 +2983,12 @@ static int mv643xx_eth_probe(struct platform_device *pdev)
2983 return 0; 2983 return 0;
2984 2984
2985out: 2985out:
2986#if defined(CONFIG_HAVE_CLK)
2987 if (!IS_ERR(mp->clk)) {
2988 clk_disable_unprepare(mp->clk);
2989 clk_put(mp->clk);
2990 }
2991#endif
2986 free_netdev(dev); 2992 free_netdev(dev);
2987 2993
2988 return err; 2994 return err;
diff --git a/drivers/rtc/rtc-mv.c b/drivers/rtc/rtc-mv.c
index b2185f4255aa..ebc1649d45d6 100644
--- a/drivers/rtc/rtc-mv.c
+++ b/drivers/rtc/rtc-mv.c
@@ -297,7 +297,7 @@ static int __exit mv_rtc_remove(struct platform_device *pdev)
297 297
298#ifdef CONFIG_OF 298#ifdef CONFIG_OF
299static struct of_device_id rtc_mv_of_match_table[] = { 299static struct of_device_id rtc_mv_of_match_table[] = {
300 { .compatible = "mrvl,orion-rtc", }, 300 { .compatible = "marvell,orion-rtc", },
301 {} 301 {}
302}; 302};
303#endif 303#endif
diff --git a/drivers/usb/host/ehci-orion.c b/drivers/usb/host/ehci-orion.c
index 82de1073aa52..c6903e3af29c 100644
--- a/drivers/usb/host/ehci-orion.c
+++ b/drivers/usb/host/ehci-orion.c
@@ -298,6 +298,10 @@ static int __devinit ehci_orion_drv_probe(struct platform_device *pdev)
298err4: 298err4:
299 usb_put_hcd(hcd); 299 usb_put_hcd(hcd);
300err3: 300err3:
301 if (!IS_ERR(clk)) {
302 clk_disable_unprepare(clk);
303 clk_put(clk);
304 }
301 iounmap(regs); 305 iounmap(regs);
302err2: 306err2:
303 release_mem_region(res->start, resource_size(res)); 307 release_mem_region(res->start, resource_size(res));
diff --git a/sound/soc/kirkwood/kirkwood-i2s.c b/sound/soc/kirkwood/kirkwood-i2s.c
index fa4556750451..7646dd7f30cb 100644
--- a/sound/soc/kirkwood/kirkwood-i2s.c
+++ b/sound/soc/kirkwood/kirkwood-i2s.c
@@ -458,7 +458,13 @@ static __devinit int kirkwood_i2s_dev_probe(struct platform_device *pdev)
458 } 458 }
459 clk_prepare_enable(priv->clk); 459 clk_prepare_enable(priv->clk);
460 460
461 return snd_soc_register_dai(&pdev->dev, &kirkwood_i2s_dai); 461 err = snd_soc_register_dai(&pdev->dev, &kirkwood_i2s_dai);
462 if (!err)
463 return 0;
464 dev_err(&pdev->dev, "snd_soc_register_dai failed\n");
465
466 clk_disable_unprepare(priv->clk);
467 clk_put(priv->clk);
462 468
463err_ioremap: 469err_ioremap:
464 iounmap(priv->io); 470 iounmap(priv->io);