* [U-Boot] Crash nand init UPMA - NAND flash MPC832x
@ 2009-12-20 17:24 nanda
2009-12-20 18:40 ` Wolfgang Denk
0 siblings, 1 reply; 5+ messages in thread
From: nanda @ 2009-12-20 17:24 UTC (permalink / raw)
To: u-boot
Our development needs NAND to be implemented from u-boot level. And our booting from FLASH depends of NOR flash using the GPCM.
We are facing in the initialization of the nand_init, a crash in the dummy write during the UPM program based on the UPM mode of freescale MPC8323 in the code below:
void UPMA_prog()
{
int i=0;
// OP set to write to RAM array command
*(int *)(MAMR) = 0x10000000;
// Write word to RAM arrays
for (i=0;i
^ permalink raw reply [flat|nested] 5+ messages in thread
* [U-Boot] Crash nand init UPMA - NAND flash MPC832x
2009-12-20 17:24 [U-Boot] Crash nand init UPMA - NAND flash MPC832x nanda
@ 2009-12-20 18:40 ` Wolfgang Denk
2009-12-21 5:55 ` KoteswarK
0 siblings, 1 reply; 5+ messages in thread
From: Wolfgang Denk @ 2009-12-20 18:40 UTC (permalink / raw)
To: u-boot
Dear "nanda",
In message <20091220172434.48360.qmail@f5mail-237-207.rediffmail.com> you wrote:
>
> Our development needs NAND to be implemented from u-boot level. And our booting from FLASH depends of NOR flash using the GPCM.
>
> We are facing in the initialization of the nand_init, a crash in the dummy write during the UPM program based on the UPM mode of freescale MPC8323 in the code below:
>
> void UPMA_prog()
> {
> int i=0;
> // OP set to write to RAM array command
> *(int *)(MAMR) = 0x10000000;
> // Write word to RAM arrays
> for (i=0;i
There is no such code in mainline U-Boot. I recommend you look for
existing (and working) code examples when porting U-Boot to your
hardware. Note that you should use I/O accessor functions instead of
plain register writes.
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Digital computers are themselves more complex than most things people
build: They have very large numbers of states. This makes conceiving,
describing, and testing them hard. Software systems have orders-of-
magnitude more states than computers do. - Fred Brooks, Jr.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [U-Boot] Crash nand init UPMA - NAND flash MPC832x
2009-12-20 18:40 ` Wolfgang Denk
@ 2009-12-21 5:55 ` KoteswarK
2009-12-21 6:49 ` Ben Warren
0 siblings, 1 reply; 5+ messages in thread
From: KoteswarK @ 2009-12-21 5:55 UTC (permalink / raw)
To: u-boot
Hi
What are those "I/O accessor functions"? API present in
./drivers/mtd/nand/fsl_upm.c file??? I am also getting crash while doing
dummy write to NAND_BASE. Code is follows....
void UPMA_prog()
{
int i=0;
/* OP set to write to RAM array command*/
*(int *)(MAMR) = 0x10000000;
/* Write word to RAM arrays*/
for (i=0;i<32;i++)
{
*(int *)(MDR) = UPMATable[i];
udelay (100);
/* *(int *)(MAMR) = 0x10000000;
*
* *(int *)(MAMR) = 0x10000000+i;*/
/*dummy write*/
*(char *)(CFG_NAND_BASE) = 0xff;
}
.............
}
Rgds
Koteswar
wd wrote:
>
> Dear "nanda",
>
> In message <20091220172434.48360.qmail@f5mail-237-207.rediffmail.com> you
> wrote:
>>
>> Our development needs NAND to be implemented from u-boot level. And our
>> booting from FLASH depends of NOR flash using the GPCM.
>>
>> We are facing in the initialization of the nand_init, a crash in the
>> dummy write during the UPM program based on the UPM mode of freescale
>> MPC8323 in the code below:
>>
>> void UPMA_prog()
>> {
>> int i=0;
>> // OP set to write to RAM array command
>> *(int *)(MAMR) = 0x10000000;
>> // Write word to RAM arrays
>> for (i=0;i
>
> There is no such code in mainline U-Boot. I recommend you look for
> existing (and working) code examples when porting U-Boot to your
> hardware. Note that you should use I/O accessor functions instead of
> plain register writes.
>
> Best regards,
>
> Wolfgang Denk
>
> --
> DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
> HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
> Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
> Digital computers are themselves more complex than most things people
> build: They have very large numbers of states. This makes conceiving,
> describing, and testing them hard. Software systems have orders-of-
> magnitude more states than computers do. - Fred Brooks, Jr.
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot
>
>
--
View this message in context: http://old.nabble.com/-U-Boot--Crash-nand-init--UPMA---NAND-flash-MPC832x-tp26865466p26870202.html
Sent from the Uboot - Users mailing list archive at Nabble.com.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [U-Boot] Crash nand init UPMA - NAND flash MPC832x
2009-12-21 5:55 ` KoteswarK
@ 2009-12-21 6:49 ` Ben Warren
0 siblings, 0 replies; 5+ messages in thread
From: Ben Warren @ 2009-12-21 6:49 UTC (permalink / raw)
To: u-boot
Koteswar,
A few things:
First of all, please don't top post.
On Sun, Dec 20, 2009 at 9:55 PM, KoteswarK <koti.kelam@gmail.com> wrote:
>
> Hi
> What are those "I/O accessor functions"? API present in
>
Look in include/asm-ppc/io.h. You'll find lots of wonderful accessor
functions. They're always preferable to the alternative.
> ./drivers/mtd/nand/fsl_upm.c file??? I am also getting crash while doing
> dummy write to NAND_BASE. Code is follows....
> void UPMA_prog()
> {
> int i=0;
> /* OP set to write to RAM array command*/
> *(int *)(MAMR) = 0x10000000;
> /* Write word to RAM arrays*/
> for (i=0;i<32;i++)
> {
> *(int *)(MDR) = UPMATable[i];
>
> udelay (100);
> /* *(int *)(MAMR) = 0x10000000;
> *
> * *(int *)(MAMR) = 0x10000000+i;*/
>
> /*dummy write*/
> *(char *)(CFG_NAND_BASE) = 0xff;
> }
> .............
> }
>
Why don't you use the upmconfig() function that's in cpu/mpc83xx/cpu.c? It
doesn't use I/O accessors either, but I give it better odds of working than
your code.
> Rgds
> Koteswar
>
>
regards,
Ben
^ permalink raw reply [flat|nested] 5+ messages in thread
* [U-Boot] Crash nand init UPMA - NAND flash MPC832x
@ 2009-12-28 6:18 nanda
0 siblings, 0 replies; 5+ messages in thread
From: nanda @ 2009-12-28 6:18 UTC (permalink / raw)
To: u-boot
Hi,
IO accessor function did not work out for us. But we survived from the crash in the UPM programming, if I move the base address of NAND after the NOR flash base address it programmed the UPM successfully.
Earlier Configuration ( Crash while programming UPMA):
------------------------------------------------------
CFG_NAND_BASE 0xFA000000 // 64 MB NAND flash
CFG_FLASH_BASE 0xFE000000 // NOR flash size is 16MB flash
Now Configuration(UPM Programming success case) :
---------------------------------------------------
CFG_NAND_BASE 0xFB000000 // 64 MB NAND flash
CFG_FLASH_BASE 0xFA000000 // NOR flash size is 16MB flash
Our summarized configuration file
include/configs/MPC832x_RDB.h is as below
NOR Flash Configuration using Local bus 0:
------------------------------------------
CFG_FLASH_BASE 0xFA000000 // NOR flash size is 16MB flash
CFG_BR0_PRELIM (CFG_FLASH_BASE | /* Flash Base address */ \
(2
> Our development needs NAND to be implemented from u-boot level. And our booting from FLASH depends of NOR flash using the GPCM.
>
> We are facing in the initialization of the nand_init, a crash in the dummy write during the UPM program based on the UPM mode of freescale MPC8323 in the code below:
>
> void UPMA_prog()
> {
> int i=0;
> // OP set to write to RAM array command
> *(int *)(MAMR) = 0x10000000;
> // Write word to RAM arrays
> for (i=0;i
There is no such code in mainline U-Boot. I recommend you look for
existing (and working) code examples when porting U-Boot to your
hardware. Note that you should use I/O accessor functions instead of
plain register writes.
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Digital computers are themselves more complex than most things people
build: They have very large numbers of states. This makes conceiving,
describing, and testing them hard. Software systems have orders-of-
magnitude more states than computers do. - Fred Brooks, Jr.
--------------------------------------------------------------------------------
Previous message: [U-Boot] Crash nand init UPMA - NAND flash MPC832x
Next message: [U-Boot] Crash nand init UPMA - NAND flash MPC832x
Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2009-12-28 6:18 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-20 17:24 [U-Boot] Crash nand init UPMA - NAND flash MPC832x nanda
2009-12-20 18:40 ` Wolfgang Denk
2009-12-21 5:55 ` KoteswarK
2009-12-21 6:49 ` Ben Warren
-- strict thread matches above, loose matches on Subject: below --
2009-12-28 6:18 nanda
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.