aboutsummaryrefslogtreecommitdiffstats
path: root/arch/microblaze/kernel
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2009-12-11 01:42:17 -0500
committerGrant Likely <grant.likely@secretlab.ca>2009-12-11 01:42:17 -0500
commit0f0b56c3f2df4a083fc9e934266e5bab1710e286 (patch)
tree8e40c58c5eaae83d68eba6c31a93ff9c5414800a /arch/microblaze/kernel
parent83f7a06eb479e2aeb83536e77a2cb14cc2285e32 (diff)
of/flattree: eliminate cell_t typedef
A cell is firmly established as a u32. No need to do an ugly typedef to redefine it to cell_t. Eliminate the unnecessary typedef so that it doesn't have to be added to the of_fdt header file Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Tested-by: Wolfram Sang <w.sang@pengutronix.de> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/microblaze/kernel')
-rw-r--r--arch/microblaze/kernel/prom.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/arch/microblaze/kernel/prom.c b/arch/microblaze/kernel/prom.c
index e0f4c34ed0f2..50d8b09d5e3f 100644
--- a/arch/microblaze/kernel/prom.c
+++ b/arch/microblaze/kernel/prom.c
@@ -42,8 +42,6 @@
42#include <asm/sections.h> 42#include <asm/sections.h>
43#include <asm/pci-bridge.h> 43#include <asm/pci-bridge.h>
44 44
45typedef u32 cell_t;
46
47/* export that to outside world */ 45/* export that to outside world */
48struct device_node *of_chosen; 46struct device_node *of_chosen;
49 47
@@ -159,7 +157,7 @@ static int __init early_init_dt_scan_memory(unsigned long node,
159 const char *uname, int depth, void *data) 157 const char *uname, int depth, void *data)
160{ 158{
161 char *type = of_get_flat_dt_prop(node, "device_type", NULL); 159 char *type = of_get_flat_dt_prop(node, "device_type", NULL);
162 cell_t *reg, *endp; 160 __be32 *reg, *endp;
163 unsigned long l; 161 unsigned long l;
164 162
165 /* Look for the ibm,dynamic-reconfiguration-memory node */ 163 /* Look for the ibm,dynamic-reconfiguration-memory node */
@@ -178,13 +176,13 @@ static int __init early_init_dt_scan_memory(unsigned long node,
178 } else if (strcmp(type, "memory") != 0) 176 } else if (strcmp(type, "memory") != 0)
179 return 0; 177 return 0;
180 178
181 reg = (cell_t *)of_get_flat_dt_prop(node, "linux,usable-memory", &l); 179 reg = (__be32 *)of_get_flat_dt_prop(node, "linux,usable-memory", &l);
182 if (reg == NULL) 180 if (reg == NULL)
183 reg = (cell_t *)of_get_flat_dt_prop(node, "reg", &l); 181 reg = (__be32 *)of_get_flat_dt_prop(node, "reg", &l);
184 if (reg == NULL) 182 if (reg == NULL)
185 return 0; 183 return 0;
186 184
187 endp = reg + (l / sizeof(cell_t)); 185 endp = reg + (l / sizeof(__be32));
188 186
189 pr_debug("memory scan node %s, reg size %ld, data: %x %x %x %x,\n", 187 pr_debug("memory scan node %s, reg size %ld, data: %x %x %x %x,\n",
190 uname, l, reg[0], reg[1], reg[2], reg[3]); 188 uname, l, reg[0], reg[1], reg[2], reg[3]);