Skip to contentSkip to conversation

ARM: mxs: Adjust of_find_property()

PATCH New Fabio Estevam 2 participants 3 messages Jul 23, 2012 – Jul 25, 2012

Subsystems (3)
lore
Share & tools
lore

Fabio Estevam

author reviewer
#0 lore raw

PATCH 1/1 ARM: mxs: Adjust of_find_property()

From: Fabio Estevam <[email protected]>

Since commit 475d00 (of: Improve prom_update_property() function) prom_update_property requires two arguments.

Fix this in order to get rid of the following build error:

arch/arm/mach-mxs/mach-mxs.c:175:4: error: too many arguments to function 'prom_update_property'

---
 arch/arm/mach-mxs/mach-mxs.c |    8 ++------
 1 files changed, 2 insertions(+), 6 deletions(-)
arch/arm/mach-mxs/mach-mxs.c +2 -6
index 648bdd0..b70011d 100644
@@ -162,7 +162,7 @@ enum mac_oui {
 static void __init update_fec_mac_prop(enum mac_oui oui)
 {
 	struct device_node *np, *from = NULL;
-	struct property *oldmac, *newmac;
+	struct property *newmac;
 	const u32 *ocotp = mxs_get_ocotp();
 	u8 *macaddr;
 	u32 val;
@@ -208,11 +208,7 @@ static void __init update_fec_mac_prop(enum mac_oui oui)
 		macaddr[4] = (val >> 8) & 0xff;
 		macaddr[5] = (val >> 0) & 0xff;
 
-		oldmac = of_find_property(np, newmac->name, NULL);
-		if (oldmac)
-			prom_update_property(np, newmac, oldmac);
-		else
-			prom_add_property(np, newmac);
+		prom_add_property(np, newmac);
 	}
 }
 
Signature · 1 line
1.7.1
#1 lore raw

PATCH 1/1 ARM: mxs: Adjust of_find_property()

Quoted 8 lines · On Mon, 23 Jul 2012 04:28:58 -0300 Fabio Estevam <[email protected]> wrote:

From: Fabio Estevam <[email protected]>

Since commit 475d00 (of: Improve prom_update_property() function) prom_update_property requires two arguments.

Fix this in order to get rid of the following build error:

arch/arm/mach-mxs/mach-mxs.c:175:4: error: too many arguments to function 'prom_update_property'

The same fix has been already send by Shawn Guo[1] and Lauri Hintsala[2]

Attila Kinali

[1] http://article.gmane.org/gmane.linux.kernel.next/23330
[2] http://article.gmane.org/gmane.linux.ports.arm.kernel/177465

Signature · 4 lines
The trouble with you, Shev, is you don't say anything until you've saved
up a whole truckload of damned heavy brick arguments and then you dump
them all out and never look at the bleeding body mangled beneath the heap
		-- Tirin, The Dispossessed, U. Le Guin
author reviewer
#2 lore raw

PATCH 1/1 ARM: mxs: Adjust of_find_property()

Quoted 5 lines · Attila Kinali
Quoted 2 lines · On Mon, 23 Jul 2012 04:28:58 -0300 Fabio Estevam <[email protected]> wrote:

From: Fabio Estevam <[email protected]>

Quoted 8 lines
Quoted 6 lines

Since commit 475d00 (of: Improve prom_update_property() function) prom_update_property requires two arguments.

Fix this in order to get rid of the following build error:

arch/arm/mach-mxs/mach-mxs.c:175:4: error: too many arguments to function 'prom_update_property'

The same fix has been already send by Shawn Guo[1] and Lauri Hintsala[2]

Couldn't one of this patch be applied then?