主题 : android移植mini2440过程中碰到的问题 复制链接 | 浏览器收藏 | 打印
级别: 新手上路
UID: 10967
精华: 0
发帖: 27
金钱: 140 两
威望: 28 点
贡献值: 0 点
综合积分: 54 分
注册时间: 2009-11-23
最后登录: 2011-03-23
楼主  发表于: 2010-01-31 17:37

 android移植mini2440过程中碰到的问题

在google source下了linux-2.6.25-android-1.0_r1进行移植 按照网上搜到的教程来做,但是下到板子上面运行就有问题了,串口输出如下:
NOW, Booting Linux......
Uncompressing Linux.............................................................
............................................. done, booting the kernel.
Linux version 2.6.25 (root@localhost.localdomain) (gcc version 4.3.2 (Sourcery G
++ Lite 2008q3-72) ) #12 Mon Dec 21 02:31:56 CST 2009
CPU: ARM920T [41129200] revision 0 (ARMv4T), cr=c0007177
Machine: SMDK2410
ATAG_INITRD is deprecated; please update your bootloader.
Memory policy: ECC disabled, Data cache writeback
CPU S3C2440A (id 0x32440001)
S3C244X: core 405.000 MHz, memory 101.250 MHz, peripheral 50.625 MHz
S3C24XX Clocks, (c) 2004 Simtec Electronics
CLOCK: Slow mode (1.500 MHz), fast, MPLL on, UPLL on
CPU0: D VIVT write-back cache
CPU0: I cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets
CPU0: D cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 16256
Kernel command line: noinitrd root=/dev/mtdblock2 init=/linuxrc console=ttySAC0
irq: clearing subpending status 00000003
irq: clearing subpending status 00000002
PID hash table entries: 256 (order: 8, 1024 bytes)
timer tcon=00000000, tcnt a4ca, tcfg 00000200,00000000, usec 00001e57
Console: colour dummy device 80x30
console [ttySAC0] enabled
Unable to handle kernel NULL pointer dereference at virtual address 00000000
pgd = c0004000
[00000000] *pgd=00000000
Internal error: Oops: 5 [#1]
Modules linked in:
CPU: 0    Not tainted  (2.6.25 #12)
PC is at kmem_cache_alloc+0x20/0x80
LR is at init_rs_internal+0xfc/0x460
pc : [<c008d2a4>]    lr : [<c0153cc4>]    psr: 600000d3
sp : c031bec8  ip : c031bee8  fp : c031bee4
r10: 00000000  r9 : 41129200  r8 : 00000000
r7 : 000000d0  r6 : 00000000  r5 : 60000053  r4 : c032c8b8
r3 : 600000d3  r2 : c032c8d0  r1 : 000000d0  r0 : 00000000
Flags: nZCv  IRQs off  FIQs off  Mode SVC_32  ISA ARM  Segment kernel
Control: c000717f  Table: 30004000  DAC: 00000017
Process swapper (pid: 0, stack limit = 0xc031a268)
Stack: (0xc031bec8 to 0xc031c000)
bec0:                   c032c8b8 00000008 00000100 0000011d c031bf24 c031bee8
bee0: c0153cc4 c008d294 c031bf64 c031bef8 c002c5e4 c002c010 000005d2 c0360328
bf00: 00000000 c0024f2c c031dd60 30023198 41129200 30023130 c031bf3c c031bf28
bf20: c0154088 c0153bd8 00000001 00000010 c031bfb4 c031bf40 c001e318 c0154070
bf40: 00000010 00000000 c033b190 00000000 c033b168 41129200 c031bf94 c031bf68
bf60: c004aef0 c004a2cc c031bf94 c031bf78 c01846f4 c03309cc c033a108 c0330a50
bf80: c031dd60 30023198 c031bfb4 c031bf98 c0184898 c004ac6c c0023c14 c0024f30
bfa0: c0024f2c c031dd60 c031bfcc c031bfb8 c001a368 c001e2e0 c0339580 c0024f30
bfc0: c031bff4 c031bfd0 c0008bec c001a34c c00087cc 00000000 00000000 c0024f30
bfe0: c0007175 c0339f2c 00000000 c031bff8 30008034 c0008a58 00000000 00000000
Backtrace:
[<c008d284>] (kmem_cache_alloc+0x0/0x80) from [<c0153cc4>] (init_rs_internal+0xf
c/0x460)
r7:0000011d r6:00000100 r5:00000008 r4:c032c8b8
[<c0153bc8>] (init_rs_internal+0x0/0x460) from [<c0154088>] (init_rs+0x28/0x30)
[<c0154060>] (init_rs+0x0/0x30) from [<c001e318>] (ram_console_early_init+0x48/0
x2c8)
[<c001e2d0>] (ram_console_early_init+0x0/0x2c8) from [<c001a368>] (console_init+
0x2c/0x48)
r7:c031dd60 r6:c0024f2c r5:c0024f30 r4:c0023c14
[<c001a33c>] (console_init+0x0/0x48) from [<c0008bec>] (start_kernel+0x1a4/0x2b8
)
r5:c0024f30 r4:c0339580
[<c0008a48>] (start_kernel+0x0/0x2b8) from [<30008034>] (0x30008034)
r5:c0339f2c r4:c0007175
Code: e1a07001 e10f5000 e3853080 e121f003 (e590c000)
---[ end trace ca143223eefdc828 ]---
Kernel panic - not syncing: Attempted to kill the idle task!


看到这里Unable to handle kernel NULL pointer dereference at virtual address 00000000
start_kernel>console_init>ram_console_early_init>init_rs_internal>kmem_cache_alloc
pgd = c0004000
[00000000] *pgd=00000000
Internal error: Oops: 5 [#1]
调用了空指针,source insight查到mm的slub.c这个应该是底层操作,而且看了mini2440 android的kernel发现函数是一样的,
这个要怎么改呢?
而且去掉了
Device Drivers  ---> Character devices  ---> < > Goldfish TTY Driver
Device Drivers  ---> Power supply class support  ---> < >   Goldfish battery driver (NEW)
Device Drivers  ---> Real Time Clock  ---> < >   GOLDFISH (NEW)
Device Drivers  ---> Graphics support  ---> Support for frame buffer devices  ---> < >   Goldfish Framebuffer
编译下载到开发板碰到的结果是一样的。希望高手能解答一下,谢谢!
级别: 新手上路
UID: 10967
精华: 0
发帖: 27
金钱: 140 两
威望: 28 点
贡献值: 0 点
综合积分: 54 分
注册时间: 2009-11-23
最后登录: 2011-03-23
1楼  发表于: 2010-02-04 22:09
使用android_linux 2.6.29 patch补丁打到我移植好的kernel上面,修改以后可以挂载mini2440T35_android.img。
显示android启动,进去可以看到文件系统,但是提示如下后重启:
/ # <3>init: untracked pid 1636 exited
init: untracked pid 1636 exited
<3>init: untracked pid 1640 exited
init: untracked pid 1640 exited
<3>init: untracked pid 1638 exited
init: untracked pid 1638 exited
/ # <3>init: critical process 'servicemanager' exited 4 times in 4 minutes; rebo
oting into recovery mode
init: critical process 'servicemanager' exited 4 times in 4 minutes; rebooting i
nto recovery mode
<4>save exit: isCheckpointed 1
save exit: isCheckpointed 1
<0>Restarting system with command 'recovery'.
Restarting system with command 'recovery'.
arch_reset: attempting watchdog reset
arch_reset: at?

我去掉了make menuconfig s3c2410watchdog driver但是还是重启。这个和servicemanager有关?怎么解决呢?
级别: 新手上路
UID: 10967
精华: 0
发帖: 27
金钱: 140 两
威望: 28 点
贡献值: 0 点
综合积分: 54 分
注册时间: 2009-11-23
最后登录: 2011-03-23
2楼  发表于: 2010-02-05 10:32
解决了。在/fs的init.rc文件中将有关servicemanager的服务注销掉重新编译下载就可以了。
级别: 新手上路
UID: 19180
精华: 0
发帖: 2
金钱: 10 两
威望: 2 点
贡献值: 0 点
综合积分: 4 分
注册时间: 2010-04-17
最后登录: 2010-05-23
3楼  发表于: 2010-04-30 01:27

 回 楼主(chenbo35) 的帖子

请问Unable to handle kernel NULL pointer dereference at virtual address 00000000

这个问题是怎么解决的呢?