diff options
author | Stephen Rothwell <sfr@canb.auug.org.au> | 2007-04-02 20:57:48 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2007-04-12 13:55:18 -0400 |
commit | 9213feea6e197f8507ec855337798cc3388f5570 (patch) | |
tree | da8015e33f1a242a050ef62603bdc53a7982441c | |
parent | a8bda5dd4f99d6469f3c0dc362db3cce8a4d6416 (diff) |
[POWERPC] Rename prom_n_size_cells to of_n_size_cells
This is more consistent and gets us closer to the Sparc code.
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
-rw-r--r-- | arch/powerpc/kernel/prom.c | 5 | ||||
-rw-r--r-- | arch/powerpc/kernel/prom_parse.c | 4 | ||||
-rw-r--r-- | arch/powerpc/kernel/setup-common.c | 2 | ||||
-rw-r--r-- | arch/powerpc/mm/numa.c | 2 | ||||
-rw-r--r-- | drivers/char/tpm/tpm_atmel.h | 2 | ||||
-rw-r--r-- | include/asm-powerpc/prom.h | 2 |
6 files changed, 8 insertions, 9 deletions
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c index 08d619756d33..2890ce3d6641 100644 --- a/arch/powerpc/kernel/prom.c +++ b/arch/powerpc/kernel/prom.c | |||
@@ -1056,8 +1056,7 @@ int of_n_addr_cells(struct device_node* np) | |||
1056 | } | 1056 | } |
1057 | EXPORT_SYMBOL(of_n_addr_cells); | 1057 | EXPORT_SYMBOL(of_n_addr_cells); |
1058 | 1058 | ||
1059 | int | 1059 | int of_n_size_cells(struct device_node* np) |
1060 | prom_n_size_cells(struct device_node* np) | ||
1061 | { | 1060 | { |
1062 | const int* ip; | 1061 | const int* ip; |
1063 | do { | 1062 | do { |
@@ -1070,7 +1069,7 @@ prom_n_size_cells(struct device_node* np) | |||
1070 | /* No #size-cells property for the root node, default to 1 */ | 1069 | /* No #size-cells property for the root node, default to 1 */ |
1071 | return 1; | 1070 | return 1; |
1072 | } | 1071 | } |
1073 | EXPORT_SYMBOL(prom_n_size_cells); | 1072 | EXPORT_SYMBOL(of_n_size_cells); |
1074 | 1073 | ||
1075 | /** | 1074 | /** |
1076 | * Construct and return a list of the device_nodes with a given name. | 1075 | * Construct and return a list of the device_nodes with a given name. |
diff --git a/arch/powerpc/kernel/prom_parse.c b/arch/powerpc/kernel/prom_parse.c index e3d036fa6059..ba9c7c1e4108 100644 --- a/arch/powerpc/kernel/prom_parse.c +++ b/arch/powerpc/kernel/prom_parse.c | |||
@@ -70,7 +70,7 @@ static void of_bus_default_count_cells(struct device_node *dev, | |||
70 | if (addrc) | 70 | if (addrc) |
71 | *addrc = of_n_addr_cells(dev); | 71 | *addrc = of_n_addr_cells(dev); |
72 | if (sizec) | 72 | if (sizec) |
73 | *sizec = prom_n_size_cells(dev); | 73 | *sizec = of_n_size_cells(dev); |
74 | } | 74 | } |
75 | 75 | ||
76 | static u64 of_bus_default_map(u32 *addr, const u32 *range, | 76 | static u64 of_bus_default_map(u32 *addr, const u32 *range, |
@@ -660,7 +660,7 @@ void of_parse_dma_window(struct device_node *dn, const void *dma_window_prop, | |||
660 | dma_window += cells; | 660 | dma_window += cells; |
661 | 661 | ||
662 | prop = get_property(dn, "ibm,#dma-size-cells", NULL); | 662 | prop = get_property(dn, "ibm,#dma-size-cells", NULL); |
663 | cells = prop ? *(u32 *)prop : prom_n_size_cells(dn); | 663 | cells = prop ? *(u32 *)prop : of_n_size_cells(dn); |
664 | *size = of_read_number(dma_window, cells); | 664 | *size = of_read_number(dma_window, cells); |
665 | } | 665 | } |
666 | 666 | ||
diff --git a/arch/powerpc/kernel/setup-common.c b/arch/powerpc/kernel/setup-common.c index f7ef5a97c0ea..640ff0d8f83c 100644 --- a/arch/powerpc/kernel/setup-common.c +++ b/arch/powerpc/kernel/setup-common.c | |||
@@ -380,7 +380,7 @@ void __init smp_setup_cpu_maps(void) | |||
380 | const unsigned int *ireg; | 380 | const unsigned int *ireg; |
381 | 381 | ||
382 | num_addr_cell = of_n_addr_cells(dn); | 382 | num_addr_cell = of_n_addr_cells(dn); |
383 | num_size_cell = prom_n_size_cells(dn); | 383 | num_size_cell = of_n_size_cells(dn); |
384 | 384 | ||
385 | ireg = get_property(dn, "ibm,lrdr-capacity", NULL); | 385 | ireg = get_property(dn, "ibm,lrdr-capacity", NULL); |
386 | 386 | ||
diff --git a/arch/powerpc/mm/numa.c b/arch/powerpc/mm/numa.c index 119cef99a2b0..683839b2b06b 100644 --- a/arch/powerpc/mm/numa.c +++ b/arch/powerpc/mm/numa.c | |||
@@ -202,7 +202,7 @@ static void __init get_n_mem_cells(int *n_addr_cells, int *n_size_cells) | |||
202 | panic("numa.c: No memory nodes found!"); | 202 | panic("numa.c: No memory nodes found!"); |
203 | 203 | ||
204 | *n_addr_cells = of_n_addr_cells(memory); | 204 | *n_addr_cells = of_n_addr_cells(memory); |
205 | *n_size_cells = prom_n_size_cells(memory); | 205 | *n_size_cells = of_n_size_cells(memory); |
206 | of_node_put(memory); | 206 | of_node_put(memory); |
207 | } | 207 | } |
208 | 208 | ||
diff --git a/drivers/char/tpm/tpm_atmel.h b/drivers/char/tpm/tpm_atmel.h index 3501c0369d38..3c852009196e 100644 --- a/drivers/char/tpm/tpm_atmel.h +++ b/drivers/char/tpm/tpm_atmel.h | |||
@@ -54,7 +54,7 @@ static void __iomem * atmel_get_base_addr(unsigned long *base, int *region_size) | |||
54 | 54 | ||
55 | reg = get_property(dn, "reg", ®len); | 55 | reg = get_property(dn, "reg", ®len); |
56 | naddrc = of_n_addr_cells(dn); | 56 | naddrc = of_n_addr_cells(dn); |
57 | nsizec = prom_n_size_cells(dn); | 57 | nsizec = of_n_size_cells(dn); |
58 | 58 | ||
59 | of_node_put(dn); | 59 | of_node_put(dn); |
60 | 60 | ||
diff --git a/include/asm-powerpc/prom.h b/include/asm-powerpc/prom.h index e0c92bf2019b..fb068f2eca4a 100644 --- a/include/asm-powerpc/prom.h +++ b/include/asm-powerpc/prom.h | |||
@@ -172,7 +172,7 @@ extern const void *of_get_property(const struct device_node *node, | |||
172 | #define get_property(a, b, c) of_get_property((a), (b), (c)) | 172 | #define get_property(a, b, c) of_get_property((a), (b), (c)) |
173 | extern void print_properties(struct device_node *node); | 173 | extern void print_properties(struct device_node *node); |
174 | extern int of_n_addr_cells(struct device_node* np); | 174 | extern int of_n_addr_cells(struct device_node* np); |
175 | extern int prom_n_size_cells(struct device_node* np); | 175 | extern int of_n_size_cells(struct device_node* np); |
176 | extern int prom_n_intr_cells(struct device_node* np); | 176 | extern int prom_n_intr_cells(struct device_node* np); |
177 | extern void prom_get_irq_senses(unsigned char *senses, int off, int max); | 177 | extern void prom_get_irq_senses(unsigned char *senses, int off, int max); |
178 | extern int prom_add_property(struct device_node* np, struct property* prop); | 178 | extern int prom_add_property(struct device_node* np, struct property* prop); |