Albert,

first of all, your device shoud be connected properly to the EMIF bus. Let's 
assume you did it.

KERNEL CHANGES:

Be sure to have in .config

CONFIG_MTD_PHYSMAP_START=0x2000000   (or wherever your flash base address is)
CONFIG_MTD_PHYSMAP_LEN=0x2000000        (i.e. 32MB)

In arch/arm/mach-davinci/board-yourboardname.c (or wherever your flash 
partitions are defined) you have to have

static struct resource davinci_yourboardname_norflash_resource = {
                .start = NOR_FLASH_PHYS,                                        
               //i.e. 0x2000000
                .end = NOR_FLASH_PHYS + SZ_32M - 1;                             
//i.e. 0x2000000 + 0x2000000 - 1
                .flags = IORESOURCE_MEM,
};

U-BOOT CHANGES:

But, I'm not sure this is all what you need. The flash device is initialized by 
the bootloader. I applied the following changes to u-boot (1.1.4) to make it 
able to recognize my flash (INTEL PC28F256P30B85):

board/yourboardname/flash_params.h
be sure NORFlashType enum contains your flash type (in my case it is 
FLASH_INTEL_P30_32MB_BOTTOM)

board/yourboardname/flash.c
                in flash_print_info() add
                               case  FLASH_28F256P30B: fmt = "28F256P30B\n"; 
break;
                in flash_get_size() add
                                case (FPW)INTEL_ID_28F256P30B:         /* Intel 
StrataFlash 28F256P30B */
                               info->flash_id += FLASH_28F256P30B;
                               info->sector_count = 259;
                               info->size = 0x02000000;
                               for (i = 0; i < info->sector_count; i++)
                               {
                                               if (i < 255)
                                                               info->start[i] = 
(ulong)addr + 0x20000 * i;
                                               else
                                                               info->start[i] = 
(ulong)addr + 0xfe0000 + 0x8000 * (i-255);
                               }
                               break;

in include/flash.h add the following definitions. They specify the number and 
size of sectors (you can find these values consulting the datasheet)
#define INTEL_ID_28F256P30B                0x891C891C
#define FLASH_28F256P30B                      0x00BD

I hope this helps

Regards

Gabriele

Da: Albert Burbea [mailto:[EMAIL PROTECTED]
Inviato: giovedì 7 agosto 2008 18.08
A: Gabriele Filosofi
Cc: [email protected]
Oggetto: Re: I: how can I get visibility to the full 32MB size of my flash?

hi gabriele
can you please explain how you did it?
Albert


On 8/7/08, Gabriele Filosofi <[EMAIL PROTECTED]<mailto:[EMAIL PROTECTED]>> 
wrote:
Hi,

For your information, this is just a SW limitation, not an intrinsic EMIF 
limitation. Indeed I was able to adjust things in SW and now the entire 32MB 
flash space can be accessed on my board.

Gabriele
_____________________________________________
Da: Gabriele Filosofi
Inviato: mercoledì 6 agosto 2008 11.54
A: 
'[email protected]<mailto:[email protected]>'
Oggetto: how can I get visibility to the full 32MB size of my flash?


Hi,

I Read that DaVinci supports only 16MByte NOR. Is this a device or a SW 
limitation? If it is a SW limitation, how can I get visibility to the full 
32MByte size of my flash?

Thanks a lot

Gabriele




_______________________________________________
Davinci-linux-open-source mailing list
[email protected]<mailto:[email protected]>
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source



--
Albert Burbea
Harishonim 8
Ramat Gan 52502, Israel
Tel/Fax + 972-3-7526016
Mobile: +972-52-3541842
_______________________________________________
Davinci-linux-open-source mailing list
[email protected]
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source

Reply via email to