Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754163AbdCIJZy (ORCPT ); Thu, 9 Mar 2017 04:25:54 -0500 Received: from szxga02-in.huawei.com ([45.249.212.188]:3853 "EHLO dggrg02-dlp.huawei.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1753712AbdCIJZv (ORCPT ); Thu, 9 Mar 2017 04:25:51 -0500 Subject: Re: cgroup: WARNING in cgroup_kill_sb To: Dmitry Vyukov , Tejun Heo , "Eric W. Biederman" , , LKML , Al Viro , "linux-fsdevel@vger.kernel.org" References: CC: syzkaller From: Zefan Li Message-ID: <58C11F61.1090804@huawei.com> Date: Thu, 9 Mar 2017 17:24:49 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.177.19.236] X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A020201.58C11F6A.025C,ss=1,re=0.000,recu=0.000,reip=0.000,cl=1,cld=1,fgs=0, ip=0.0.0.0, so=2014-11-16 11:51:01, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: f5983f5e308c15e98af8fd2144a66dbc Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2170 Lines: 45 On 2017/3/3 3:15, Dmitry Vyukov wrote: > Hello, > > The following program triggers WARNING in cgroup_kill_sb: > https://gist.githubusercontent.com/dvyukov/47a37d3b899ece1f57e512dc6c90bca6/raw/250894f3d6e2954eed01bac39e4c3b7ec59a9c31/gistfile1.txt > > > WARNING: CPU: 2 PID: 3092 at lib/percpu-refcount.c:317 > percpu_ref_kill_and_confirm+0x3ff/0x4f0 lib/percpu-refcount.c:316 > percpu_ref_kill_and_confirm called more than once on css_release! > Kernel panic - not syncing: panic_on_warn set ... > > CPU: 2 PID: 3092 Comm: a.out Not tainted 4.10.0+ #260 > Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs 01/01/2011 > Call Trace: > __dump_stack lib/dump_stack.c:15 [inline] > dump_stack+0x2ee/0x3ef lib/dump_stack.c:51 > panic+0x1fb/0x412 kernel/panic.c:179 > __warn+0x1c4/0x1e0 kernel/panic.c:540 > warn_slowpath_fmt+0xc5/0x100 kernel/panic.c:563 > percpu_ref_kill_and_confirm+0x3ff/0x4f0 lib/percpu-refcount.c:316 > percpu_ref_kill include/linux/percpu-refcount.h:119 [inline] > cgroup_kill_sb+0x188/0x530 kernel/cgroup/cgroup.c:1833 > deactivate_locked_super+0x88/0xd0 fs/super.c:309 > deactivate_super+0x155/0x1b0 fs/super.c:340 > cleanup_mnt+0xb2/0x160 fs/namespace.c:1112 > __cleanup_mnt+0x16/0x20 fs/namespace.c:1119 > task_work_run+0x18a/0x260 kernel/task_work.c:116 > tracehook_notify_resume include/linux/tracehook.h:191 [inline] > exit_to_usermode_loop+0x23b/0x2a0 arch/x86/entry/common.c:160 > prepare_exit_to_usermode arch/x86/entry/common.c:190 [inline] > syscall_return_slowpath+0x4d3/0x570 arch/x86/entry/common.c:259 > entry_SYSCALL_64_fastpath+0xc0/0xc2 > RIP: 0033:0x440b39 > RSP: 002b:00007f3e8bd0cdb8 EFLAGS: 00000202 ORIG_RAX: 00000000000000a5 > RAX: ffffffffffffffec RBX: 0000000000000000 RCX: 0000000000440b39 > RDX: 00000000004a0f3b RSI: 00000000004a0f34 RDI: 00000000004a0f34 > RBP: 00007f3e8bd0cdd0 R08: 0000000000000000 R09: 0000000000000000 > R10: 0000000000000005 R11: 0000000000000202 R12: 0000000000000000 > R13: 0000000000000000 R14: 00007f3e8bd0d9c0 R15: 00007f3e8bd0d700 > > On commit 4977ab6e92e267afe9d8f78438c3db330ca8434c > . could you share your kernel config? I can't reproduce this bug.