Hello all:
My device is about S3C2440, it has a large page(2k byte/page)
nandflash(SAMSUNG K9F4G08,

512M), My OS is WinCE4.2 and the BSP is SMDK2440, so My bootlaoders are
nboot and eboot.

Using the BootPart library in eboot, the nandflash in my device has
two partions:BINFS

and FAT32. After the OS is running, I go to the storage manager in
control pannels and can

see two parts(part00, part01) in the list box, the Properties of each
Partition are OK, as

follows:

part00 size 18432 sectors
type 0x21
file system binfs.dll
flag 0x00000000

part01 size 242496 sectors
type 0x0B
file system fatfsd.dll
flag 0x00000000

However, the PART_DOS32 partition(part01) is not mounted by
WinCE4.2, and can not see

the folder "ResidentFlash". If select the Property of part01, the
Partition Properties

dialog correctly displays fatfsd.dll as the file system, but clicking
the mount button just

opens a message box that sais "Unable to mount partition". Even firstly
click the format

button, it shows ok, secondly click the mount button again, it also
shows "Unable

to mount partition".

The registry in the platform.reg used are as follows:

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Support BINFS Section
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Add BinFS to partition table
[HKEY_LOCAL_MACHINE\System\StorageManager\PartitionTable]
"21"="BINFS"

[HKEY_LOCAL_MACHINE\System\StorageManager\BINFS]
"Folder"="BINFS"
"FriendlyName"="Bin FileSystem"
"Dll"="binfs.dll"
; MountFlags:
; 0x10 specifies that this file system is to be mounted as an external
; ROM filesystem shadowing the \windows directory
; 0x1 specifies that the mountpoint \BINFS is to be hidden
;
"MountFlags"=dword:11
"BootPhase"=dword:0

;
; Entries to load the block driver that BINFS uses
; This is dependent on what device is used
;

[HKEY_LOCAL_MACHINE\System\StorageManager\AutoLoad\FlashDrv]
"DriverPath"="Drivers\\BlockDevice\\FlashDrv"
"LoadFlags"=dword:1
"MountFlags"=dword:11
"BootPhase"=dword:0

[HKEY_LOCAL_MACHINE\Drivers\BlockDevice\FlashDrv]
"Prefix"="DSK"
"Dll"="FLASHDRV.dll"
"Order"=dword:0
"Ioctl"=dword:4
"Profile"="FlashDrv"
"FriendlyName"="MS Flash Driver"
"MountFlags"=dword:11
"BootPhase"=dword:0

; Bind BINFS to the block driver
[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv]
"DefaultFileSystem"="BINFS"
"PartitionDriver"="mspart.dll"
"AutoMount"=dword:1
"AutoPart"=dword:1
"MountFlags"=dword:11
"Folder"="ResidentFlash"
"Name"="Microsoft Flash Disk"
"BootPhase"=dword:0

; Keep FATFS from trying to shadow \Windows
[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv\FATFS]
"MountFlags"=dword:0

[HKEY_LOCAL_MACHINE\System\StorageManager\FATFS]
"MountFlags"=dword:0

How to auto mount the PART_DOS32 partition in WinCE4.2 with large
page nandflash? Pls

give me some advices.

Thanks a lot for your answers.

Re: How to auto mount a PART_DOS32 patition in WinCE4.2 with 2k byte/page nandflash? by Anthony

Anthony
Thu Oct 26 01:42:20 CDT 2006

CE4.2 does not support sectors that are not 512. So you can either modify
your driver to manage your 2048 sectors as 4 sectors of 512 or customize the
FATUTIL code (I think the problem comes from a hard coded value inside)
after having cloned it.

HTH

--
--
--
----------------------------------------------------------------
Anthony Pellerin (eMVP)
ADENEO (ADESET)
Windows Embedded Consultant
<apellerin AT adeneo DOT adetelgroup DOT com>
http://www.adeneo.adetelgroup.com
Tél : +33 (0)4.72.18.57.77
Fax : +33 (0)4.72.18.57.78
----------------------------------------------------------------
<lljj462@tom.com> a écrit dans le message de news:
1161824527.252393.253450@i3g2000cwc.googlegroups.com...
> Hello all:
> My device is about S3C2440, it has a large page(2k byte/page)
> nandflash(SAMSUNG K9F4G08,
>
> 512M), My OS is WinCE4.2 and the BSP is SMDK2440, so My bootlaoders are
> nboot and eboot.
>
> Using the BootPart library in eboot, the nandflash in my device has
> two partions:BINFS
>
> and FAT32. After the OS is running, I go to the storage manager in
> control pannels and can
>
> see two parts(part00, part01) in the list box, the Properties of each
> Partition are OK, as
>
> follows:
>
> part00 size 18432 sectors
> type 0x21
> file system binfs.dll
> flag 0x00000000
>
> part01 size 242496 sectors
> type 0x0B
> file system fatfsd.dll
> flag 0x00000000
>
> However, the PART_DOS32 partition(part01) is not mounted by
> WinCE4.2, and can not see
>
> the folder "ResidentFlash". If select the Property of part01, the
> Partition Properties
>
> dialog correctly displays fatfsd.dll as the file system, but clicking
> the mount button just
>
> opens a message box that sais "Unable to mount partition". Even firstly
> click the format
>
> button, it shows ok, secondly click the mount button again, it also
> shows "Unable
>
> to mount partition".
>
> The registry in the platform.reg used are as follows:
>
> ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> ; Support BINFS Section
> ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> ; Add BinFS to partition table
> [HKEY_LOCAL_MACHINE\System\StorageManager\PartitionTable]
> "21"="BINFS"
>
> [HKEY_LOCAL_MACHINE\System\StorageManager\BINFS]
> "Folder"="BINFS"
> "FriendlyName"="Bin FileSystem"
> "Dll"="binfs.dll"
> ; MountFlags:
> ; 0x10 specifies that this file system is to be mounted as an external
> ; ROM filesystem shadowing the \windows directory
> ; 0x1 specifies that the mountpoint \BINFS is to be hidden
> ;
> "MountFlags"=dword:11
> "BootPhase"=dword:0
>
> ;
> ; Entries to load the block driver that BINFS uses
> ; This is dependent on what device is used
> ;
>
> [HKEY_LOCAL_MACHINE\System\StorageManager\AutoLoad\FlashDrv]
> "DriverPath"="Drivers\\BlockDevice\\FlashDrv"
> "LoadFlags"=dword:1
> "MountFlags"=dword:11
> "BootPhase"=dword:0
>
> [HKEY_LOCAL_MACHINE\Drivers\BlockDevice\FlashDrv]
> "Prefix"="DSK"
> "Dll"="FLASHDRV.dll"
> "Order"=dword:0
> "Ioctl"=dword:4
> "Profile"="FlashDrv"
> "FriendlyName"="MS Flash Driver"
> "MountFlags"=dword:11
> "BootPhase"=dword:0
>
> ; Bind BINFS to the block driver
> [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv]
> "DefaultFileSystem"="BINFS"
> "PartitionDriver"="mspart.dll"
> "AutoMount"=dword:1
> "AutoPart"=dword:1
> "MountFlags"=dword:11
> "Folder"="ResidentFlash"
> "Name"="Microsoft Flash Disk"
> "BootPhase"=dword:0
>
> ; Keep FATFS from trying to shadow \Windows
> [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv\FATFS]
> "MountFlags"=dword:0
>
> [HKEY_LOCAL_MACHINE\System\StorageManager\FATFS]
> "MountFlags"=dword:0
>
> How to auto mount the PART_DOS32 partition in WinCE4.2 with large
> page nandflash? Pls
>
> give me some advices.
>
> Thanks a lot for your answers.
>



Re: How to auto mount a PART_DOS32 patition in WinCE4.2 with 2k byte/page nandflash? by ryanox

ryanox
Fri Oct 27 01:01:05 CDT 2006

Reveiw the code of bootpart.cpp(\public\common\oak\drivers\ethdbg\bootpart)
and the header bootpart.h(\public\common\oak\inc)
I find that these codes seem to support the 512B size.

maybe it's necessary to modify the bootpart code to support the large size

and in my project, i hope to store the nk image and the Fat system in the
same nand flash(2KB/page, wince5.0).
The nand driver works, and in the system, I got the folder "nand flash"
defined in the platform.reg.
But each time booting into the system, the fat will format the entire nand
flash and erase the nk, even i set other areas as readonly.

My question is that, the binfs feature is the solution to my problem, isn't
it?

thanks
Ryo


"Anthony Pellerin" <apellerin@nospam_adeneo.adetelgroup.com> дÈëÓʼþ
news:%23$mVmnM%23GHA.5092@TK2MSFTNGP04.phx.gbl...
> CE4.2 does not support sectors that are not 512. So you can either modify
> your driver to manage your 2048 sectors as 4 sectors of 512 or customize
the
> FATUTIL code (I think the problem comes from a hard coded value inside)
> after having cloned it.
>
> HTH
>
> --
> --
> --
> ----------------------------------------------------------------
> Anthony Pellerin (eMVP)
> ADENEO (ADESET)
> Windows Embedded Consultant
> <apellerin AT adeneo DOT adetelgroup DOT com>
> http://www.adeneo.adetelgroup.com
> Tél : +33 (0)4.72.18.57.77
> Fax : +33 (0)4.72.18.57.78
> ----------------------------------------------------------------
> <lljj462@tom.com> a écrit dans le message de news:
> 1161824527.252393.253450@i3g2000cwc.googlegroups.com...
> > Hello all:
> > My device is about S3C2440, it has a large page(2k byte/page)
> > nandflash(SAMSUNG K9F4G08,
> >
> > 512M), My OS is WinCE4.2 and the BSP is SMDK2440, so My bootlaoders are
> > nboot and eboot.
> >
> > Using the BootPart library in eboot, the nandflash in my device has
> > two partions:BINFS
> >
> > and FAT32. After the OS is running, I go to the storage manager in
> > control pannels and can
> >
> > see two parts(part00, part01) in the list box, the Properties of each
> > Partition are OK, as
> >
> > follows:
> >
> > part00 size 18432 sectors
> > type 0x21
> > file system binfs.dll
> > flag 0x00000000
> >
> > part01 size 242496 sectors
> > type 0x0B
> > file system fatfsd.dll
> > flag 0x00000000
> >
> > However, the PART_DOS32 partition(part01) is not mounted by
> > WinCE4.2, and can not see
> >
> > the folder "ResidentFlash". If select the Property of part01, the
> > Partition Properties
> >
> > dialog correctly displays fatfsd.dll as the file system, but clicking
> > the mount button just
> >
> > opens a message box that sais "Unable to mount partition". Even firstly
> > click the format
> >
> > button, it shows ok, secondly click the mount button again, it also
> > shows "Unable
> >
> > to mount partition".
> >
> > The registry in the platform.reg used are as follows:
> >
> >
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> > ; Support BINFS Section
> >
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> > ; Add BinFS to partition table
> > [HKEY_LOCAL_MACHINE\System\StorageManager\PartitionTable]
> > "21"="BINFS"
> >
> > [HKEY_LOCAL_MACHINE\System\StorageManager\BINFS]
> > "Folder"="BINFS"
> > "FriendlyName"="Bin FileSystem"
> > "Dll"="binfs.dll"
> > ; MountFlags:
> > ; 0x10 specifies that this file system is to be mounted as an external
> > ; ROM filesystem shadowing the \windows directory
> > ; 0x1 specifies that the mountpoint \BINFS is to be hidden
> > ;
> > "MountFlags"=dword:11
> > "BootPhase"=dword:0
> >
> > ;
> > ; Entries to load the block driver that BINFS uses
> > ; This is dependent on what device is used
> > ;
> >
> > [HKEY_LOCAL_MACHINE\System\StorageManager\AutoLoad\FlashDrv]
> > "DriverPath"="Drivers\\BlockDevice\\FlashDrv"
> > "LoadFlags"=dword:1
> > "MountFlags"=dword:11
> > "BootPhase"=dword:0
> >
> > [HKEY_LOCAL_MACHINE\Drivers\BlockDevice\FlashDrv]
> > "Prefix"="DSK"
> > "Dll"="FLASHDRV.dll"
> > "Order"=dword:0
> > "Ioctl"=dword:4
> > "Profile"="FlashDrv"
> > "FriendlyName"="MS Flash Driver"
> > "MountFlags"=dword:11
> > "BootPhase"=dword:0
> >
> > ; Bind BINFS to the block driver
> > [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv]
> > "DefaultFileSystem"="BINFS"
> > "PartitionDriver"="mspart.dll"
> > "AutoMount"=dword:1
> > "AutoPart"=dword:1
> > "MountFlags"=dword:11
> > "Folder"="ResidentFlash"
> > "Name"="Microsoft Flash Disk"
> > "BootPhase"=dword:0
> >
> > ; Keep FATFS from trying to shadow \Windows
> > [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv\FATFS]
> > "MountFlags"=dword:0
> >
> > [HKEY_LOCAL_MACHINE\System\StorageManager\FATFS]
> > "MountFlags"=dword:0
> >
> > How to auto mount the PART_DOS32 partition in WinCE4.2 with large
> > page nandflash? Pls
> >
> > give me some advices.
> >
> > Thanks a lot for your answers.
> >
>
>



Re: How to auto mount a PART_DOS32 patition in WinCE4.2 with 2k byte/page nandflash? by ryanox

ryanox
Fri Oct 27 03:26:12 CDT 2006

Review the bootpart.cpp and bootpart.h in "public/common/oak", it seems that
the bootpart is for 512 bytes sector.

I guess it is necessary to modify the bootpart.cpp to support the large
size.

FOR my question, to use the rest area of the nand flash as fat system, is it
necessary to use binfs feature?

wince5.0, nand with 2K/page

The nand driver is working and the folder "nand flash" defined in
platform.reg can be found after booting into the system. I can store/delete
files in "nand flash".
But the problem is that each time booting into the system, the FAT driver
will format the entire flash area and erase nk image. I try to set other
sectors as READONLY, but it does not work.

What's up??

Thanks
Ryo


"Anthony Pellerin" <apellerin@nospam_adeneo.adetelgroup.com> дÈëÓʼþ
news:%23$mVmnM%23GHA.5092@TK2MSFTNGP04.phx.gbl...
> CE4.2 does not support sectors that are not 512. So you can either modify
> your driver to manage your 2048 sectors as 4 sectors of 512 or customize
the
> FATUTIL code (I think the problem comes from a hard coded value inside)
> after having cloned it.
>
> HTH
>
> --
> --
> --
> ----------------------------------------------------------------
> Anthony Pellerin (eMVP)
> ADENEO (ADESET)
> Windows Embedded Consultant
> <apellerin AT adeneo DOT adetelgroup DOT com>
> http://www.adeneo.adetelgroup.com
> Tél : +33 (0)4.72.18.57.77
> Fax : +33 (0)4.72.18.57.78
> ----------------------------------------------------------------
> <lljj462@tom.com> a écrit dans le message de news:
> 1161824527.252393.253450@i3g2000cwc.googlegroups.com...
> > Hello all:
> > My device is about S3C2440, it has a large page(2k byte/page)
> > nandflash(SAMSUNG K9F4G08,
> >
> > 512M), My OS is WinCE4.2 and the BSP is SMDK2440, so My bootlaoders are
> > nboot and eboot.
> >
> > Using the BootPart library in eboot, the nandflash in my device has
> > two partions:BINFS
> >
> > and FAT32. After the OS is running, I go to the storage manager in
> > control pannels and can
> >
> > see two parts(part00, part01) in the list box, the Properties of each
> > Partition are OK, as
> >
> > follows:
> >
> > part00 size 18432 sectors
> > type 0x21
> > file system binfs.dll
> > flag 0x00000000
> >
> > part01 size 242496 sectors
> > type 0x0B
> > file system fatfsd.dll
> > flag 0x00000000
> >
> > However, the PART_DOS32 partition(part01) is not mounted by
> > WinCE4.2, and can not see
> >
> > the folder "ResidentFlash". If select the Property of part01, the
> > Partition Properties
> >
> > dialog correctly displays fatfsd.dll as the file system, but clicking
> > the mount button just
> >
> > opens a message box that sais "Unable to mount partition". Even firstly
> > click the format
> >
> > button, it shows ok, secondly click the mount button again, it also
> > shows "Unable
> >
> > to mount partition".
> >
> > The registry in the platform.reg used are as follows:
> >
> >
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> > ; Support BINFS Section
> >
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> > ; Add BinFS to partition table
> > [HKEY_LOCAL_MACHINE\System\StorageManager\PartitionTable]
> > "21"="BINFS"
> >
> > [HKEY_LOCAL_MACHINE\System\StorageManager\BINFS]
> > "Folder"="BINFS"
> > "FriendlyName"="Bin FileSystem"
> > "Dll"="binfs.dll"
> > ; MountFlags:
> > ; 0x10 specifies that this file system is to be mounted as an external
> > ; ROM filesystem shadowing the \windows directory
> > ; 0x1 specifies that the mountpoint \BINFS is to be hidden
> > ;
> > "MountFlags"=dword:11
> > "BootPhase"=dword:0
> >
> > ;
> > ; Entries to load the block driver that BINFS uses
> > ; This is dependent on what device is used
> > ;
> >
> > [HKEY_LOCAL_MACHINE\System\StorageManager\AutoLoad\FlashDrv]
> > "DriverPath"="Drivers\\BlockDevice\\FlashDrv"
> > "LoadFlags"=dword:1
> > "MountFlags"=dword:11
> > "BootPhase"=dword:0
> >
> > [HKEY_LOCAL_MACHINE\Drivers\BlockDevice\FlashDrv]
> > "Prefix"="DSK"
> > "Dll"="FLASHDRV.dll"
> > "Order"=dword:0
> > "Ioctl"=dword:4
> > "Profile"="FlashDrv"
> > "FriendlyName"="MS Flash Driver"
> > "MountFlags"=dword:11
> > "BootPhase"=dword:0
> >
> > ; Bind BINFS to the block driver
> > [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv]
> > "DefaultFileSystem"="BINFS"
> > "PartitionDriver"="mspart.dll"
> > "AutoMount"=dword:1
> > "AutoPart"=dword:1
> > "MountFlags"=dword:11
> > "Folder"="ResidentFlash"
> > "Name"="Microsoft Flash Disk"
> > "BootPhase"=dword:0
> >
> > ; Keep FATFS from trying to shadow \Windows
> > [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv\FATFS]
> > "MountFlags"=dword:0
> >
> > [HKEY_LOCAL_MACHINE\System\StorageManager\FATFS]
> > "MountFlags"=dword:0
> >
> > How to auto mount the PART_DOS32 partition in WinCE4.2 with large
> > page nandflash? Pls
> >
> > give me some advices.
> >
> > Thanks a lot for your answers.
> >
>
>



Re: How to auto mount a PART_DOS32 patition in WinCE4.2 with 2k byte/page nandflash? by lljj462

lljj462
Sun Oct 29 18:40:26 CST 2006


Perhaps, in platform.reg, you should not set
"AutoFormat"=dword:1

this will auto format the nandflash


Re: How to auto mount a PART_DOS32 patition in WinCE4.2 with 2k byte/page nandflash? by ryanox

ryanox
Mon Oct 30 02:52:03 CST 2006

I tried, but it does not work.

thanks
Ryo

<lljj462@tom.com> ????
news:1162168826.020826.171250@f16g2000cwb.googlegroups.com...
>
> Perhaps, in platform.reg, you should not set
> "AutoFormat"=dword:1
>
> this will auto format the nandflash
>




Re: How to auto mount a PART_DOS32 patition in WinCE4.2 with 2k byte/page nandflash? by Anthony

Anthony
Mon Oct 30 04:51:45 CST 2006

For the FATFS, the bootloader as nothing to see. Just build a block driver
based on an FMD where the sector 0 is not the first one of the nandflash but
the first one available for stopring data (it is the same FMD as you should
run except that you should add an offset).
Try making the modification I talked about in the thread for fatutil and
re-format the flash.

HTH

--
--
--
----------------------------------------------------------------
Anthony Pellerin (eMVP)
ADENEO (ADESET)
Windows Embedded Consultant
<apellerin AT adeneo DOT adetelgroup DOT com>
http://www.adeneo.adetelgroup.com
Tél : +33 (0)4.72.18.57.77
Fax : +33 (0)4.72.18.57.78
----------------------------------------------------------------
"ryanox" <ryanoxox@hotmail.com> a écrit dans le message de news:
%23SCxZGa%23GHA.4888@TK2MSFTNGP04.phx.gbl...
> Review the bootpart.cpp and bootpart.h in "public/common/oak", it seems
> that
> the bootpart is for 512 bytes sector.
>
> I guess it is necessary to modify the bootpart.cpp to support the large
> size.
>
> FOR my question, to use the rest area of the nand flash as fat system, is
> it
> necessary to use binfs feature?
>
> wince5.0, nand with 2K/page
>
> The nand driver is working and the folder "nand flash" defined in
> platform.reg can be found after booting into the system. I can
> store/delete
> files in "nand flash".
> But the problem is that each time booting into the system, the FAT driver
> will format the entire flash area and erase nk image. I try to set other
> sectors as READONLY, but it does not work.
>
> What's up??
>
> Thanks
> Ryo
>
>
> "Anthony Pellerin" <apellerin@nospam_adeneo.adetelgroup.com> дÈëÓʼþ
> news:%23$mVmnM%23GHA.5092@TK2MSFTNGP04.phx.gbl...
>> CE4.2 does not support sectors that are not 512. So you can either modify
>> your driver to manage your 2048 sectors as 4 sectors of 512 or customize
> the
>> FATUTIL code (I think the problem comes from a hard coded value inside)
>> after having cloned it.
>>
>> HTH
>>
>> --
>> --
>> --
>> ----------------------------------------------------------------
>> Anthony Pellerin (eMVP)
>> ADENEO (ADESET)
>> Windows Embedded Consultant
>> <apellerin AT adeneo DOT adetelgroup DOT com>
>> http://www.adeneo.adetelgroup.com
>> Tél : +33 (0)4.72.18.57.77
>> Fax : +33 (0)4.72.18.57.78
>> ----------------------------------------------------------------
>> <lljj462@tom.com> a écrit dans le message de news:
>> 1161824527.252393.253450@i3g2000cwc.googlegroups.com...
>> > Hello all:
>> > My device is about S3C2440, it has a large page(2k byte/page)
>> > nandflash(SAMSUNG K9F4G08,
>> >
>> > 512M), My OS is WinCE4.2 and the BSP is SMDK2440, so My bootlaoders are
>> > nboot and eboot.
>> >
>> > Using the BootPart library in eboot, the nandflash in my device has
>> > two partions:BINFS
>> >
>> > and FAT32. After the OS is running, I go to the storage manager in
>> > control pannels and can
>> >
>> > see two parts(part00, part01) in the list box, the Properties of each
>> > Partition are OK, as
>> >
>> > follows:
>> >
>> > part00 size 18432 sectors
>> > type 0x21
>> > file system binfs.dll
>> > flag 0x00000000
>> >
>> > part01 size 242496 sectors
>> > type 0x0B
>> > file system fatfsd.dll
>> > flag 0x00000000
>> >
>> > However, the PART_DOS32 partition(part01) is not mounted by
>> > WinCE4.2, and can not see
>> >
>> > the folder "ResidentFlash". If select the Property of part01, the
>> > Partition Properties
>> >
>> > dialog correctly displays fatfsd.dll as the file system, but clicking
>> > the mount button just
>> >
>> > opens a message box that sais "Unable to mount partition". Even firstly
>> > click the format
>> >
>> > button, it shows ok, secondly click the mount button again, it also
>> > shows "Unable
>> >
>> > to mount partition".
>> >
>> > The registry in the platform.reg used are as follows:
>> >
>> >
> ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
>> > ; Support BINFS Section
>> >
> ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
>> > ; Add BinFS to partition table
>> > [HKEY_LOCAL_MACHINE\System\StorageManager\PartitionTable]
>> > "21"="BINFS"
>> >
>> > [HKEY_LOCAL_MACHINE\System\StorageManager\BINFS]
>> > "Folder"="BINFS"
>> > "FriendlyName"="Bin FileSystem"
>> > "Dll"="binfs.dll"
>> > ; MountFlags:
>> > ; 0x10 specifies that this file system is to be mounted as an external
>> > ; ROM filesystem shadowing the \windows directory
>> > ; 0x1 specifies that the mountpoint \BINFS is to be hidden
>> > ;
>> > "MountFlags"=dword:11
>> > "BootPhase"=dword:0
>> >
>> > ;
>> > ; Entries to load the block driver that BINFS uses
>> > ; This is dependent on what device is used
>> > ;
>> >
>> > [HKEY_LOCAL_MACHINE\System\StorageManager\AutoLoad\FlashDrv]
>> > "DriverPath"="Drivers\\BlockDevice\\FlashDrv"
>> > "LoadFlags"=dword:1
>> > "MountFlags"=dword:11
>> > "BootPhase"=dword:0
>> >
>> > [HKEY_LOCAL_MACHINE\Drivers\BlockDevice\FlashDrv]
>> > "Prefix"="DSK"
>> > "Dll"="FLASHDRV.dll"
>> > "Order"=dword:0
>> > "Ioctl"=dword:4
>> > "Profile"="FlashDrv"
>> > "FriendlyName"="MS Flash Driver"
>> > "MountFlags"=dword:11
>> > "BootPhase"=dword:0
>> >
>> > ; Bind BINFS to the block driver
>> > [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv]
>> > "DefaultFileSystem"="BINFS"
>> > "PartitionDriver"="mspart.dll"
>> > "AutoMount"=dword:1
>> > "AutoPart"=dword:1
>> > "MountFlags"=dword:11
>> > "Folder"="ResidentFlash"
>> > "Name"="Microsoft Flash Disk"
>> > "BootPhase"=dword:0
>> >
>> > ; Keep FATFS from trying to shadow \Windows
>> > [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv\FATFS]
>> > "MountFlags"=dword:0
>> >
>> > [HKEY_LOCAL_MACHINE\System\StorageManager\FATFS]
>> > "MountFlags"=dword:0
>> >
>> > How to auto mount the PART_DOS32 partition in WinCE4.2 with large
>> > page nandflash? Pls
>> >
>> > give me some advices.
>> >
>> > Thanks a lot for your answers.
>> >
>>
>>
>
>



Re: How to auto mount a PART_DOS32 patition in WinCE4.2 with 2k byte/page nandflash? by ryanox

ryanox
Mon Oct 30 20:41:57 CST 2006

It's such a good advice.
I tried, add an offset in the FMD, and it is ok.
Just make a few modification, it's interesting.

Thanks a lot.

Ryo


"Anthony Pellerin" <apellerin@nospam_adeneo.adetelgroup.com> дÈëÓʼþ
news:uifs4DB$GHA.4740@TK2MSFTNGP03.phx.gbl...
> For the FATFS, the bootloader as nothing to see. Just build a block driver
> based on an FMD where the sector 0 is not the first one of the nandflash
but
> the first one available for stopring data (it is the same FMD as you
should
> run except that you should add an offset).
> Try making the modification I talked about in the thread for fatutil and
> re-format the flash.
>
> HTH
>
> --
> --
> --
> ----------------------------------------------------------------
> Anthony Pellerin (eMVP)
> ADENEO (ADESET)
> Windows Embedded Consultant
> <apellerin AT adeneo DOT adetelgroup DOT com>
> http://www.adeneo.adetelgroup.com
> Tél : +33 (0)4.72.18.57.77
> Fax : +33 (0)4.72.18.57.78
> ----------------------------------------------------------------
> "ryanox" <ryanoxox@hotmail.com> a écrit dans le message de news:
> %23SCxZGa%23GHA.4888@TK2MSFTNGP04.phx.gbl...
> > Review the bootpart.cpp and bootpart.h in "public/common/oak", it seems
> > that
> > the bootpart is for 512 bytes sector.
> >
> > I guess it is necessary to modify the bootpart.cpp to support the large
> > size.
> >
> > FOR my question, to use the rest area of the nand flash as fat system,
is
> > it
> > necessary to use binfs feature?
> >
> > wince5.0, nand with 2K/page
> >
> > The nand driver is working and the folder "nand flash" defined in
> > platform.reg can be found after booting into the system. I can
> > store/delete
> > files in "nand flash".
> > But the problem is that each time booting into the system, the FAT
driver
> > will format the entire flash area and erase nk image. I try to set other
> > sectors as READONLY, but it does not work.
> >
> > What's up??
> >
> > Thanks
> > Ryo
> >
> >
> > "Anthony Pellerin" <apellerin@nospam_adeneo.adetelgroup.com> дÈëÓʼþ
> > news:%23$mVmnM%23GHA.5092@TK2MSFTNGP04.phx.gbl...
> >> CE4.2 does not support sectors that are not 512. So you can either
modify
> >> your driver to manage your 2048 sectors as 4 sectors of 512 or
customize
> > the
> >> FATUTIL code (I think the problem comes from a hard coded value inside)
> >> after having cloned it.
> >>
> >> HTH
> >>
> >> --
> >> --
> >> --
> >> ----------------------------------------------------------------
> >> Anthony Pellerin (eMVP)
> >> ADENEO (ADESET)
> >> Windows Embedded Consultant
> >> <apellerin AT adeneo DOT adetelgroup DOT com>
> >> http://www.adeneo.adetelgroup.com
> >> Tél : +33 (0)4.72.18.57.77
> >> Fax : +33 (0)4.72.18.57.78
> >> ----------------------------------------------------------------
> >> <lljj462@tom.com> a écrit dans le message de news:
> >> 1161824527.252393.253450@i3g2000cwc.googlegroups.com...
> >> > Hello all:
> >> > My device is about S3C2440, it has a large page(2k byte/page)
> >> > nandflash(SAMSUNG K9F4G08,
> >> >
> >> > 512M), My OS is WinCE4.2 and the BSP is SMDK2440, so My bootlaoders
are
> >> > nboot and eboot.
> >> >
> >> > Using the BootPart library in eboot, the nandflash in my device has
> >> > two partions:BINFS
> >> >
> >> > and FAT32. After the OS is running, I go to the storage manager in
> >> > control pannels and can
> >> >
> >> > see two parts(part00, part01) in the list box, the Properties of each
> >> > Partition are OK, as
> >> >
> >> > follows:
> >> >
> >> > part00 size 18432 sectors
> >> > type 0x21
> >> > file system binfs.dll
> >> > flag 0x00000000
> >> >
> >> > part01 size 242496 sectors
> >> > type 0x0B
> >> > file system fatfsd.dll
> >> > flag 0x00000000
> >> >
> >> > However, the PART_DOS32 partition(part01) is not mounted by
> >> > WinCE4.2, and can not see
> >> >
> >> > the folder "ResidentFlash". If select the Property of part01, the
> >> > Partition Properties
> >> >
> >> > dialog correctly displays fatfsd.dll as the file system, but clicking
> >> > the mount button just
> >> >
> >> > opens a message box that sais "Unable to mount partition". Even
firstly
> >> > click the format
> >> >
> >> > button, it shows ok, secondly click the mount button again, it also
> >> > shows "Unable
> >> >
> >> > to mount partition".
> >> >
> >> > The registry in the platform.reg used are as follows:
> >> >
> >> >
> >
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> >> > ; Support BINFS Section
> >> >
> >
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> >> > ; Add BinFS to partition table
> >> > [HKEY_LOCAL_MACHINE\System\StorageManager\PartitionTable]
> >> > "21"="BINFS"
> >> >
> >> > [HKEY_LOCAL_MACHINE\System\StorageManager\BINFS]
> >> > "Folder"="BINFS"
> >> > "FriendlyName"="Bin FileSystem"
> >> > "Dll"="binfs.dll"
> >> > ; MountFlags:
> >> > ; 0x10 specifies that this file system is to be mounted as an
external
> >> > ; ROM filesystem shadowing the \windows directory
> >> > ; 0x1 specifies that the mountpoint \BINFS is to be hidden
> >> > ;
> >> > "MountFlags"=dword:11
> >> > "BootPhase"=dword:0
> >> >
> >> > ;
> >> > ; Entries to load the block driver that BINFS uses
> >> > ; This is dependent on what device is used
> >> > ;
> >> >
> >> > [HKEY_LOCAL_MACHINE\System\StorageManager\AutoLoad\FlashDrv]
> >> > "DriverPath"="Drivers\\BlockDevice\\FlashDrv"
> >> > "LoadFlags"=dword:1
> >> > "MountFlags"=dword:11
> >> > "BootPhase"=dword:0
> >> >
> >> > [HKEY_LOCAL_MACHINE\Drivers\BlockDevice\FlashDrv]
> >> > "Prefix"="DSK"
> >> > "Dll"="FLASHDRV.dll"
> >> > "Order"=dword:0
> >> > "Ioctl"=dword:4
> >> > "Profile"="FlashDrv"
> >> > "FriendlyName"="MS Flash Driver"
> >> > "MountFlags"=dword:11
> >> > "BootPhase"=dword:0
> >> >
> >> > ; Bind BINFS to the block driver
> >> > [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv]
> >> > "DefaultFileSystem"="BINFS"
> >> > "PartitionDriver"="mspart.dll"
> >> > "AutoMount"=dword:1
> >> > "AutoPart"=dword:1
> >> > "MountFlags"=dword:11
> >> > "Folder"="ResidentFlash"
> >> > "Name"="Microsoft Flash Disk"
> >> > "BootPhase"=dword:0
> >> >
> >> > ; Keep FATFS from trying to shadow \Windows
> >> > [HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\FlashDrv\FATFS]
> >> > "MountFlags"=dword:0
> >> >
> >> > [HKEY_LOCAL_MACHINE\System\StorageManager\FATFS]
> >> > "MountFlags"=dword:0
> >> >
> >> > How to auto mount the PART_DOS32 partition in WinCE4.2 with large
> >> > page nandflash? Pls
> >> >
> >> > give me some advices.
> >> >
> >> > Thanks a lot for your answers.
> >> >
> >>
> >>
> >
> >
>
>