1 From: Olaf Hering <olh@novell.com>
2 Subject: [PATCH] poweroc: vio modalias
4 Acked-by: Olaf Hering <olh@novell.com>
6 arch/powerpc/kernel/vio.c | 15 +++++++++++++++
7 1 file changed, 15 insertions(+)
9 --- a/arch/powerpc/kernel/vio.c
10 +++ b/arch/powerpc/kernel/vio.c
11 @@ -1315,9 +1315,24 @@ static ssize_t devspec_show(struct devic
12 return sprintf(buf, "%s\n", of_node ? of_node->full_name : "none");
15 +static ssize_t modalias_show (struct device *dev, struct device_attribute *attr,
18 + struct device_node *of_node = dev->archdata.of_node;
23 + compat = of_get_property(of_node, "compatible", &i);
24 + i = sprintf (buf, "vio:T%sS%s\n", of_node->type, compat);
29 static struct device_attribute vio_dev_attrs[] = {
32 + __ATTR_RO(modalias),