Received: by 2002:ac0:a679:0:0:0:0:0 with SMTP id p54csp1315028imp; Fri, 22 Feb 2019 00:44:38 -0800 (PST) X-Google-Smtp-Source: AHgI3Ia1OEst6D5zRYu+PtN6EKK4Co14cBNzlHyXFi8Pxr+4R6LaMbVxFIVNuEtEVNQRSGqBCy99 X-Received: by 2002:a63:d70a:: with SMTP id d10mr2892870pgg.286.1550825078360; Fri, 22 Feb 2019 00:44:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550825078; cv=none; d=google.com; s=arc-20160816; b=GWHnnWd+RecuqwXsddnx/v+01S3r2iTaXl00GlVRp8I+SuFP/OPOh9loLkdyUNu53/ ZlCtJcXjyTKPl9vMUGuDcae5K02nyVPIcg2EFwKp/xYIPl7j/Uah7lz5mclkmxmXMhbX E/RcPzZ64otAUnBDyfYQPMy2f9c8J68EwBV557k155eY5F9TZJiR5ZVsSXq1Txa7ZsAd Dshn9CGy/qwap6qlKb1bsFTVG8hmEgXPatTTDoW4ke7i6mcFl3n1K8IHYrxGq2pkH6/T BotLWTnOMuBNwPQRAT6XJQ4MohsmABjXdGMNhur/bZ0boBbKxn2mrXRoGJrFQl2oMvyX cSEQ== 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; bh=vKHpxGjL31QoZY21O4flGmi7TPgecuLyyOMVtZY5Iik=; b=A3SGgwOPRu0Agdh9cTnysg0HFvxm9caU5QslG5p8JY3hTKiX1qdYRSycjaxi8KirRa 6FlQevE35dO6DXkTeOKxbKQPEBSLxmvy8RMGMJY2QoA0vbb72CnwtRBo2H9eUPzPEcp5 /AGrl87BA5VVM0pUIEU6sDOuPD/+lQszP5iCEpmW+h8sbdnckBioz2xluleRFS0poUbB I8wh8gIWEbk3TgReI2Xj1ezS5Pl7vTtELcq8QKQ4G+bQwC+UgzTmX4amTS2SXRXIb6ze J3ztiPfZVEezuMuQiddBF0xZDWNZv5oWb8YL6AE2V0fWg71xCNQamhPgpXNNtJcYq0/D XXAg== 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 o24si782671pgv.224.2019.02.22.00.44.23; Fri, 22 Feb 2019 00:44:38 -0800 (PST) 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 S1726254AbfBVImr (ORCPT + 99 others); Fri, 22 Feb 2019 03:42:47 -0500 Received: from mx2.suse.de ([195.135.220.15]:54828 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725872AbfBVImq (ORCPT ); Fri, 22 Feb 2019 03:42:46 -0500 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 51335AE28; Fri, 22 Feb 2019 08:42:45 +0000 (UTC) Date: Fri, 22 Feb 2019 09:42:41 +0100 From: Joerg Roedel To: Dave Young Cc: Borislav Petkov , bhe@redhat.com, Jerry Hoemann , x86@kernel.org, Randy Dunlap , kexec@lists.infradead.org, linux-kernel@vger.kernel.org, Pingfan Liu , Mike Rapoport , Andrew Morton , yinghai@kernel.org, vgoyal@redhat.com, iommu@lists.linux-foundation.org, konrad.wilk@oracle.com Subject: Re: [PATCHv7] x86/kdump: bugfix, make the behavior of crashkernel=X consistent with kaslr Message-ID: <20190222084241.GC8380@suse.de> References: <20190204223016.GB11986@anatevka> <20190205081552.GG21801@zn.tnic> <20190206120804.GC10062@dhcp-128-65.nay.redhat.com> <20190211204816.GB21473@dhcp-128-65.nay.redhat.com> <20190215102458.GD10433@zn.tnic> <20190218014820.GA10711@dhcp-128-65.nay.redhat.com> <20190220083241.GA3447@zn.tnic> <20190220094146.GA8597@dhcp-128-65.nay.redhat.com> <20190221171321.GD12997@zn.tnic> <20190222021101.GA11654@dhcp-128-65.nay.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190222021101.GA11654@dhcp-128-65.nay.redhat.com> 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 Fri, Feb 22, 2019 at 10:11:01AM +0800, Dave Young wrote: > In case people have a lot of devices need more swiotlb, then he manually > set the ,high with ,low together. The option to specify the high and low values for the crashkernel are important for certain machines. The point is that swiotlb already allocates 64MB of low memory by default. But that memory is only used for 32bit DMA-mask devices that want to DMA into high memory. There are drivers just allocating GFP_DMA32 memory, which also ends up in the low region (but not swiotlb), that is why the previous default of 72MB low memory was not enough, it only left 8MB of GFP_DMA32 memory. The current default of 256MB was found by experiments on a bigger number of machines, to create a reasonable default that is at least likely to be sufficient of an average machine. There is no way today for the kernel to find an optimum value for the amount of low memory required to successfully create a crash dump. It depends on the amount of devices in the system and how the drivers for them are written. The drivers have no way to report back their requirements, and even if they had, at the time the allocation happens no driver is loaded yet. So it is up to the system administrator to find workable values for the high and low memory requirements, even using experiments as a last resort. Regards, Joerg