Re: [PATCHv2 2/2] Update ibm,client-architecture call field based on device tree

2010-02-03 Thread Benjamin Herrenschmidt
On Tue, 2010-02-02 at 12:37 -0600, Joel Schopp wrote: > >> + if(*cores != NR_CPUS) > >> + prom_printf("client-architecture structure > >> corrupted\n"); > >> + *cores = (NR_CPUS / prom_smt_way()); > >> + prom_printf("setting client-architecture cores to

Re: [PATCHv2 2/2] Update ibm,client-architecture call field based on device tree

2010-02-02 Thread Joel Schopp
+ if(*cores != NR_CPUS) + prom_printf("client-architecture structure corrupted\n"); + *cores = (NR_CPUS / prom_smt_way()); + prom_printf("setting client-architecture cores to %x\n", *cores); I don't know if I'm painting a b

Re: [PATCHv2 2/2] Update ibm,client-architecture call field based on device tree

2010-02-01 Thread Tony Breeds
On Mon, Feb 01, 2010 at 04:51:02PM -0600, Joel Schopp wrote: > static void __init prom_send_capabilities(void) > { > ihandle elfloader, root; > prom_arg_t ret; > + u32 *cores; > > root = call_prom("open", 1, 1, ADDR("/")); > if (root != 0) { > + /* > +

[PATCHv2 2/2] Update ibm,client-architecture call field based on device tree

2010-02-01 Thread Joel Schopp
In the previous patch the client-architecture field for the number of cores supported is set statically as high as is possible. However, that static setting could be too high if the system supports smt, resulting in cpus assigned to Linux that are not booted. This patch reads the device tree (bef