Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

powerpc: More little endian fixes for setup-common.c

Signed-off-by: Alistair Popple <alistair@popple.id.au>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>

authored by

Alistair Popple and committed by
Benjamin Herrenschmidt
43f88120 ac13282d

+5 -2
+5 -2
arch/powerpc/kernel/setup-common.c
··· 437 437 438 438 while ((dn = of_find_node_by_type(dn, "cpu")) && cpu < nr_cpu_ids) { 439 439 const __be32 *intserv; 440 + __be32 cpu_be; 440 441 int j, len; 441 442 442 443 DBG(" * %s...\n", dn->full_name); ··· 451 450 } else { 452 451 DBG(" no ibm,ppc-interrupt-server#s -> 1 thread\n"); 453 452 intserv = of_get_property(dn, "reg", NULL); 454 - if (!intserv) 455 - intserv = &cpu; /* assume logical == phys */ 453 + if (!intserv) { 454 + cpu_be = cpu_to_be32(cpu); 455 + intserv = &cpu_be; /* assume logical == phys */ 456 + } 456 457 } 457 458 458 459 for (j = 0; j < nthreads && cpu < nr_cpu_ids; j++) {