Introducing XDA:DevCon – A Conference For Developers By Developers
XDA Developers Android and Mobile Development Forum
Forgot your password?
 
Post Reply+
Tip us?
 
highfly22
Old
#1  
Junior Member - OP
Thanks Meter 0
Posts: 8
Join Date: Aug 2009
Default KEXEC works in the nook tablet

I managed to execute a customized kernel. But it hangs in somewhere.

The main trouble is l2 cache. The l2 cache may crash the kernel in the somewhere. I am inspired by hkvc. http://forum.xda-developers.com/show....php?t=1427610

Did you meet this problem?

Here is output from uart:

<code>
<5>Linux version 2.6.35.7-g63bc7cb-dirty (haiwei@haiwei-X201) (gcc version 4.4.1 (Sourcery G++ Lite 2010q1-202) ) #8 SMP PREEMPT Sat Jan 14 22:48:10 CST 2012
CPU: ARMv7 Processor [411fc093] revision 3 (ARMv7), cr=10c53c7f
CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache
Machine: OMAP4430 ACCLAIM
Memory policy: ECC disabled, Data cache writealloc
<7>On node 0 totalpages: 245760
<7>free_area_init_node: node 0, pgdat c058bec0, node_mem_map c0a6c000
<7> Normal zone: 1536 pages used for memmap
<7> Normal zone: 0 pages reserved
<7> Normal zone: 178688 pages, LIFO batch:31
<7> HighMem zone: 512 pages used for memmap
<7> HighMem zone: 65024 pages, LIFO batch:15
<6>***********************<6>OMAP4430 ES2.3 type(HS)
<6>id-code (6b95c02f)
<6>Die-id (22DC0006-00000001-09111ED0-06011014)
<6>Prod-id (000DB95C-000600CC)
<6>***********************<6>SRAM: Mapped pa 0x40300000 to va 0xfe400000 size: 0x100000
<3>FIXME: omap44xx_sram_init not implemented
<6>Reserving 33554432 bytes SDRAM for VRAM
<6>SMC: Allocated workspace of 3M at (0x9c900000)
<6>PERCPU: Embedded 7 pages/cpu @c1279000 s5632 r8192 d14848 u65536
<6>pcpu-alloc: s5632 r8192 d14848 u65536 alloc=16*4096
<6>pcpu-alloc: [0] 0 [0] 1
Built 1 zonelists in Zone order, mobility grouping on. Total pages: 243712
<5>Kernel command line: androidboot.console=ttyO0 console=ttyO0,115200n8 mem=448M@0x80000000 mem=512M@0xA0000000 init=/init rootwait vram=32M,82000000 omapf0
<6>PID hash table entries: 4096 (order: 2, 16384 bytes)
<6>Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
<6>Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
<6>Memory: 448MB 256MB 256MB = 960MB total
<5>Memory: 935228k/935228k available, 47812k reserved, 262144K highmem
<5>Virtual kernel memory layout:
vector : 0xffff0000 - 0xffff1000 ( 4 kB)
fixmap : 0xfff00000 - 0xfffe0000 ( 896 kB)
DMA : 0xffc00000 - 0xffe00000 ( 2 MB)
vmalloc : 0xf0800000 - 0xf8000000 ( 120 MB)
lowmem : 0xc0000000 - 0xf0000000 ( 768 MB)
pkmap : 0xbfe00000 - 0xc0000000 ( 2 MB)
modules : 0xbf000000 - 0xbfe00000 ( 14 MB)
.init : 0xc0008000 - 0xc003e000 ( 216 kB)
.text : 0xc003e000 - 0xc0543000 (5140 kB)
.data : 0xc0544000 - 0xc058c980 ( 291 kB)
<6>SLUB: Genslabs=11, HWalign=32, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
<6>Hierarchical RCU implementation.
<6> RCU-based detection of stalled CPUs is disabled.
<6> Verbose stalled-CPUs detection is disabled.
<6>NR_IRQS:388
<4>omap_hwmod: sys_32k_ck: missing clockdomain for sys_32k_ck.
<4>omap_hwmod: l3_div_ck: missing clockdomain for l3_div_ck.
<4>omap_hwmod: dpll_mpu_m2_ck: missing clockdomain for dpll_mpu_m2_ck.
<4>omap_hwmod: dmic: resetting
<4>omap_hwmod: dss: cannot be enabled (3)
<4>omap_hwmod: dss_dispc: cannot be enabled (3)
<4>omap_hwmod: dss_dsi1: cannot be enabled (3)
<4>omap_hwmod: dss_dsi2: cannot be enabled (3)
<4>omap_hwmod: dss_hdmi: cannot be enabled (3)
<4>omap_hwmod: dss_rfbi: cannot be enabled (3)
<4>omap_hwmod: dss_venc: cannot be enabled (3)
<4>omap_hwmod: iva: reset already de-asserted
<4>omap_hwmod: mailbox: resetting
<4>omap_hwmod: omap-mcpdm-dai: cannot be enabled (3)
<4>omap_hwmod: mcspi1: resetting
<4>omap_hwmod: mcspi2: resetting
<4>omap_hwmod: mcspi3: resetting
<4>omap_hwmod: mcspi4: resetting
<4>omap_hwmod: mmc1: resetting
<4>omap_hwmod: mmc2: resetting
<4>omap_hwmod: mmc3: resetting
<4>omap_hwmod: mmc4: resetting
<4>omap_hwmod: mmc5: resetting
<4>omap_hwmod: timer3: resetting
<4>omap_hwmod: timer4: resetting
<4>omap_hwmod: timer5: resetting
<4>omap_hwmod: timer6: resetting
<4>omap_hwmod: timer7: resetting
<4>omap_hwmod: timer8: resetting
<4>omap_hwmod: timer9: resetting
<4>omap_hwmod: timer11: resetting
</code>
Attached Files
File Type: zip kexec.zip - [Click for QR Code] (155.2 KB, 18 views)
 
hkvc
Old
(Last edited by hkvc; 24th January 2012 at 05:39 PM.)
#2  
Member
Thanks Meter 252
Posts: 83
Join Date: Jul 2011
Post you could try the l2 cache flush logic in my linboothkvc

Hi Highfly,

I haven't really looked at kexec directly, because I figured/or_rather_think(haven't had time to patiently go thro it, I am bit lazy and impatient wrt reading thro documents or others code and so, unless I have to) it has too many dependcies or a few kernel space things distributed here and there and few userspace stuff distributed here and there logically and so on and so forth. And also because I was more interested in exploring and facing the possible problems on my own so that I learn more about the new Arm cores and SOCs.

If you are facing any problem with L2 cache, then try the l2 cache flush stuff I have put in my source package and see if it helps. It is a much much simplified version of what is there in sleep file and the PL310 trm, because I don't really want to wakeup from a sleep, so I or for that matter, even you don't have to worry much about saving stuffs (i don't mean everything here, yes some stuffs you have to save from cache to memory like the code you want to run in the new environment etc) and other stuff. Also I take care of disabling the 2nd processor before I do the cache related stuff, so that way also I don't have to worry about syncing across them (There is a small corner case, there in my flow, but I haven't seen it triggered till now, and I have a simple way of bypassing it for now, so I am not worrying too much about the 2nd processor).

Or you could also try disabling the L2 cache specifically before exiting from existing kernel (which I am not doing by the way, rather I fully disable all cache thro cp15), based on what I have read, disabling L2 cache specifically is supposed to make it automatically do a safe flush i.e clean followed by invalidate in a automic manner.
 
Post Reply+
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Go to top of page...