public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: Justin Wojdacki <justin.wojdacki@analog.com>
To: linux-mtd@lists.infradead.org
Subject: Strange problem related to writing to flash
Date: Tue, 04 Jun 2002 12:21:01 -0700	[thread overview]
Message-ID: <3CFD131D.1AA4678F@analog.com> (raw)

Okay, so here's the problem I'm running into:

On a hard reset, the board I'm working with always comes up fine.
Linux boots, mounts the root filesystem (JFFS2) and all that. It looks
happy. 

If I don't modify the filesystem, Linux boots fine on a soft reset. 

If I modify the filesystem in some way, Linux fails to boot properly
on a soft reset. What happens is the bootstrap loads the kernel from
the JFFS2 partition and boots the kernel. When the kernel probes the
flash, it sees 2 8-bit wide devices instead of the actual 1 16-bit
wide device. JFFS2 then get's really unhappy because it's attempts to
access the flash device fail. 

here are relevant bits of dmesg

First, on success:
AD6489 Residential Gateway flash probe(0x1fc00000,2097152,2): 200000
at 1fc00000
Analog Devices AD6489 Residential Gateway, Rev 2.0: Found 1 x16
devices at 0x0 in 16-bit mode
Found: ST M29W160DB
number of JEDEC chips: 1
0: offset=0x0,size=0x4000,blocks=1
1: offset=0x4000,size=0x2000,blocks=2
2: offset=0x8000,size=0x8000,blocks=1
3: offset=0x10000,size=0x10000,blocks=31
Creating 4 MTD partitions on "Analog Devices AD6489 Residential
Gateway, Rev 2.0":
0x00000000-0x00004000 : "Bootstrap 1"
0x00004000-0x00008000 : "Configuration"
0x00008000-0x00020000 : "Bootstrap 2"
0x00020000-0x00200000 : "Root"

Next, on failure:
AD6489 Residential Gateway flash probe(0x1fc00000,2097152,2): 200000
at 1fc00000
Analog Devices AD6489 Residential Gateway, Rev 2.0: Found 2 x8 devices
at 0x0 in 16-bit mode
Found: ST M29W160DB
number of JEDEC chips: 1
0: offset=0x0,size=0x8000,blocks=1
1: offset=0x8000,size=0x4000,blocks=2
2: offset=0x10000,size=0x10000,blocks=1
3: offset=0x20000,size=0x20000,blocks=31
Creating 4 MTD partitions on "Analog Devices AD6489 Residential
Gateway, Rev 2.0":
0x00000000-0x00004000 : "Bootstrap 1"
0x00004000-0x00008000 : "Configuration"
0x00008000-0x00020000 : "Bootstrap 2"
0x00020000-0x00200000 : "Root"
...
jffs2_scan_empty(): Empty block at 0x0000ffc0 ends at 0x00010000 (with
0x1985e002)! Marking dirty
(message repeats for successive 128KB blocks)
CLEANMARKER node found at 0x00150000, not first node in block
(0x00140000)
jffs2_scan_empty(): Empty block at 0x0016000c ends at 0x00170000 (with
0x19852003)! Marking dirty
CLEANMARKER node found at 0x00170000, not first node in block
(0x00160000)
jffs2_scan_empty(): Empty block at 0x0018000c ends at 0x00190000 (with
0x19852003)! Marking dirty
CLEANMARKER node found at 0x00190000, not first node in block
(0x00180000)
jffs2_scan_empty(): Empty block at 0x001a000c ends at 0x001b0000 (with
0x19852003)! Marking dirty
CLEANMARKER node found at 0x001b0000, not first node in block
(0x001a0000)
jffs2_scan_empty(): Empty block at 0x001c000c ends at 0x001d0000 (with
0x19852003)! Marking dirty
CLEANMARKER node found at 0x001d0000, not first node in block
(0x001c0000)
VFS: Mounted root (jffs2 filesystem).
Freeing unused kernel memory: 40k freed
Waiting for chip to read, status = 7
Waiting for chip to read, status = 7

Any pointers on what to look for here? 

-- 
-------------------------------------------------
Justin Wojdacki        
justin.wojdacki@analog.com         (408) 350-5032
Communications Processors Group -- Analog Devices

             reply	other threads:[~2002-06-04 22:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-04 19:21 Justin Wojdacki [this message]
2002-06-04 22:29 ` Strange problem related to writing to flash Jim Thompson
2002-06-04 23:41   ` Justin Wojdacki
2002-06-05 20:58     ` Justin Wojdacki

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=3CFD131D.1AA4678F@analog.com \
    --to=justin.wojdacki@analog.com \
    --cc=linux-mtd@lists.infradead.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