Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 74BEDC433EF for ; Wed, 10 Nov 2021 20:03:47 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 515BD61205 for ; Wed, 10 Nov 2021 20:03:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231667AbhKJUGe (ORCPT ); Wed, 10 Nov 2021 15:06:34 -0500 Received: from mail-pl1-f175.google.com ([209.85.214.175]:38607 "EHLO mail-pl1-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230230AbhKJUGc (ORCPT ); Wed, 10 Nov 2021 15:06:32 -0500 Received: by mail-pl1-f175.google.com with SMTP id o14so3938506plg.5 for ; Wed, 10 Nov 2021 12:03:45 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=cIlvWeNZo6S7NB8/mVE36tUxBBajUlrl42axwAlyXyk=; b=y3lN9Y3JBlj76sfatOaUu7KsLt8qtux1HF8aqbfA3CzQqvk7ml9qXM7sw8V1BETmA9 7Kn3WuD9DlnDa6a1SMHYezqB0ckei9+YvuKioVct8ZDjiyxWl4z/kThmfoOYSjIehV3P waQOpSzO6XfuTxNdYw0+i06rwwQrg8rsArjjaU6yVq4f/sBinBGiN/YSLbV87tV6a3rG BOzdIhWb5ufZ7TlmTwfHgPeDZ8EWnrnHtxUnDpD5TUhWSSJSKpTm3M2zXvSiDz0E35qt pKfDYxVrXgot5UGYUNEI+Hk3qvy4DPQV07tCHWmRbpnkgV5NC4JxiKKI5xuKNRIMjoSp 2keQ== X-Gm-Message-State: AOAM532RIJW+a7og+C+ZhUXfkcw5m0MJcGgJchxY7Lnq/9PVirJOtIKN uQv7uy9Y8IC86OtFHVA4lKL5ceOYyw8acQ== X-Google-Smtp-Source: ABdhPJxbf0ym4tQoEUXmUhiY1kni30w1bAq/gA3YYv9+uo4kA2qpDC0AcveRpv3V8lpBfX+icly3mw== X-Received: by 2002:a17:90a:ce02:: with SMTP id f2mr1771441pju.77.1636574624742; Wed, 10 Nov 2021 12:03:44 -0800 (PST) Received: from sultan-box.localdomain ([199.116.118.235]) by smtp.gmail.com with ESMTPSA id e7sm317936pgk.90.2021.11.10.12.03.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Nov 2021 12:03:44 -0800 (PST) Date: Wed, 10 Nov 2021 12:03:40 -0800 From: Sultan Alsawaf To: John Ogness Cc: Daniel Vetter , Peter Zijlstra , Anton Vorontsov , Ben Segall , Colin Cross , Daniel Bristot de Oliveira , David Airlie , Dietmar Eggemann , dri-devel@lists.freedesktop.org, Ingo Molnar , Juri Lelli , Kees Cook , linux-kernel@vger.kernel.org, Maarten Lankhorst , Maxime Ripard , Mel Gorman , Petr Mladek , Sergey Senozhatsky , Steven Rostedt , Thomas Zimmermann , Tony Luck , Vincent Guittot , mkoutny@suse.com Subject: Re: printk deadlock due to double lock attempt on current CPU's runqueue Message-ID: References: <20211109213847.GY174703@worktop.programming.kicks-ass.net> <87fss4wcgm.fsf@jogness.linutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87fss4wcgm.fsf@jogness.linutronix.de> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 10, 2021 at 11:13:37AM +0106, John Ogness wrote: > Even after we introduce kthread printers, there will still be situations > where direct printing is used: booting (before kthreads exist) and > shutdown/suspend/crash situations, when the kthreads may not be > active. Although I'm unaware of any ongoing kthread printer work, I'm curious to know how a kthread approach wouldn't employ a try_to_wake_up() from directly inside printk(), since the try_to_wake_up() hit from inside the fbcon code is what caused my deadlock. Sultan