Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp2029087imm; Thu, 24 May 2018 04:47:44 -0700 (PDT) X-Google-Smtp-Source: AB8JxZqnof14wn/8Mn39Ap0ehKVwQssQQ7+srllAU6VJgNCn9DCsWE7b7ZqB+6C/zZed08L6tUP2 X-Received: by 2002:a17:902:903:: with SMTP id 3-v6mr7051487plm.377.1527162464763; Thu, 24 May 2018 04:47:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527162464; cv=none; d=google.com; s=arc-20160816; b=SBQAmxZ2+AbOUvRmm63MfjHH9FiFVkBkWcjIZQIcGe6vaS/tsB5toX7tKmSEp8pTSE Y5xV7F2IfbnT9oBN/JoKGJz5ibrLWeO/Qa7u1RYWxw9g1BwUnNkCagwzbVXhF7x3T0fY CKsKaH07HH4iv3D1zmeXxaWrjOBcEnzgwTKgMKoaGjOlu30UTr0rlJQvXXapx6Fa2KvX r6EHHBrqAA8xBcy+KjL2p5FgvESGy4IM+70AZgL6PVz/2Cxv0UBK7ew1deoEXUUnZdMW 4kOG758dJthGEXaWHnF8nEFzH50KKrj/qV+xB9HgKccse88SvaYCP4EUD19lufU6SDUy thgg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=TsvILhdsB26KKTOMxXspi77vEh69DW+4c9oNhBqFeZw=; b=VE900ula9EeJ8d9MxYtEBn1LjgBUf/TEa+24pff7KNHKnpDP1KuTWKjivJP6sNlW8k I4gkPsEGyZL3hxA2TeXQt5+uNlFrATJUY/SoiWTTvQobdPy5fkt9f2otCrda1hh6uxLX XC/7V4W5fOxREqAaY/vJevZ8V/8OWS4pChCL79FxVmvytNXGKQigTB+V9HsEFcRqjnBX SNGB4tABgLllmMz5959gV0vyElPNaC3BJtDCz2OZhJCeTVJH4qdoIQapQWNyxywqDM4L 1cCmtj2xytCy/K2GVaej51SR2lR9eYovuIhMH3BWB50cA/QALDCn4nUHKmmxKdSuF5wZ Lt3g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=kPvCEyc6; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 7-v6si21125298plc.179.2018.05.24.04.47.30; Thu, 24 May 2018 04:47:44 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=kPvCEyc6; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S969235AbeEXLqq (ORCPT + 99 others); Thu, 24 May 2018 07:46:46 -0400 Received: from mail.kernel.org ([198.145.29.99]:60564 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S967068AbeEXJro (ORCPT ); Thu, 24 May 2018 05:47:44 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 8390E208DE; Thu, 24 May 2018 09:47:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1527155264; bh=v/lZhULcvh5F4v7MGdeEiNuBhlTFMzE+eFBwIniM0VM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kPvCEyc6uW+lKwbWNQ4sUFeHTVqR11XapCN2MR3/iw2isKsYGgBVrtl4UuktTPF5T 118vVuPAnkTUv/dndLr/IbmIqJ5THQkc8U4uV/68zkuf+ZnZzgPENtvSDe2jGliaPA Yn/btgVCOzlh1T45qEY+B4lN4IVVKOOZ6uXGBDi8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Tetsuo Handa , syzbot , Al Viro , David Howells , "Ernesto A. Fernandez" , Vyacheslav Dubeyko , Andrew Morton , Linus Torvalds Subject: [PATCH 4.9 22/96] hfsplus: stop workqueue when fill_super() failed Date: Thu, 24 May 2018 11:38:05 +0200 Message-Id: <20180524093606.879500341@linuxfoundation.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180524093605.602125311@linuxfoundation.org> References: <20180524093605.602125311@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: Tetsuo Handa commit 66072c29328717072fd84aaff3e070e3f008ba77 upstream. syzbot is reporting ODEBUG messages at hfsplus_fill_super() [1]. This is because hfsplus_fill_super() forgot to call cancel_delayed_work_sync(). As far as I can see, it is hfsplus_mark_mdb_dirty() from hfsplus_new_inode() in hfsplus_fill_super() that calls queue_delayed_work(). Therefore, I assume that hfsplus_new_inode() does not fail if queue_delayed_work() was called, and the out_put_hidden_dir label is the appropriate location to call cancel_delayed_work_sync(). [1] https://syzkaller.appspot.com/bug?id=a66f45e96fdbeb76b796bf46eb25ea878c42a6c9 Link: http://lkml.kernel.org/r/964a8b27-cd69-357c-fe78-76b066056201@I-love.SAKURA.ne.jp Signed-off-by: Tetsuo Handa Reported-by: syzbot Cc: Al Viro Cc: David Howells Cc: Ernesto A. Fernandez Cc: Vyacheslav Dubeyko Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman --- fs/hfsplus/super.c | 1 + 1 file changed, 1 insertion(+) --- a/fs/hfsplus/super.c +++ b/fs/hfsplus/super.c @@ -588,6 +588,7 @@ static int hfsplus_fill_super(struct sup return 0; out_put_hidden_dir: + cancel_delayed_work_sync(&sbi->sync_work); iput(sbi->hidden_dir); out_put_root: dput(sb->s_root);