Commit 2493b8ae authored by Ben Dooks's avatar Ben Dooks Committed by Russell King

[ARM PATCH] 2284/1: S3C2410 - core device registration update

Patch from Ben Dooks

If one of the devices fails to register, do not
remove any registered devices and continue registering
in case any more devices register.

Signed-off-by: Ben Dooks
Signed-off-by: Russell King
parent 0a4450c5
......@@ -174,9 +174,15 @@ static int __init s3c_arch_init(void)
return ret;
if (board != NULL) {
ret = platform_add_devices(board->devices, board->devices_count);
if (ret) {
printk(KERN_ERR "s3c24xx: failed to add board devices (%d)\n", ret);
struct platform_device **ptr = board->devices;
int i;
for (i = 0; i < board->devices_count; i++, ptr++) {
ret = platform_device_register(*ptr);
if (ret) {
printk(KERN_ERR "s3c24xx: failed to add board device %s (%d) @%p\n", (*ptr)->name, ret, *ptr);
}
}
/* mask any error, we may not need all these board
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment