diff options
author | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-22 14:51:06 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-22 14:51:06 -0700 |
commit | a4936044001694f033fe4ea94d6034d51a6b465c (patch) | |
tree | 4f1caf9899c1859277082422b1fc37901c6097ac /arch/arm/common/sa1111.c | |
parent | 9092131f7ea2f9e92a510ae13ac4d20165aa921c (diff) | |
parent | 92a8cbed29eb9bf6e8eec16ca29d54015bc0e8a2 (diff) |
Merge master.kernel.org:/home/rmk/linux-2.6-arm
Diffstat (limited to 'arch/arm/common/sa1111.c')
-rw-r--r-- | arch/arm/common/sa1111.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/arch/arm/common/sa1111.c b/arch/arm/common/sa1111.c index 21fce3414ed1..38c2eb667eb9 100644 --- a/arch/arm/common/sa1111.c +++ b/arch/arm/common/sa1111.c @@ -721,16 +721,17 @@ __sa1111_probe(struct device *me, struct resource *mem, int irq) return ret; } +static int sa1111_remove_one(struct device *dev, void *data) +{ + device_unregister(dev); + return 0; +} + static void __sa1111_remove(struct sa1111 *sachip) { - struct list_head *l, *n; void __iomem *irqbase = sachip->base + SA1111_INTC; - list_for_each_safe(l, n, &sachip->dev->children) { - struct device *d = list_to_dev(l); - - device_unregister(d); - } + device_for_each_child(sachip->dev, NULL, sa1111_remove_one); /* disable all IRQs */ sa1111_writel(0, irqbase + SA1111_INTEN0); |