summaryrefslogtreecommitdiff
path: root/include/asm-powerpc/spu.h
diff options
context:
space:
mode:
authorChristian Krafft <krafft@de.ibm.com>2006-10-24 18:31:23 +0200
committerPaul Mackerras <paulus@samba.org>2006-10-25 14:20:21 +1000
commite570beb6bb1a623849901efbf939063ec4775c9e (patch)
tree9d6766eb2ca71393bf16f0aec0cbf726282dea6e /include/asm-powerpc/spu.h
parentd8bf96e0793f9576da545bac333b2de304958d68 (diff)
[POWERPC] cell: add support for registering sysfs attributes to spus
In order to add sysfs attributes to all spu's, there is a need for a list of all available spu's. Adding the device_node makes also sense, as it is needed for proper register access. This patch also adds two functions to create and remove sysfs attributes and attribute_groups to all spus. That allows to group spu attributes in a subdirectory like: /sys/devices/system/spu/spuX/group_name/what_ever This will be used by cbe_thermal to group all attributes dealing with thermal support in one directory. Signed-off-by: Christian Krafft <krafft@de.ibm.com> Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'include/asm-powerpc/spu.h')
-rw-r--r--include/asm-powerpc/spu.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/asm-powerpc/spu.h b/include/asm-powerpc/spu.h
index 704e8a8d2ebd..ffa4df083609 100644
--- a/include/asm-powerpc/spu.h
+++ b/include/asm-powerpc/spu.h
@@ -115,6 +115,7 @@ struct spu {
struct spu_priv2 __iomem *priv2;
struct list_head list;
struct list_head sched_list;
+ struct list_head full_list;
int number;
int nid;
unsigned int irqs[3];
@@ -143,6 +144,8 @@ struct spu {
char irq_c1[8];
char irq_c2[8];
+ struct device_node *devnode;
+
struct sys_device sysdev;
};
@@ -200,6 +203,12 @@ static inline void unregister_spu_syscalls(struct spufs_calls *calls)
}
#endif /* MODULE */
+int spu_add_sysdev_attr(struct sysdev_attribute *attr);
+void spu_remove_sysdev_attr(struct sysdev_attribute *attr);
+
+int spu_add_sysdev_attr_group(struct attribute_group *attrs);
+void spu_remove_sysdev_attr_group(struct attribute_group *attrs);
+
/*
* Notifier blocks: