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.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, UNPARSEABLE_RELAY,USER_AGENT_SANE_1 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 7AC9EC433E7 for ; Tue, 13 Oct 2020 09:18:43 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id E985E214DB for ; Tue, 13 Oct 2020 09:18:42 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E985E214DB Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=collabora.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 27A2C900003; Tue, 13 Oct 2020 05:18:42 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 202E5900002; Tue, 13 Oct 2020 05:18:42 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0F1F2900003; Tue, 13 Oct 2020 05:18:42 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0025.hostedemail.com [216.40.44.25]) by kanga.kvack.org (Postfix) with ESMTP id D1643900002 for ; Tue, 13 Oct 2020 05:18:41 -0400 (EDT) Received: from smtpin13.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 769F3180AD806 for ; Tue, 13 Oct 2020 09:18:41 +0000 (UTC) X-FDA: 77366352042.13.boat30_081568e27202 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin13.hostedemail.com (Postfix) with ESMTP id 5670218140B67 for ; Tue, 13 Oct 2020 09:18:41 +0000 (UTC) X-HE-Tag: boat30_081568e27202 X-Filterd-Recvd-Size: 2766 Received: from bhuna.collabora.co.uk (bhuna.collabora.co.uk [46.235.227.227]) by imf37.hostedemail.com (Postfix) with ESMTP for ; Tue, 13 Oct 2020 09:18:40 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: rcn) with ESMTPSA id 5C1011F44FAE Date: Tue, 13 Oct 2020 11:18:33 +0200 From: Ricardo =?utf-8?Q?Ca=C3=B1uelo?= To: Petr Mladek Cc: akpm@linux-foundation.org, kernel@collabora.com, hch@lst.de, guro@fb.com, rientjes@google.com, mcgrof@kernel.org, keescook@chromium.org, yzaikin@google.com, linux-mm@kvack.org, mhocko@suse.cz, Sergey Senozhatsky , Steven Rostedt Subject: Re: [PATCH] mm, oom: enable rate-limiting controls for oom dumps Message-ID: <20201013091833.ye2xhdiu6qvnvmxs@rcn-XPS-13-9360> References: <20201009093014.9412-1-ricardo.canuelo@collabora.com> <20201012152232.GD10602@alley> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20201012152232.GD10602@alley> User-Agent: NeoMutt/20171215 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: Hi Petr, Thanks for taking the time to look into this. On lun 12-10-2020 17:22:32, Petr Mladek wrote: > It might be pretty hard to set any reasonable values. It depends on > the console speed and the amount of processes on the system. I wonder > who many people would be able to use it in reality. I agree that the interface is not obvious to use and is very system-specific. But the idea was to reuse the same parameter interface already used by printk_ratelimit. There certainly are some users that want this, but maybe they'd be happy too with another alternative that mitigates the problem of having too much OOM console output. > What about introducing some feedback from the printk code? > > static u64 printk_last_report_seq; > > if (consoles_seen(printk_last_report_seq)) { > dump_header(); > printk_last_report_seq = printk_get_last_seq(); > } > > By other words. It would skip the massive report when the consoles > were not able to see the previous one. Thanks for the suggestion. I'll take a closer look at the printk implementation to see if this is a viable alternative. > I do not see a reason to have this build configurable. The options are > either useful or not. I thought that this feature is maybe too specific to justify having two new sysctl entries for everyone. > Why is _interval suffix omitted in the first variable? I find this > pretty confusing. The name of the sysctl entries mimics those of printk_ratelimit and printk_ratelimit_burst, I thought people would be familiar with these already. Cheers, Ricardo