Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 274171
b: refs/heads/master
c: dfbe93a
h: refs/heads/master
i:
  274169: 35801b2
  274167: d9d9432
v: v3
  • Loading branch information
Anton Blanchard authored and Benjamin Herrenschmidt committed Sep 20, 2011
1 parent 9f28d22 commit 492bc88
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 94db7c5e14f44b943febe54e089d077cd983d284
refs/heads/master: dfbe93a222e74b6f96ad84eff2b04a0f864fac65
20 changes: 13 additions & 7 deletions trunk/arch/powerpc/kernel/setup_64.c
Original file line number Diff line number Diff line change
Expand Up @@ -281,11 +281,11 @@ static void __init initialize_cache_info(void)
for_each_node_by_type(np, "cpu") {
num_cpus += 1;

/* We're assuming *all* of the CPUs have the same
/*
* We're assuming *all* of the CPUs have the same
* d-cache and i-cache sizes... -Peter
*/

if ( num_cpus == 1 ) {
if (num_cpus == 1) {
const u32 *sizep, *lsizep;
u32 size, lsize;

Expand All @@ -294,10 +294,13 @@ static void __init initialize_cache_info(void)
sizep = of_get_property(np, "d-cache-size", NULL);
if (sizep != NULL)
size = *sizep;
lsizep = of_get_property(np, "d-cache-block-size", NULL);
lsizep = of_get_property(np, "d-cache-block-size",
NULL);
/* fallback if block size missing */
if (lsizep == NULL)
lsizep = of_get_property(np, "d-cache-line-size", NULL);
lsizep = of_get_property(np,
"d-cache-line-size",
NULL);
if (lsizep != NULL)
lsize = *lsizep;
if (sizep == 0 || lsizep == 0)
Expand All @@ -314,9 +317,12 @@ static void __init initialize_cache_info(void)
sizep = of_get_property(np, "i-cache-size", NULL);
if (sizep != NULL)
size = *sizep;
lsizep = of_get_property(np, "i-cache-block-size", NULL);
lsizep = of_get_property(np, "i-cache-block-size",
NULL);
if (lsizep == NULL)
lsizep = of_get_property(np, "i-cache-line-size", NULL);
lsizep = of_get_property(np,
"i-cache-line-size",
NULL);
if (lsizep != NULL)
lsize = *lsizep;
if (sizep == 0 || lsizep == 0)
Expand Down
7 changes: 4 additions & 3 deletions trunk/arch/powerpc/mm/numa.c
Original file line number Diff line number Diff line change
Expand Up @@ -709,7 +709,6 @@ static void __init parse_drconf_memory(struct device_node *memory)

static int __init parse_numa_properties(void)
{
struct device_node *cpu = NULL;
struct device_node *memory;
int default_nid = 0;
unsigned long i;
Expand All @@ -732,6 +731,7 @@ static int __init parse_numa_properties(void)
* each node to be onlined must have NODE_DATA etc backing it.
*/
for_each_present_cpu(i) {
struct device_node *cpu;
int nid;

cpu = of_get_cpu_node(i, NULL);
Expand Down Expand Up @@ -800,8 +800,9 @@ static int __init parse_numa_properties(void)
}

/*
* Now do the same thing for each MEMBLOCK listed in the ibm,dynamic-memory
* property in the ibm,dynamic-reconfiguration-memory node.
* Now do the same thing for each MEMBLOCK listed in the
* ibm,dynamic-memory property in the
* ibm,dynamic-reconfiguration-memory node.
*/
memory = of_find_node_by_path("/ibm,dynamic-reconfiguration-memory");
if (memory)
Expand Down

0 comments on commit 492bc88

Please sign in to comment.