linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Ben Warren <bwarren@qstreams.com>
To: Arun Kumar <arunkat@gmail.com>
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: problems with mounting JFFS2 using CFI for AM29LV160MT on ppc8245 k2.4.x
Date: Mon, 24 Jul 2006 10:14:54 -0400	[thread overview]
Message-ID: <1153750494.12540.23.camel@saruman.qstreams.net> (raw)
In-Reply-To: <edd12c050607240124gd001d11q77796ab4d13c241b@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 3943 bytes --]

Arun,

Looks like there are still some things broken in your MTD partition
definition.  I highly recommend that when debugging this, you boot from
an NFS mount.  That way you can modify files off-line (ie. from your
development host).  I'll point out a few things, but you're going to
have to surf the source code a bit:

On Mon, 2006-07-24 at 13:54 +0530, Arun Kumar wrote:

> Hi Ben ,
> 
> Thanks for your reply .It was indeed very comrehensive .I am able to
> proceed further But still there is a bit problem .
> 
> When I try to mknod physically viz mknod /dev/mtd0 .....
> 
> It says the node is readonly . 
> 
> Can you please point out the problem . I am attaching a dump of the
> console .

Again, put your root FS on an NFS mount and this won't be an issue.  You
can work out the ramdisk details later.


>  AMD_FLASH_INIT called  *aks *
> physmap flash device: 800000 at ff800000 virtual address Number of
> erase regions
> : 4
> Primary Vendor Command Set: 0002 (AMD/Fujitsu Standard)
> Primary Algorithm Table at 0040
> Alternative Vendor Command Set: 0000 (None)
> No Alternate Algorithm Table
> Vcc Minimum: 2.7 V
> Vcc Maximum: 3.6 V
> No Vpp line
> Typical byte/word write timeout: 128 µs
> Maximum byte/word write timeout: 256 µs
> Full buffer write not supported
> Typical block erase timeout: 1024 ms
> Maximum block erase timeout: 16384 ms
> Chip erase not supported
> Device size: 0x200000 bytes (2 MiB)
> Flash Device Interface description: 0x0002
>   - supports x8 and x16 via BYTE# with asynchronous interface
> Max. bytes in buffer write: 0x1
> Number of Erase Block Regions: 4
>   Erase Region #0: BlockSize 0x4000 bytes, 1 blocks
>   Erase Region #1: BlockSize 0x2000 bytes, 2 blocks
>   Erase Region #2: BlockSize 0x8000 bytes, 1 blocks
>   Erase Region #3: BlockSize 0x10000 bytes, 31 blocks
>  Amd/Fujitsu Extended Query Table v1.3 at 0x0040
> number of CFI chips: 4
> 
>  in amdstd_setup 0: offset=0x0,size=0x10000,blocks=1
> 1: offset=0x10000,size=0x8000,blocks=2
> 2: offset=0x20000,size=0x20000,blocks=1
> 3: offset=0x40000,size=0x40000,blocks=31
> 4: offset=0x800000,size=0x10000,blocks=1
> 5: offset=0x810000,size=0x8000,blocks=2
> 6: offset=0x820000,size=0x20000,blocks=1
> 7: offset=0x840000,size=0x40000,blocks=31
> 8: offset=0x1000000,size=0x10000,blocks=1
> 9: offset=0x1010000,size=0x8000,blocks=2
> 10: offset=0x1020000,size=0x20000,blocks=1
> 11: offset=0x1040000,size=0x40000,blocks=31
> 12: offset=0x1800000,size=0x10000,blocks=1
> 13: offset=0x1810000,size=0x8000,blocks=2
> 14: offset=0x1820000,size=0x20000,blocks=1
> 15: offset=0x1840000,size=0x40000,blocks=31
> cfi_cmdset_0002: Disabling fast programming due to code brokenness.
> aks Enabling
> *

Are you sure you have the correct chip family chosen in your CONFIG?
The block sizes found by CFI are different than those mentioned in
amdstd_setup...  CFI shows your devices being 2MB in size, while the
other shows (1*10000 + 2*8000 + 1*20000 + 31*40000 = 0x800000) 8MB per
chip.  Something is amiss here.  I don't have a clue about the fast
programming.  'grep -R' is your friend.

> 
>  in MTD Partitioning <5>No RedBoot partition table detected in
> phys_mapped_flash
> 
> Using physmap partition definition
> Creating 3 MTD partitions on "phys_mapped_flash":
> 0x00000000-0x00040000 : "agere-ets0"
> mtd: Giving out device 0 to agere-ets0
> 0x00040000-0x00080000 : "agere-ets1"
> mtd: Giving out device 1 to agere-ets1
> 0x00080000-0x0007fffe : "agere-ets2"
> mtd: partition "agere-ets2" doesn't end on an erase block -- force
> read-only

There's definitely a problem here.  First of all, 0x7fffe is < 0x80000.
Note that the start and end addresses you specify for this must be on
erase block boundaries.  Clean up your partition table to reflect what
you want.  You didn't mention whether you're passing partition info by
command line or in init code.  Also, if you're not using Redboot, get
rid of that CONFIG option.

regards,
Ben


[-- Attachment #2: Type: text/html, Size: 6615 bytes --]

  parent reply	other threads:[~2006-07-24 14:14 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-21 14:56 problems with mounting JFFS2 using CFI for AM29LV160MT on ppc8245 k2.4.x Arun Kumar
2006-07-21 16:20 ` Ben Warren
2006-07-24  8:24   ` Arun Kumar
2006-07-24  9:24     ` Arun Kumar
2006-07-24 14:14     ` Ben Warren [this message]
     [not found]       ` <edd12c050607260503y58808ecrdbee205fa4e617b3@mail.gmail.com>
2006-08-03 14:18         ` Ben Warren

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1153750494.12540.23.camel@saruman.qstreams.net \
    --to=bwarren@qstreams.com \
    --cc=arunkat@gmail.com \
    --cc=linuxppc-embedded@ozlabs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).