From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6106DC4332F for ; Tue, 21 Sep 2021 20:19:51 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id F310761165 for ; Tue, 21 Sep 2021 20:19:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org F310761165 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linutronix.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id 7D70D6B006C; Tue, 21 Sep 2021 16:19:50 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 7858A6B0071; Tue, 21 Sep 2021 16:19:50 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 69A6E6B0072; Tue, 21 Sep 2021 16:19:50 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0142.hostedemail.com [216.40.44.142]) by kanga.kvack.org (Postfix) with ESMTP id 5C4296B006C for ; Tue, 21 Sep 2021 16:19:50 -0400 (EDT) Received: from smtpin08.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id DA6C08249980 for ; Tue, 21 Sep 2021 20:19:49 +0000 (UTC) X-FDA: 78612696498.08.099BADC Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by imf08.hostedemail.com (Postfix) with ESMTP id 6881E30000AD for ; Tue, 21 Sep 2021 20:19:49 +0000 (UTC) From: Thomas Gleixner DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1632255587; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Vz7syRUN5sOPwLSCYUbNIMEsi/R8b4KCW0BzfDAPCcc=; b=Sf9kJ8F6bEpGkCkxYVZGemVx+bK63FHeiLTxvZyHUTnoC7XuxpxUV7Ph+HtegzCwp5uq4D cWVbqwxqXTmdDCPWsfTNHFf+MV8RO3fv5wsyXWu+fL2bqNiKa1tm0cY5jnJKG1+In/mLiM MMD8T7J2lS2hJddf+s/Ccgw5u8w6CqP6QcG0JXJkGfHPgKyFxcwj0MTN0u/lEFY06rULAS I4tTlJYBFWTCJv9le1meDqyrMh8Qq5Np2uqxdHbWXUqcRudYQxdMFw/nqUwJKzbaweucli cO97nILeRe6RCL1e53AWnVBvzUJH9t91akGfKWf8qwM7IY+ldC2hJE0jsIp6PA== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1632255587; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Vz7syRUN5sOPwLSCYUbNIMEsi/R8b4KCW0BzfDAPCcc=; b=tOvQKv/XPYCfTewSYn+SettAP7SzvcJxhKAHw16af75OfyfT5EbbVaO2gQkQ+l6KCioBgk uV8iuATHODDNYkBQ== To: Stephen Boyd , Andrew Morton , syzbot Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, syzkaller-bugs@googlegroups.com, Waiman Long , "Paul E. McKenney" , Al Viro , Jens Axboe , linux-block@vger.kernel.org, linux-fsdevel@vger.kernel.org Subject: Re: [syzbot] WARNING in __init_work In-Reply-To: <163224949689.3714697.17466968510780664239@swboyd.mtv.corp.google.com> References: <000000000000423e0a05cc0ba2c4@google.com> <20210915161457.95ad5c9470efc70196d48410@linux-foundation.org> <163175937144.763609.2073508754264771910@swboyd.mtv.corp.google.com> <87sfy07n69.ffs@tglx> <163224949689.3714697.17466968510780664239@swboyd.mtv.corp.google.com> Date: Tue, 21 Sep 2021 22:19:46 +0200 Message-ID: <87v92t65r1.ffs@tglx> MIME-Version: 1.0 Content-Type: text/plain X-Stat-Signature: hbdu4d461dqsuy3gkjuqwutwx5enuchm Authentication-Results: imf08.hostedemail.com; dkim=pass header.d=linutronix.de header.s=2020 header.b=Sf9kJ8F6; dkim=pass header.d=linutronix.de header.s=2020e header.b="tOvQKv/X"; dmarc=pass (policy=none) header.from=linutronix.de; spf=pass (imf08.hostedemail.com: domain of tglx@linutronix.de designates 193.142.43.55 as permitted sender) smtp.mailfrom=tglx@linutronix.de X-Rspamd-Server: rspam03 X-Rspamd-Queue-Id: 6881E30000AD X-HE-Tag: 1632255589-325237 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Stephen, On Tue, Sep 21 2021 at 11:38, Stephen Boyd wrote: > Quoting Thomas Gleixner (2021-09-19 05:41:18) >> Even if debug objects would support objects on irq stacks, the above is >> still bogus. But it does not and will not because the operations here >> have to be fully synchronous: >> >> init() -> queue() or arm() -> wait() -> destroy() >> >> because you obviously cannot queue work or arm a timer which are on stack >> and then leave the function without waiting for the operation to complete. > > Is there some way to make it more obvious that initializing a timer or > work on the stack in an irq context is a NONO because we can't wait for > it? Maybe some sort of debugobjects call to might_sleep() when it's > being told the object is on the stack, or throwing a might_sleep() into > the initialization of any stack based timer or workqueue, or both? Let me have a look.