Hello All,

My device uses Intel StrataFlash P30 (32 and 64 MB). It stores Eboot,
NK, other configurations and Filesystem. TFAT support is activated.
Following are the registry settings.

[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\MSFlash\FATFS]

;"Flags"=dword:600034 ; FATFS_DISABLE_AUTOSCAN,
FATFS_ENABLE_BACKUP_FAT, FATFS_FORCE_WRITETHROUGH
;FATFS_TFAT_ALWAYS, FATFS_FORCE_TFAT
"Flags"=dword:00290014
"FormatTFAT"=dword:1
"EnableWriteBack"=dword:1
"CheckForFormat"=dword:1
"TfatMarkAlways"=dword:1
"NonatomicSector"=dword:1
"DisableAutoScan"=dword:1
"Util"="fatutil.dll"

[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\MSFlash]
"Name"="MSFLASH for P30FLASH"
"Folder"="NOR Flash"
"FileSystem"="fatfsd.dll"
"PartitionDriver"="mspart.dll"
"Util"="fatutil.dll"
"AutoPart"=dword:1
"AutoFormat"=dword:1
"AutoMount"=dword:1
"MountFlags"=dword:2
"Flags"=dword:00290014
"MountAsRoot"=dword:1
"MountAsBootable"=dword:1
"Paging"=dword:0
"EnableCache"=dword:0

;For PowerManagement
"ActivityEvent"="PowerManager/ActivityTimer/SystemActivity"

[HKEY_LOCAL_MACHINE\System\StorageManager\AutoLoad\MSFlash]
"DriverPath"="Drivers\\BuiltIn\\P30_flashFMD"
"LoadFlags"=dword:1
"Order"=dword:0
"BootPhase"=dword:0

[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\P30_flashFMD]
"Dll"="P30_flash.dll"
"Order"=dword:2
"Prefix"="DSK"
"Ioctl"=dword:4
"Profile"="MSFlash"
"IClass"="{A4E7EDDA-E575-4252-9D6B-4195D48BB865}"
;Start file system at a 21MB offset to allow for image in flash
"MemBase"=dword:BBE00000
"MemLen"=dword:00900000


The problem is, during file copy operation, if power goes off, the
FAT corruption is observed.
The device stops booting on next power cycle.

The log is

Booting image from partition 0. Redundancy disabled

+Windows CE Kernel for ARM (Thumb Enabled) Built on Feb 8 2007 at
23:36:51
ProcessorType=0411 Revision=7
sp_abt=ffff5000 sp_irq=ffff2800 sp_undef=ffffc800 OEMAddressTable =
8010706c

Version Number: 2.0.0.5
Sp=ffffc7cc
OEMIoControl: Unsupported Code 0x101008c - device 0x0101 func 35
INFO: FMD_Init: Flash Address=0xbbe00000 Length=0x900000.
FMD_OEMIoControl: unrecognized IOCTL (0x71c24).
OEMIoControl: Unsupported Code 0x10100c4 - device 0x0101 func 49
===> hangs here.

Tried turning on debug prints from read/write routines of FMD
driver. It looks like the read routine is called infinite times from
upper layer.

Can anyone suggest what could be going wrong?... It's appreciated
for any advises.

Thanks in advance.

Suvarna.

RE: (NOR) FAT/TFAT problem. by CL

CL
Wed Aug 13 20:15:01 PDT 2008

I met this problem before. My platform is IXP425 and flash is also Intel
Strata flash.
What I do is
1. Before erasing the flash, set a flag.
2. After finishing erasing the flash, reset the flag.
If system reset when erasing the flash, the flag is not reset.
So, I can check the flag when booting up.
If the flag is set when booting up, I will erase the flash and then go into
WinCE.
This way will cause to ease the whole user storage if the condition occures.

The other way is to try WinCE6.0 FMD driver.
It seems to already resolve this problem.


"Suvarna" wrote:

> Hello All,
>
> My device uses Intel StrataFlash P30 (32 and 64 MB). It stores Eboot,
> NK, other configurations and Filesystem. TFAT support is activated.
> Following are the registry settings.
>
> [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\MSFlash\FATFS]
>
> ;"Flags"=dword:600034 ; FATFS_DISABLE_AUTOSCAN,
> FATFS_ENABLE_BACKUP_FAT, FATFS_FORCE_WRITETHROUGH
> ;FATFS_TFAT_ALWAYS, FATFS_FORCE_TFAT
> "Flags"=dword:00290014
> "FormatTFAT"=dword:1
> "EnableWriteBack"=dword:1
> "CheckForFormat"=dword:1
> "TfatMarkAlways"=dword:1
> "NonatomicSector"=dword:1
> "DisableAutoScan"=dword:1
> "Util"="fatutil.dll"
>
> [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\MSFlash]
> "Name"="MSFLASH for P30FLASH"
> "Folder"="NOR Flash"
> "FileSystem"="fatfsd.dll"
> "PartitionDriver"="mspart.dll"
> "Util"="fatutil.dll"
> "AutoPart"=dword:1
> "AutoFormat"=dword:1
> "AutoMount"=dword:1
> "MountFlags"=dword:2
> "Flags"=dword:00290014
> "MountAsRoot"=dword:1
> "MountAsBootable"=dword:1
> "Paging"=dword:0
> "EnableCache"=dword:0
>
> ;For PowerManagement
> "ActivityEvent"="PowerManager/ActivityTimer/SystemActivity"
>
> [HKEY_LOCAL_MACHINE\System\StorageManager\AutoLoad\MSFlash]
> "DriverPath"="Drivers\\BuiltIn\\P30_flashFMD"
> "LoadFlags"=dword:1
> "Order"=dword:0
> "BootPhase"=dword:0
>
> [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\P30_flashFMD]
> "Dll"="P30_flash.dll"
> "Order"=dword:2
> "Prefix"="DSK"
> "Ioctl"=dword:4
> "Profile"="MSFlash"
> "IClass"="{A4E7EDDA-E575-4252-9D6B-4195D48BB865}"
> ;Start file system at a 21MB offset to allow for image in flash
> "MemBase"=dword:BBE00000
> "MemLen"=dword:00900000
>
>
> The problem is, during file copy operation, if power goes off, the
> FAT corruption is observed.
> The device stops booting on next power cycle.
>
> The log is
>
> Booting image from partition 0. Redundancy disabled
>
> +Windows CE Kernel for ARM (Thumb Enabled) Built on Feb 8 2007 at
> 23:36:51
> ProcessorType=0411 Revision=7
> sp_abt=ffff5000 sp_irq=ffff2800 sp_undef=ffffc800 OEMAddressTable =
> 8010706c
>
> Version Number: 2.0.0.5
> Sp=ffffc7cc
> OEMIoControl: Unsupported Code 0x101008c - device 0x0101 func 35
> INFO: FMD_Init: Flash Address=0xbbe00000 Length=0x900000.
> FMD_OEMIoControl: unrecognized IOCTL (0x71c24).
> OEMIoControl: Unsupported Code 0x10100c4 - device 0x0101 func 49
> ===> hangs here.
>
> Tried turning on debug prints from read/write routines of FMD
> driver. It looks like the read routine is called infinite times from
> upper layer.
>
> Can anyone suggest what could be going wrong?... It's appreciated
> for any advises.
>
> Thanks in advance.
>
> Suvarna.
>
>