Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp3388529imm; Sun, 30 Sep 2018 19:38:00 -0700 (PDT) X-Google-Smtp-Source: ACcGV61E2EL2yRooFv4VTCWv7DFFz5A1xk91joxdEPT61FSx5BTGy0e4pIAWBlHPIkf6nHyx+dJ1 X-Received: by 2002:a17:902:a50e:: with SMTP id s14-v6mr9591700plq.78.1538361480502; Sun, 30 Sep 2018 19:38:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538361480; cv=none; d=google.com; s=arc-20160816; b=Sv/RrUwpA9B+vnmTksYv5rZMAvVkKw1D4CAqHMzYk/8S4aedg//2vgdcqTp258y0Rm rIRwBB8Zu4eigHMuGNh+M1gvLcl046ZywSwyTrgYgJTYKzkMuEb0YZb6/PsPTC+I6Fua OsxxKagAEEYIZWCZIK7Y5sdsdf7rg5N5d61CJh4uKiSKeg0xfmwHaQJZ0Txrw3j6xjzS PCk5vZVNEWSVD2/PtDvsf9R79o5/Ysp5+oICQtB/4txBSjeak+hJhWl0bM6gAnM9+c55 nYskE8kJN3oztf4w8vEY//EmtNgvibXmlftwvMJeHX9qkra7jkep4gjpWHUVSNfcrcUk PPag== 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-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=rPdcmrltulzJkEuEmVXOPPDqv5gYoeLZfgs9OSIgqwA=; b=F3ED8LNr+rhy/R4C0DBcOpB9qRfdPAZQjx0bfcBoRBpoSbxhBE1NQXZpG3aabbFhkn 8oNsrswZv4fmHKjlWqL6jBXVIssRtJYASOECxrOcEZT0A+tVZbMMi2/BfVXgwPdxaKxP sKXfwUf6ggT7W2mrlHp+7o5+ahqXpUIXxa/5vG+JU0t4oE1zKQoXPFML1fQ2oeA98dqf g9Ulms+HulsJudZfNbuEJUeiw3m9zs+fkk/4ojw15dj2ixsuv6xY5227XGUBRJD1CIGK 6XHJBwO5glbtCnOY7e2CwgQgzU9ih85LPW0hRm+Xp73f1A34z8MmMLw+GdE3XhVKUwpT C/ag== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=FUf+3VmH; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t26-v6si36057pgm.672.2018.09.30.19.37.31; Sun, 30 Sep 2018 19:38:00 -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=@gmail.com header.s=20161025 header.b=FUf+3VmH; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727764AbeJAJM6 (ORCPT + 99 others); Mon, 1 Oct 2018 05:12:58 -0400 Received: from mail-pg1-f195.google.com ([209.85.215.195]:44848 "EHLO mail-pg1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726945AbeJAJM6 (ORCPT ); Mon, 1 Oct 2018 05:12:58 -0400 Received: by mail-pg1-f195.google.com with SMTP id g2-v6so8323187pgu.11 for ; Sun, 30 Sep 2018 19:37:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=rPdcmrltulzJkEuEmVXOPPDqv5gYoeLZfgs9OSIgqwA=; b=FUf+3VmHmUofAbU/3vTAYBnUIUfpu7RxrsvWIOwIS/aYoN8Z1gyoNPzlI3QYL8+XBt BnMfwgE4IUeokD00oucNQfFZF8Q0g2oDG5/abza33JTcPtNXzR04es+4lvI/KQTsjHCF 4g6QHXTic+1d6Dm3+lh+4IsBDCVgYh7HUvjPe/o1rz45jObmBmKXzoECi6dXIP0n8Asb Y4QjxxX/wm9biUmtXCAe8Ke8E4grJ+U2NOc9H6J50uGj+ilpl542GTjhOcraFp6ie4hL gd7ji4zQB17hlDruKFgBGU/cxQ81gx+/VG3I3QoumN8MU6Q44JJ++UNMEjIP5DnMAyF7 oq/Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=rPdcmrltulzJkEuEmVXOPPDqv5gYoeLZfgs9OSIgqwA=; b=BaBNYpduhmDiHGXo1OUYBPumXsDjW+rnYjzgjfbvI2+U0tl9OQ9+VX6iPnVQMtecwA vhg5utJ464izyA9NnqQMc9tTuZ9C1VB8uOFLpMysqROBQc64xJ/ZZMHZa6dLYXQ7xDRU e+4ZucTtG3H2WyttyzhZWcaSwhu3yJg9cAIg8zzTIwXtEsHqksb+3HoaAtKU40OGhQuy jItz2oVzw1kT+O7gYyDYDq0rgM0AGfxCbyPmnCQxuOoHQZ67DXa6dkHaOl65xlpONkFq 1yYBhZJnPr5jRgvrq2EFVuFKiVOuzPh57klGqchZ4P10Nem0vWjH4jy8vk7RAahUPgOU H1+Q== X-Gm-Message-State: ABuFfoiY6ZQ7/Gk6yRdVSsTzjCxYUowEqtLIgJkfrN4w0Gfv/nQsBWds WleZwjzINcn1H7RxqfgIdR4= X-Received: by 2002:a63:c20:: with SMTP id b32-v6mr8355759pgl.400.1538361447102; Sun, 30 Sep 2018 19:37:27 -0700 (PDT) Received: from localhost ([39.7.15.30]) by smtp.gmail.com with ESMTPSA id d81-v6sm19235958pfj.122.2018.09.30.19.37.24 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sun, 30 Sep 2018 19:37:25 -0700 (PDT) Date: Mon, 1 Oct 2018 11:37:21 +0900 From: Sergey Senozhatsky To: Tetsuo Handa Cc: Sergey Senozhatsky , Sergey Senozhatsky , Petr Mladek , Steven Rostedt , Alexander Potapenko , Dmitriy Vyukov , kbuild test robot , syzkaller , LKML , Linus Torvalds , Andrew Morton Subject: Re: [PATCH] printk: inject caller information into the body of message Message-ID: <20181001023721.GA6409@jagdpanzerIV> References: <49d22738-17ad-410a-be0a-d27d76ba9f37@i-love.sakura.ne.jp> <20180914115028.GB20572@tigerII.localdomain> <20180914122217.GA518@tigerII.localdomain> <7dadfa8c-1f69-ae0f-d747-dbbc9f97c2b6@i-love.sakura.ne.jp> <20180928090939.GE1160@jagdpanzerIV> <3b378c7d-c613-4a8d-67f8-946fac8ad0b0@i-love.sakura.ne.jp> <20180929105151.GA1392@tigerII.localdomain> <91efcff8-dc6d-b7b4-9ac8-2f3882289f95@i-love.sakura.ne.jp> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <91efcff8-dc6d-b7b4-9ac8-2f3882289f95@i-love.sakura.ne.jp> 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 (09/29/18 20:15), Tetsuo Handa wrote: > > Because there is no guarantee that memory information is dumped under the > oom_lock mutex. The oom_lock is held when calling out_of_memory(), and it > cannot be held when reporting GFP_ATOMIC memory allocation failures. IOW, static pr_line buffer needs additional synchronization for OOM. Correct? If we are about to have a list of printk buffers then we probably can define a list of NR_CPUS cont buffers. And we probably can reuse the existing struct cont for buffered printk, having 2 different struct-s for the same thing - struct cont and struct printk_buffer - is not very cool. > But I don't want line buffered printk() API to truncate upon out of > space for line buffered printk() API. All printk()-s are limited by LOG_LINE_MAX. Buffered printk() is not special. -ss