Received: by 2002:a05:7412:cfc7:b0:fc:a2b0:25d7 with SMTP id by7csp1879338rdb; Tue, 20 Feb 2024 09:33:03 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCU9ZpowkVNrLRF4KQ/3Zb1DFsv/n8RG9118HrLrITmnuu0J2Mq0BkUbfSPIAr/QZthES0SC5B8KTR33dN5RGBhHvs6X7PW93GshzZSZjw== X-Google-Smtp-Source: AGHT+IEmKVqOQci7liYFqAg8Ye0w0ndKSbjnnHK4fx/ixdgYvDR6zqSj7JlMxEXXVgjNJEyza6Lu X-Received: by 2002:a17:902:e74d:b0:1db:e7a4:90a5 with SMTP id p13-20020a170902e74d00b001dbe7a490a5mr8303842plf.12.1708450383340; Tue, 20 Feb 2024 09:33:03 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708450383; cv=pass; d=google.com; s=arc-20160816; b=s3zP07MdGAu/4+EFGNKkOde5YvB7O85hWHaBBqHyrbrFtCkvox9+HF/a+xTactU/jw QsSUC3e/8fbRd9vmVn7vlt84wUV9u0hpGslv7vPGG7Wu4m+Hd3FOgQxtX2wlW5/kbYoe EMqvXgGrrmCdIVZTJik4oumZQASiPd9sjhOAyJPFEYUVauI6DSP4SIEcmtuckt+4ACZa UF1vCJEFHQvXNpsQrIg41zoCv5+CHBrtGHOI+vdB8Fvus4vuv40JUhNqwYGbjFPt9kMC Z1da2l/yMw2oufJHhMxzDof5bMebYZ0pwzQ5JkwaJCgakL1AYNhmai4JgFgX6/K6qojp C7yg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:dkim-signature:date; bh=OL5xFDTNv2eO4cGs2LE/aYT6r12sFC1afgYu/aCZ6KM=; fh=cdnrFe24HzwWdEILUfE8iAnKpZWbuzZYUVYziuBEAhI=; b=mozpr1x9Vm633IkUWlhkpPucbZio2ec/5IpILrAwTUAL/brA3Df6YB8rJLXFklLBEi AzYiDGW0csm/jdsbChHVtR6fyH5xiKigkeA98a1RxyUo7Z7uGZJtWkDET7bGYwE9LPvS bcyq5BIyQXcZtRmj6MdWrNF8pDzA/HvOzsin2ebfFR5QLLdKzh9O3+dZdEw6mOLWVJ6c o35KaPrgoGJAhahYBLL/jCSdGxQUNUQPTHPlQJtff4NNAsgcPtxGiXKkekt0LAUP/ocm HWaUAhbnpSkWhQQs1kEPJ8pdQZmQ0BN+Dl4UgKKnwqtzg2OSp7jUAr9bFoiOFde/MxTx tk0w==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=fxyuYm2K; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-73449-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-73449-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id j1-20020a170902da8100b001d717e60007si6591087plx.397.2024.02.20.09.33.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Feb 2024 09:33:03 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-73449-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=fxyuYm2K; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-73449-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-73449-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 10235281F34 for ; Tue, 20 Feb 2024 17:33:03 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A572C768FF; Tue, 20 Feb 2024 17:32:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="fxyuYm2K" Received: from out-177.mta0.migadu.com (out-177.mta0.migadu.com [91.218.175.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2A66076C8E for ; Tue, 20 Feb 2024 17:32:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=91.218.175.177 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708450367; cv=none; b=ldDWGPD2w7JpuWTzzNTxvjXWjWaCaTp3KzOQK1nE58l8XgKJLzOF+z7bEtGFo2d9L7NR6lUYqsQIlceJhjmRQQnc6nq2OLG00r8Tz6GoPM+VbY7ThJeLGyczlVwpS2jQssoYyOb90tSCvh0ds59OR2HvgnUSyCJ1l0vyna+iv3Y= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708450367; c=relaxed/simple; bh=vLoBhOInKMXmUWflzrfzPFlT60Q1ZisK5pqmlkGmoR0=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=U/9O8BSay9DESk1+v0mh7Pv4Iw8xK10Bl2GToE4JlMOpJtyLU8IjkhzR0Dfp33EDtCrcT2h5xhJbHhchemN0gKWHBomdYNVMjoVaiMvVbdTuziLHcTL8w3b0gxLGO7dcBC3gthoq7SR1ZnC+PiY+GYot4Un7AsUCjYO8efI9ST8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=fxyuYm2K; arc=none smtp.client-ip=91.218.175.177 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Date: Tue, 20 Feb 2024 12:32:32 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1708450363; 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=OL5xFDTNv2eO4cGs2LE/aYT6r12sFC1afgYu/aCZ6KM=; b=fxyuYm2KyZqwOjeFMmi1Let2DbXxCie5EhloySkSitC8BRgYw+g8xhKzEPRyrpwaBbr/TU 0tafzqcQ40XKTEmAPrIZ3Iw4O895GFa3q7oGe4uavWICcPdzTfB8TRB60MOp0jzPbPvQnG iSWlmNcgFKjgbSQNuTfPAxD2k6jceVg= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Kent Overstreet To: Michal Hocko Cc: Suren Baghdasaryan , Steven Rostedt , Vlastimil Babka , akpm@linux-foundation.org, hannes@cmpxchg.org, roman.gushchin@linux.dev, mgorman@suse.de, dave@stgolabs.net, willy@infradead.org, liam.howlett@oracle.com, corbet@lwn.net, void@manifault.com, peterz@infradead.org, juri.lelli@redhat.com, catalin.marinas@arm.com, will@kernel.org, arnd@arndb.de, tglx@linutronix.de, mingo@redhat.com, dave.hansen@linux.intel.com, x86@kernel.org, peterx@redhat.com, david@redhat.com, axboe@kernel.dk, mcgrof@kernel.org, masahiroy@kernel.org, nathan@kernel.org, dennis@kernel.org, tj@kernel.org, muchun.song@linux.dev, rppt@kernel.org, paulmck@kernel.org, pasha.tatashin@soleen.com, yosryahmed@google.com, yuzhao@google.com, dhowells@redhat.com, hughd@google.com, andreyknvl@gmail.com, keescook@chromium.org, ndesaulniers@google.com, vvvvvv@google.com, gregkh@linuxfoundation.org, ebiggers@google.com, ytcoode@gmail.com, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, bsegall@google.com, bristot@redhat.com, vschneid@redhat.com, cl@linux.com, penberg@kernel.org, iamjoonsoo.kim@lge.com, 42.hyeyoo@gmail.com, glider@google.com, elver@google.com, dvyukov@google.com, shakeelb@google.com, songmuchun@bytedance.com, jbaron@akamai.com, rientjes@google.com, minchan@google.com, kaleshsingh@google.com, kernel-team@android.com, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, iommu@lists.linux.dev, linux-arch@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-modules@vger.kernel.org, kasan-dev@googlegroups.com, cgroups@vger.kernel.org Subject: Re: [PATCH v3 31/35] lib: add memory allocations report in show_mem() Message-ID: References: <320cd134-b767-4f29-869b-d219793ba8a1@suse.cz> <20240215180742.34470209@gandalf.local.home> <20240215181648.67170ed5@gandalf.local.home> <20240215182729.659f3f1c@gandalf.local.home> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Migadu-Flow: FLOW_OUT On Tue, Feb 20, 2024 at 06:24:41PM +0100, Michal Hocko wrote: > On Tue 20-02-24 12:18:49, Kent Overstreet wrote: > > On Tue, Feb 20, 2024 at 05:23:29PM +0100, Michal Hocko wrote: > > > On Mon 19-02-24 09:17:36, Suren Baghdasaryan wrote: > > > [...] > > > > For now I think with Vlastimil's __GFP_NOWARN suggestion the code > > > > becomes safe and the only risk is to lose this report. If we get cases > > > > with reports missing this data, we can easily change to reserved > > > > memory. > > > > > > This is not just about missing part of the oom report. This is annoying > > > but not earth shattering. Eating into very small reserves (that might be > > > the only usable memory while the system is struggling in OOM situation) > > > could cause functional problems that would be non trivial to test for. > > > All that for debugging purposes is just lame. If you want to reuse the code > > > for a different purpose then abstract it and allocate the buffer when you > > > can afford that and use preallocated on when in OOM situation. > > > > > > We have always went extra mile to avoid potentially disruptive > > > operations from the oom handling code and I do not see any good reason > > > to diverge from that principle. > > > > Michal, I gave you the logic between dedicated reserves and system > > reserves. Please stop repeating these vague what-ifs. > > Your argument makes little sense and it seems that it is impossible to > explain that to you. I gave up on discussing this further with you. It was your choice to not engage with the technical discussion. And if you're not going to engage, repeating the same arguments that I already responded to 10 or 20 emails later is a pretty dishonest way to argue. You've been doing this kind of grandstanding throughout the entire discussion across every revision of the patchset. Knock it off.