1 --- a/arch/powerpc/include/asm/spu.h 2012-03-01 01:32:49.000000000 +0100
2 +++ b/arch/powerpc/include/asm/spu.h 2012-03-05 17:49:44.083370504 +0100
5 extern struct cbe_spu_info cbe_spu_info[];
7 +extern int spu_enum_shared(void);
9 void spu_init_channels(struct spu *spu);
10 void spu_irq_setaffinity(struct spu *spu, int cpu);
12 --- a/arch/powerpc/platforms/cell/spu_base.c 2012-03-01 01:32:49.000000000 +0100
13 +++ b/arch/powerpc/platforms/cell/spu_base.c 2012-03-05 17:52:47.659547098 +0100
16 #include <asm/kexec.h>
18 +static int enum_shared = 0;
19 +module_param(enum_shared, int, S_IRUGO);
20 +MODULE_PARM_DESC(enum_shared, "Enumerate shared SPUs");
22 const struct spu_management_ops *spu_management_ops;
23 EXPORT_SYMBOL_GPL(spu_management_ops);
26 free_irq(spu->irqs[2], spu);
29 +int spu_enum_shared(void)
31 + return (enum_shared);
33 +EXPORT_SYMBOL_GPL(spu_enum_shared);
35 void spu_init_channels(struct spu *spu)
38 --- a/arch/powerpc/platforms/ps3/spu.c 2012-03-01 01:32:49.000000000 +0100
39 +++ b/arch/powerpc/platforms/ps3/spu.c 2012-03-05 17:54:01.800664787 +0100
44 - if (resource_type == PS3_SPU_RESOURCE_TYPE_EXCLUSIVE) {
45 + if (resource_type == PS3_SPU_RESOURCE_TYPE_EXCLUSIVE || spu_enum_shared()) {
46 result = fn((void*)(unsigned long)resource_id);