AnsweredAssumed Answered

iMX28 Mfgtool File Transfer Failing

Question asked by markwilliams on Sep 24, 2015
Latest reply on Jun 28, 2017 by markwilliams

Hi all,

 

We have been successfully using mfgtool to program our iMX28 NAND with Windows CE 6.0 for the last few years. I have recently had to modify the UUT project source and rebuild it for use with mfgtool. Since rebuilding I am able to program eboot and the nk image to flash but the file transfers fail.

 

Eboot and the NK image are written with custom ioctl codes. The file writes first get a file handle using createfile but this is where I have an issue.

 

At the point where the files are to be transferred it seems to crash in a 'CreateFile' call with a DMA timeout. This timeout debug message is only output under an actual DMA timeout condition (I checked in case the error was something else and the debug message misleading). Using the same UCL xml file the process completes for our earlier build UUT project.

 

I am currently working through all BSP changes that have been made to see if anything could be preventing the NAND from writing the files but I have not found anything yet. While I search further I am raising this discussion in case anyone has suffered this issue and may be able to help.

 

The debug output during the mfgtool transfer is below:

 

Windows CE Kernel for ARM (Thumb Enabled) Built on Mar  8 2013 at 17:05:33

INFO:OALLogSetZones: dpCurSettings.ulZoneMask: 0xb

OALInitCpuHclkClock:Update CPU clock to 454MHz!

WARN: Boot arguments not found, use defaults

DeviceId................. MX280

pArgs->flags............. 0xC

pArgs->devLoc.IfcType.... 0

pArgs->devLoc.LogicalLoc. 0x80080000

pArgs->devLoc.PhysicalLoc 0x80080000

pArgs->devLoc.Pin........ 0

pArgs->ip4address........ 0

pDevice->Name............  s

pDevice->ifcType......... 0

pDevice->id.............. 0x80080000

pDevice->resource........ 0

pDevice->type............ 2

pDevice->pDriver......... 0x8049902C

WARN: OALKitlInit: KITL Disabled

reset GPMI module

enable bch module

NAND FullCode = 0x1590da98

NAND FullCode = 0x0

NumberOfChip=1

NAND_ECCConfLayout, pagesize=2048,sisize=64

INFO: Set NAND flash blocks [0x0 ~ 0x217] as reserved.

BOT_InternalInit with Drivers\Active\07

SDHC: + DllEntry, Enter

UFN_ATTACH with key = Drivers\Active\07

UFN_CONFIGURED: BOT_OpenInterface again

UTP command:Media type: NAND.

UTP command:Check if disk is ready.

Please be patient to wait...

Send storage Friendly name: NAND FLASH Storage.

Send time out: 10.

Find Store Device Name is DSK2:

Find Store Friendly Name is NAND FLASH Storage

Info:Find Store by Friendly Name NAND FLASH Storage

Get Store disk name:DSK2: by Friendly name NAND FLASH Storage.

GetStoreList:szDisplayName is DSK2: NAND FLASH Storage

GetStoreList:szDisplayName is DSK1: SD Memory Card

DSK2: is ready.

UTP command:Write image.

UTP command:Image type: EBOOT SB.

UTP command:Send data.

Whole data length to be sent: 0xa09b0.

INFO: Programming NAND flash blocks 0xa

INFO: Programming NAND flash blocks 0x10

INFO: Programming NAND flash blocks 0xb

INFO: Programming NAND flash blocks 0x11

INFO: Programming NAND flash blocks 0xc

INFO: Programming NAND flash blocks 0x12

INFO: Programming NAND flash blocks 0xd

INFO: Programming NAND flash blocks 0x13

INFO: Programming NAND flash blocks 0xe

INFO: Programming NAND flash blocks 0x14

INFO: Programming NAND flash blocks 0xf

INFO: Programming NAND flash blocks 0x15

INFO: Set NAND flash blocks [0x0 ~ 0x217] as reserved.

Recieving data: 100% finished.

UTP command:Write image.

UTP command:Image type: NK NB0.

UTP command:Send data.

Whole data length to be sent: 0x3200000.

INFO: Set NAND flash blocks [0x0 ~ 0x217] as reserved.

Recieving data: 100% finished.

UTP command:Check if folder is ready.

Please be patient to wait...

Send folder name: FlashDisk.

Send time out: 10.

FlashDisk disk is ready.

UTP command:Write file.

UTP command:File name to be sent: FlashDisk\test.txt.

CreateFile FlashDisk\test.txt file.

-DMA_Wait(ERROR_DDI_NAND_DMA_TIMEOUT)

Flash PDD Error: Function: FlashPdd_IoControl,  Line: 365-DMA_Wait(ERROR_DDI_NAND_DMA_TIMEOUT)

Flash PDD Error: Function: FlashPdd_IoControl,  Line: 365-DMA_Wait(ERROR_DDI_NAND_DMA_TIMEOUT)

 

On the old UUT build the debug is exactly the same except the last stage:

 

CreateFile FlashDisk\test.txt file.

UTP command:Send data.

Whole data length to be sent: 0x670.

Prepare to receive file data...

Writing File data: 100% is finished.

Close file.

Whole update work is finished successfully. Please power off the board.

 

 

I am also wondering if anyone could help with how to debug this project in visual studio? As this is loaded directly into RAM by mfgtool I am not sure if I can connect and step through the image in VS? At the moment I am using retailmsg to output progress.

 

The only other thing I can think of is that there has been a Windows Update that has broken this functionality in the UUT project.

 

Thanks in advance,

 

Mark

Outcomes