aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/common/sa1111.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/common/sa1111.c')
-rw-r--r--arch/arm/common/sa1111.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/arch/arm/common/sa1111.c b/arch/arm/common/sa1111.c
index 2048ae0b1559..c8e8f0ea59e1 100644
--- a/arch/arm/common/sa1111.c
+++ b/arch/arm/common/sa1111.c
@@ -550,9 +550,7 @@ sa1111_init_one_child(struct sa1111 *sachip, struct resource *parent,
550 goto out; 550 goto out;
551 } 551 }
552 552
553 snprintf(dev->dev.bus_id, sizeof(dev->dev.bus_id), 553 dev_set_name(&dev->dev, "%4.4lx", info->offset);
554 "%4.4lx", info->offset);
555
556 dev->devid = info->devid; 554 dev->devid = info->devid;
557 dev->dev.parent = sachip->dev; 555 dev->dev.parent = sachip->dev;
558 dev->dev.bus = &sa1111_bus_type; 556 dev->dev.bus = &sa1111_bus_type;
@@ -560,7 +558,7 @@ sa1111_init_one_child(struct sa1111 *sachip, struct resource *parent,
560 dev->dev.coherent_dma_mask = sachip->dev->coherent_dma_mask; 558 dev->dev.coherent_dma_mask = sachip->dev->coherent_dma_mask;
561 dev->res.start = sachip->phys + info->offset; 559 dev->res.start = sachip->phys + info->offset;
562 dev->res.end = dev->res.start + 511; 560 dev->res.end = dev->res.start + 511;
563 dev->res.name = dev->dev.bus_id; 561 dev->res.name = dev_name(&dev->dev);
564 dev->res.flags = IORESOURCE_MEM; 562 dev->res.flags = IORESOURCE_MEM;
565 dev->mapbase = sachip->base + info->offset; 563 dev->mapbase = sachip->base + info->offset;
566 dev->skpcr_mask = info->skpcr_mask; 564 dev->skpcr_mask = info->skpcr_mask;
@@ -570,6 +568,7 @@ sa1111_init_one_child(struct sa1111 *sachip, struct resource *parent,
570 if (ret) { 568 if (ret) {
571 printk("SA1111: failed to allocate resource for %s\n", 569 printk("SA1111: failed to allocate resource for %s\n",
572 dev->res.name); 570 dev->res.name);
571 dev_set_name(&dev->dev, NULL);
573 kfree(dev); 572 kfree(dev);
574 goto out; 573 goto out;
575 } 574 }