【发布时间】:2014-12-28 02:34:46
【问题描述】:
我有以下锁定。这是否表明 slic_test pid 5207 是违规者,还是仅表明因为内核中的当前宏仍指向使系统调用进入我的驱动程序的用户空间进程?此外 - irq event stamp 0 ... irq event stamp 究竟代表什么?不能是开机以来的中断次数……88798秒后肯定不止0次……
系统是单处理器,禁用了 CONFIG_SMP。
[88798.449628] BUG: soft lockup - CPU#0 stuck for 61s! [slic_test:5207]
[88798.449628] Modules linked in: slic_xxxx leds_xxxx vortex86_spi dm_mirror dm_log dm_multipath dm_mod ohci_hcd ehci_hcd r6040 vortex86_wdt vortex86_gpio [last un]
[88798.449628] irq event stamp: 0
[88798.449628] hardirqs last enabled at (0): [<00000000>] 0x0
[88798.449628] hardirqs last disabled at (0): [<c0115563>] copy_process+0x233/0x1090
[88798.449628] softirqs last enabled at (0): [<c0115563>] copy_process+0x233/0x1090
[88798.449628] softirqs last disabled at (0): [<00000000>] 0x0
[88798.449628]
[88798.449628] Pid: 5207, comm: slic_test Not tainted (2.6.27.62 #11)
[88798.449628] EIP: 0060:[<c011b6b5>] EFLAGS: 00000246 CPU: 0
[88798.449628] EIP is at __do_softirq+0x45/0xb0
[88798.449628] EAX: 00000000 EBX: 00000082 ECX: 00000001 EDX: dfac5080
[88798.449628] ESI: c0696120 EDI: 0000000a EBP: df3bdf8c ESP: df3bdf80
[88798.449628] DS: 007b ES: 007b FS: 0000 GS: 0033 SS: 0068
[88798.449628] CR0: 8005003b CR2: b7622780 CR3: 1f3c8000 CR4: 00000000
[88798.449628] DR0: 00000000 DR1: 00000000 DR2: 00000000 DR3: 00000000
[88798.449628] DR6: ffff0ff0 DR7: 00000400
[88798.449628] [<c011b766>] do_softirq+0x46/0x50
[88798.449628] [<c011bad5>] irq_exit+0x45/0x50
[88798.449628] [<c01057ba>] do_IRQ+0x4a/0x90
[88798.449628] [<c0103e68>] common_interrupt+0x28/0x30
[88798.449628] =======================
【问题讨论】:
-
当进程只执行内核上下文而不是用户上下文时会发生软锁定。软锁定是一个错误,它会导致内核在内核模式下循环一段不合理的时间,从而阻止其他进程运行。
标签: linux linux-kernel kernel driver linux-device-driver