Wednesday, August 25, 2010

Printascii failure

I added functional support for printascii after editing vprintk(), which will be described in a seperate posting. But doing so resulted in system printing debug messages until


OMAP3 beagleboard.org # bootm 0x80300000
## Booting kernel from Legacy Image at 80300000 ...
   Image Name:   Puppy Linux
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    1398532 Bytes =  1.3 MB
   Load Address: 80008000
   Entry Point:  80008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
<5>Linux version 2.6.35-rc3 (amar@amar-laptop) (gcc version 4.4.1 (Sourcery G++ Lite 2010q1-188) ) #6 PREEMPT Wed Aug 25 00:38:20 CEST 2010
CPU: ARMv7 Processor [411fc083] revision 3 (ARMv7), cr=10c53c7f
CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache
Machine: PuppyBeagle
Memory policy: ECC disabled, Data cache writeback
<7>On node 0 totalpages: 65536
<7>free_area_init_node: node 0, pgdat c02d4714, node_mem_map c02eb000
<7>  Normal zone: 512 pages used for memmap
<7>  Normal zone: 0 pages reserved
<7>  Normal zone: 65024 pages, LIFO batch:15

But after this, the system started crashing. Careful debugging revealed that system crashed inside
setup_arch( ) call. Further debugging revealed the following:

clean_pmd_entry clears 0xfd000000 (VA for UART3)

and then returns back from __phys_to_pfn call within clean_pmd_entry fn. (inline fn..no symbol found)
called from devicemaps_init() inside mmu.c

devicemaps_init( ) banner clearly states that:
"We clear out pg tables for all mappings above VMALLOC_END, we will remove any debug device mappings.
This means that you have to be careful how you debug this function, or any called function. This means that
you can't use any function or debugging method which may touch the device, otherwise the kernel *_will_ crash *!!!

Exact behavior as seen in my case!

Now I know......

Next step: Probably remove debug printascii support and find any other way of retrieving the prints.....

No comments:

Post a Comment