diff options
author | Paul Mackerras <paulus@samba.org> | 2005-11-09 19:06:04 -0500 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2005-11-09 19:06:04 -0500 |
commit | 31e7f1ff3c5d39a70da85f7d81a1ab1f4e64fa97 (patch) | |
tree | a6cb8f14b1182e5dce55d13e52c1182a8c7e0402 /arch/powerpc/kernel | |
parent | fca5dcd4835ed09bb1a48a355344aff7a25c76e0 (diff) | |
parent | 6730c3c14421b7c924d06e31bb66e0adad225547 (diff) |
Merge ../linux-2.6
Diffstat (limited to 'arch/powerpc/kernel')
-rw-r--r-- | arch/powerpc/kernel/traps.c | 4 | ||||
-rw-r--r-- | arch/powerpc/kernel/vio.c | 27 |
2 files changed, 27 insertions, 4 deletions
diff --git a/arch/powerpc/kernel/traps.c b/arch/powerpc/kernel/traps.c index 32f215825e8d..0578f8387603 100644 --- a/arch/powerpc/kernel/traps.c +++ b/arch/powerpc/kernel/traps.c | |||
@@ -887,10 +887,6 @@ void altivec_unavailable_exception(struct pt_regs *regs) | |||
887 | die("Unrecoverable VMX/Altivec Unavailable Exception", regs, SIGABRT); | 887 | die("Unrecoverable VMX/Altivec Unavailable Exception", regs, SIGABRT); |
888 | } | 888 | } |
889 | 889 | ||
890 | #ifdef CONFIG_PPC64 | ||
891 | extern perf_irq_t perf_irq; | ||
892 | #endif | ||
893 | |||
894 | #if defined(CONFIG_PPC64) || defined(CONFIG_E500) | 890 | #if defined(CONFIG_PPC64) || defined(CONFIG_E500) |
895 | void performance_monitor_exception(struct pt_regs *regs) | 891 | void performance_monitor_exception(struct pt_regs *regs) |
896 | { | 892 | { |
diff --git a/arch/powerpc/kernel/vio.c b/arch/powerpc/kernel/vio.c index 97082a4203ad..71a6addf9f7f 100644 --- a/arch/powerpc/kernel/vio.c +++ b/arch/powerpc/kernel/vio.c | |||
@@ -21,6 +21,7 @@ | |||
21 | #include <asm/iommu.h> | 21 | #include <asm/iommu.h> |
22 | #include <asm/dma.h> | 22 | #include <asm/dma.h> |
23 | #include <asm/vio.h> | 23 | #include <asm/vio.h> |
24 | #include <asm/prom.h> | ||
24 | 25 | ||
25 | static const struct vio_device_id *vio_match_device( | 26 | static const struct vio_device_id *vio_match_device( |
26 | const struct vio_device_id *, const struct vio_dev *); | 27 | const struct vio_device_id *, const struct vio_dev *); |
@@ -265,7 +266,33 @@ static int vio_bus_match(struct device *dev, struct device_driver *drv) | |||
265 | return (ids != NULL) && (vio_match_device(ids, vio_dev) != NULL); | 266 | return (ids != NULL) && (vio_match_device(ids, vio_dev) != NULL); |
266 | } | 267 | } |
267 | 268 | ||
269 | static int vio_hotplug(struct device *dev, char **envp, int num_envp, | ||
270 | char *buffer, int buffer_size) | ||
271 | { | ||
272 | const struct vio_dev *vio_dev = to_vio_dev(dev); | ||
273 | char *cp; | ||
274 | int length; | ||
275 | |||
276 | if (!num_envp) | ||
277 | return -ENOMEM; | ||
278 | |||
279 | if (!vio_dev->dev.platform_data) | ||
280 | return -ENODEV; | ||
281 | cp = (char *)get_property(vio_dev->dev.platform_data, "compatible", &length); | ||
282 | if (!cp) | ||
283 | return -ENODEV; | ||
284 | |||
285 | envp[0] = buffer; | ||
286 | length = scnprintf(buffer, buffer_size, "MODALIAS=vio:T%sS%s", | ||
287 | vio_dev->type, cp); | ||
288 | if (buffer_size - length <= 0) | ||
289 | return -ENOMEM; | ||
290 | envp[1] = NULL; | ||
291 | return 0; | ||
292 | } | ||
293 | |||
268 | struct bus_type vio_bus_type = { | 294 | struct bus_type vio_bus_type = { |
269 | .name = "vio", | 295 | .name = "vio", |
296 | .hotplug = vio_hotplug, | ||
270 | .match = vio_bus_match, | 297 | .match = vio_bus_match, |
271 | }; | 298 | }; |