MTD XIP related issue

Paulius Zaleckas paulius.zaleckas at teltonika.lt
Fri Nov 14 07:42:53 EST 2008


Avik Sil wrote:
> While porting Linux kernel 2.6.26 on an ARM922T based custom board for
> XIP kernel, I came across the following bug report during boot-up:

Had the same problem. See my comments on your config file

[...]

> My kernel configuration is:

[...]

> #
> 
> # RAM/ROM/Flash chip drivers
> 
> #
> 
> CONFIG_MTD_CFI=y
> 
> # CONFIG_MTD_JEDECPROBE is not set
> 
> CONFIG_MTD_GEN_PROBE=y
> 
> # CONFIG_MTD_CFI_ADV_OPTIONS is not set
> 
> CONFIG_MTD_MAP_BANK_WIDTH_1=y
> 
> CONFIG_MTD_MAP_BANK_WIDTH_2=y
> 
> CONFIG_MTD_MAP_BANK_WIDTH_4=y

Select only the supported BANK_WIDTH.
The problem is that if multiple bank widths are selected, then in code which is placed
in RAM for XIP to work appears reference to __udivsi3(if I remember correctly) and
this function is on FLASH and FLASH at that moment is inaccessible.
Sometimes it works because this function is already cached by CPU.

Nicolas: I think there should be some way to work around this... If not maybe we should
add compile #error if multiple bank widths and XIP are selected...
 
> # CONFIG_MTD_MAP_BANK_WIDTH_8 is not set
> 
> # CONFIG_MTD_MAP_BANK_WIDTH_16 is not set
> 
> # CONFIG_MTD_MAP_BANK_WIDTH_32 is not set
> 
> CONFIG_MTD_CFI_I1=y
> 
> CONFIG_MTD_CFI_I2=y

Don't remember, but this may have the same effect also.
 
> # CONFIG_MTD_CFI_I4 is not set
> 
> # CONFIG_MTD_CFI_I8 is not set
> 
> # CONFIG_MTD_CFI_INTELEXT is not set
> 
> CONFIG_MTD_CFI_AMDSTD=y
> 
> # CONFIG_MTD_CFI_STAA is not set
> 
> CONFIG_MTD_CFI_UTIL=y
> 
> # CONFIG_MTD_RAM is not set
> 
> # CONFIG_MTD_ROM is not set
> 
> # CONFIG_MTD_ABSENT is not set
> 
> CONFIG_MTD_XIP=y



More information about the linux-mtd mailing list