diff options
author | Russell King <rmk@dyn-67.arm.linux.org.uk> | 2005-10-29 16:08:31 +0100 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2005-10-29 16:08:31 +0100 |
commit | 14e66f767f5e8d023e098b475dc24ddc9a5dbdfd (patch) | |
tree | 11d0835775cb00a164b2e3d4b23f282a002277cd /drivers | |
parent | 822e5e72697ce06e4425c17d161b0482c7d9b6d4 (diff) | |
download | kernel_samsung_tuna-14e66f767f5e8d023e098b475dc24ddc9a5dbdfd.zip kernel_samsung_tuna-14e66f767f5e8d023e098b475dc24ddc9a5dbdfd.tar.gz kernel_samsung_tuna-14e66f767f5e8d023e098b475dc24ddc9a5dbdfd.tar.bz2 |
[ARM] Allow MTD device name to be passed via platform data
Allow SA1100 devices to pass the name of the flash device to the
SA1100 map driver.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/mtd/maps/sa1100-flash.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/mtd/maps/sa1100-flash.c b/drivers/mtd/maps/sa1100-flash.c index c38c2c3..acf01ef 100644 --- a/drivers/mtd/maps/sa1100-flash.c +++ b/drivers/mtd/maps/sa1100-flash.c @@ -301,7 +301,7 @@ sa1100_setup_mtd(struct platform_device *pdev, struct flash_platform_data *plat) break; subdev->map.name = subdev->name; - sprintf(subdev->name, "sa1100-%d", i); + sprintf(subdev->name, "%s-%d", plat->name, i); subdev->plat = plat; ret = sa1100_probe_subdev(subdev, res); @@ -323,7 +323,7 @@ sa1100_setup_mtd(struct platform_device *pdev, struct flash_platform_data *plat) * otherwise fail. Either way, it'll be called "sa1100". */ if (info->num_subdev == 1) { - strcpy(info->subdev[0].name, "sa1100"); + strcpy(info->subdev[0].name, plat->name); info->mtd = info->subdev[0].mtd; ret = 0; } else if (info->num_subdev > 1) { @@ -336,7 +336,7 @@ sa1100_setup_mtd(struct platform_device *pdev, struct flash_platform_data *plat) cdev[i] = info->subdev[i].mtd; info->mtd = mtd_concat_create(cdev, info->num_subdev, - "sa1100"); + plat->name); if (info->mtd == NULL) ret = -ENXIO; #else |