none
What is "shadow" role of x86InitRomChain() ? RRS feed

  • Question

  • WinCE 5/6/7

    I found that OEMInit() calls stub routine known as x86InitRomChain() that always returns from its first lines. I have no ideas why is it "supported" through numerous WinCE versions?! Has had this routine ever some practice role?



    Tuesday, August 30, 2011 9:28 AM

Answers

  • It's related to multiple XIP  (see http://msdn.microsoft.com/en-us/library/aa450576.aspx and http://msdn.microsoft.com/en-us/library/ms836792.aspx) which is rarely if ever used in x86 systems, thus most of times the function returns since "Rom chain NOT found".

    (This happens because DWORD *pdwXIPLoc = NOT_FIXEDUP in %_WINCEROOT%\PLATFORM\COMMON\SRC\X86\COMMON\STARTUP\oeminit.c and, in case you should fix up the variable in config.bib, see http://msdn.microsoft.com/en-us/library/ee482877.aspx):

    MEMORY
      #define XIPLOC_PHYSICAL 802C0000;
      Location of the chain
      RESERVE $(XIPLOC_PHYSICAL) 00002000;
      CHAIN
      nk.exe:pdwXIPLoc 00000000 $(XIPLOC_PHYSICAL) FIXUPVAR
    CONFIG
      XIPSCHAIN= $(XIPLOC_PHYSICAL)
    

    I can't tell why this is the only sample of this 'function' which it's not 'prototyped' in the documentation while you can find reference to the XIPCHAIN_ENTRY structure.


    Luca Calligaris lucaDOTcalligarisATeurotechDOTcom www.eurotech.com Check my blog: http://lcalligaris.wordpress.com

    • Marked as answer by iShust Tuesday, August 30, 2011 12:56 PM
    Tuesday, August 30, 2011 10:30 AM

All replies

  • It's related to multiple XIP  (see http://msdn.microsoft.com/en-us/library/aa450576.aspx and http://msdn.microsoft.com/en-us/library/ms836792.aspx) which is rarely if ever used in x86 systems, thus most of times the function returns since "Rom chain NOT found".

    (This happens because DWORD *pdwXIPLoc = NOT_FIXEDUP in %_WINCEROOT%\PLATFORM\COMMON\SRC\X86\COMMON\STARTUP\oeminit.c and, in case you should fix up the variable in config.bib, see http://msdn.microsoft.com/en-us/library/ee482877.aspx):

    MEMORY
      #define XIPLOC_PHYSICAL 802C0000;
      Location of the chain
      RESERVE $(XIPLOC_PHYSICAL) 00002000;
      CHAIN
      nk.exe:pdwXIPLoc 00000000 $(XIPLOC_PHYSICAL) FIXUPVAR
    CONFIG
      XIPSCHAIN= $(XIPLOC_PHYSICAL)
    

    I can't tell why this is the only sample of this 'function' which it's not 'prototyped' in the documentation while you can find reference to the XIPCHAIN_ENTRY structure.


    Luca Calligaris lucaDOTcalligarisATeurotechDOTcom www.eurotech.com Check my blog: http://lcalligaris.wordpress.com

    • Marked as answer by iShust Tuesday, August 30, 2011 12:56 PM
    Tuesday, August 30, 2011 10:30 AM
  • Thanks Luca,

    but have you ever faced with XIP implementation on x86 targets?

    Tuesday, August 30, 2011 12:36 PM
  • Persolnally no, I've never needed to use it: one scenario it may be useful is when the OS image is stored on the same flash as the BIOS (or even without BIOS at all) without any other storage

     


    Luca Calligaris lucaDOTcalligarisATeurotechDOTcom www.eurotech.com Check my blog: http://lcalligaris.wordpress.com
    Tuesday, August 30, 2011 12:52 PM
  • Hmm, I suppose that it's very rare case on x86...
    Tuesday, August 30, 2011 12:56 PM