RE: mtd

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Paulius,

I check boot log and see exactly what say. I am going to exchange registration order and make NAND stays in mtdblock3 and SPI stays in mtdblock7 no matter SPI enabled or not.

Thanks.

----Henry

--- On Fri, 1/28/11, H Hartley Sweeten <hartleys@xxxxxxxxxxxxxxxxxxx> wrote:

> From: H Hartley Sweeten <hartleys@xxxxxxxxxxxxxxxxxxx>
> Subject: RE: mtd
> To: "hong zhang" <henryzhang62@xxxxxxxxx>, "Paulius Zaleckas" <paulius.zaleckas@xxxxxxxxx>
> Cc: "linux-arm@xxxxxxxxxxxxxxxxxxx" <linux-arm@xxxxxxxxxxxxxxxxxxx>
> Date: Friday, January 28, 2011, 11:27 AM
> On Friday, January 28, 2011 10:05 AM,
> hong zhang wrote:
> >
> > root@ti8168-evm:~# cat /proc/mtd
> > dev:   
> size   erasesize  name
> > mtd0: 00040000 00001000 "U-Boot"
> > mtd1: 00002000 00001000 "U-Boot Env"
> > mtd2: 00280000 00001000 "Kernel"
> > mtd3: 0013e000 00001000 "File System"
> > mtd4: 00260000 00020000 "U-Boot"
> > mtd5: 00020000 00020000 "U-Boot Env"
> > mtd6: 00440000 00020000 "Kernel"
> > mtd7: 0c820000 00020000 "File System"
> > mtd8: 03120000 00020000 "Reserved"
> >
> > File System sits in mtd3 and mtd7. But only one of
> them can be used. In
> > my case mtd7 is used when SPI is enabled or mtd3 is
> used w/o SPI. I do
> > not know why.
> 
> It looks like your spi device is getting processed by the
> mtd subsystem
> before your actual flash device.  But both devices
> have the same partition
> layout (and names) which is confusing you.
> 
> In the information shown above, mtd[0-3] all have an
> erasesize of 4KB.
> These are probably associated with your spi device. 
> The remaining ones
> all have an erasesize of 128KB so these are probably your
> flash device.
> 
> If you look are your boot messages you will probably be
> able to verify
> this.  Look for something like: Creating <x> MTD
> partitions on "<name>".
> 
> The simplest solution would probably be changing the
> registration order
> of the spi and flash devices in your platform init
> code.  That way the
> flash partitions will always be first and the spi
> partitions, when enabled,
> will come after.
> 
> Regards,
> Hartley



_______________________________________________
linux-arm mailing list
linux-arm@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/linux-arm



[Linux ARM]     [Linux ARM MSM]     [Linux ARM Kernel]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

Add to Google Follow linuxarm on Twitter