none
Wince LazyFlush resume problem RRS feed

  • Question

  • Dear Experts,

    I am using OMAP35X and WinCE 6.14 BSP.

    I am trying LazyFlush feature by set PRJ_ENABLE_REGFLUSH_THREAD=1, PRJ_ENABLE_FSREGHIVE=1, "RegistryFlags"=dword:0).

    And add [HKEY_LOCAL_MACHINE\System\ObjectStore\RegFlush] registry key:

    [HKEY_LOCAL_MACHINE\System\ObjectStore\RegFlush]

    ;"ActivityName"=""

    "SpawnThread"=dword:1

    "FlushPriority256"=dword:FF

    "ActivityThreshold"=dword:100

    "FlushPeriod"=dword:1388

    =========================

    It works, but there is a issue:

    When system into suspend and resume, sometimes I can not save registry anymore.

    If I can not save registry anymore, it will keep this situation until power off/on system.

    I wonder if resume happend, LazyFlush thread might occurs early than resume/re-mount storage device, 

    thus filesystem will break down somewhere.

    Am I right ?

    However, If I disable background saving registry ("RegistryFlags"=dword:2). There is no problem during suspend/resume.

    It seems that an existing thread which need read/write storage device will influence resume procedure.

     

    Can I delay the lazy flush thread when I resume the platform ??  How to achieve this ?? I can't find any implementation about lazy flush  !!

     

    Anyone can tell me how to solve this issue ~ ?!

    Thx ~


    Thursday, March 24, 2011 3:05 AM

All replies

  • What type of storage device are you persisting the registry to?  Does it get unmounted during suspend?  Also, are you - or have you tried - running under KITL to see if there are any errors being reported during the suspend/resume that would indicate that there is a problem with accessing the storage device?
    Tom Gensel PTG Systems, LLC
    http://www.ptgsystems.com
    Thursday, March 24, 2011 10:04 PM
  • 1) I am using SD Card and iNand Flash as my storage device.

    2) If I turn on the Lazy Flush, sometimes the storage device will be unmounted during resume. If turn off Lazy Flush, never happened!

    3) Accessing the storage device is no problem after resume, I thought the problem is when I resume the system, sometimes my storage device is unmounted and remounted, thus I cant not save registry anymore. I adjust "PNPUnloadDelay" to large value, but storage device will also be unmounted during resume sometimes.

     

    (No Lazy Flush) 

    Wince --> suspend --> resume --> everything works fine.

    ------

    (Have lazy Flush)

    Wince --> suspend --> resume --> sometimes storage device is unmounted and remounted --> can't save registry anymore till power off/on system.

     

    I thought this issue is similar with following situation:

    Wince Media player is playing Media file -> suspend -> resume --> sometimes Media player play media continuously, sometimes Media player get errors.

     

    They both have a thread which read/write storage device during suspend/resume.

     

    Friday, March 25, 2011 2:00 AM
  • Again, have you tried capturing the debug output stream (using KITL or debug serial) to see if there are any error messages that might indicate something is breaking during the process of suspend/resume or the subsequent attempt(s) to save the registry?


    Tom Gensel PTG Systems, LLC
    http://www.ptgsystems.com
    Sunday, March 27, 2011 4:04 PM