TI中文支持网
TI专业的中文技术问题搜集分享网站

在LINUX的驱动层映射SHARE_RAM地址不成功,是什么原因啊?

其出现的错误提示如下:

kernel BUG at mm/vmalloc.c:1166!

Unable to handle kernel NULL pointer dereference at virtual address 00000000

pgd = c1f8c000

[00000000] *pgd=c1f90031, *pte=00000000, *ppte=00000000

Internal error: Oops: 817 [#1] PREEMPT

last sysfs file: /sys/devices/virtual/vc/vcsa1/dev

Modules linked in: dsplinkk

CPU: 0    Not tainted  (2.6.33-rc4 #164)

PC is at __bug+0x20/0x2c

LR is at release_console_sem+0x1f8/0x210

pc : [<c002e414>]    lr : [<c003f268>]    psr: 60000013

sp : c1f85c68  ip : c1f85ba8  fp : c1f85c74

r10: 000000d0  r9 : c1f84000  r8 : c2800000

r7 : 00000001  r6 : 00000001  r5 : 00000400  r4 : c1f85c78

r3 : 00000000  r2 : 00010001  r1 : 0001891a  r0 : 00000027

Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment user

Control: 0005317f  Table: c1f8c000  DAC: 00000015

Process uartgpp (pid: 672, stack limit = 0xc1f84270)

Stack: (0xc1f85c68 to 0xc1f86000)

5c60:                   c1f85ca4 c1f85c78 c00945dc c002e404 00000400 00000000

5c80: 00001000 00000400 00000000 00080000 c040ea20 00000000 c1f85cc4 c1f85ca8

5ca0: c00947ac c00945a0 fea00000 ffffffff 000000d0 c0031360 c1f85cec c1f85cc8

5cc0: c0031360 c0094770 00000000 80000000 00000000 00000400 00080000 00000000

5ce0: c1f85d14 c1f85cf0 c003152c c00312a8 c044d594 00000000 00000000 0000001e

5d00: 00000000 bf031d6c c1f85d24 c1f85d18 c003488c c00314a0 c1f85d3c c1f85d28

5d20: c01a42c0 c003487c c1ca4d80 00000000 c1f85d5c c1f85d40 c006db64 c01a4270

5d40: c04152c0 c1f84000 0000001e c1ca4d80 c1f85d7c c1f85d60 c006f9cc c006db30

5d60: 0000001e 00000000 40000000 00000001 c1f85d94 c1f85d80 c002a074 c006f888

5d80: ffffffff febfd000 c1f85e04 c1f85d98 c002ab2c c002a010 00008000 00000000

5da0: 00000000 ffffffff 0097e3df c2b40100 00000000 00000002 c28f9000 c1f84000

5dc0: bf031d6c c1f85e04 c1f85e08 c1f85de0 bf002dc0 bf003af0 60000013 ffffffff

5de0: c2b40000 00008000 00000000 bf031d6c 00000002 c1f84000 c1f85e3c c1f85e08

5e00: bf002dc0 bf0039f8 c3f5b000 beb05a4c c1f84000 40025000 00008000 00000000

5e20: bf031d50 c3f5b000 beb05a4c 40025000 c1f85e5c c1f85e40 bf002590 bf002ca0

5e40: 00008000 bf033698 00000000 c1dd1c00 c1f85e7c c1f85e60 bf01e150 bf002498

5e60: c018e013 c018e013 beb05a4c c1dd1c00 c1f85eec c1f85e80 bf020508 bf01e094

5e80: c1d57800 00000000 c1f85eb4 c1f85e98 c1f85ebc c1f85ea0 c0195120 c016ef14

5ea0: 00000025 c1f85ee0 c1eed000 00008000 00000000 4009edd0 00008cdc 00000000

5ec0: 00008c30 c1f85ed0 c018eff8 c1dd1c00 c018e013 beb05a4c c1dd1c00 beb05a4c

5ee0: c1f85f0c c1f85ef0 c00b0474 bf020218 00000004 c1dd1c00 00000004 c1dd1c00

5f00: c1f85f7c c1f85f10 c00b0b88 c00b0450 c018f0e4 00000002 00000000 c1806e80

5f20: c180c548 00000025 c1f84000 0002209b c1f85f6c c1f85f40 c00a2aa0 c00d1fd8

5f40: 00000000 00000000 630e0207 00000000 00000000 00000004 beb05a4c c018e013

5f60: c1dd1c00 c002b0a4 c1f84000 40025000 c1f85fa4 c1f85f80 c00b0c24 c00b0604

5f80: c1f84000 00000001 00000000 00000000 00008c30 00000036 00000000 c1f85fa8

5fa0: c002af20 c00b0bf4 00000000 00000000 00000004 c018e013 beb05a4c 00000004

5fc0: 00000000 00000000 00008c30 00000036 00000000 00000000 40025000 beb05a3c

5fe0: 00000000 beb05928 0000c6f8 401036dc 60000010 00000004 70736e61 4f74726f

Backtrace:

[<c002e3f4>] (__bug+0x0/0x2c) from [<c00945dc>] (__get_vm_area_node+0x4c/0x120)

[<c0094590>] (__get_vm_area_node+0x0/0x120) from [<c00947ac>] (get_vm_area+0x4c/0x5c)

[<c0094760>] (get_vm_area+0x0/0x5c) from [<c0031360>] (__arm_ioremap_pfn+0xc8/0x1f8)

[<c0031298>] (__arm_ioremap_pfn+0x0/0x1f8) from [<c003152c>] (__arm_ioremap+0x9c/0xb4)

[<c0031490>] (__arm_ioremap+0x0/0xb4) from [<c003488c>] (davinci_ioremap+0x20/0x24)

[<c003486c>] (davinci_ioremap+0x0/0x24) from [<c01a42c0>] (dsp_interrupt_arm+0x60/0xb4)

[<c01a4260>] (dsp_interrupt_arm+0x0/0xb4) from [<c006db64>] (handle_IRQ_event+0x44/0x114)

r5:00000000 r4:c1ca4d80

[<c006db20>] (handle_IRQ_event+0x0/0x114) from [<c006f9cc>] (handle_edge_irq+0x154/0x1c8)

r7:c1ca4d80 r6:0000001e r5:c1f84000 r4:c04152c0

[<c006f878>] (handle_edge_irq+0x0/0x1c8) from [<c002a074>] (asm_do_IRQ+0x74/0x94)

r7:00000001 r6:40000000 r5:00000000 r4:0000001e

[<c002a000>] (asm_do_IRQ+0x0/0x94) from [<c002ab2c>] (__irq_svc+0x4c/0x9c)

Exception stack(0xc1f85d98 to 0xc1f85de0)

5d80:                                                       00008000 00000000

5da0: 00000000 ffffffff 0097e3df c2b40100 00000000 00000002 c28f9000 c1f84000

5dc0: bf031d6c c1f85e04 c1f85e08 c1f85de0 bf002dc0 bf003af0 60000013 ffffffff

r5:febfd000 r4:ffffffff

[<bf0039e8>] (SHMDRV_handshake+0x0/0x164 [dsplinkk]) from [<bf002dc0>] (LDRV_DRV_handshake+0x130/0x36c [dsplinkk])

r9:c1f84000 r8:00000002 r7:bf031d6c r6:00000000 r5:00008000

r4:c2b40000

[<bf002c90>] (LDRV_DRV_handshake+0x0/0x36c [dsplinkk]) from [<bf002590>] (LDRV_PROC_start+0x108/0x1c4 [dsplinkk])

[<bf002488>] (LDRV_PROC_start+0x0/0x1c4 [dsplinkk]) from [<bf01e150>] (PMGR_PROC_start+0xcc/0x130 [dsplinkk])

r7:c1dd1c00 r6:00000000 r5:bf033698 r4:00008000

[<bf01e084>] (PMGR_PROC_start+0x0/0x130 [dsplinkk]) from [<bf020508>] (DRV_Ioctl+0x300/0x7f4 [dsplinkk])

r7:c1dd1c00 r6:beb05a4c r5:c018e013 r4:c018e013

[<bf020208>] (DRV_Ioctl+0x0/0x7f4 [dsplinkk]) from [<c00b0474>] (vfs_ioctl+0x34/0xb4)

r8:beb05a4c r7:c1dd1c00 r6:beb05a4c r5:c018e013 r4:c1dd1c00

[<c00b0440>] (vfs_ioctl+0x0/0xb4) from [<c00b0b88>] (do_vfs_ioctl+0x594/0x5f0)

r7:c1dd1c00 r6:00000004 r5:c1dd1c00 r4:00000004

[<c00b05f4>] (do_vfs_ioctl+0x0/0x5f0) from [<c00b0c24>] (sys_ioctl+0x40/0x64)

[<c00b0be4>] (sys_ioctl+0x0/0x64) from [<c002af20>] (ret_fast_syscall+0x0/0x28)

r7:00000036 r6:00008c30 r5:00000000 r4:00000000

Code: e1a01000 e59f000c eb0b9942 e3a03000 (e5833000)

—[ end trace 884b1dcf18f8763f ]—

Kernel panic – not syncing: Fatal exception in interrupt

Backtrace:

[<c002e730>] (dump_backtrace+0x0/0x114) from [<c03147dc>] (dump_stack+0x18/0x1c)

r7:c002e418 r6:c002e416 r5:00000001 r4:c0438518

[<c03147c4>] (dump_stack+0x0/0x1c) from [<c0314844>] (panic+0x64/0x13c)

[<c03147e0>] (panic+0x0/0x13c) from [<c002ead4>] (die+0x290/0x2cc)

r3:00010000 r2:c1f85ac8 r1:00000000 r0:c03a8ad1

[<c002e844>] (die+0x0/0x2cc) from [<c0030308>] (__do_kernel_fault+0x6c/0x7c)

[<c003029c>] (__do_kernel_fault+0x0/0x7c) from [<c00304e8>] (do_page_fault+0x1d0/0x1e8)

r7:c1dff180 r6:00000000 r5:c1c6b2c0 r4:c040e68c

[<c0030318>] (do_page_fault+0x0/0x1e8) from [<c002a2e0>] (do_DataAbort+0x3c/0x9c)

[<c002a2a4>] (do_DataAbort+0x0/0x9c) from [<c002aacc>] (__dabt_svc+0x4c/0x60)

Exception stack(0xc1f85c20 to 0xc1f85c68)

5c20: 00000027 0001891a 00010001 00000000 c1f85c78 00000400 00000001 00000001

5c40: c2800000 c1f84000 000000d0 c1f85c74 c1f85ba8 c1f85c68 c003f268 c002e414

5c60: 60000013 ffffffff

r8:c2800000 r7:00000001 r6:00000001 r5:c1f85c54 r4:ffffffff

[<c002e3f4>] (__bug+0x0/0x2c) from [<c00945dc>] (__get_vm_area_node+0x4c/0x120)

[<c0094590>] (__get_vm_area_node+0x0/0x120) from [<c00947ac>] (get_vm_area+0x4c/0x5c)

[<c0094760>] (get_vm_area+0x0/0x5c) from [<c0031360>] (__arm_ioremap_pfn+0xc8/0x1f8)

[<c0031298>] (__arm_ioremap_pfn+0x0/0x1f8) from [<c003152c>] (__arm_ioremap+0x9c/0xb4)

[<c0031490>] (__arm_ioremap+0x0/0xb4) from [<c003488c>] (davinci_ioremap+0x20/0x24)

[<c003486c>] (davinci_ioremap+0x0/0x24) from [<c01a42c0>] (dsp_interrupt_arm+0x60/0xb4)

[<c01a4260>] (dsp_interrupt_arm+0x0/0xb4) from [<c006db64>] (handle_IRQ_event+0x44/0x114)

r5:00000000 r4:c1ca4d80

[<c006db20>] (handle_IRQ_event+0x0/0x114) from [<c006f9cc>] (handle_edge_irq+0x154/0x1c8)

r7:c1ca4d80 r6:0000001e r5:c1f84000 r4:c04152c0

[<c006f878>] (handle_edge_irq+0x0/0x1c8) from [<c002a074>] (asm_do_IRQ+0x74/0x94)

r7:00000001 r6:40000000 r5:00000000 r4:0000001e

[<c002a000>] (asm_do_IRQ+0x0/0x94) from [<c002ab2c>] (__irq_svc+0x4c/0x9c)

Exception stack(0xc1f85d98 to 0xc1f85de0)

5d80:                                                       00008000 00000000

5da0: 00000000 ffffffff 0097e3df c2b40100 00000000 00000002 c28f9000 c1f84000

5dc0: bf031d6c c1f85e04 c1f85e08 c1f85de0 bf002dc0 bf003af0 60000013 ffffffff

r5:febfd000 r4:ffffffff

[<bf0039e8>] (SHMDRV_handshake+0x0/0x164 [dsplinkk]) from [<bf002dc0>] (LDRV_DRV_handshake+0x130/0x36c [dsplinkk])

r9:c1f84000 r8:00000002 r7:bf031d6c r6:00000000 r5:00008000

r4:c2b40000

[<bf002c90>] (LDRV_DRV_handshake+0x0/0x36c [dsplinkk]) from [<bf002590>] (LDRV_PROC_start+0x108/0x1c4 [dsplinkk])

[<bf002488>] (LDRV_PROC_start+0x0/0x1c4 [dsplinkk]) from [<bf01e150>] (PMGR_PROC_start+0xcc/0x130 [dsplinkk])

r7:c1dd1c00 r6:00000000 r5:bf033698 r4:00008000

[<bf01e084>] (PMGR_PROC_start+0x0/0x130 [dsplinkk]) from [<bf020508>] (DRV_Ioctl+0x300/0x7f4 [dsplinkk])

r7:c1dd1c00 r6:beb05a4c r5:c018e013 r4:c018e013

[<bf020208>] (DRV_Ioctl+0x0/0x7f4 [dsplinkk]) from [<c00b0474>] (vfs_ioctl+0x34/0xb4)

r8:beb05a4c r7:c1dd1c00 r6:beb05a4c r5:c018e013 r4:c1dd1c00

[<c00b0440>] (vfs_ioctl+0x0/0xb4) from [<c00b0b88>] (do_vfs_ioctl+0x594/0x5f0)

r7:c1dd1c00 r6:00000004 r5:c1dd1c00 r4:00000004

[<c00b05f4>] (do_vfs_ioctl+0x0/0x5f0) from [<c00b0c24>] (sys_ioctl+0x40/0x64)

[<c00b0be4>] (sys_ioctl+0x0/0x64) from [<c002af20>] (ret_fast_syscall+0x0/0x28)

r7:00000036 r6:00008c30 r5:00000000 r4:00000000

Denny%20Yang99373:

做什么操作时发现的这个错误?

请帖清楚操作流程,并说明在哪个板子上做的实验,DDR多大,uboot传的bootargs是什么?

Zhongshan Wang:

是我使用ioremap(0x80000000,size)时出现这个情况的。在是合众达的SEED-DIM138,DDR为512M,

setenv bootargs mem=32M console=ttyS1,115200n8 root=/dev/nfs nfsroot=192.168.1.100:/opt/workspace/SEED-DIM138/nfs/ rw ip=192.168.1.112:192.168.1.1:255.255.255.0

Denny%20Yang99373:

回复 Zhongshan Wang:

可以检查一下是不是超出128K范围了,把SIZE缩小试试

也可以先掉requset_region()试试

赞(0)
未经允许不得转载:TI中文支持网 » 在LINUX的驱动层映射SHARE_RAM地址不成功,是什么原因啊?
分享到: 更多 (0)