[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YuYm3dWwpZwH58Hu@xsang-OptiPlex-9020>
Date: Sun, 31 Jul 2022 14:53:17 +0800
From: kernel test robot <oliver.sang@...el.com>
To: Feng Tang <feng.tang@...el.com>
CC: 0day robot <lkp@...el.com>, Vlastimil Babka <vbabka@...e.cz>,
LKML <linux-kernel@...r.kernel.org>, <linux-mm@...ck.org>,
<lkp@...ts.01.org>, Andrew Morton <akpm@...ux-foundation.org>,
Christoph Lameter <cl@...ux.com>,
Pekka Enberg <penberg@...nel.org>,
David Rientjes <rientjes@...gle.com>,
Joonsoo Kim <iamjoonsoo.kim@....com>,
Roman Gushchin <roman.gushchin@...ux.dev>,
Hyeonggon Yoo <42.hyeyoo@...il.com>,
Dave Hansen <dave.hansen@...el.com>,
Robin Murphy <robin.murphy@....com>,
John Garry <john.garry@...wei.com>,
Kefeng Wang <wangkefeng.wang@...wei.com>,
Feng Tang <feng.tang@...el.com>
Subject: [mm/slub] 3616799128:
BUG_kmalloc-#(Not_tainted):kmalloc_Redzone_overwritten
Greeting,
FYI, we noticed the following commit (built with gcc-11):
commit: 3616799128612e04ed919579e2c7b0dccf6bcb00 ("[PATCH v3 3/3] mm/slub: extend redzone check to cover extra allocated kmalloc space than requested")
url: https://github.com/intel-lab-lkp/linux/commits/Feng-Tang/mm-slub-some-debug-enhancements/20220727-151318
base: git://git.kernel.org/cgit/linux/kernel/git/vbabka/slab.git for-next
patch link: https://lore.kernel.org/linux-mm/20220727071042.8796-4-feng.tang@intel.com
in testcase: boot
on test machine: qemu-system-x86_64 -enable-kvm -cpu SandyBridge -smp 2 -m 16G
caused below changes (please refer to attached dmesg/kmsg for entire log/backtrace):
If you fix the issue, kindly add following tag
Reported-by: kernel test robot <oliver.sang@...el.com>
[ 50.637839][ T154] =============================================================================
[ 50.639937][ T154] BUG kmalloc-16 (Not tainted): kmalloc Redzone overwritten
[ 50.641291][ T154] -----------------------------------------------------------------------------
[ 50.641291][ T154]
[ 50.643617][ T154] 0xffff88810018464c-0xffff88810018464f @offset=1612. First byte 0x7 instead of 0xcc
[ 50.645311][ T154] Allocated in __sdt_alloc+0x258/0x457 age=14287 cpu=0 pid=1
[ 50.646584][ T154] ___slab_alloc+0x52b/0x5b6
[ 50.647411][ T154] __slab_alloc+0x1a/0x22
[ 50.648374][ T154] __kmalloc_node+0x10c/0x1e1
[ 50.649237][ T154] __sdt_alloc+0x258/0x457
[ 50.650060][ T154] build_sched_domains+0xae/0x10e8
[ 50.650981][ T154] sched_init_smp+0x30/0xa5
[ 50.651805][ T154] kernel_init_freeable+0x1c6/0x23b
[ 50.652767][ T154] kernel_init+0x14/0x127
[ 50.653594][ T154] ret_from_fork+0x1f/0x30
[ 50.654414][ T154] Slab 0xffffea0004006100 objects=28 used=28 fp=0x0000000000000000 flags=0x1fffc0000000201(locked|slab|node=0|zone=1|lastcpupid=0x3fff)
[ 50.656866][ T154] Object 0xffff888100184640 @offset=1600 fp=0xffff888100184520
[ 50.656866][ T154]
[ 50.658410][ T154] Redzone ffff888100184630: cc cc cc cc cc cc cc cc cc cc cc cc cc cc cc cc ................
[ 50.660047][ T154] Object ffff888100184640: 00 32 80 00 81 88 ff ff 01 00 00 00 07 00 80 8a .2..............
[ 50.661837][ T154] Redzone ffff888100184650: cc cc cc cc cc cc cc cc ........
[ 50.663454][ T154] Padding ffff8881001846b4: 5a 5a 5a 5a 5a 5a 5a 5a 5a 5a 5a 5a ZZZZZZZZZZZZ
[ 50.665225][ T154] CPU: 0 PID: 154 Comm: systemd-udevd Not tainted 5.19.0-rc5-00010-g361679912861 #1
[ 50.666861][ T154] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.16.0-debian-1.16.0-4 04/01/2014
[ 50.668694][ T154] Call Trace:
[ 50.669331][ T154] <TASK>
[ 50.669832][ T154] dump_stack_lvl+0x57/0x7d
[ 50.670601][ T154] check_bytes_and_report+0xca/0xfe
[ 50.671436][ T154] check_object+0xdc/0x24d
[ 50.672163][ T154] free_debug_processing+0x98/0x210
[ 50.673036][ T154] ? qlist_free_all+0x90/0xde
[ 50.673904][ T154] __slab_free+0x46/0x198
[ 50.674660][ T154] ? lockdep_hardirqs_on_prepare+0x32d/0x34e
[ 50.675746][ T154] qlist_free_all+0xae/0xde
[ 50.676552][ T154] kasan_quarantine_reduce+0x10d/0x145
[ 50.677507][ T154] __kasan_slab_alloc+0x1c/0x5a
[ 50.678327][ T154] slab_post_alloc_hook+0x5a/0xa2
[ 50.679249][ T154] ? getname_flags+0x4b/0x314
[ 50.680069][ T154] kmem_cache_alloc+0x102/0x135
[ 50.680938][ T154] getname_flags+0x4b/0x314
[ 50.681781][ T154] do_sys_openat2+0x7a/0x15c
[ 50.682624][ T154] ? build_open_flags+0x324/0x324
[ 50.683522][ T154] ? __lock_release+0xe8/0x367
[ 50.684407][ T154] do_sys_open+0x6b/0x83
[ 50.685225][ T154] ? file_open_root+0xbf/0xbf
[ 50.686093][ T154] do_syscall_64+0x6e/0x82
[ 50.686895][ T154] ? lockdep_hardirqs_on_prepare+0x32d/0x34e
[ 50.688007][ T154] ? do_syscall_64+0x7c/0x82
[ 50.688859][ T154] ? rcu_read_lock_sched_held+0x60/0x98
[ 50.689780][ T154] ? lockdep_hardirqs_on_prepare+0x32d/0x34e
[ 50.690766][ T154] ? do_syscall_64+0x7c/0x82
[ 50.691591][ T154] ? lockdep_hardirqs_on_prepare+0x32d/0x34e
[ 50.692521][ T154] entry_SYSCALL_64_after_hwframe+0x46/0xb0
[ 50.693535][ T154] RIP: 0033:0x7f60f7d2a767
[ 50.694372][ T154] Code: 25 00 00 41 00 3d 00 00 41 00 74 47 64 8b 04 25 18 00 00 00 85 c0 75 6b 44 89 e2 48 89 ee bf 9c ff ff ff b8 01 01 00 00 0f 05 <48> 3d 00 f0 ff ff 0f 87 95 00 00 00 48 8b 4c 24 28 64 48 2b 0c 25
[ 50.697786][ T154] RSP: 002b:00007ffe8d6644b0 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
[ 50.699213][ T154] RAX: ffffffffffffffda RBX: 00007f60f77916c0 RCX: 00007f60f7d2a767
[ 50.700601][ T154] RDX: 00000000000800c1 RSI: 000056320c6d0431 RDI: 00000000ffffff9c
[ 50.702019][ T154] RBP: 000056320c6d0431 R08: 000056320cec9d30 R09: 00007f60f7c90e20
[ 50.703408][ T154] R10: 00000000000001a4 R11: 0000000000000246 R12: 00000000000800c1
[ 50.704860][ T154] R13: 000056320c6d0431 R14: 00000000ffffffff R15: 00007ffe8d6645b8
[ 50.706282][ T154] </TASK>
[ 50.706848][ T154] Disabling lock debugging due to kernel taint
[ 50.707913][ T154] FIX kmalloc-16: Restoring kmalloc Redzone 0xffff88810018464c-0xffff88810018464f=0xcc
To reproduce:
# build kernel
cd linux
cp config-5.19.0-rc5-00010-g361679912861 .config
make HOSTCC=gcc-11 CC=gcc-11 ARCH=x86_64 olddefconfig prepare modules_prepare bzImage modules
make HOSTCC=gcc-11 CC=gcc-11 ARCH=x86_64 INSTALL_MOD_PATH=<mod-install-dir> modules_install
cd <mod-install-dir>
find lib/ | cpio -o -H newc --quiet | gzip > modules.cgz
git clone https://github.com/intel/lkp-tests.git
cd lkp-tests
bin/lkp qemu -k <bzImage> -m modules.cgz job-script # job-script is attached in this email
# if come across any failure that blocks the test,
# please remove ~/.lkp and /lkp dir to run from a clean state.
--
0-DAY CI Kernel Test Service
https://01.org/lkp
View attachment "config-5.19.0-rc5-00010-g361679912861" of type "text/plain" (133440 bytes)
View attachment "job-script" of type "text/plain" (4946 bytes)
Download attachment "dmesg.xz" of type "application/x-xz" (70772 bytes)
Powered by blists - more mailing lists