[U-Boot-Users] U-boot Bus Fault Error while accessing NOR flash

Nikhil Gautam
2008-02-19T19:32:44Z

Hi HTH,

Thanks for the information. My problem is that "md 0xFFFFE000" and any
other read command up to this address works fine. Its just when I try
to read @ 0xFFFF F000 I see this problem.

I didn't see any obvious problem with the global and static initialization.

Nikhil

>
> Hi Nikhil,
>
> If I understand you correctly, this sounds like improperly initialized
> variables in your build. This is very likely a (build | link |
> initialization | relocation) issue (pick any combination).
>
> The "md 0xFFFFF000" command is using the default value for the number of
> objects, which comes from a static variable dp_last_length that is
> initialized to 0x40 (see common/cmd_mem.c):
> uint dp_last_length = 0x40;
>
> If dp_last_length is not initialized properly to 0x40 on start up,
> unexpected things are going to happen. I don't see an obvious path to
> an illegal access to location 0x00000000, but it could be.
>
> In addition, if you hit <enter> with no command the first time your
> board boots, the command parser tries to run the last command you
> executed. Of course, there *is no* "last command", which ties into my
> theory of uninitialized static/global variables.
>
> I would suspect your link control isn't linking the static variable
> initialization in the right section or your (compiler's) initialization
> of the static variables isn't working as expected.
>
> HTH,
> gvb
>
>

On Feb 15, 2008 10:15 AM, Jerry Van Baren <gerald.vanbaren@ge.com> wrote:
>
> Nikhil Gautam wrote:
> > Hi Everyone,
> >
> > I am try to use the u-boot to program the NOR flash on my proprietary
> > board based on AMCC sequoia board. I can boot from 1Gb NAND flash ok
> > but everytime I try access the last 4K of NOR flash, U-boot gives me
> > following error and reboots:-
> >
> > {{{
> > U-Boot$ md 0xFFFFF000
> > fffff000:Bus Fault @ 0x00000000, fixup 0x00000000
> > Machine check in kernel mode.
> > Caused by (from msr): regs 0fe8fca8 Unknown values in msr
> > NIP: 00000000 XER: 20000000 LR: 0FF6412C REGS: 0fe8fca8 TRAP: 0200 DAR:
> > 041F0000
> > MSR: 00000000 EE: 0 PR: 0 FP: 0 ME: 0 IR/DR: 00
> >
> > GPR00: 0FF6412C 0FE8FD98 7FFFFFFF EF600300 00000000 00000001 00000001 C838AE89
> > GPR08: 0FF5145C 00000000 01FCA055 03F940AB 0FE8FB50 041F0000 0FFACD00 0EED0000
> > GPR16: 00000000 00000000 00000000 00000000 0FE8FDA0 00000040 0FE8FDA0 0FE8FDA0
> > GPR24: 00000000 00000100 00000010 00000004 FFFFF000 0FE8FF40 0FFADB58 0FE8FDA0
> > Call backtrace:
> > machine check
> > }}}
> >
> > I get the same error if I press "ENTER" after u-boot gives me the
> > prompt. If I type some command its ok and then its fine thereafter.
> >
> > I know the NOR flash is ok because I used BDI to program it and also I
> > can access this address when I boot from NOR flash.
> >
> > Any Clue?
> >
> > Thanks In Advance!
> >
> > Nikhil Gautam