Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp1756592imm; Wed, 23 May 2018 23:58:35 -0700 (PDT) X-Google-Smtp-Source: AB8JxZp6Dq89HACyb/oUaKsjt1cZIyXFjszDdsGSPPkUr7vFq3/QhyLkkuTaePTXHg5zvf4pwy38 X-Received: by 2002:a17:902:9a9:: with SMTP id 38-v6mr6200716pln.114.1527145115375; Wed, 23 May 2018 23:58:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527145115; cv=none; d=google.com; s=arc-20160816; b=LZEPsUj4mStCaccDOUKeL/LBRQQQSI361ac09Z8O8bWQdSWF1qQ7s6HHJAo5hwFrAI m8YDmHnd/vOzN75ISUkKeri+VkTYddnWD8Esuk2p8B4uPhl+9IZQgu8aFAsSmpUK13zs Kw3p7+3gHQ8Pq4Fi40irXHLFQYFvVIjDGKUj3d7RUOoSyHpjlgu/QJxmc1gLH8fkOv1a ne0caYaSZkTpgogwVw95cHqMjULnEX1UN3a/F2999aF7els/FCCv992rXtLtd3u2uz6n hh4rt6f7AOanwOR4JcAo/ZnNqrP6KZ4/3cjxcl2N4IDhY+tB061ysMlQuG4SmMg8RAKl cNew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date:arc-authentication-results; bh=dkrB6yLLOPEmAuupk03Tn4QmQmmidPjhR2FSvwhm9Gg=; b=g4ffsy5mbc8loTlgq/nmE0GbpUuPKa0M4EXpjzDt/Xp93BVVTmnFxNToWmORiT7/xq YPwKhXrd5dkGMgSGVUQlwKvjj6C2VpjLFHGpRo9eoThtV2HmPAEvQ+syGDJUN55NcVdZ sejS3OaPzrhIzAtAHGSJZuIPDbOOs7rT0bRrMpL3XfJ/yYQ1TUno+TUEji0tBVI5u70n ujc83+s5RYHEhj5nQtKQZ3uwONpFMBB/fEaTjtC2FSSNXdoT+s5cGU9pKU7Mk7LG8i3e NYQ+hu6+lri6tTedh3AibRkAMoftT2CoJrnNXc3UsJaFz6p75NR47SDV8xs0mSy67GbW OXjQ== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m8-v6si19789918plt.29.2018.05.23.23.58.20; Wed, 23 May 2018 23:58:35 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964928AbeEXG5R (ORCPT + 99 others); Thu, 24 May 2018 02:57:17 -0400 Received: from mx2.suse.de ([195.135.220.15]:44490 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964884AbeEXG5M (ORCPT ); Thu, 24 May 2018 02:57:12 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id D95A2AAB2; Thu, 24 May 2018 06:57:09 +0000 (UTC) Date: Thu, 24 May 2018 08:57:08 +0200 From: Petr Tesarik To: Dave Young Cc: dzickus@redhat.com, Neil Horman , Tony Luck , bhe@redhat.com, Michael Ellerman , kexec@lists.infradead.org, linux-kernel@vger.kernel.org, Martin Schwidefsky , "Eric W. Biederman" , Benjamin Herrenschmidt , Hari Bathini , Cong Wang , Andrew Morton , Ingo Molnar , Vivek Goyal Subject: Re: [PATCH] kdump: add default crashkernel reserve kernel config options Message-ID: <20180524085708.31aa311d@ezekiel.suse.cz> In-Reply-To: <20180524014905.GB2031@dhcp-128-65.nay.redhat.com> References: <20180521025337.GA4627@dhcp-128-65.nay.redhat.com> <20180521120215.117d963a7619eb0d1f54bced@linux-foundation.org> <20180523070641.GA1689@dhcp-128-65.nay.redhat.com> <877enucqr0.fsf@xmission.com> <20180523222236.5a96732e@ezekiel.suse.cz> <20180524014905.GB2031@dhcp-128-65.nay.redhat.com> Organization: SUSE Linux, s.r.o. X-Mailer: Claws Mail 3.13.2 (GTK+ 2.24.31; x86_64-suse-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 24 May 2018 09:49:05 +0800 Dave Young wrote: > Hi Petr, > > On 05/23/18 at 10:22pm, Petr Tesarik wrote: >[...] > > In short, if one size fits none, what good is it to hardcode that "one > > size" into the kernel image? > > I agreed with all the things that we can not know the exact memory > requirement for 100% use cases. But that does not means this is useless > it is still useful for common use cases of no special and memory hog > requirements as I mentioned in another reply it can simplify the kdump > deployment for those people who do not need the special setup. I still tend to disagree. This "common-case" reservation depends on things that are defined by user space. It surely does not make it easier to build a distribution kernel. Today, I get bug reports that the number calculated and added to the boot loader configuration by the installer is inaccurate. If I put a fixed number into a kernel config option, I will start getting bugs that this number is incorrect (for some systems). > For example, if this is a workstation I just want to break into a shell > to collect some panic info, then I just need a very minimal initrd, then > the Kconfig will work just fine. What is "a very minimal initrd"? Last time I had to make a significant adjustment to the estimation for openSUSE, this was caused by growing user-space requirements (systemd in this case, but I don't want to start flamewars on that topic, please). Anyway, if you want to improve the "common case", then look how IBM tries to solve it for firmware-assisted dump (fadump) on powerpc: https://patchwork.ozlabs.org/patch/905026/ The main idea is: > Instead of setting aside a significant chunk of memory nobody can use, > [...] reserve a significant chunk of memory that the kernel is prevented > from using [...], but applications are free to use it. That works great, because user space pages are filtered out in the common case, so they can be used freely by the panic kernel. Just my two cents, Petr T