Received: by 10.223.164.202 with SMTP id h10csp4689476wrb; Wed, 29 Nov 2017 10:12:24 -0800 (PST) X-Google-Smtp-Source: AGs4zMYpoHmFQrBPw4do1rBewZcY/PmwLwfAy6Sto19PRmJovVdHEpIu3ZbTeD/+oFYAJU5oIld4 X-Received: by 10.98.27.3 with SMTP id b3mr3820144pfb.159.1511979144510; Wed, 29 Nov 2017 10:12:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1511979144; cv=none; d=google.com; s=arc-20160816; b=qHsafzUNA5pXwI2zelu2YrlrxffSO62D8gK/YD092adZhIFZh98DZ+Zi+EbElZEzKu bpPU5PuBkxrJTxW0qno6n4gL/yinifgtWzJg1etJIwy6GQnVLLz/w9qXMSSpyJCFX4Px CtqGOMowzBmJyL5xNK7XJb9PBh4w7l6nc8j2XnJ3iNUm7juyNjpY/q2EImFdB+7xiVgw oz4UGHfqW5Oj3Enf1isjrF0JysH18bDB8s0ziiczylm+BYkQG7isitfaKHNVyEKOnRv6 i6maAux1tUGD2H1GKePvqZVjykNuyPxCesel6LmoCiSeYnhnuv1ukUclALz6s4MQll1P LAJQ== 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:arc-authentication-results; bh=5ARC63BoiV81PWFZtYnjeAOw6StWAYTfnj9n++KAxBk=; b=ADvnCAsySoY0ZKAyQHc7y40k2jkJ8Ef0MiEJHeiwA12yjul5G69dS8//CBwqWh5oiE Qpaz5hCVTAWguVKeJTpHjo5ojvwhrN9d6ca/eWkHRysX81tAuAU9Iv4WJR9nCV2uUJbX TRiKAe0u6MQU9+1q6eHUTVeX1wPMwyKy9T+5EQ8w9y7j2IFgCbdiiIF9hLyk8b3yBJRf MQcJvxFmCOvhcdvmUvo1U2H/4goElNV9MupPkoxTO0QIbjeOFLAteZA2CA9sbv0SHw+C VHTK+RQ7yQzWVx6wrhjiT3ecotkkwWO8XlCrwNGtOxghyX8wf2nNSbaULARaGEXOZWNp r6AQ== 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 n1si1618125pld.501.2017.11.29.10.12.14; Wed, 29 Nov 2017 10:12:24 -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 S1751791AbdK2M1h (ORCPT + 70 others); Wed, 29 Nov 2017 07:27:37 -0500 Received: from mx2.suse.de ([195.135.220.15]:54987 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751744AbdK2M1f (ORCPT ); Wed, 29 Nov 2017 07:27:35 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id DEEB0AD92; Wed, 29 Nov 2017 12:27:33 +0000 (UTC) Date: Wed, 29 Nov 2017 13:27:32 +0100 From: Jiri Bohac To: Baoquan He Cc: Toshi Kani , David Airlie , Dave Young , joro@8bytes.org, kexec@lists.infradead.org, linux-kernel@vger.kernel.org, Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , Bjorn Helgaas , Thomas Gleixner , yinghai@kernel.org, Vivek Goyal Subject: Re: [PATCH] x86/kexec: Exclude GART aperture from vmcore Message-ID: <20171129122732.qcpi655yf26iuspg@dwarf.suse.cz> References: <20171106024143.GA3669@x1> <20171106090155.p7jhe2m57whfxma3@dwarf.suse.cz> <20171106092729.GB3669@x1> <20171106095638.7iwlyjmlom3tqelt@dwarf.suse.cz> <20171107113956.GC3669@x1> <20171107134212.tmjdt7rdailtbosa@dwarf.suse.cz> <20171107153428.ex27nwkvelhm2nm7@dwarf.suse.cz> <20171112080426.GB6429@x1> <20171128215833.hhcjvn5qjfc3bdrk@dwarf.suse.cz> <20171129024307.GE15074@x1> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171129024307.GE15074@x1> User-Agent: NeoMutt/20170912 (1.9.0) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 29, 2017 at 10:43:07AM +0800, Baoquan He wrote: > On 11/28/17 at 10:58pm, Jiri Bohac wrote: > > On Sun, Nov 12, 2017 at 04:04:26PM +0800, Baoquan He wrote: > > > Solution: > > > 1) Remove the code which support GART IOMMU when it's not enabled in > > > BIOS. This has been done in the new generation of hardware IOMMU like > > > intel vt-d IOMMU and amd-Vi IOMMU. We should not make GART IOMMU be > > > exceptional. > > > > Wouldn't this break old machines with actual AGP and > > misconfigured/bugg BIOSes? Wasn't that the reason why we have the > > workaround of mapping the hole over real memory? > > Hmm, a quick question, does it work when GART support is enabled in > bios? In intel vt-d and amd-vi iommu, if user doesn't enable it in bios, > the functionality will be disabled in kernel, why would we not do that > for GART IOMMU? and why is GART so special? My feeling is that there is no technical reason (perhaps there were more broken BIOSes in the AGP days?). The main reason is that the kernel has included the workaround since ever and removing it now will break these machines. Even if most of them would be fixed by properly configuring the BIOS, it will still be regardes as a regression by the user, which I don't think is acceptable. Currently everything works with the workaround, except kdump. That's why I came up with a fix for [half of] kdump. > > > 2) Remove those pages from mm subsystem since they are not seen any more > > > though they have been added into mm subsystem, because CPU can't see > > > them. Could you explain what exactly you mean and how it would fix the vmcore issue? > > > 3) Remove the apreture region from /proc/iomem so that pages in that > > > region can't be seen by kdump kernel. This is easier, but just a work > > > around. > > > > I like this idea, but won't this cause pci_claim_resource() fail > > after the call to pci_find_parent_resource() ? See my previous > > mail. > > Not very sure, now have not time to investigate why it cause failure. > > I tried to find a system with GART in our lab, but failed. Those > machines are too old The vmcore problem is reproducible on modern AMD systems. This has originally been reported by a customer running an "HP ProLiant BL465c Gen8". I later reproduced it on a "ProLiant DL385p Gen8", as well as many older systems. So I believe kdump/vmcore needs fixing - it is broken on machines sold today. What became a bit "old" is the reason why we don't include the "GART" region in the iomem resources - fix for a resource conflict resulting in malfuncioning AGP hardware as reported in bko#72201; see my original mail for the full info. But I don't think we should break this old hardware again just to make the kdump fix more beautiful. > If have a easy fix, worth to have a try. The fix for kexec_file_load-based kdump is easy and tested. I don't insist on fixing the old kexec, because we don't use it on x86_64. But I'm willing to help if you think it needs to be fixed as well. Regards, -- Jiri Bohac SUSE Labs, Prague, Czechia From 1585366635754291144@xxx Wed Nov 29 02:44:02 +0000 2017 X-GM-THRID: 1583066928846548446 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread