WARNING: CPU: 0 PID: 61 at kernel/sched/core.c:7312 __might_sleep()
by Fengguang Wu
Greetings,
0day kernel testing robot got the below dmesg and the first bad commit is
git://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git sched/wait
commit 245747099820df3007f60128b1264fef9d2a69d2
Author: Peter Zijlstra <peterz(a)infradead.org>
AuthorDate: Wed Sep 24 10:18:55 2014 +0200
Commit: Peter Zijlstra <peterz(a)infradead.org>
CommitDate: Mon Oct 27 10:42:51 2014 +0100
sched: Debug nested sleeps
Validate we call might_sleep() with TASK_RUNNING, which catches places
where we nest blocking primitives, eg. mutex usage in a wait loop.
Since all blocking is arranged through task_struct::state, nesting
this will cause the inner primitive to set TASK_RUNNING and the outer
will thus not block.
Another observed problem is calling a blocking function from
schedule()->sched_submit_work()->blk_schedule_flush_plug() which will
then destroy the task state for the actual __schedule() call that
comes after it.
Cc: torvalds(a)linux-foundation.org
Cc: tglx(a)linutronix.de
Cc: ilya.dryomov(a)inktank.com
Cc: umgwanakikbuti(a)gmail.com
Cc: mingo(a)kernel.org
Cc: oleg(a)redhat.com
Signed-off-by: Peter Zijlstra (Intel) <peterz(a)infradead.org>
Link: http://lkml.kernel.org/r/20140924082242.5[email protected]
===================================================
PARENT COMMIT NOT CLEAN. LOOK OUT FOR WRONG BISECT!
===================================================
120 /kernel/i386-randconfig-r2-1027/592ed717ef33150f6888c333c28021283cc9aabc
To bisect errors in parent:
/c/kernel-tests/queue-reproduce /kernel/i386-randconfig-r2-1027/592ed717ef33150f6888c333c28021283cc9aabc/dmesg-quantal-kbuild-20:20141027231410:i386-randconfig-r2-1027:3.18.0-rc2-00036-g592ed71:139 BUG: kernel test crashed
Attached dmesg for the parent commit, too, to help confirm whether it is a noise error.
+---------------------------------------------------+------------+------------+------------+
| | 592ed717ef | 2457470998 | 2d55520314 |
+---------------------------------------------------+------------+------------+------------+
| boot_successes | 1080 | 267 | 110 |
| boot_failures | 120 | 33 | 21 |
| BUG:kernel_test_crashed | 110 | 30 | 16 |
| WARNING:at_kernel/locking/lockdep.c:check_flags() | 10 | 0 | 3 |
| backtrace:might_fault | 2 | | |
| backtrace:SyS_perf_event_open | 3 | 0 | 1 |
| backtrace:mutex_lock_nested | 1 | | |
| WARNING:at_kernel/sched/core.c:__might_sleep() | 0 | 3 | 2 |
| backtrace:cleanup_net | 0 | 3 | 2 |
| backtrace:register_perf_hw_breakpoint | 0 | 0 | 1 |
| backtrace:hw_breakpoint_event_init | 0 | 0 | 1 |
| backtrace:perf_init_event | 0 | 0 | 1 |
| backtrace:perf_event_alloc | 0 | 0 | 1 |
+---------------------------------------------------+------------+------------+------------+
[ 122.133640] Fix your initscripts?
[ 122.133905] trinity-c0 (23733) uses deprecated remap_file_pages() syscall. See Documentation/vm/remap_file_pages.txt.
[ 122.247299] ------------[ cut here ]------------
[ 122.247328] WARNING: CPU: 0 PID: 61 at kernel/sched/core.c:7312 __might_sleep+0x50/0x249()
[ 122.247334] do not call blocking ops when !TASK_RUNNING; state=2 set at [<c106ffd9>] prepare_to_wait+0x3c/0x5f
[ 122.247339] Modules linked in:
[ 122.247349] CPU: 0 PID: 61 Comm: kworker/u2:1 Not tainted 3.18.0-rc2-00037-g24574709 #136
[ 122.247350] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011
[ 122.247368] Workqueue: netns cleanup_net
[ 122.247377] c1071d83 d2b83dd8 d2b83dac c15887b1 d2b83dc8 c104c4c6 00001c90 c1068ebf
[ 122.247383] 00000000 c17b67e3 0000026d d2b83de0 c104c508 00000009 d2b83dd8 c17b5d4b
[ 122.247388] d2b83df4 d2b83e0c c1068ebf c17b5cec 00001c90 c17b5d4b 00000002 c106ffd9
[ 122.247389] Call Trace:
[ 122.247393] [<c1071d83>] ? down_trylock+0x23/0x2c
[ 122.247402] [<c15887b1>] dump_stack+0x16/0x18
[ 122.247413] [<c104c4c6>] warn_slowpath_common+0x66/0x7d
[ 122.247416] [<c1068ebf>] ? __might_sleep+0x50/0x249
[ 122.247419] [<c104c508>] warn_slowpath_fmt+0x2b/0x2f
[ 122.247422] [<c1068ebf>] __might_sleep+0x50/0x249
[ 122.247424] [<c106ffd9>] ? prepare_to_wait+0x3c/0x5f
[ 122.247426] [<c106ffd9>] ? prepare_to_wait+0x3c/0x5f
[ 122.247432] [<c158c364>] mutex_lock_nested+0x23/0x347
[ 122.247436] [<c1075105>] ? trace_hardirqs_on+0xb/0xd
[ 122.247439] [<c158eb0c>] ? _raw_spin_unlock_irqrestore+0x66/0x78
[ 122.247445] [<c1570e10>] rtnl_lock+0x14/0x16
[ 122.247449] [<c156516b>] default_device_exit_batch+0x54/0xf3
[ 122.247452] [<c1570e1f>] ? rtnl_unlock+0xd/0xf
[ 122.247454] [<c1070233>] ? __wake_up_sync+0x12/0x12
[ 122.247461] [<c155e35d>] ops_exit_list+0x20/0x40
[ 122.247464] [<c155ec96>] cleanup_net+0xbe/0x140
[ 122.247473] [<c105ffe4>] process_one_work+0x29e/0x643
[ 122.247479] [<c1061215>] worker_thread+0x23a/0x311
[ 122.247482] [<c1060fdb>] ? rescuer_thread+0x204/0x204
[ 122.247486] [<c10648cc>] kthread+0xbe/0xc3
[ 122.247490] [<c158f4c0>] ret_from_kernel_thread+0x20/0x30
[ 122.247492] [<c106480e>] ? kthread_stop+0x364/0x364
[ 122.247495] ---[ end trace 2073c37ae3c8b3b4 ]---
[ 157.390879] Unregister pv shared memory for cpu 0
git bisect start 2d55520314eb5603b855ac1b994705dc6a352d9e 522e980064c24d3dd9859e9375e17417496567cf --
git bisect good c3f9b6ec744e12ff09677c4c0cb3164ad5b62702 # 19:25 300+ 36 Merge branch 'sched/core'
git bisect good 344c57c17c7f857f9c92317e0d5cbb5c59f8d6e0 # 19:49 300+ 62 Merge branch 'perf/urgent'
git bisect good 54de76b06a8098c11f15857a57e23c6e630a34b6 # 20:19 300+ 66 Merge branch 'perf/core'
git bisect good 126b6dbcbedb5c0defe5c39e0310feed061569bf # 20:51 300+ 50 exit: Deal with nested sleeps
git bisect good 8641f9cba8ce5f3bfc5da47861180617cbfc6e7f # 22:02 300+ 68 module: Fix nested sleep
git bisect bad 245747099820df3007f60128b1264fef9d2a69d2 # 22:25 142- 18 sched: Debug nested sleeps
git bisect good 592ed717ef33150f6888c333c28021283cc9aabc # 22:59 300+ 27 net: Clean up sk_wait_event() vs might_sleep()
# first bad commit: [245747099820df3007f60128b1264fef9d2a69d2] sched: Debug nested sleeps
git bisect good 592ed717ef33150f6888c333c28021283cc9aabc # 00:15 900+ 120 net: Clean up sk_wait_event() vs might_sleep()
git bisect bad 2d55520314eb5603b855ac1b994705dc6a352d9e # 00:19 0- 21 Merge branch 'sched/wait'
git bisect good cac7f2429872d3733dc3f9915857b1691da2eb2f # 01:33 900+ 66 Linux 3.18-rc2
git bisect good 7a891e6323e963f3301e44bdeee734028e34d390 # 02:26 900+ 93 Add linux-next specific files for 20141027
This script may reproduce the error.
----------------------------------------------------------------------------
#!/bin/bash
kernel=$1
initrd=yocto-minimal-i386.cgz
wget --no-clobber https://github.com/fengguang/reproduce-kernel-bug/raw/master/initrd/$initrd
kvm=(
qemu-system-x86_64
-cpu kvm64
-enable-kvm
-kernel $kernel
-initrd $initrd
-m 320
-smp 1
-net nic,vlan=1,model=e1000
-net user,vlan=1
-boot order=nc
-no-reboot
-watchdog i6300esb
-rtc base=localtime
-serial stdio
-display none
-monitor null
)
append=(
hung_task_panic=1
earlyprintk=ttyS0,115200
debug
apic=debug
sysrq_always_enabled
rcupdate.rcu_cpu_stall_timeout=100
panic=-1
softlockup_panic=1
nmi_watchdog=panic
oops=panic
load_ramdisk=2
prompt_ramdisk=0
console=ttyS0,115200
console=tty0
vga=normal
root=/dev/ram0
rw
drbd.minor_count=8
)
"${kvm[@]}" --append "${append[*]}"
----------------------------------------------------------------------------
Thanks,
Fengguang
_______________________________________________
LKP mailing list
LKP(a)linux.intel.com
7 years, 4 months
[mm] BUG: unable to handle kernel paging request at c2446ffc
by Fengguang Wu
Greetings,
0day kernel testing robot got the below dmesg and the first bad commit is
git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
commit 1e491e9be4c97229a3a88763aada9582e37c7eaf
Author: Joonsoo Kim <iamjoonsoo.kim(a)lge.com>
AuthorDate: Thu Nov 27 11:09:34 2014 +1100
Commit: Stephen Rothwell <sfr(a)canb.auug.org.au>
CommitDate: Thu Nov 27 11:09:34 2014 +1100
mm/debug-pagealloc: prepare boottime configurable on/off
Until now, debug-pagealloc needs extra flags in struct page, so we need to
recompile whole source code when we decide to use it. This is really
painful, because it takes some time to recompile and sometimes rebuild is
not possible due to third party module depending on struct page. So, we
can't use this good feature in many cases.
Now, we have the page extension feature that allows us to insert extra
flags to outside of struct page. This gets rid of third party module
issue mentioned above. And, this allows us to determine if we need extra
memory for this page extension in boottime. With these property, we can
avoid using debug-pagealloc in boottime with low computational overhead in
the kernel built with CONFIG_DEBUG_PAGEALLOC. This will help our
development process greatly.
This patch is the preparation step to achive above goal. debug-pagealloc
originally uses extra field of struct page, but, after this patch, it will
use field of struct page_ext. Because memory for page_ext is allocated
later than initialization of page allocator in CONFIG_SPARSEMEM, we should
disable debug-pagealloc feature temporarily until initialization of
page_ext. This patch implements this.
Signed-off-by: Joonsoo Kim <iamjoonsoo.kim(a)lge.com>
Cc: Mel Gorman <mgorman(a)suse.de>
Cc: Johannes Weiner <hannes(a)cmpxchg.org>
Cc: Minchan Kim <minchan(a)kernel.org>
Cc: Dave Hansen <dave(a)sr71.net>
Cc: Michal Nazarewicz <mina86(a)mina86.com>
Cc: Jungsoo Son <jungsoo.son(a)lge.com>
Cc: Ingo Molnar <mingo(a)redhat.com>
Cc: Joonsoo Kim <iamjoonsoo.kim(a)lge.com>
Signed-off-by: Andrew Morton <akpm(a)linux-foundation.org>
Attached dmesg for the parent commit, too, to help confirm whether it is a noise error.
+-------------------------------------------------+------------+------------+---------------+
| | 34bf7903e1 | 1e491e9be4 | next-20141127 |
+-------------------------------------------------+------------+------------+---------------+
| boot_successes | 95 | 26 | 11 |
| boot_failures | 10 | 9 | 3 |
| BUG:kernel_early_hang_without_any_printk_output | 10 | 8 | |
| BUG:unable_to_handle_kernel | 0 | 1 | 3 |
| Oops | 0 | 1 | 3 |
| EIP_is_at__free_pages_ok | 0 | 1 | 3 |
| Kernel_panic-not_syncing:Fatal_exception | 0 | 1 | 3 |
| backtrace:put_tty_driver | 0 | 1 | 3 |
| backtrace:rp_init | 0 | 1 | 3 |
| backtrace:kernel_init_freeable | 0 | 1 | 3 |
+-------------------------------------------------+------------+------------+---------------+
[ 13.206984] RocketPort device driver module, version 2.09, 12-June-2003
[ 13.208641] No rocketport ports found; unloading driver
[ 13.208641] No rocketport ports found; unloading driver
[ 13.213422] BUG: unable to handle kernel
[ 13.213422] BUG: unable to handle kernel paging requestpaging request at c2446ffc
at c2446ffc
[ 13.214380] IP:
[ 13.214380] IP: [<b11ab6fe>] __free_pages_ok+0x376/0x62c
[<b11ab6fe>] __free_pages_ok+0x376/0x62c
[ 13.214380] *pde = 123ca067
[ 13.214380] *pde = 123ca067 *pte = 12446060 *pte = 12446060
[ 13.214380] Oops: 0000 [#1]
[ 13.214380] Oops: 0000 [#1] SMP SMP DEBUG_PAGEALLOCDEBUG_PAGEALLOC
[ 13.214380] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.18.0-rc6-00201-g1e491e9 #14
[ 13.214380] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.18.0-rc6-00201-g1e491e9 #14
[ 13.214380] task: c1c40000 ti: c1c48000 task.ti: c1c48000
[ 13.214380] task: c1c40000 ti: c1c48000 task.ti: c1c48000
[ 13.214380] EIP: 0060:[<b11ab6fe>] EFLAGS: 00010097 CPU: 0
[ 13.214380] EIP: 0060:[<b11ab6fe>] EFLAGS: 00010097 CPU: 0
[ 13.214380] EIP is at __free_pages_ok+0x376/0x62c
[ 13.214380] EIP is at __free_pages_ok+0x376/0x62c
[ 13.214380] EAX: c2446ffc EBX: c2513200 ECX: 00000004 EDX: c2447000
[ 13.214380] EAX: c2446ffc EBX: c2513200 ECX: 00000004 EDX: c2447000
[ 13.214380] ESI: c2513300 EDI: 00000004 EBP: c1c49e94 ESP: c1c49e64
[ 13.214380] ESI: c2513300 EDI: 00000004 EBP: c1c49e94 ESP: c1c49e64
[ 13.214380] DS: 007b ES: 007b FS: 00d8 GS: 0000 SS: 0068
[ 13.214380] DS: 007b ES: 007b FS: 00d8 GS: 0000 SS: 0068
[ 13.214380] CR0: 8005003b CR2: c2446ffc CR3: 02729000 CR4: 00000690
[ 13.214380] CR0: 8005003b CR2: c2446ffc CR3: 02729000 CR4: 00000690
[ 13.214380] Stack:
[ 13.214380] Stack:
[ 13.214380] 00000008
[ 13.214380] 00000008 b26054ec b26054ec b2605440 b2605440 00000246 00000246 00000010 00000010 00000000 00000000 c2513000 c2513000 00000000 00000000
[ 13.214380] 00000003
[ 13.214380] 00000003 00000000 00000000 c2513300 c2513300 00000000 00000000 c1c49e9c c1c49e9c b11aba32 b11aba32 c1c49ea4 c1c49ea4 b11abc52 b11abc52
[ 13.214380] c1c49ec4
[ 13.214380] c1c49ec4 b1204fb5 b1204fb5 c1c49ebc c1c49ebc b10deca7 b10deca7 b0018000 b0018000 bbf20984 bbf20984 00000100 00000100 bbf20980 bbf20980
[ 13.214380] Call Trace:
[ 13.214380] Call Trace:
[ 13.214380] [<b11aba32>] __free_pages+0x7e/0x8e
[ 13.214380] [<b11aba32>] __free_pages+0x7e/0x8e
[ 13.214380] [<b11abc52>] __free_kmem_pages+0x16/0x26
[ 13.214380] [<b11abc52>] __free_kmem_pages+0x16/0x26
[ 13.214380] [<b1204fb5>] kfree+0x292/0x4e1
[ 13.214380] [<b1204fb5>] kfree+0x292/0x4e1
[ 13.214380] [<b10deca7>] ? debug_mutex_unlock+0x2f3/0x398
[ 13.214380] [<b10deca7>] ? debug_mutex_unlock+0x2f3/0x398
[ 13.214380] [<b14f5c36>] destruct_tty_driver+0xee/0x158
[ 13.214380] [<b14f5c36>] destruct_tty_driver+0xee/0x158
[ 13.214380] [<b14f5fe5>] tty_driver_kref_put+0xb4/0xc6
[ 13.214380] [<b14f5fe5>] tty_driver_kref_put+0xb4/0xc6
[ 13.214380] [<b14f6121>] put_tty_driver+0x16/0x26
[ 13.214380] [<b14f6121>] put_tty_driver+0x16/0x26
[ 13.214380] [<b26aa177>] rp_init+0xc04/0xc23
[ 13.214380] [<b26aa177>] rp_init+0xc04/0xc23
[ 13.214380] [<b12050e9>] ? kfree+0x3c6/0x4e1
[ 13.214380] [<b12050e9>] ? kfree+0x3c6/0x4e1
[ 13.214380] [<b26a9573>] ? register_PCI+0x1091/0x1091
[ 13.214380] [<b26a9573>] ? register_PCI+0x1091/0x1091
[ 13.214380] [<b26469d2>] do_one_initcall+0x1ed/0x356
[ 13.214380] [<b26469d2>] do_one_initcall+0x1ed/0x356
[ 13.214380] [<b2646d8b>] kernel_init_freeable+0x250/0x3ab
[ 13.214380] [<b2646d8b>] kernel_init_freeable+0x250/0x3ab
[ 13.214380] [<b1d95dd0>] kernel_init+0x16/0x1e7
[ 13.214380] [<b1d95dd0>] kernel_init+0x16/0x1e7
[ 13.214380] [<b1dcdd01>] ret_from_kernel_thread+0x21/0x30
[ 13.214380] [<b1dcdd01>] ret_from_kernel_thread+0x21/0x30
[ 13.214380] [<b1d95dba>] ? rest_init+0x15b/0x15b
[ 13.214380] [<b1d95dba>] ? rest_init+0x15b/0x15b
[ 13.214380] Code:
[ 13.214380] Code: 31 31 d0 d0 29 29 d0 d0 c1 c1 e0 e0 05 05 80 80 3d 3d 00 00 30 30 64 64 b2 b2 00 00 8d 8d 14 14 03 03 74 74 71 71 83 83 05 05 28 28 90 90 da da b2 b2 01 01 89 89 d0 d0 89 89 55 55 e8 e8 83 83 15 15 2c 2c 90 90 da da b2 b2 00 00 e8 e8 67 67 d9 d9 05 05 00 00 <8b> <8b> 00 00 83 83 05 05 30 30 90 90 da da b2 b2 01 01 83 83 15 15 34 34 90 90 da da b2 b2 00 00 a8 a8 02 02 8b 8b 55 55 e8 e8
[ 13.214380] EIP: [<b11ab6fe>]
[ 13.214380] EIP: [<b11ab6fe>] __free_pages_ok+0x376/0x62c__free_pages_ok+0x376/0x62c SS:ESP 0068:c1c49e64
SS:ESP 0068:c1c49e64
[ 13.214380] CR2: 00000000c2446ffc
[ 13.214380] CR2: 00000000c2446ffc
[ 13.214380] ---[ end trace fe261d43ae421f43 ]---
[ 13.214380] ---[ end trace fe261d43ae421f43 ]---
git bisect start 3bcf494d225fd193d02e8cb2e2c3fe3cc476ff3f 5d01410fe4d92081f349b013a2e7a95429e4f2c9 --
git bisect good 14692f2c9f01c7f21f83d41a8cb99fea1e4f803f # 10:20 35+ 0 Merge remote-tracking branch 'dlm/next'
git bisect good 17623427488fe306376e18e0ee63c2c1bcbf5612 # 10:42 35+ 0 Merge remote-tracking branch 'edac-amd/for-next'
git bisect good 6acfd0c5752274ad5099152d9a00c99f81c273b5 # 10:54 35+ 0 Merge remote-tracking branch 'char-misc/char-misc-next'
git bisect good 574733068e280900745b7241a51f26815f25ca64 # 11:24 35+ 5 Merge remote-tracking branch 'userns/for-next'
git bisect good d3d6c2b2574a1700a33c3f40a8adcd11db728926 # 11:36 35+ 11 Merge remote-tracking branch 'llvmlinux/for-next'
git bisect good 749230afd0fa54770f95063071b1bdfb6dee9bc2 # 11:45 35+ 13 Merge remote-tracking branch 'y2038/y2038'
git bisect bad 35cc8c3f978f75a04ac96b3cb72b8f7630ea04f4 # 11:50 0- 1 Merge branch 'akpm-current/current'
git bisect bad 6aab9099af555bf5a464f318d312ba5baa5cf516 # 11:59 0- 1 stacktrace: introduce snprint_stack_trace for buffer output
git bisect good 15c2416b0e6f21f17152e0ba32202bb1354394e3 # 12:10 35+ 18 mm-compaction-more-focused-lru-and-pcplists-draining-fix
git bisect good c5c825302103a196aa94efa121c011121ffff14b # 12:17 35+ 2 uprobes: share the i_mmap_rwsem
git bisect good b225ec73923a04a6d00dd28c6372c167780921b8 # 12:24 35+ 0 hugetlb: hugetlb_register_all_nodes(): add __init marker
git bisect good 4fb10ba778d4c4ccefee3ce833e487a6695068b1 # 12:32 35+ 1 mm: support madvise(MADV_FREE)
git bisect good 0aba43a2670028ec26cfeb59d3c2610ab0ee140b # 12:42 35+ 4 arm64: add pmd_[dirty|mkclean] for THP
git bisect bad 1e491e9be4c97229a3a88763aada9582e37c7eaf # 12:51 0- 1 mm/debug-pagealloc: prepare boottime configurable on/off
git bisect good 34bf7903e195347898a225220357f3a49dd65e7e # 12:57 35+ 0 mm/page_ext: resurrect struct page extending code for debugging
# first bad commit: [1e491e9be4c97229a3a88763aada9582e37c7eaf] mm/debug-pagealloc: prepare boottime configurable on/off
git bisect good 34bf7903e195347898a225220357f3a49dd65e7e # 13:01 105+ 10 mm/page_ext: resurrect struct page extending code for debugging
# extra tests on HEAD of next/master
git bisect bad 3bcf494d225fd193d02e8cb2e2c3fe3cc476ff3f # 13:01 0- 3 Add linux-next specific files for 20141127
# extra tests on tree/branch next/master
git bisect bad 3bcf494d225fd193d02e8cb2e2c3fe3cc476ff3f # 13:01 0- 3 Add linux-next specific files for 20141127
# extra tests on tree/branch linus/master
git bisect good 98e8d2e094de67315f786cd81b1dccb4ac040cc2 # 13:11 105+ 21 Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus
# extra tests on tree/branch next/master
git bisect bad 3bcf494d225fd193d02e8cb2e2c3fe3cc476ff3f # 13:11 0- 3 Add linux-next specific files for 20141127
This script may reproduce the error.
----------------------------------------------------------------------------
#!/bin/bash
kernel=$1
initrd=quantal-core-i386.cgz
wget --no-clobber https://github.com/fengguang/reproduce-kernel-bug/raw/master/initrd/$initrd
kvm=(
qemu-system-x86_64
-cpu kvm64
-enable-kvm
-kernel $kernel
-initrd $initrd
-m 320
-smp 2
-net nic,vlan=1,model=e1000
-net user,vlan=1
-boot order=nc
-no-reboot
-watchdog i6300esb
-rtc base=localtime
-serial stdio
-display none
-monitor null
)
append=(
hung_task_panic=1
earlyprintk=ttyS0,115200
debug
apic=debug
sysrq_always_enabled
rcupdate.rcu_cpu_stall_timeout=100
panic=-1
softlockup_panic=1
nmi_watchdog=panic
oops=panic
load_ramdisk=2
prompt_ramdisk=0
console=ttyS0,115200
console=tty0
vga=normal
root=/dev/ram0
rw
drbd.minor_count=8
)
"${kvm[@]}" --append "${append[*]}"
----------------------------------------------------------------------------
Thanks,
Fengguang
_______________________________________________
LKP mailing list
LKP(a)linux.intel.com
7 years, 6 months
[alsa/virmidi] BUG: unable to handle kernel NULL pointer dereference at 000002a0
by Fengguang Wu
Hi Kyle,
0day kernel testing robot got the below dmesg and the first bad commit is
git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
commit 316638a5030a04bb3259dcbca0632281001a4b24
Author: Kyle Chamberlin <kylechamberlin(a)project20million.org>
AuthorDate: Fri Nov 28 13:59:56 2014 -0500
Commit: Takashi Iwai <tiwai(a)suse.de>
CommitDate: Sat Nov 29 21:34:47 2014 +0100
ALSA: virmidi: fixed code style issues
Fixed some minor code style issues and also removed some
assignments inside of if conditionals.
Signed-off-by: Kyle Chamberlin <kylechamberlin(a)project20million.org>
Signed-off-by: Takashi Iwai <tiwai(a)suse.de>
In particular, this chunk introduced the behavior change:
- if ((err = snd_card_register(card)) == 0) {
+ err = snd_card_register(card);
+ if (err) {
+-------------------------------------------------+------------+------------+------------+
| | 31514bfb4a | 316638a503 | 795172aaa6 |
+-------------------------------------------------+------------+------------+------------+
| boot_successes | 67 | 0 | 0 |
| boot_failures | 13 | 20 | 14 |
| BUG:kernel_early_hang_without_any_printk_output | 13 | 0 | 2 |
| BUG:unable_to_handle_kernel | 0 | 20 | 12 |
| Oops | 0 | 20 | 12 |
| EIP_is_at_snd_card_free | 0 | 20 | 12 |
| Kernel_panic-not_syncing:Fatal_exception | 0 | 20 | 12 |
| backtrace:platform_device_unregister | 0 | 20 | 12 |
| backtrace:alsa_card_virmidi_init | 0 | 20 | 12 |
| backtrace:kernel_init_freeable | 0 | 20 | 12 |
+-------------------------------------------------+------------+------------+------------+
[ 1.688337] usbcore: registered new interface driver line6usb
[ 1.689386] dgap: dgap-1.3-16, Digi International Part Number 40002347_C
[ 1.690258] dgap: For the tools package please visit http://www.digi.com
[ 1.694793] BUG: unable to handle kernel NULL pointer dereference at 000002a0
[ 1.695739] IP: [<7940555f>] snd_card_free+0x36/0x7f
[ 1.696409] *pde = 00000000
[ 1.696686] Oops: 0002 [#1]
[ 1.696686] Modules linked in:
[ 1.696686] CPU: 0 PID: 1 Comm: swapper Not tainted 3.18.0-rc5-00179-g316638a #101
[ 1.696686] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.7.5-20140531_083030-gandalf 04/01/2014
[ 1.696686] task: 8a068000 ti: 8a064000 task.ti: 8a064000
[ 1.696686] EIP: 0060:[<7940555f>] EFLAGS: 00010246 CPU: 0
[ 1.696686] EIP is at snd_card_free+0x36/0x7f
[ 1.696686] EAX: 00000000 EBX: 8a065e04 ECX: 7a354880 EDX: 798a5d21
[ 1.696686] ESI: 00000000 EDI: 00000000 EBP: 8a065e44 ESP: 8a065e04
[ 1.696686] DS: 007b ES: 007b FS: 0000 GS: 00e0 SS: 0068
[ 1.696686] CR0: 8005003b CR2: 000002a0 CR3: 01d49000 CR4: 000006d0
[ 1.696686] Stack:
[ 1.696686] 00000000 00000001 dead4ead ffffffff ffffffff 7a354880 00000000 00000000
[ 1.696686] 798a5d21 00000000 00000000 8a065e30 8a065e30 006d61bc 7808440c 00000001
[ 1.696686] 8a065e4c 7943d967 8a065e54 792c0e93 8a065e68 792befa9 78084440 7808440c
[ 1.696686] Call Trace:
[ 1.696686] [<7943d967>] snd_virmidi_remove+0x13/0x17
[ 1.696686] [<792c0e93>] platform_drv_remove+0x14/0x16
[ 1.696686] [<792befa9>] __device_release_driver+0xc1/0x121
[ 1.696686] [<792bf028>] device_release_driver+0x1f/0x2a
[ 1.696686] [<792be929>] bus_remove_device+0x166/0x17d
[ 1.696686] [<792bb4ad>] device_del+0x14b/0x1d8
[ 1.696686] [<792bb4ad>] ? device_del+0x14b/0x1d8
[ 1.696686] [<792c1407>] platform_device_del+0x32/0xa3
[ 1.696686] [<792c1488>] platform_device_unregister+0x10/0x1a
[ 1.696686] [<79cee7bf>] alsa_card_virmidi_init+0xd1/0x118
[ 1.696686] [<79cee6ee>] ? alsa_seq_midi_init+0x34/0x34
[ 1.696686] [<79000551>] do_one_initcall+0x186/0x288
[ 1.696686] [<79cb4400>] ? rdinit_setup+0x18/0x22
[ 1.696686] [<79060c87>] ? parse_args+0x4a6/0x579
[ 1.696686] [<7906be5f>] ? local_clock+0x2b/0x35
[ 1.696686] [<79cb44f6>] ? do_early_param+0xac/0xac
[ 1.696686] [<79cb4f46>] kernel_init_freeable+0xfd/0x1bd
[ 1.696686] [<79cb4f46>] ? kernel_init_freeable+0xfd/0x1bd
[ 1.696686] [<7959bbfc>] kernel_init+0xe/0x13c
[ 1.696686] [<795a7cc0>] ret_from_kernel_thread+0x20/0x30
[ 1.696686] [<7959bbee>] ? rest_init+0xa7/0xa7
[ 1.696686] Code: 26 00 89 c6 65 a1 14 00 00 00 89 45 f4 31 c0 c7 45 c0 00 00 00 00 8d 5d c0 b9 80 48 35 7a ba 21 5d 8a 79 8d 45 c4 e8 bc b2 c6 ff <89> 9e a0 02 00 00 89 f0 e8 80 fe ff ff 85 c0 0f 95 c2 0f b6 f2
[ 1.696686] EIP: [<7940555f>] snd_card_free+0x36/0x7f SS:ESP 0068:8a065e04
[ 1.696686] CR2: 00000000000002a0
[ 1.696686] ---[ end trace bc9b8dd3625e806d ]---
[ 1.696686] Kernel panic - not syncing: Fatal exception
git bisect start 795172aaa6701c4b66b449e79b49c41e044156c6 5d01410fe4d92081f349b013a2e7a95429e4f2c9 --
git bisect bad 5d81516a74d44d9301e140ff97e06b37eaf5831d # 06:13 0- 13 Merge 'luto/userns/setgroups' into devel-lkp-hsx01-smoke-201411300558
git bisect good b5675b9e191a3981a38f5c94b6dd8b6fa4ba8091 # 06:23 20+ 3 0day base guard for 'devel-lkp-hsx01-smoke-201411300558'
git bisect bad e929ef74cdd822177ad2322514a40127ad1e696c # 06:31 0- 4 Merge 'sound/for-next' into devel-lkp-hsx01-smoke-201411300558
git bisect good 2603fe21b764eb7412598c8c6cd6199fb8b1d9c5 # 06:41 20+ 10 ALSA: es18xx: Add GPO controls
git bisect good 2bfb14c3b8fbc787ff4478f9d77ecee78cb922fe # 06:51 20+ 0 ALSA: usb-audio: Add Xonar U1 resume support
git bisect good 37e661ee10c6d0d1310c62b3d29ae9a63073ac5d # 06:58 20+ 5 ALSA: hda - Add AZX_DCAPS_SNOOP_OFF (and refactor snoop setup)
git bisect good 6eb6c81eee2a6270b39ca02a446f3ccece24b6f8 # 07:16 20+ 0 ALSA: dice: Split stream functionality into a file
git bisect good 8832c5a74ba3506c51b6637ac78941fcd21afbef # 07:25 20+ 0 ALSA: speakers: Rename to oxfw and rename some members
git bisect good 3713d93a6a12f8629c2660bb4a30d48b98105fca # 07:32 20+ 4 ALSA: oxfw: Split PCM functionality to a new file
git bisect bad 316638a5030a04bb3259dcbca0632281001a4b24 # 07:40 0- 17 ALSA: virmidi: fixed code style issues
git bisect good 31514bfb4ab8ba6f93b5ce5fcc543cb2ac4f96e5 # 07:46 20+ 1 ALSA: oxfw: Split control functionality to a new file
# first bad commit: [316638a5030a04bb3259dcbca0632281001a4b24] ALSA: virmidi: fixed code style issues
git bisect good 31514bfb4ab8ba6f93b5ce5fcc543cb2ac4f96e5 # 07:48 60+ 13 ALSA: oxfw: Split control functionality to a new file
# extra tests on HEAD of linux-devel/devel-lkp-hsx01-smoke-201411300558
git bisect bad 795172aaa6701c4b66b449e79b49c41e044156c6 # 07:48 0- 14 0day head guard for 'devel-lkp-hsx01-smoke-201411300558'
# extra tests on tree/branch sound/for-next
git bisect bad 316638a5030a04bb3259dcbca0632281001a4b24 # 07:49 0- 20 ALSA: virmidi: fixed code style issues
# extra tests on tree/branch linus/master
git bisect good 7a5a4f978750756755dc839014e13d1b088ccc8e # 07:51 60+ 10 Merge branch 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
# extra tests on tree/branch next/master
git bisect good 29340b8ee0b4def844aa8d6b09babcede80993d2 # 07:54 60+ 80 Add linux-next specific files for 20141128
This script may reproduce the error.
----------------------------------------------------------------------------
#!/bin/bash
kernel=$1
initrd=quantal-core-i386.cgz
wget --no-clobber https://github.com/fengguang/reproduce-kernel-bug/raw/master/initrd/$initrd
kvm=(
qemu-system-x86_64
-cpu kvm64
-enable-kvm
-kernel $kernel
-initrd $initrd
-m 320
-smp 2
-net nic,vlan=1,model=e1000
-net user,vlan=1
-boot order=nc
-no-reboot
-watchdog i6300esb
-rtc base=localtime
-serial stdio
-display none
-monitor null
)
append=(
hung_task_panic=1
earlyprintk=ttyS0,115200
debug
apic=debug
sysrq_always_enabled
rcupdate.rcu_cpu_stall_timeout=100
panic=-1
softlockup_panic=1
nmi_watchdog=panic
oops=panic
load_ramdisk=2
prompt_ramdisk=0
console=ttyS0,115200
console=tty0
vga=normal
root=/dev/ram0
rw
drbd.minor_count=8
)
"${kvm[@]}" --append "${append[*]}"
----------------------------------------------------------------------------
Thanks,
Fengguang
_______________________________________________
LKP mailing list
LKP(a)linux.intel.com
7 years, 7 months
[spi/of] WARNING: CPU: 0 PID: 1 at drivers/spi/spi.c:2419 spi_init()
by Fengguang Wu
Greetings,
0day kernel testing robot got the below dmesg and the first bad commit is
git://git.kernel.org/pub/scm/linux/kernel/git/glikely/linux devicetree/next
commit ce79d54ae447d65117303ca9f61ffe9dcbc2465d
Author: Pantelis Antoniou <pantelis.antoniou(a)konsulko.com>
AuthorDate: Tue Oct 28 22:36:05 2014 +0200
Commit: Grant Likely <grant.likely(a)linaro.org>
CommitDate: Tue Nov 25 15:36:24 2014 +0000
spi/of: Add OF notifier handler
Add OF notifier handler needed for creating/destroying spi devices
according to dynamic runtime changes in the DT live tree. This code is
enabled when CONFIG_OF_DYNAMIC is selected.
Signed-off-by: Pantelis Antoniou <pantelis.antoniou(a)konsulko.com>
Signed-off-by: Grant Likely <grant.likely(a)linaro.org>
Reviewed-by: Mark Brown <broonie(a)kernel.org>
Cc: <linux-spi(a)vger.kernel.org>
+------------------------------------------+------------+------------+------------+
| | aff5e3f89a | ce79d54ae4 | 394b0904b6 |
+------------------------------------------+------------+------------+------------+
| boot_successes | 60 | 0 | 0 |
| boot_failures | 0 | 20 | 14 |
| WARNING:at_drivers/spi/spi.c:#spi_init() | 0 | 20 | 14 |
| backtrace:spi_init | 0 | 20 | 14 |
| backtrace:warn_slowpath_null | 0 | 20 | 14 |
| backtrace:kernel_init_freeable | 0 | 20 | 14 |
| page_allocation_failure:order:#,mode | 0 | 1 | |
| backtrace:vmalloc | 0 | 1 | |
| backtrace:SyS_init_module | 0 | 1 | |
+------------------------------------------+------------+------------+------------+
[ 0.083682] regulator-dummy: no parameters
[ 0.084524] NET: Registered protocol family 16
[ 0.085741] ------------[ cut here ]------------
[ 0.086403] WARNING: CPU: 0 PID: 1 at drivers/spi/spi.c:2419 spi_init+0xa9/0xd0()
[ 0.087647] Modules linked in:
[ 0.088216] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.18.0-rc6-00033-gce79d54 #113
[ 0.089562] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011
[ 0.090014] 00000001 00000000 00000001 d342bef0 c176d4b3 00000000 00000000 c1c165ed
[ 0.091632] d342bf0c c1057020 00000973 c1fcb187 00000000 d34029d0 c1cae680 d342bf1c
[ 0.093223] c105709b 00000009 00000000 d342bf28 c1fcb187 00000000 d342bf8c c10004e5
[ 0.094826] Call Trace:
[ 0.095277] [<c176d4b3>] dump_stack+0x78/0xa8
[ 0.095931] [<c1057020>] warn_slowpath_common+0x7e/0x95
[ 0.096663] [<c1fcb187>] ? spi_init+0xa9/0xd0
[ 0.097307] [<c105709b>] warn_slowpath_null+0xf/0x13
[ 0.098019] [<c1fcb187>] spi_init+0xa9/0xd0
[ 0.098656] [<c10004e5>] do_one_initcall+0x132/0x218
[ 0.099365] [<c1fcb0de>] ? ftrace_define_fields_spi_master+0x35/0x35
[ 0.100008] [<c1f7b500>] ? initcall_blacklist+0x2a/0x96
[ 0.100744] [<c1076520>] ? parse_args+0x334/0x3f6
[ 0.101435] [<c1f7bf61>] kernel_init_freeable+0x19a/0x25c
[ 0.102185] [<c1769ba4>] kernel_init+0x9/0x13c
[ 0.102837] [<c1777401>] ret_from_kernel_thread+0x21/0x30
[ 0.103587] [<c1769b9b>] ? rest_init+0xa5/0xa5
[ 0.104245] ---[ end trace e27f70e68b83202c ]---
[ 0.105000] EISA bus registered
git bisect start 394b0904b6b812bf7c3cb75bc81e910e58b0d44a 5d01410fe4d92081f349b013a2e7a95429e4f2c9 --
git bisect bad b119a9cf315b27f39a7af0869c508e30cc2bc438 # 06:15 0- 12 Merge 'cdall-kvm-arm/vcpu_init_fixes' into devel-lkp-ib03-smoke-201411280554
git bisect bad 7959073eeb45f3c359f9af7e906d495258ddc579 # 06:20 0- 20 Merge 'glikely/devicetree/next' into devel-lkp-ib03-smoke-201411280554
git bisect good a33e66ee6a821d4b9a0ed82f72439ec807ac8051 # 06:27 20+ 0 0day base guard for 'devel-lkp-ib03-smoke-201411280554'
git bisect good 2d0747c4b68be8eb8ccfa2c538f2f5dd2ea89094 # 06:33 20+ 0 of: Properly set the OF_POPULATED_BUS flag on root node
git bisect good 801d728c10db4b28e01590b46bf1f0df930760cc # 06:38 20+ 0 of/reconfig: Add OF_DYNAMIC notifier for platform_bus_type
git bisect good aff5e3f89a0b07e7edf9243f913378cc27e4110d # 06:42 20+ 0 spi/of: Create new device registration method and accessors
git bisect bad 65d473b8007b4ef9f2a5e52f39c52d2141dfd421 # 06:47 0- 20 of: remove select of non-existant OF_DEVICE config symbol
git bisect bad ce79d54ae447d65117303ca9f61ffe9dcbc2465d # 06:53 0- 20 spi/of: Add OF notifier handler
# first bad commit: [ce79d54ae447d65117303ca9f61ffe9dcbc2465d] spi/of: Add OF notifier handler
git bisect good aff5e3f89a0b07e7edf9243f913378cc27e4110d # 06:55 60+ 0 spi/of: Create new device registration method and accessors
# extra tests on HEAD of linux-devel/devel-lkp-ib03-smoke-201411280554
git bisect bad 394b0904b6b812bf7c3cb75bc81e910e58b0d44a # 06:55 0- 14 0day head guard for 'devel-lkp-ib03-smoke-201411280554'
# extra tests on tree/branch glikely/devicetree/next
git bisect bad a81a6c654bbe129af529d11b4763367af90d1152 # 07:01 0- 4 ARM: dt: fix up PL011 device tree bindings
# extra tests on tree/branch linus/master
git bisect good 3314bf6ba2ac8f1a2dd0d55a980835a258f1a45d # 08:10 60+ 0 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm
# extra tests on tree/branch next/master
git bisect bad 3bcf494d225fd193d02e8cb2e2c3fe3cc476ff3f # 08:11 0- 12 Add linux-next specific files for 20141127
This script may reproduce the error.
----------------------------------------------------------------------------
#!/bin/bash
kernel=$1
initrd=yocto-minimal-i386.cgz
wget --no-clobber https://github.com/fengguang/reproduce-kernel-bug/raw/master/initrd/$initrd
kvm=(
qemu-system-x86_64
-cpu kvm64
-enable-kvm
-kernel $kernel
-initrd $initrd
-m 320
-smp 1
-net nic,vlan=1,model=e1000
-net user,vlan=1
-boot order=nc
-no-reboot
-watchdog i6300esb
-rtc base=localtime
-serial stdio
-display none
-monitor null
)
append=(
hung_task_panic=1
earlyprintk=ttyS0,115200
debug
apic=debug
sysrq_always_enabled
rcupdate.rcu_cpu_stall_timeout=100
panic=-1
softlockup_panic=1
nmi_watchdog=panic
oops=panic
load_ramdisk=2
prompt_ramdisk=0
console=ttyS0,115200
console=tty0
vga=normal
root=/dev/ram0
rw
drbd.minor_count=8
)
"${kvm[@]}" --append "${append[*]}"
----------------------------------------------------------------------------
Thanks,
Fengguang
_______________________________________________
LKP mailing list
LKP(a)linux.intel.com
7 years, 7 months
[ip_tunnel] WARNING: CPU: 0 PID: 1 at net/batman-adv/hard-interface.c:92 batadv_is_on_batman_iface()
by Fengguang Wu
HI Steffen,
We detected this warning in the stable tree. I wonder if it's known
issue and if there are fixes in mainline.
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-3.14.y
commit 49da0655e28b5bf9d869e1c50c15c990c5db5f94
Author: Steffen Klassert <steffen.klassert(a)secunet.com>
AuthorDate: Mon May 19 11:36:56 2014 +0200
Commit: Greg Kroah-Hartman <gregkh(a)linuxfoundation.org>
CommitDate: Sat May 31 13:20:39 2014 -0700
ip_tunnel: Initialize the fallback device properly
[ Upstream commit 78ff4be45a4c51d8fb21ad92e4fabb467c6c3eeb ]
We need to initialize the fallback device to have a correct mtu
set on this device. Otherwise the mtu is set to null and the device
is unusable.
Fixes: fd58156e456d ("IPIP: Use ip-tunneling code.")
Cc: Pravin B Shelar <pshelar(a)nicira.com>
Signed-off-by: Steffen Klassert <steffen.klassert(a)secunet.com>
Signed-off-by: David S. Miller <davem(a)davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh(a)linuxfoundation.org>
+-------------------------------------------------------------------------+------------+------------+----------+
| | 39f95dfd2c | 49da0655e2 | v3.14.24 |
+-------------------------------------------------------------------------+------------+------------+----------+
| boot_successes | 60 | 0 | 0 |
| boot_failures | 0 | 20 | 42 |
| WARNING:at_net/batman-adv/hard-interface.c:batadv_is_on_batman_iface() | 0 | 20 | 10 |
| backtrace:register_netdevice_notifier | 0 | 20 | 42 |
| backtrace:batadv_init | 0 | 20 | 42 |
| backtrace:kernel_init_freeable | 0 | 20 | 42 |
| WARNING:at_net/batman-adv/hard-interface.c:#batadv_is_on_batman_iface() | 0 | 0 | 32 |
+-------------------------------------------------------------------------+------------+------------+----------+
[ 3.019820] libceph: loaded (mon/osd proto 15/24)
[ 3.021215] ------------[ cut here ]------------
[ 3.021215] ------------[ cut here ]------------
[ 3.022447] WARNING: CPU: 0 PID: 1 at net/batman-adv/hard-interface.c:92 batadv_is_on_batman_iface+0x52/0x65()
[ 3.022447] WARNING: CPU: 0 PID: 1 at net/batman-adv/hard-interface.c:92 batadv_is_on_batman_iface+0x52/0x65()
[ 3.025458] Cannot find parent device
[ 3.025458] Cannot find parent device
[ 3.026403] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.14.4-00438-g49da065 #27
[ 3.026403] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.14.4-00438-g49da065 #27
[ 3.028383] 0000000000000000
[ 3.028383] 0000000000000000 ffff880011533d48 ffff880011533d48 ffffffff81883d03 ffffffff81883d03 ffff880011533d90 ffff880011533d90
[ 3.030446] ffff880011533d80
[ 3.030446] ffff880011533d80 ffffffff810b3427 ffffffff810b3427 ffffffff8185c842 ffffffff8185c842 0000000000000000 0000000000000000
[ 3.032471] ffff880000170000
[ 3.032471] ffff880000170000 0000000000000005 0000000000000005 ffffffff81e93301 ffffffff81e93301 ffff880011533de8 ffff880011533de8
[ 3.034496] Call Trace:
[ 3.034496] Call Trace:
[ 3.035145] [<ffffffff81883d03>] dump_stack+0x4d/0x66
[ 3.035145] [<ffffffff81883d03>] dump_stack+0x4d/0x66
[ 3.036494] [<ffffffff810b3427>] warn_slowpath_common+0x70/0x89
[ 3.036494] [<ffffffff810b3427>] warn_slowpath_common+0x70/0x89
[ 3.038086] [<ffffffff8185c842>] ? batadv_is_on_batman_iface+0x52/0x65
[ 3.038086] [<ffffffff8185c842>] ? batadv_is_on_batman_iface+0x52/0x65
[ 3.039803] [<ffffffff810b349d>] warn_slowpath_fmt+0x43/0x4b
[ 3.039803] [<ffffffff810b349d>] warn_slowpath_fmt+0x43/0x4b
[ 3.041337] [<ffffffff8185c842>] batadv_is_on_batman_iface+0x52/0x65
[ 3.041337] [<ffffffff8185c842>] batadv_is_on_batman_iface+0x52/0x65
[ 3.043039] [<ffffffff8185d2a8>] batadv_hard_if_event+0xbc/0x357
[ 3.043039] [<ffffffff8185d2a8>] batadv_hard_if_event+0xbc/0x357
[ 3.044637] [<ffffffff8170c650>] call_netdevice_notifier+0x12/0x14
[ 3.044637] [<ffffffff8170c650>] call_netdevice_notifier+0x12/0x14
[ 3.046271] [<ffffffff8170f28d>] register_netdevice_notifier+0x83/0x174
[ 3.046271] [<ffffffff8170f28d>] register_netdevice_notifier+0x83/0x174
[ 3.048039] [<ffffffff820f5c6a>] ? batadv_iv_init+0x36/0x36
[ 3.048039] [<ffffffff820f5c6a>] ? batadv_iv_init+0x36/0x36
[ 3.049511] [<ffffffff820f5d62>] batadv_init+0xf8/0x124
[ 3.049511] [<ffffffff820f5d62>] batadv_init+0xf8/0x124
[ 3.050934] [<ffffffff820a7dc4>] do_one_initcall+0x7f/0x110
[ 3.050934] [<ffffffff820a7dc4>] do_one_initcall+0x7f/0x110
[ 3.052446] [<ffffffff810cb000>] ? parse_args+0xe5/0x292
[ 3.052446] [<ffffffff810cb000>] ? parse_args+0xe5/0x292
[ 3.053885] [<ffffffff820a7f81>] kernel_init_freeable+0x12c/0x1af
[ 3.053885] [<ffffffff820a7f81>] kernel_init_freeable+0x12c/0x1af
[ 3.055509] [<ffffffff8187a083>] ? rest_init+0xc7/0xc7
[ 3.055509] [<ffffffff8187a083>] ? rest_init+0xc7/0xc7
[ 3.056899] [<ffffffff8187a08c>] kernel_init+0x9/0xd5
[ 3.056899] [<ffffffff8187a08c>] kernel_init+0x9/0xd5
[ 3.058250] [<ffffffff8189158c>] ret_from_fork+0x7c/0xb0
[ 3.058250] [<ffffffff8189158c>] ret_from_fork+0x7c/0xb0
[ 3.059647] [<ffffffff8187a083>] ? rest_init+0xc7/0xc7
[ 3.059647] [<ffffffff8187a083>] ? rest_init+0xc7/0xc7
[ 3.061059] ---[ end trace c1c0c6629162e83a ]---
[ 3.061059] ---[ end trace c1c0c6629162e83a ]---
git bisect start 9c3da88145da7cd96bb898bc0304d3f783d4c8b2 455c6fdbd219161bd09b1165f11699d6d73de11c --
git bisect bad 693639e6d5de17cdd5db53f8046a4c6fd275647a # 09:55 0- 20 tty: Correct INPCK handling
git bisect bad 6f5d63343a96cfadaa16fd4bcc06c0c7b0b26c7f # 10:11 0- 10 ARM: dts: kirkwood: fix mislocated pcie-controller nodes
git bisect good aa0e5094d6c6117d2c3ba65378c61a36984acb53 # 10:18 20+ 0 pinctrl: as3722: fix handling of GPIO invert bit
git bisect good 22b2efbb5aa8d97b5f2b7a030dea626d97c87a09 # 10:22 20+ 0 ip_tunnel: Set network header properly for IP_ECN_decapsulate()
git bisect bad 6a12f896ce0aa2e88af62b5282b2a40488a5283e # 10:27 0- 20 mac80211: fix on-channel remain-on-channel
git bisect bad 7c3b5654c06c68470c446f96c6ba9b939c67771e # 10:30 0- 20 futex: Prevent attaching to kernel threads
git bisect good adeb3fe4ef6621793d7f1d6f0b9c9cc88827c5b7 # 10:38 20+ 0 net: avoid dependency of net_get_random_once on nop patching
git bisect good 32eb568e09bfdf10bd90c8478e5a79b5f9f3c841 # 10:41 20+ 0 batman-adv: increase orig refcount when storing ref in gw_node
git bisect bad ff9cfa6b917a903fe24dba928dca61d0c9339864 # 10:44 0- 20 ipv6: gro: fix CHECKSUM_COMPLETE support
git bisect bad 49da0655e28b5bf9d869e1c50c15c990c5db5f94 # 10:44 0- 20 ip_tunnel: Initialize the fallback device properly
git bisect good 39f95dfd2c76415d03489aef9674638e00c95055 # 10:44 60+ 0 batman-adv: fix local TT check for outgoing arp requests in DAT
# first bad commit: [49da0655e28b5bf9d869e1c50c15c990c5db5f94] ip_tunnel: Initialize the fallback device properly
git bisect good 39f95dfd2c76415d03489aef9674638e00c95055 # 10:44 60+ 0 batman-adv: fix local TT check for outgoing arp requests in DAT
# extra tests on HEAD of stable/linux-3.14.y
git bisect bad 9c3da88145da7cd96bb898bc0304d3f783d4c8b2 # 10:44 0- 42 Linux 3.14.24
# extra tests on tree/branch stable/linux-3.14.y
git bisect bad 2dc2565902d3c24108c4b7101e91957fd068a242 # 10:48 0- 2 Linux 3.14.25
# extra tests on tree/branch linus/master
git bisect good 5d01410fe4d92081f349b013a2e7a95429e4f2c9 # 10:55 60+ 0 Linux 3.18-rc6
# extra tests on tree/branch next/master
git bisect good 7cc2ecdb63cfae062aeadc7c575a02b6e9cc4dbb # 11:05 60+ 60 Add linux-next specific files for 20141125
This script may reproduce the error.
----------------------------------------------------------------------------
#!/bin/bash
kernel=$1
initrd=quantal-core-x86_64.cgz
wget --no-clobber https://github.com/fengguang/reproduce-kernel-bug/raw/master/initrd/$initrd
kvm=(
qemu-system-x86_64
-cpu kvm64
-enable-kvm
-kernel $kernel
-initrd $initrd
-m 320
-smp 2
-net nic,vlan=1,model=e1000
-net user,vlan=1
-boot order=nc
-no-reboot
-watchdog i6300esb
-rtc base=localtime
-serial stdio
-display none
-monitor null
)
append=(
hung_task_panic=1
earlyprintk=ttyS0,115200
debug
apic=debug
sysrq_always_enabled
rcupdate.rcu_cpu_stall_timeout=100
panic=-1
softlockup_panic=1
nmi_watchdog=panic
oops=panic
load_ramdisk=2
prompt_ramdisk=0
console=ttyS0,115200
console=tty0
vga=normal
root=/dev/ram0
rw
drbd.minor_count=8
)
"${kvm[@]}" --append "${append[*]}"
----------------------------------------------------------------------------
Thanks,
Fengguang
_______________________________________________
LKP mailing list
LKP(a)linux.intel.com
7 years, 7 months
WARNING: CPU: 1 PID: 0 at kernel/rcu/tree.c:790 rcu_nmi_enter()
by Fengguang Wu
Hi Andy,
0day kernel testing robot got the below dmesg and the first bad commit is
git://git.kernel.org/pub/scm/linux/kernel/git/luto/linux.git x86/paranoid
commit 995b9074245bb97a669cb0f1e0942b4f086f8e31
Author: Andy Lutomirski <luto(a)amacapital.net>
AuthorDate: Fri Nov 21 17:35:26 2014 -0800
Commit: Andy Lutomirski <luto(a)amacapital.net>
CommitDate: Mon Nov 24 11:56:06 2014 -0800
[TEST ONLY] Force RCU NMI nesting
+--------------------------------------------------------+------------+------------+------------+
| | b7b2ac6ea2 | 995b907424 | d962a8c53c |
+--------------------------------------------------------+------------+------------+------------+
| boot_successes | 360 | 81 | 12 |
| boot_failures | 0 | 39 | 4 |
| WARNING:at_kernel/rcu/tree.c:#rcu_nmi_enter() | 0 | 39 | 4 |
| WARNING:at_kernel/rcu/tree.c:#rcu_nmi_exit() | 0 | 39 | 4 |
| WARNING:at_kernel/rcu/tree.c:#rcu_eqs_exit_common() | 0 | 39 | 4 |
| WARNING:at_kernel/rcu/tree.c:#rcu_eqs_enter_common() | 0 | 39 | 4 |
| WARNING:at_kernel/sched/sched.h:#select_task_rq_fair() | 0 | 39 | 4 |
| backtrace:do_fork | 0 | 39 | 4 |
| backtrace:kthreadd | 0 | 39 | 4 |
| backtrace:__call_usermodehelper | 0 | 19 | 2 |
| backtrace:do_execve_common | 0 | 39 | 4 |
| backtrace:SyS_execve | 0 | 39 | 4 |
| backtrace:SyS_clone | 0 | 39 | 4 |
| backtrace:wait_for_helper | 0 | 30 | 3 |
| backtrace:do_execve | 0 | 15 | 2 |
| backtrace:run_init_process | 0 | 15 | 2 |
| WARNING:CPU:#PID:#at_kernel/sched/sched.h:#select_task | 0 | 0 | 1 |
+--------------------------------------------------------+------------+------------+------------+
[ 0.164000] ------------[ cut here ]------------
[ 0.164000] ------------[ cut here ]------------
[ 0.164000] WARNING: CPU: 1 PID: 0 at kernel/rcu/tree.c:790 rcu_nmi_enter+0xd6/0xf0()
[ 0.164000] WARNING: CPU: 1 PID: 0 at kernel/rcu/tree.c:790 rcu_nmi_enter+0xd6/0xf0()
[ 0.164000] Modules linked in:
[ 0.164000] Modules linked in:
[ 0.164000] CPU: 1 PID: 0 Comm: swapper/1 Not tainted 3.18.0-rc6-00006-g995b907 #169
[ 0.164000] CPU: 1 PID: 0 Comm: swapper/1 Not tainted 3.18.0-rc6-00006-g995b907 #169
[ 0.164000] c21933b8
[ 0.164000] c21933b8 cfc7fe4c cfc7fe4c c1db13a9 c1db13a9 00000000 00000000 cfc7fe80 cfc7fe80 c1086c7c c1086c7c c218eb9c c218eb9c 00000001 00000001
[ 0.164000] 00000000
[ 0.164000] 00000000 c21933b8 c21933b8 00000316 00000316 c111dfb6 c111dfb6 00000316 00000316 c111dfb6 c111dfb6 cfc7febc cfc7febc 00000000 00000000
[ 0.164000] cfc7d490
[ 0.164000] cfc7d490 cfc7fe90 cfc7fe90 c1086cf9 c1086cf9 00000009 00000009 00000000 00000000 cfc7fe98 cfc7fe98 c111dfb6 c111dfb6 cfc7feb4 cfc7feb4
[ 0.164000] Call Trace:
[ 0.164000] Call Trace:
[ 0.164000] [<c1db13a9>] dump_stack+0xb8/0x108
[ 0.164000] [<c1db13a9>] dump_stack+0xb8/0x108
[ 0.164000] [<c1086c7c>] warn_slowpath_common+0xcc/0x110
[ 0.164000] [<c1086c7c>] warn_slowpath_common+0xcc/0x110
[ 0.164000] [<c111dfb6>] ? rcu_nmi_enter+0xd6/0xf0
[ 0.164000] [<c111dfb6>] ? rcu_nmi_enter+0xd6/0xf0
[ 0.164000] [<c111dfb6>] ? rcu_nmi_enter+0xd6/0xf0
[ 0.164000] [<c111dfb6>] ? rcu_nmi_enter+0xd6/0xf0
[ 0.164000] [<c1086cf9>] warn_slowpath_null+0x39/0x50
[ 0.164000] [<c1086cf9>] warn_slowpath_null+0x39/0x50
[ 0.164000] [<c111dfb6>] rcu_nmi_enter+0xd6/0xf0
[ 0.164000] [<c111dfb6>] rcu_nmi_enter+0xd6/0xf0
[ 0.164000] [<c10051b3>] do_int3+0xf3/0x290
[ 0.164000] [<c10051b3>] do_int3+0xf3/0x290
[ 0.164000] [<c1402cfb>] ? trace_hardirqs_off_thunk+0xc/0x11
[ 0.164000] [<c1402cfb>] ? trace_hardirqs_off_thunk+0xc/0x11
[ 0.164000] [<c1dc75cd>] int3+0x31/0x38
[ 0.164000] [<c1dc75cd>] int3+0x31/0x38
[ 0.164000] [<c106cb13>] ? native_safe_halt+0x13/0x30
[ 0.164000] [<c106cb13>] ? native_safe_halt+0x13/0x30
[ 0.164000] [<c100bf6b>] ? default_do_nmi+0x4b/0x4b
[ 0.164000] [<c100bf6b>] ? default_do_nmi+0x4b/0x4b
[ 0.164000] [<c10fd30a>] ? trace_hardirqs_on_caller+0x27a/0x3f0
[ 0.164000] [<c10fd30a>] ? trace_hardirqs_on_caller+0x27a/0x3f0
[ 0.164000] [<c100c416>] do_nmi+0x166/0x220
[ 0.164000] [<c100c416>] do_nmi+0x166/0x220
[ 0.164000] [<c1dc754a>] nmi_stack_correct+0x28/0x2d
[ 0.164000] [<c1dc754a>] nmi_stack_correct+0x28/0x2d
[ 0.164000] [<c106cb13>] ? native_safe_halt+0x13/0x30
[ 0.164000] [<c106cb13>] ? native_safe_halt+0x13/0x30
[ 0.164000] [<c1016029>] default_idle+0x29/0x40
[ 0.164000] [<c1016029>] default_idle+0x29/0x40
[ 0.164000] [<c1017377>] arch_cpu_idle+0x17/0x30
[ 0.164000] [<c1017377>] arch_cpu_idle+0x17/0x30
[ 0.164000] [<c10ef722>] cpu_startup_entry+0x722/0x870
[ 0.164000] [<c10ef722>] cpu_startup_entry+0x722/0x870
[ 0.164000] [<c10590b9>] ? setup_APIC_timer+0x109/0x120
[ 0.164000] [<c10590b9>] ? setup_APIC_timer+0x109/0x120
[ 0.164000] [<c10567be>] start_secondary+0x38e/0x440
[ 0.164000] [<c10567be>] start_secondary+0x38e/0x440
[ 0.164000] ---[ end trace 2458105dd873601c ]---
[ 0.164000] ---[ end trace 2458105dd873601c ]---
git bisect start d962a8c53cb93a1841e5e54a60ce7f52f5ebd5cf 5d01410fe4d92081f349b013a2e7a95429e4f2c9 --
git bisect good 95336268c2f9a2418f5f0e46f4b7970af6d2bd34 # 09:42 80+ 0 Merge 'wireless-testing/master' into devel-cairo-smoke-201411250813
git bisect bad fcea503aa41277952d2fc2e8b6b056220dddd32c # 10:08 10- 1 Merge 'luto/x86/paranoid' into devel-cairo-smoke-201411250813
git bisect good 449d9d1087c0783f04b8f18554f2c43e03b844a8 # 10:52 120+ 0 x86: Clean up current_stack_pointer
git bisect good b7b2ac6ea2b5951189cf2fdb801a82a36cb3faeb # 11:15 120+ 0 x86, mce: Improve timeout error messages
git bisect bad 995b9074245bb97a669cb0f1e0942b4f086f8e31 # 12:44 30- 16 [TEST ONLY] Force RCU NMI nesting
# first bad commit: [995b9074245bb97a669cb0f1e0942b4f086f8e31] [TEST ONLY] Force RCU NMI nesting
git bisect good b7b2ac6ea2b5951189cf2fdb801a82a36cb3faeb # 12:53 360+ 0 x86, mce: Improve timeout error messages
# extra tests on HEAD of linux-devel/devel-cairo-smoke-201411250813
git bisect bad d962a8c53cb93a1841e5e54a60ce7f52f5ebd5cf # 12:53 0- 4 0day head guard for 'devel-cairo-smoke-201411250813'
# extra tests on tree/branch luto/x86/paranoid
git bisect good 0a584d301550531d87debefeef554c7b74f401f3 # 14:15 360+ 0 x86, mce: Improve timeout error messages
# extra tests on tree/branch linus/master
git bisect good 5d01410fe4d92081f349b013a2e7a95429e4f2c9 # 15:07 360+ 0 Linux 3.18-rc6
# extra tests on tree/branch next/master
This script may reproduce the error.
----------------------------------------------------------------------------
#!/bin/bash
kernel=$1
initrd=quantal-core-i386.cgz
wget --no-clobber https://github.com/fengguang/reproduce-kernel-bug/raw/master/initrd/$initrd
kvm=(
qemu-system-x86_64
-enable-kvm
-cpu Haswell,+smep,+smap
-kernel $kernel
-initrd $initrd
-m 320
-smp 2
-net nic,vlan=1,model=e1000
-net user,vlan=1
-boot order=nc
-no-reboot
-watchdog i6300esb
-rtc base=localtime
-serial stdio
-display none
-monitor null
)
append=(
hung_task_panic=1
earlyprintk=ttyS0,115200
debug
apic=debug
sysrq_always_enabled
rcupdate.rcu_cpu_stall_timeout=100
panic=-1
softlockup_panic=1
nmi_watchdog=panic
oops=panic
load_ramdisk=2
prompt_ramdisk=0
console=ttyS0,115200
console=tty0
vga=normal
root=/dev/ram0
rw
drbd.minor_count=8
)
"${kvm[@]}" --append "${append[*]}"
----------------------------------------------------------------------------
Thanks,
Fengguang
_______________________________________________
LKP mailing list
LKP(a)linux.intel.com
7 years, 7 months
[time] WARNING: CPU: 0 PID: 1 at kernel/time/timekeeping.c:1337 update_wall_time()
by Fengguang Wu
Greetings,
0day kernel testing robot got the below dmesg and the first bad commit is
git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
commit 6067dc5a8c2b1b57e67eaf1125db1d63c1ed6361
Author: pang.xunlei <pang.xunlei(a)linaro.org>
AuthorDate: Wed Oct 8 15:03:34 2014 +0800
Commit: John Stultz <john.stultz(a)linaro.org>
CommitDate: Fri Nov 21 11:59:56 2014 -0800
time: Avoid possible NTP adjustment mult overflow.
Ideally, __clocksource_updatefreq_scale, selects the largest shift
value possible for a clocksource. This results in the mult memember of
struct clocksource being particularly large, although not so large
that NTP would adjust the clock to cause it to overflow.
That said, nothing actually prohibits an overflow from occuring, its
just that it "shouldn't" occur.
So while very unlikely, and so far never observed, the value of
(cs->mult+cs->maxadj) may have a chance to reach very near 0xFFFFFFFF,
so there is a possibility it may overflow when doing NTP positive
adjustment
See the following detail: When NTP slewes the clock, kernel goes
through update_wall_time()->...->timekeeping_apply_adjustment():
tk->tkr.mult += mult_adj;
Since there is no guard against it, its possible tk->tkr.mult may
overflow during this operation.
This patch avoids any possible mult overflow by judging the overflow
case before adding mult_adj to mult, also adds the WARNING message
when capturing such case.
Signed-off-by: pang.xunlei <pang.xunlei(a)linaro.org>
[jstultz: Reworded commit message]
Signed-off-by: John Stultz <john.stultz(a)linaro.org>
+----------------------------------------------------------+------------+------------+---------------+
| | fd866e2b11 | 6067dc5a8c | next-20141125 |
+----------------------------------------------------------+------------+------------+---------------+
| boot_successes | 60 | 0 | 0 |
| boot_failures | 0 | 20 | 12 |
| WARNING:at_kernel/time/timekeeping.c:#update_wall_time() | 0 | 20 | 12 |
| backtrace:acpi_get_devices | 0 | 19 | 12 |
| backtrace:pnpacpi_init | 0 | 19 | 12 |
| backtrace:kernel_init_freeable | 0 | 20 | 12 |
| backtrace:pcibios_assign_resources | 0 | 1 | |
+----------------------------------------------------------+------------+------------+---------------+
[ 0.789871] IOAPIC[0]: Set routing entry (0-12 -> 0x3c -> IRQ 12 Mode:0 Active:0 Dest:1)
[ 0.791002] ------------[ cut here ]------------
[ 0.791002] ------------[ cut here ]------------
[ 0.791002] WARNING: CPU: 0 PID: 1 at kernel/time/timekeeping.c:1337 update_wall_time+0x3a8/0x56f()
[ 0.791002] WARNING: CPU: 0 PID: 1 at kernel/time/timekeeping.c:1337 update_wall_time+0x3a8/0x56f()
[ 0.791002] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.18.0-rc2-g6067dc5 #280
[ 0.791002] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.18.0-rc2-g6067dc5 #280
[ 0.791002] 0000000000000009 ffff880013803e68 ffffffff81a5803b 0000000000000068
git bisect start 7cc2ecdb63cfae062aeadc7c575a02b6e9cc4dbb 5d01410fe4d92081f349b013a2e7a95429e4f2c9 --
git bisect good c9f4ffa0ef6c4c71735e10e20d363b9de90725ac # 10:27 20+ 0 Merge remote-tracking branch 'l2-mtd/master'
git bisect bad 0ac890893dfd6c51841f35b9cada0a002ada075d # 10:33 0- 7 Merge remote-tracking branch 'ftrace/for-next'
git bisect good 4e0bc872f2ddddc08c0c5f18c9de6ef058d8d4fd # 10:59 20+ 0 Merge remote-tracking branch 'battery/master'
git bisect good a86dc53b0ec5196141ee0552805e03e42ba315d2 # 11:05 20+ 0 Merge remote-tracking branch 'trivial/for-next'
git bisect bad 50fa5ed69f4656a571166eac72c5b9108d487e7c # 11:09 0- 5 Merge remote-tracking branch 'tip/auto-latest'
git bisect good 709de16948ef4b4bdc92fa7bff3808367f184075 # 11:59 20+ 0 Merge remote-tracking branch 'devicetree/devicetree/next'
git bisect good daef792655bde9319bdfe5ba04ff42767d7622b4 # 12:05 20+ 0 Merge remote-tracking branch 'spi/for-next'
git bisect bad 0a2b9eac5a4567ca85c5a0daf96196563414765f # 12:15 0- 3 Merge branch 'timers/core'
git bisect good 4e6e311e596eadba30d4f56f64eae7d45611a01c # 12:17 20+ 0 Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core
git bisect good 36ce98818a4df66c8134c31fd6e768b4119c7a90 # 12:24 20+ 0 sched/deadline: Introduce start_hrtick_dl() for !CONFIG_SCHED_HRTICK
git bisect good 9ea6c5885681e3d9ce9844ba9dc57371a5cfc6d2 # 12:32 20+ 0 Merge branches 'torture.2014.11.03a', 'cpu.2014.11.03a', 'doc.2014.11.13a', 'fixes.2014.11.13a', 'signal.2014.10.29a' and 'rt.2014.10.29a' into HEAD
git bisect bad 21b6c0512e8aca75ce76365e1aef9fb16e007100 # 12:36 0- 18 time: Remove timekeeping_inject_sleeptime()
git bisect bad 90b6ce9c4066e0b2098dff65e52e6e7df1a51079 # 12:39 0- 1 time: Provide y2038 safe mktime() replacement
git bisect bad 659bc17b80c692e0ccda757e207fc4666d9b3e71 # 12:55 0- 19 time: Complete NTP adjustment threshold judging conditions
git bisect bad 6067dc5a8c2b1b57e67eaf1125db1d63c1ed6361 # 12:58 0- 20 time: Avoid possible NTP adjustment mult overflow.
git bisect good fd866e2b116b01d42428491899fe9925c42c121c # 13:06 20+ 0 time: Rename udelay_test.c to test_udelay.c
# first bad commit: [6067dc5a8c2b1b57e67eaf1125db1d63c1ed6361] time: Avoid possible NTP adjustment mult overflow.
git bisect good fd866e2b116b01d42428491899fe9925c42c121c # 13:09 60+ 0 time: Rename udelay_test.c to test_udelay.c
# extra tests on HEAD of next/master
git bisect bad 7cc2ecdb63cfae062aeadc7c575a02b6e9cc4dbb # 13:09 0- 12 Add linux-next specific files for 20141125
# extra tests on tree/branch next/master
git bisect bad 7cc2ecdb63cfae062aeadc7c575a02b6e9cc4dbb # 13:09 0- 12 Add linux-next specific files for 20141125
# extra tests on tree/branch linus/master
git bisect good b914c5b2130239fd378d1a719ab3c53f0c782be9 # 13:16 60+ 0 Merge branch 'for-3.18' of git://linux-nfs.org/~bfields/linux
# extra tests on tree/branch next/master
git bisect bad 7cc2ecdb63cfae062aeadc7c575a02b6e9cc4dbb # 13:16 0- 12 Add linux-next specific files for 20141125
This script may reproduce the error.
----------------------------------------------------------------------------
#!/bin/bash
kernel=$1
initrd=yocto-minimal-x86_64.cgz
wget --no-clobber https://github.com/fengguang/reproduce-kernel-bug/raw/master/initrd/$initrd
kvm=(
qemu-system-x86_64
-enable-kvm
-cpu Haswell,+smep,+smap
-kernel $kernel
-initrd $initrd
-m 320
-smp 1
-net nic,vlan=1,model=e1000
-net user,vlan=1
-boot order=nc
-no-reboot
-watchdog i6300esb
-rtc base=localtime
-serial stdio
-display none
-monitor null
)
append=(
hung_task_panic=1
earlyprintk=ttyS0,115200
debug
apic=debug
sysrq_always_enabled
rcupdate.rcu_cpu_stall_timeout=100
panic=-1
softlockup_panic=1
nmi_watchdog=panic
oops=panic
load_ramdisk=2
prompt_ramdisk=0
console=ttyS0,115200
console=tty0
vga=normal
root=/dev/ram0
rw
drbd.minor_count=8
)
"${kvm[@]}" --append "${append[*]}"
----------------------------------------------------------------------------
Thanks,
Fengguang
_______________________________________________
LKP mailing list
LKP(a)linux.intel.com
7 years, 7 months
[PATCH] time: Avoid possible NTP adjustment mult overflow
by pang.xunlei
Ideally, __clocksource_updatefreq_scale, selects the largest shift
value possible for a clocksource. This results in the mult memember
of struct clocksource being particularly large, although not so large
that NTP would adjust the clock to cause it to overflow.
That said, nothing actually prohibits an overflow from occurring, its
just that it "shouldn't" occur.
So while very unlikely, and so far never observed, the value of
(cs->mult+cs->maxadj) may have a chance to reach very near 0xFFFFFFFF,
so there is a possibility it may overflow when doing NTP positive
adjustment
See the following detail: When NTP slewes the clock, kernel goes
through update_wall_time()->...->timekeeping_apply_adjustment():
tk->tkr.mult += mult_adj;
Since there is no guard against it, its possible tk->tkr.mult may
overflow during this operation.
This patch avoids any possible mult overflow by judging the overflow
case before adding mult_adj to mult, also adds the WARNING message
when capturing such case.
Signed-off-by: pang.xunlei <pang.xunlei(a)linaro.org>
---
Fix the problem in the former patch catched by Fengguang's 0day robot:
[time] WARNING: CPU: 0 PID: 1 at kernel/time/timekeeping.c:1337 update_wall_time()
kernel/time/timekeeping.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c
index 0aef92a..9a1482e 100644
--- a/kernel/time/timekeeping.c
+++ b/kernel/time/timekeeping.c
@@ -1390,6 +1390,12 @@ static __always_inline void timekeeping_apply_adjustment(struct timekeeper *tk,
*
* XXX - TODO: Doc ntp_error calculation.
*/
+ if (mult_adj > 0 && (tk->tkr.mult + mult_adj < mult_adj)) {
+ /* NTP adjustment caused clocksource mult overflow */
+ WARN_ON_ONCE(1);
+ return;
+ }
+
tk->tkr.mult += mult_adj;
tk->xtime_interval += interval;
tk->tkr.xtime_nsec -= offset;
--
1.7.9.5
7 years, 7 months
[net] 4ed2d765dfa:
by Yuanhan Liu
FYI, we noticed the below changes on
commit 4ed2d765dfaccff5ebdac68e2064b59125033a3b ("net-timestamp: TCP timestamping")
testbox/testcase/testparams: vm-vp-2G/ltp/syscalls
e7fd2885385157d4 4ed2d765dfaccff5ebdac68e20
---------------- --------------------------
fail:runs %reproduction fail:runs
| | |
:5 100% 5:5 ltp.recv01.fail
:5 100% 5:5 ltp.recvfrom01.fail
:5 100% 5:5 ltp.recvmsg01.fail
:5 20% 1:5 kmsg.APIC_calibration_not_consistent_with_PM-Timer:#ms_instead_of#ms
:5 20% 1:5 kmsg.hrtimer:interrupt_took#ns
:5 20% 1:5 kmsg.TINFO:mlock_failed:errno=ENOMEM(#):Cannot_allocate_memory
:5 20% 1:5 kmsg.estcases/kernel/syscalls/getgroups/../utils/compat_16.h::#-bit_version_of_getgroups()is_not_supported_on_your_platform
testbox/testcase/testparams: nhm-white/ltp/syscalls
e7fd2885385157d4 4ed2d765dfaccff5ebdac68e20
---------------- --------------------------
:10 100% 5:5 ltp.recv01.fail
:10 100% 5:5 ltp.recvfrom01.fail
:10 100% 5:5 ltp.recvmsg01.fail
vm-vp-2G: qemu-system-x86_64 -enable-kvm -cpu Penryn
Memory: 2G
nhm-white: Nehalem
Memory: 6G
To reproduce:
apt-get install ruby ruby-oj
git clone git://git.kernel.org/pub/scm/linux/kernel/git/wfg/lkp-tests.git
cd lkp-tests
bin/setup-local job.yaml # the job file attached in this email
bin/run-local job.yaml
--yliu
7 years, 7 months
[sched] INFO: suspicious RCU usage. ]
by Yuanhan Liu
FYI, we noticed the below changes on
commit eeb61e53ea19be0c4015b00b2e8b3b2185436f2b ("sched: Fix race between task_group and sched_task_group")
+---------------------------+------------+------------+
| | xfs-for-li | eeb61e53ea |
+---------------------------+------------+------------+
| boot_successes | 0 | 0 |
| boot_failures | 54 | 10 |
| BUG:kernel_boot_hang | 54 | 10 |
| INFO:suspicious_RCU_usage | 0 | 10 |
| backtrace:do_fork | 0 | 10 |
+---------------------------+------------+------------+
[ 0.054010] ftrace: allocating 44163 entries in 87 pages
[ 0.072399]
[ 0.073480] ===============================
[ 0.074916] [ INFO: suspicious RCU usage. ]
[ 0.076000] 3.18.0-rc2-g05da589 #861 Not tainted
[ 0.076000] -------------------------------
[ 0.076000] kernel/sched/core.c:7449 suspicious rcu_dereference_check() usage!
[ 0.076000]
[ 0.076000] other info that might help us debug this:
[ 0.076000]
[ 0.076000]
[ 0.076000] rcu_scheduler_active = 1, debug_locks = 0
[ 0.076000] 2 locks held by swapper/0/0:
[ 0.076000] #0: (&p->pi_lock){......}, at: [<c1069318>] task_rq_lock+0x28/0xba
[ 0.076000] #1: (&rq->lock){-.....}, at: [<c1069336>] task_rq_lock+0x46/0xba
[ 0.076000]
[ 0.076000] stack backtrace:
[ 0.076000] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.18.0-rc2-g05da589 #861
[ 0.076000] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011
[ 0.076000] 00000000 00000000 c209be98 c1b238b0 00000001 c209beb4 c108ba6a c1f54e96
[ 0.076000] c20a3550 d30c0000 d370c300 c20b28a0 c209bed4 c10731b6 00000000 00003550
[ 0.076000] 00200246 d30c0000 00000000 00000000 c209bedc c1073285 c209bef0 c10cb273
[ 0.076000] Call Trace:
[ 0.076000] [<c1b238b0>] dump_stack+0x48/0x60
[ 0.076000] [<c108ba6a>] lockdep_rcu_suspicious+0xd3/0xdc
[ 0.076000] [<c10731b6>] sched_move_task+0xd1/0x17c
[ 0.076000] [<c1073285>] cpu_cgroup_fork+0xd/0xf
[ 0.076000] [<c10cb273>] cgroup_post_fork+0xe1/0xec
[ 0.076000] [<c10464a4>] copy_process+0x1652/0x181f
[ 0.076000] [<c1b1c321>] ? rest_init+0x116/0x116
[ 0.076000] [<c1073f5b>] ? sched_clock_cpu+0x11b/0x136
[ 0.076000] [<c1b1c321>] ? rest_init+0x116/0x116
[ 0.076000] [<c10467c7>] do_fork+0x7d/0x632
[ 0.076000] [<c1088ad7>] ? trace_hardirqs_on_caller+0x160/0x17b
[ 0.076000] [<c1b1c321>] ? rest_init+0x116/0x116
[ 0.076000] [<c1088afd>] ? trace_hardirqs_on+0xb/0xd
[ 0.076000] [<c106ce9c>] ? nr_context_switches+0xb2/0xe4
[ 0.076000] [<c1b1c321>] ? rest_init+0x116/0x116
[ 0.076000] [<c1046d9b>] kernel_thread+0x1f/0x24
[ 0.076000] [<c1b1c22a>] rest_init+0x1f/0x116
[ 0.076000] [<c222db5b>] start_kernel+0x3fd/0x404
[ 0.076000] [<c222d2af>] i386_start_kernel+0x79/0x7d
[ 0.076113] Getting VERSION: 50014
[ 0.077525] Getting VERSION: 50014
[ 0.080016] Getting ID: 0
--yliu
7 years, 7 months