lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Wed, 25 May 2022 15:56:51 +0800
From:   kernel test robot <oliver.sang@...el.com>
To:     hezhongkun <hezhongkun.hzk@...edance.com>
Cc:     0day robot <lkp@...el.com>, LKML <linux-kernel@...r.kernel.org>,
        cgroups@...r.kernel.org, linux-mm@...ck.org, lkp@...ts.01.org,
        hannes@...xchg.org, mhocko@...nel.org, roman.gushchin@...ux.dev,
        lizefan.x@...edance.com, Hezhongkun <hezhongkun.hzk@...edance.com>
Subject: [mm]  6adb0a02c2: WARNING:suspicious_RCU_usage



Greeting,

FYI, we noticed the following commit (built with gcc-11):

commit: 6adb0a02c27c8811bee9783451ee25155baf490e ("[PATCH] mm: memcontrol: add the mempolicy interface for cgroup v2.")
url: https://github.com/intel-lab-lkp/linux/commits/hezhongkun/mm-memcontrol-add-the-mempolicy-interface-for-cgroup-v2/20220524-183922
base: https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git 143a6252e1b8ab424b4b293512a97cca7295c182
patch link: https://lore.kernel.org/lkml/20220524103638.473-1-hezhongkun.hzk@bytedance.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>


[    1.775514][    T2] WARNING: suspicious RCU usage
[    1.776115][    T2] 5.18.0-01158-g6adb0a02c27c #10 Not tainted
[    1.776513][    T2] -----------------------------
[    1.777133][    T2] include/linux/cgroup.h:495 suspicious rcu_dereference_check() usage!
[    1.777513][    T2]
[    1.777513][    T2] other info that might help us debug this:
[    1.777513][    T2]
[    1.778513][    T2]
[    1.778513][    T2] rcu_scheduler_active = 1, debug_locks = 1
[    1.779493][    T2] no locks held by kthreadd/2.
[    1.779514][    T2]
[    1.779514][    T2] stack backtrace:
[    1.780272][    T2] CPU: 0 PID: 2 Comm: kthreadd Not tainted 5.18.0-01158-g6adb0a02c27c #10
[    1.780509][    T2] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.16.0-debian-1.16.0-4 04/01/2014
[    1.780509][    T2] Call Trace:
[    1.780509][    T2]  <TASK>
[ 1.780509][ T2] dump_stack_lvl (kbuild/src/x86_64-2/lib/dump_stack.c:107 (discriminator 4)) 
[ 1.780509][ T2] mem_cgroup_from_task (kbuild/src/x86_64-2/include/linux/cgroup.h:495 kbuild/src/x86_64-2/mm/memcontrol.c:909) 
[ 1.780509][ T2] get_cgrp_or_task_policy (kbuild/src/x86_64-2/mm/mempolicy.c:184) 
[ 1.780509][ T2] alloc_pages (kbuild/src/x86_64-2/mm/mempolicy.c:2280) 
[ 1.780509][ T2] allocate_slab (kbuild/src/x86_64-2/mm/slub.c:1799 kbuild/src/x86_64-2/mm/slub.c:1944) 
[ 1.780509][ T2] ___slab_alloc (kbuild/src/x86_64-2/mm/slub.c:3005) 
[ 1.780509][ T2] ? dup_task_struct (kbuild/src/x86_64-2/kernel/fork.c:172 kbuild/src/x86_64-2/kernel/fork.c:971) 
[ 1.780509][ T2] kmem_cache_alloc_node (kbuild/src/x86_64-2/mm/slub.c:3092 kbuild/src/x86_64-2/mm/slub.c:3183 kbuild/src/x86_64-2/mm/slub.c:3267) 
[ 1.780509][ T2] dup_task_struct (kbuild/src/x86_64-2/kernel/fork.c:172 kbuild/src/x86_64-2/kernel/fork.c:971) 
[ 1.780509][ T2] ? trace_hardirqs_on (kbuild/src/x86_64-2/kernel/trace/trace_preemptirq.c:50 (discriminator 22)) 
[ 1.780509][ T2] copy_process (kbuild/src/x86_64-2/kernel/fork.c:2073) 
[ 1.780509][ T2] ? alloc_chain_hlocks (kbuild/src/x86_64-2/kernel/locking/lockdep.c:3455) 
[ 1.780509][ T2] ? add_chain_cache (kbuild/src/x86_64-2/kernel/locking/lockdep.c:3664) 
[ 1.780509][ T2] ? __lock_acquire (kbuild/src/x86_64-2/kernel/locking/lockdep.c:5029) 
[ 1.780509][ T2] ? __cleanup_sighand (kbuild/src/x86_64-2/kernel/fork.c:1982) 
[ 1.780509][ T2] ? finish_task_switch+0x20f/0x900 
[ 1.780509][ T2] ? check_prev_add (kbuild/src/x86_64-2/kernel/locking/lockdep.c:3759) 
[ 1.780509][ T2] ? __lock_release (kbuild/src/x86_64-2/kernel/locking/lockdep.c:5317) 
[ 1.780509][ T2] kernel_clone (kbuild/src/x86_64-2/kernel/fork.c:2644) 
[ 1.780509][ T2] ? create_io_thread (kbuild/src/x86_64-2/kernel/fork.c:2604) 
[ 1.780509][ T2] ? __lock_acquire (kbuild/src/x86_64-2/kernel/locking/lockdep.c:5029) 
[ 1.780509][ T2] ? finish_task_switch+0x214/0x900 
[ 1.780509][ T2] ? find_held_lock (kbuild/src/x86_64-2/kernel/locking/lockdep.c:5132) 
[ 1.780509][ T2] kernel_thread (kbuild/src/x86_64-2/kernel/fork.c:2687) 
[ 1.780509][ T2] ? __ia32_sys_clone3 (kbuild/src/x86_64-2/kernel/fork.c:2687) 
[ 1.780509][ T2] ? lock_downgrade (kbuild/src/x86_64-2/kernel/locking/lockdep.c:5293) 
[ 1.780509][ T2] ? kthread_complete_and_exit (kbuild/src/x86_64-2/kernel/kthread.c:331) 
[ 1.780509][ T2] ? kthreadd (kbuild/src/x86_64-2/kernel/kthread.c:396 kbuild/src/x86_64-2/kernel/kthread.c:745) 
[ 1.780509][ T2] ? do_raw_spin_unlock (kbuild/src/x86_64-2/arch/x86/include/asm/atomic.h:29 kbuild/src/x86_64-2/include/linux/atomic/atomic-instrumented.h:28 kbuild/src/x86_64-2/include/asm-generic/qspinlock.h:28 kbuild/src/x86_64-2/kernel/locking/spinlock_debug.c:100 kbuild/src/x86_64-2/kernel/locking/spinlock_debug.c:140) 
[ 1.780509][ T2] kthreadd (kbuild/src/x86_64-2/kernel/kthread.c:400 kbuild/src/x86_64-2/kernel/kthread.c:745) 
[ 1.780509][ T2] ? kthread_is_per_cpu (kbuild/src/x86_64-2/kernel/kthread.c:718) 
[ 1.780509][ T2] ret_from_fork (kbuild/src/x86_64-2/arch/x86/entry/entry_64.S:308) 
[    1.780509][    T2]  </TASK>
[    1.781590][    T1] cblist_init_generic: Setting adjustable number of callback queues.
[    1.782518][    T1] cblist_init_generic: Setting shift to 1 and lim to 1.
[    1.783730][    T1] cblist_init_generic: Setting shift to 1 and lim to 1.
[    1.784646][    T1] Running RCU-tasks wait API self tests
[    1.785657][    T1] Performance Events: unsupported p6 CPU model 42 no PMU driver, software events only.
[    1.787556][    T1] rcu: Hierarchical SRCU implementation.
[    1.791308][    T1] NMI watchdog: Perf NMI watchdog permanently disabled
[    1.792109][    T1] smp: Bringing up secondary CPUs ...
[    1.793634][    T1] x86: Booting SMP configuration:
[    1.794300][    T1] .... node  #0, CPUs:      #1
[    0.090644][    T0] masked ExtINT on CPU#1
[    1.797615][    T1] smp: Brought up 1 node, 2 CPUs
[    1.798527][    T1] smpboot: Max logical packages: 1
[    1.799519][    T1] smpboot: Total of 2 processors activated (8380.31 BogoMIPS)
[    1.802552][   T11] Callback from call_rcu_tasks_trace() invoked.
[    1.898728][   T10] Callback from call_rcu_tasks_rude() invoked.
[    1.998585][   T22] node 0 deferred pages initialised in 196ms
[    2.099652][    T1] allocated 268435456 bytes of page_ext
[    2.100769][    T1] Node 0, zone      DMA: page owner found early allocated 0 pages
[    2.106388][    T1] Node 0, zone    DMA32: page owner found early allocated 0 pages
[    2.143231][    T1] Node 0, zone   Normal: page owner found early allocated 66872 pages
[    2.145828][    T1] devtmpfs: initialized
[    2.147626][    T1] x86/mm: Memory block size: 128MB
[    2.195988][    T1] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 1911260446275000 ns
[    2.197567][    T1] futex hash table entries: 512 (order: 4, 65536 bytes, linear)
[    2.199426][    T1] pinctrl core: initialized pinctrl subsystem
[    2.212984][    T1] NET: Registered PF_NETLINK/PF_ROUTE protocol family
[    2.217521][    T1] audit: initializing netlink subsys (disabled)
[    2.219652][   T27] audit: type=2000 audit(1653397015.364:1): state=initialized audit_enabled=0 res=1
[    2.222174][    T1] thermal_sys: Registered thermal governor 'fair_share'
[    2.222184][    T1] thermal_sys: Registered thermal governor 'bang_bang'
[    2.222529][    T1] thermal_sys: Registered thermal governor 'step_wise'
[    2.223522][    T1] thermal_sys: Registered thermal governor 'user_space'
[    2.224756][    T1] cpuidle: using governor menu
[    2.227738][    T1] acpiphp: ACPI Hot Plug PCI Controller Driver version: 0.5
[    2.229834][    T1] PCI: Using configuration type 1 for base access
[    2.279233][    T1] kprobes: kprobe jump-optimization is enabled. All kprobes are optimized if possible.
[    2.281673][    T1] HugeTLB registered 2.00 MiB page size, pre-allocated 0 pages
[    2.285568][    T1] cryptd: max_cpu_qlen set to 1000
[    2.291676][    T1] ACPI: Added _OSI(Module Device)
[    2.292523][    T1] ACPI: Added _OSI(Processor Device)
[    2.293523][    T1] ACPI: Added _OSI(3.0 _SCP Extensions)
[    2.294523][    T1] ACPI: Added _OSI(Processor Aggregator Device)
[    2.295547][    T1] ACPI: Added _OSI(Linux-Dell-Video)
[    2.296535][    T1] ACPI: Added _OSI(Linux-Lenovo-NV-HDMI-Audio)
[    2.297539][    T1] ACPI: Added _OSI(Linux-HPI-Hybrid-Graphics)
[    2.347738][    T1] ACPI: 1 ACPI AML tables successfully acquired and loaded
[    2.363724][    T1] ACPI: Interpreter enabled
[    2.364811][    T1] ACPI: PM: (supports S0 S3 S4 S5)
[    2.365567][    T1] ACPI: Using IOAPIC for interrupt routing
[    2.366799][    T1] PCI: Using host bridge windows from ACPI; if necessary, use "pci=nocrs" and report a bug
[    2.370916][    T1] ACPI: Enabled 2 GPEs in block 00 to 0F


To reproduce:

        # build kernel
	cd linux
	cp config-5.18.0-01158-g6adb0a02c27c .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.18.0-01158-g6adb0a02c27c" of type "text/plain" (167364 bytes)

View attachment "job-script" of type "text/plain" (4768 bytes)

Download attachment "dmesg.xz" of type "application/x-xz" (13732 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ