2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-20 19:23:57 +08:00
linux-next/drivers/mtd
Anton Vorontsov 9ebed3e60f [MTD] [NAND] fsl_elbc_nand: fix mtd name
Currently fsl_elbc_nand doesn't initialize mtd->name, and this causes
nand_get_flash_type() to assign name that is equal to chip type, like
this:

   root@b1:~# cat /proc/mtd
   dev:    size   erasesize  name
   mtd0: 00800000 00010000 "fe000000.flash"
   mtd1: 02000000 00004000 "NAND 32MiB 3,3V 8-bit"

mtd0 is physmap_of flash (normal name), and mtd1 is fsl_elbc_nand.

Despite inconsistency, with mtd name like this specifying paritions
from the kernel command line becomes a torture (though, I didn't tried
and not sure if mtdparts= can handle spaces at all). Plus, this causes
real bugs when multiple fsl_elbc_nand chips registered.

With this patch applied fsl_elbc_nand chip will have proper name:

   root@b1:~# cat /proc/mtd
   dev:    size   erasesize  name
   mtd0: 00800000 00010000 "fe000000.flash"
   mtd1: 02000000 00004000 "e0600000.flash"

p.s. We can't use priv->dev->bus_id as in physmap_of, because
fsl_elbc_nand pretends to be a localbus controller, so its bus_id is
"address.localbus", which is incorrect and thus will also not work
for multiple chips.

Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-04-22 20:50:31 +01:00
..
chips [MTD] [NOR] Add JEDEC support for the SST 36VF3203 flash chip 2008-04-22 20:24:59 +01:00
devices [MTD] mtdram.c should #include <linux/mtd/mtdram.h> 2008-04-22 15:55:07 +01:00
maps [MTD] [MAPS] Extend plat-ram to support a supplied probe type 2008-04-22 20:10:10 +01:00
nand [MTD] [NAND] fsl_elbc_nand: fix mtd name 2008-04-22 20:50:31 +01:00
onenand [MTD] [OneNAND] unlikely(x) || unlikely(y) => unlikely(x || y) 2008-04-22 19:15:28 +01:00
ubi [MTD] replace remaining __FUNCTION__ occurrences 2008-04-22 12:36:04 +01:00
afs.c [MTD] replace kmalloc+memset with kzalloc 2006-11-28 23:47:21 +00:00
ar7part.c [MTD] AR7 mtd partition map 2008-04-22 20:48:12 +01:00
cmdlinepart.c [MTD] cmdlinepart: Missing partition info is not an error 2008-04-22 19:10:15 +01:00
ftl.c [MTD] ftl.c: make code static 2008-04-22 15:56:00 +01:00
inftlcore.c [MTD] replace kmalloc+memset with kzalloc 2006-11-28 23:47:21 +00:00
inftlmount.c [MTD] proper prototypes for inftl_{read,write}_oob() 2008-04-22 15:54:16 +01:00
Kconfig [MTD] AR7 mtd partition map 2008-04-22 20:48:12 +01:00
Makefile [MTD] AR7 mtd partition map 2008-04-22 20:48:12 +01:00
mtd_blkdevs.c [MTD] Always initialise mutex in new mtd_blktrans_dev. 2007-12-03 12:46:12 +00:00
mtdblock_ro.c [MTD] replace kmalloc+memset with kzalloc 2006-11-28 23:47:21 +00:00
mtdblock.c [MTD] replace kmalloc+memset with kzalloc 2006-11-28 23:47:21 +00:00
mtdchar.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git 2008-02-03 18:30:32 +11:00
mtdconcat.c [MTD] fix mtdconcat for subpage-write NAND 2007-10-14 13:38:02 +01:00
mtdcore.c [MTD] Unlocking all Intel flash that is locked on power up. 2008-02-03 18:25:16 +11:00
mtdcore.h [MTD] mtdcore.c: share syms with mtd_blkdev.c 2007-06-28 20:24:50 +01:00
mtdoops.c [MTD] mtdoops.c: make struct oops_cxt static again 2008-04-22 12:35:34 +01:00
mtdpart.c [MTD] Add mtd panic_write function pointer 2008-02-07 10:30:48 +00:00
mtdsuper.c Introduce path_put() 2008-02-14 21:13:33 -08:00
nftlcore.c PCI: Cleanup the includes of <linux/pci.h> 2007-05-02 19:02:35 -07:00
nftlmount.c [MTD] proper prototypes for nftl_{read,write}_oob() 2008-04-22 15:54:29 +01:00
ofpart.c [MTD] mtd/ofpart.c: add MODULE_LICENSE 2008-04-22 15:53:52 +01:00
redboot.c [MTD] Skip bad blocks when checking for RedBoot partition table 2007-10-28 21:57:02 -04:00
rfd_ftl.c [MTD] make struct rfd_ftl_tr static 2008-04-22 15:59:25 +01:00
ssfdc.c [MTD] Fix ssfdc blksize typo 2006-12-11 09:43:38 +00:00