Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp2208193ybp; Thu, 10 Oct 2019 04:03:19 -0700 (PDT) X-Google-Smtp-Source: APXvYqy3VXZsXLN4+afQj4ccjXCMnH9TbgRnvEuAWI/5X9KwPOJo8A17+QlruXb1GBcFckqOlKRs X-Received: by 2002:a17:906:1343:: with SMTP id x3mr7565949ejb.113.1570705399612; Thu, 10 Oct 2019 04:03:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570705399; cv=none; d=google.com; s=arc-20160816; b=DfgHyMtV1KhlOnurHHOk5ygy2Xgj7749jsDbNKu6JQoxLdZx79AXpJLRBGg8eiDN7s Gto/7aayOeCmndiSqf4FJpDPlgI72//aAped2Pxfa/cm855G4b3SrFe05jOlgBbF2OBG tdl7SIzrpozcNQOaRVXxJaT83V1RHNEOwiuFJtNLvnW28d5m+2f49s3RtlkYtKp3XfES QqHssC1+W2ae+ielrjSFYbMgEEtkAif5duaYUtt2CqoE0e9ir0xiRfzisGr5dCYLKr2M LvMFP/9z0nUmpXQa06x7GduKx/+Vgar1AsHwAItAEZIr2ojxz1fvrFBdEQKLVFOkxy86 4//w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=Xa8wWkTJRrlhibk7A/JPugJWGvYu39u3G3EzXtWfka4=; b=UWyXqvptQTLGcrAO9Av8PbI3Fjitye2Cp3gXzk6wINiobA2DWE6mSMcAESNG5NjUpX iUSN5wkvZq3P/aytLFSOUIptInHVeoyvZh7qE92SKMsATlqvuyGWXomoOyDw+tCZC/qE Z0fdeiot+EP1/fbgerM46e1TIWmB4qSKWK5Uaub4GqxuUplc2W4XIrqfwRDMauP1JlKY 2vyyUWjvn/7tAfrcIROGSSzKIFyLv0jA+imwiP0hcuO0bzGf/2Hp8DRt824eLggruyXE Ih5/99J7KosN6wmBHEWVNABLqOM6mn/U9sbLUdDr0A6Ngr4Rhzp7ehIB1LcRszP8rgYZ kScQ== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id oq24si2839635ejb.202.2019.10.10.04.02.54; Thu, 10 Oct 2019 04:03:19 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1733022AbfJJK7a (ORCPT + 99 others); Thu, 10 Oct 2019 06:59:30 -0400 Received: from mx2.suse.de ([195.135.220.15]:42804 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725601AbfJJK7a (ORCPT ); Thu, 10 Oct 2019 06:59:30 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 7F349B17F; Thu, 10 Oct 2019 10:59:28 +0000 (UTC) Date: Thu, 10 Oct 2019 12:59:27 +0200 From: Michal Hocko To: Qian Cai Cc: Petr Mladek , Christian Borntraeger , Heiko Carstens , sergey.senozhatsky.work@gmail.com, rostedt@goodmis.org, peterz@infradead.org, linux-mm@kvack.org, john.ogness@linutronix.de, akpm@linux-foundation.org, Vasily Gorbik , Peter Oberparleiter , david@redhat.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] mm/page_isolation: fix a deadlock with printk() Message-ID: <20191010105927.GG18412@dhcp22.suse.cz> References: <20191009162339.GI6681@dhcp22.suse.cz> <6AAB77B5-092B-43E3-9F4B-0385DE1890D9@lca.pw> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <6AAB77B5-092B-43E3-9F4B-0385DE1890D9@lca.pw> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu 10-10-19 05:01:44, Qian Cai wrote: > > > > On Oct 9, 2019, at 12:23 PM, Michal Hocko wrote: > > > > If this was only about the memory offline code then I would agree. But > > we are talking about any printk from the zone->lock context and that is > > a bigger deal. Besides that it is quite natural that the printk code > > should be more universal and allow to be also called from the MM > > contexts as much as possible. If there is any really strong reason this > > is not possible then it should be documented at least. > > Where is the best place to document this? I am thinking about under > the “struct zone” definition’s lock field in mmzone.h. I am not sure TBH and I do not think we have reached the state where this would be the only way forward. -- Michal Hocko SUSE Labs