From: Arnd Bergmann Date: Wed, 4 Oct 2006 15:26:15 +0000 (+0200) Subject: [POWERPC] spufs: Add infrastructure needed for gang scheduling X-Git-Tag: v2.6.19-rc1~3^2~9 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6263203ed6e9ff107129a1ebe613290b342a4465;p=pandora-kernel.git [POWERPC] spufs: Add infrastructure needed for gang scheduling Add the concept of a gang to spufs as a new type of object. So far, this has no impact whatsover on scheduling, but makes it possible to add that later. A new type of object in spufs is now a spu_gang. It is created with the spu_create system call with the flags argument set to SPU_CREATE_GANG (0x2). Inside of a spu_gang, it is then possible to create spu_context objects, which until now was only possible at the root of spufs. There is a new member in struct spu_context pointing to the spu_gang it belongs to, if any. The spu_gang maintains a list of spu_context structures that are its children. This information can then be used in the scheduler in the future. There is still a bug that needs to be resolved in this basic infrastructure regarding the order in which objects are removed. When the spu_gang file descriptor is closed before the spu_context descriptors, we leak the dentry and inode for the gang. Any ideas how to cleanly solve this are appreciated. Signed-off-by: Arnd Bergmann Signed-off-by: Paul Mackerras --- Reading git-diff-tree failed