none
TI AM3703 - WEC7 BSP: Cannot process OALIoctl after OEMInit() RRS feed

  • Question

  • Hi All,

    I am migrating a BSP from WCE6 to WEC7. I have a working WCE6 serial log and compare it with my building WEC7 BSP log: I found in WEC7, I cannot get further log msg after OEMinit, where in WCE6, I can have a lot of msg in function OEMKitlIoctl() and OEMKitlIoctl() after OEMinit, and eventually I will get a working application in my WCE6 on the hardware.

    I posted WEC7 serial log here:

    NK Image Loaded
    Launch Windows CE image by jumping to 0x80002000...
    
    Windows CE Kernel for ARM (Thumb Enabled)
    +OEMInit
    OAL: CPU revision 0x12:VAR-OM37
    OAL: CPU L2 Aux register 0x400042
    
     BSP_VERSION: (V1.4.0.0)****Profiler Build****
    ---High Performance Frequency is 25999260 hz---
    DeviceId................. VAR-OM37-
    pArgs->flags............. 0x28
    pArgs->devLoc.IfcType.... 0
    pArgs->devLoc.LogicalLoc. 0x15000000
    pArgs->devLoc.PhysicalLoc 0x0
    pArgs->devLoc.Pin........ 0
    pArgs->ip4address........ 0
    pArgs->mac............... 0xDCF8 0x287A 0xF2A9
    pDevice->Name............  s
    pDevice->ifcType......... 0
    pDevice->id.............. 0x15000000
    pDevice->resource........ 0
    pDevice->type............ 2
    pDevice->pDriver......... 0x83642000
    WARN: OALKitlInit: KITL Disabled
    -OEMInit
    
    // No more log msg, system is hanging at this point. 

    In contrast, as the log msg in WCE6:

    NK Image Loaded
    Launch Windows CE image by jumping to 0x80002000...
    
    Windows CE Kernel for ARM (Thumb Enabled) Built on Sep 25 2009 at 11:04:23
    +OEMInit
    OAL: CPU revision 0x12:VAR-OM37
    OAL: CPU L2 Aux register 0x400042
    
     BSP_VERSION: (V1.4.0.0)****Profiler Build****
    ---High Performance Frequency is 25999372 hz---
    DeviceId................. VAR-OM37-
    pArgs->flags............. 0x28
    pArgs->devLoc.IfcType.... 0
    pArgs->devLoc.LogicalLoc. 0x15000000
    pArgs->devLoc.PhysicalLoc 0x0
    pArgs->devLoc.Pin........ 0
    pArgs->ip4address........ 0
    pArgs->mac............... 0xDCF8 0x2871 0xF2A9
    pDevice->Name............  s
    pDevice->ifcType......... 0
    pDevice->id.............. 0x15000000
    pDevice->resource........ 0
    pDevice->type............ 2
    pDevice->pDriver......... 0x81C62000
    WARN: OALKitlInit: KITL Disabled
    -OEMInit
    
    Myname: after  BOOL fRet = FALSE 2    // I added log here in BSP/KITL/oemkitl.c OEMKitlIoctl()
    Myname: before OALIoCtlVBridge2v      // I added log here in BSP/KITL/oemkitl.c OEMKitlIoctl()
    Myname: OALIoCtlVBridge                    // I added log here in Common/Kitl/Kilteth.c OALioctlVbridge()
    Myname: NKSetLastError                      // I added log here in Common/Kitl/Kilteth.c OALioctlVbridge()
    Myname: end of OALIoCtlVBridge          // I added log here in Common/Kitl/Kilteth.c OALioctlVbridge()
    
    Compensating OPP1 for 63mV Orig nvalue:0x898bf0 New nvalue:0x99ceb2
    Compensating OPP2 for 63mV Orig nvalue:0x9a8ff8 New nvalue:0xaaf2d2
    Compensating OPP3 for 75mV Orig nvalue:0xaadec2 New nvalue:0xaabea6
    Compensating OPP4 for 100mV Orig nvalue:0xaaa998 New nvalue:0xaa9081
    
    I2C: I2COpen bus 0
    
    // more log msg not posted here in WCE 6.

    Can you please guide me how to debug this hanging issue? I thought it probably a OALioct issue, or issue in ioctlVbridge. 

    Regards,

    Xuke  

    Monday, September 30, 2019 2:58 PM

All replies

  • You need a JTAGger to debug this. KITL is not active yet at this stage, so you will either need to start commenting out calls and see exactly where it hangs, or connect a JTAGger and set a breakpoint at OEMInit (or implement an infinite for loop so you can break in, set the PC to after the loop, and then step debug from that point).


    Good luck,

    Michel Verhagen, eMVP
    Check out my blog: https://guruce.com/blog

    GuruCE
    Microsoft Embedded Partner
    NXP Proven Partner
    https://guruce.com
    Consultancy, training and development services.

    Interested in WEC on i.MX6?
    Get the only 100% stable and best performing i.MX6 BSP for WEC7 and WEC2013 here: https://guruce.com/imx6

    Tuesday, October 1, 2019 12:12 AM
    Moderator
  • Hello Michel,

    Thanks for the reply.

    I disabled the KITL in the project build option and tried to focus on debugging inside the OEMInit() function, which is in OAL. I found I can only get log +OEMInit in log file, which means when the KITL disabled, the process count is hanging at somewhere inside the OEMInit(). Then I found pc stops at Get_CPUVersion(). I did some comparison and I didn't think there is anything wrong with this function. 

    So I suspect something wrong in the memory setting because the BSP is from WCE6 and I used the WEC7 memory layout (config.bib and eboot.bib, image_cfg.h) from soc example rather than use the one from working WCE6 environment. I changed the current memory layout back to the one in WCE6, and finally I got the log file can reach -OEMInit again.

    Now, I still have the issue on the pc hanging at the end of OEMInit(), but this time, the KITL disabled at this moment and memory layout I used WCE6 setting.

    Do you have any idea where are possible places go wrong? I appreciate any input!

    Wednesday, October 2, 2019 3:28 AM