Yannick
Thu Oct 07 01:16:51 CDT 2004
Do you see the debug msg in any of the configuration (eboot or kernel)? If
no, you should focus on having it working in eboot, before trying to debug
the kernel starting code.
--
----------------------------------------------------------------
Yannick Chamming's (eMVP)
ADESET
Windows Embedded Manager
ychammings AT adeset DOT com>
http://www.adeset.com
Tél : +33 (0)4.72.18.57.77
Fax : +33 (0)4.72.18.57.78
----------------------------------------------------------------
"Sujith" <sujithss@hotmail.com> wrote in message
news:ep6799pqEHA.3760@TK2MSFTNGP09.phx.gbl...
> Thanks Yannick,
> but the MMU initialization is being done in the KernelStart only. I am not
> doing the initialization of the MMU in the startupcode at all..
> it is like this,
> 1. Put the processor in Supervisor mode,
> 2. disable MMU
> 3. flush TLB
> 4. Flush Instruction and Data Cache
> 5.Drain the write and fill buffers
> 6. Initialize PLL (Clock)
> 7. Initialize SDRAM
> 8.Initialize SP in IRAM
> now some debug prints followed by jump to either KernelStart or SBootMain
> according to the option..like
> mov sp, #0x4000 ; setting the stack pointer
> mov r5, #0x30000 ; UART Initialization have to be removed later
> add r5, r5, #0x300
> mov r0, #0x0D
> strh r0, [r5, #2]
> ;flush Transmit FIFO
> mov r0, #0x8000
> strh r0, [r5, #8]
> ;write into DTR
> mov r0, #0x65
> strb r0, [r5, #0x00]
> mov r0, #0x65
> strb r0, [r5, #0x00] ; END of transmit data.
>
> IF SBOOT
> bl SBootMain
> ELSE
> ; (r0) = physical address of OEMMemoryMap
> adr r0, OEMAddressTable
>
> bl KernelStart
> ENDIF
> I gave only a wrap up in the .s file for bootloader....
> anything more do i need to do?
> regards
> Sujith
>
> "Yannick Chamming's [eMVP]" <ychammings_nospam@adeset.com> wrote in
message
> news:OHZ5P0pqEHA.3396@tk2msftngp13.phx.gbl...
> > If you are using the same startup code between bootloader & kernel, you
> > might have some memory access issues, as your bootloader might work with
> > physical mem (no MMU) which is not the case of the kernel.
> >
> > You should check your memory accesses
> >
> > --
> > ----------------------------------------------------------------
> > Yannick Chamming's (eMVP)
> > ADESET
> > Windows Embedded Manager
> > ychammings AT adeset DOT com>
> >
http://www.adeset.com
> > Tél : +33 (0)4.72.18.57.77
> > Fax : +33 (0)4.72.18.57.78
> > ----------------------------------------------------------------
> >
> > "Sujith" <sujithss@hotmail.com> wrote in message
> > news:#CuSG2dqEHA.3800@TK2MSFTNGP14.phx.gbl...
> > > Thanks Yannick,
> > > still I am unable to get any debug prints.
> > > I am using a custom .s file instead of the given fw_arm.s, which is
> > > startup.s and I am using the same with bootloader also.
> > > is that is the problem?
> > > regards
> > > Sujith
> > >
> > > "Yannick Chamming's [eMVP]" <ychammings_nospam@adeset.com> wrote in
> > message
> > > news:OWh$CddqEHA.896@TK2MSFTNGP12.phx.gbl...
> > > > NK base should be 88090000 and not 88900000
> > > > RAM should start at 88A70000 (88090000+009E0000) and have a size of
> > > > 3590000, which make it go till 8C000000 (88000000 + 64MB)
> > > >
> > > > with your config, you are not using RAM from 88090000 (end of EDBG)
to
> > > > 88900000 (start of NK)
> > > > And furthermore, RAM goes after the end of your SDRAM area
> > > (892E0000+3400000
> > > > = 8C6E0000 whic is over 8C000000 !)
> > > >
> > > > BR
> > > > Yannick
> > > >
> > > >
> > > > --
> > > > ----------------------------------------------------------------
> > > > Yannick Chamming's (eMVP)
> > > > ADESET
> > > > Windows Embedded Manager
> > > > ychammings AT adeset DOT com>
> > > >
http://www.adeset.com
> > > > Tél : +33 (0)4.72.18.57.77
> > > > Fax : +33 (0)4.72.18.57.78
> > > > ----------------------------------------------------------------
> > > >
> > > > "Sujith" <sujithss@hotmail.com> wrote in message
> > > > news:##s7hCqpEHA.324@TK2MSFTNGP11.phx.gbl...
> > > > > Thanks Steve and Yannick.
> > > > > but i configured the config.bib and OEMAddressTable according to
the
> > > > points
> > > > > which the community people gave me..
> > > > > well, i am including the config.bib and OEMAddressTable here.
please
> > > > > advise..
> > > > > I have 64MB SDRAM (external) (900000 - 94MB). and 8MB Flash
> (external)
> > > > > (programmable to 16MB, currently using only defaults)(100000 to
> > 900000)
> > > > > MEMORY
> > > > > NK 88900000 009E0000 RAMIMAGE
> > > > > RAM 892E0000 03400000 RAM
> > > > > ; ** Reserved section **
> > > > > DRV_GLB 88008000 00001000 RESERVED ; Boot Args
> > > > > BLDR 88010000 00040000 RESERVED ; Bldr + Bldr
RAM
> > > > > EDBG 88050000 00040000 RESERVED ; EthDbg
Buffers
> > > > > CONFIG
> > > > > IF IMGFLASH !
> > > > > AUTOSIZE=ON
> > > > > ENDIF
> > > > > COMPRESSION=OFF
> > > > > KERNELFIXUPS=ON
> > > > > ROMSTART=88900000
> > > > > ROMWIDTH=32
> > > > > ROMSIZE=300000
> > > > > IF IMGFLASH !
> > > > > ; This causes the BIN file sections to be placed at the correct
RAM
> > > > > ; address (starting at 0x0090.0000) before the MMU is turned on.
> > After
> > > > > ; the MMU is enabled, the OEMAddressTable defines the mapping
> > > > > ; (0x8890.0000).
> > > > > ROMOFFSET=78000000
> > > > > ENDIF
> > > > > IF IMGFLASH
> > > > > ; This causes the BIN file sections to be placed at the correct
> FLASH
> > > > > ; address (starting at 0x0010.0000) before the MMU is turned on.
> > After
> > > > > ; the MMU is enabled, the OEMAddressTable defines the mapping
> > > > > ; (0x8000.0000).
> > > > > ROMOFFSET=77800000
> > > > > ENDIF
> > > > >
> > > > > And here is my OEMAddressTable
> > > > >
> > > > > ; System Flash
> > > > > VA_FLASH_BASE EQU 0x80000000 ; Flash, 8Mb
> > > > >
> > > > > ; Allow space for the RAM to grow up 128Mb. NOTE, however, that we
> > > > > ; can only declare RAM for the minimum amount of memory possible
in
> > > > > ; a system, 'cause the kernel uses the very top of RAM for its own
> > > > > ; structures
> > > > >
> > > > > VA_RAM_BASE EQU 0x88000000
> > > > > VA_CF_BASE EQU 0x91000000
> > > > > VA_USB_BASE EQU 0x92000000
> > > > >
> > > > > VA_PERIPHERAL_COMMON EQU 0x96000000
> > > > > VA_CT_BASE EQU (VA_PERIPHERAL_COMMON + 0x30000) ;Timer
> > > > > VA_IC_BASE EQU (VA_PERIPHERAL_COMMON + 0x30500) ;
> > Interrupt
> > > > > Control, 1Mb
> > > > > VA_UART0_BASE EQU (VA_PERIPHERAL_COMMON + 0x30300) ; UART0
Base
> > > > > VA_UART1_BASE EQU (VA_PERIPHERAL_COMMON + 0x30380) ; UART1
Base
> > > > > VA_DBG_BASE EQU (VA_PERIPHERAL_COMMON + 0x30580) ; debug
> base
> > > > >
> > > > > EXPORT OEMAddressTable[DATA]
> > > > > OEMAddressTable
> > > > >
;;;-------------------------------------------------------------
> > > > > ;;; Virt Addr Phys Addr MB
> > > > >
;;;-------------------------------------------------------------
> > > > > DCD VA_RAM_BASE, 0x00900000,
64
> ;
> > 64
> > > > MB
> > > > > SDRAM
> > > > > DCD VA_FLASH_BASE, 0x00100000, 8
;
> 8
> > > MB
> > > > > Flash
> > > > > DCD VA_CF_BASE, 0x40000000,
> 16
> > ;
> > > > 16
> > > > > MB Compact Flash
> > > > > DCD VA_USB_BASE, 0x80000000,
> 64
> > ;
> > > 64
> > > > > MB USB
> > > > > DCD VA_PERIPHERAL_COMMON, 0x00000000, 1 ; 1MB
common
> > > Space
> > > > > for all peripherals maps to memory includes SRAM Also
> > > > > DCD 0, 0, 0 ; end of table must be zero
> > > > > END
> > > > >
> > > > > Also in the board.h i am using only Uncached area only.
> > > > > #define VA_PERIPHERAL_COMMON_C 0x96000000 // Cached peripherals
> > > > > #define VA_PERIPHERAL_COMMON_U 0xB6000000 // But use only
Uncached
> > area
> > > > to
> > > > > talk to the Peripherals.
> > > > > #define VA_CT_BASE (VA_PERIPHERAL_COMMON_U + 0x30000)
> > > > > #define VA_IC_BASE (VA_PERIPHERAL_COMMON_U +
0x30500)
> > > > > #define VA_UART0_BASE (VA_PERIPHERAL_COMMON_U + 0x30300)
> > > > > #define VA_UART1_BASE (VA_PERIPHERAL_COMMON_U + 0x30380)
> > > > > #define VA_DBG_BASE (VA_PERIPHERAL_COMMON_U + 0x30580)
> //GIO
> > > > BASE
> > > > > #define VA_RAM_BASE 0x88000000 ; since this
> value
> > i
> > > > > gave 88900000 for NK in the config.bib
> > > > > #define VA_FLASH_BASE 0x80000000
> > > > >
> > > > > Regards
> > > > > Sujith
> > > > >
> > > > >
> > > > > "Steve Maillet (eMVP)" <nospam1@EntelechyConsulting.com> wrote in
> > > message
> > > > > news:OOs7nPipEHA.2988@TK2MSFTNGP15.phx.gbl...
> > > > > > Nope, probably something wrong in CONFIG.BIB or OEMAddressTable
> > > > > >
> > > > > > --
> > > > > > Steve Maillet
> > > > > > EmbeddedFusion
> > > > > > www.EmbeddedFusion.com
> > > > > >
> > > > > > Do have an opinion on the effectiveness of Microsoft Windows
> Mobile
> > > and
> > > > > > Embedded newsgroups? Let us know!
> > > > > > https://www.windowsembeddedeval.com/community/newsgroups
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>