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=-0.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS 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 7085FC76192 for ; Tue, 16 Jul 2019 19:26:48 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 4345020880 for ; Tue, 16 Jul 2019 19:26:48 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="IocULp/k"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=soleen.com header.i=@soleen.com header.b="Vs748xKj" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4345020880 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=soleen.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:To:Subject:Message-ID:Date:From: In-Reply-To:References:MIME-Version:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=//ffuNg9+iwbZvAwqya8UNuPUQ4/liqEzcTqQ2uhowQ=; b=IocULp/kcVFhbh uBye9W90LQ9jQSIlfn/LRqhDD/R5STKYi0uTT/m+Koc8V4x6LPmUjNufOgJgoHmnrY2BBauQbMqAz FoInna2erc01I7dtkLIp8Z99P8jKXmYLXgZcUqb5zr+sv25ZHkIxZt45sw/8XCsdD0Js8SCk6pdew TwWfBBaeqCguUscUpw3qaAYQrteqq9ocnPdcSA6eVBMsM0i6pv6bSEYUZYqlfd1NlaTSoGQILl0Uj feZ6+q3hdK1DFQLTNCaucMAPqq7qBn+gIXswymRtpX+b3dl/FThDP3C6veuM4jb180hDDtB1/eoN3 TzRdfuHd0abQS5iygzGw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hnT65-00085x-6y; Tue, 16 Jul 2019 19:26:45 +0000 Received: from mail-ed1-x543.google.com ([2a00:1450:4864:20::543]) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hnT5s-0007sg-5U for linux-arm-kernel@lists.infradead.org; Tue, 16 Jul 2019 19:26:34 +0000 Received: by mail-ed1-x543.google.com with SMTP id w20so21617445edd.2 for ; Tue, 16 Jul 2019 12:26:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=soleen.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=tAMcer/o92OFVt119e6yifT3N3R3a5gfAH/A3YrhyPY=; b=Vs748xKj2hviUzrn4HuUZQJnzrom7YeHQzEBrRW3chVySiB4qVTO8ok+BmdZd/0Hkp ds9XA1cCfWwC0UUGBF6Uec9vZkeWsZumHKY7C7CWILZXjTQYfi83Zxqp386+dGJXg2sk 5m5/QXQPcctDZzGAHeVD4jUurF6StkJcJsA7S2MuvDb430nXwLW8oKl0zcWIv1k0X/QH LzPEQ87Qpbify0cfq0eAlzE32H7JJ2SbOspS9aGI/LYBh0ZlwCWHBL53kYyGcoxYeWHR +7odcl9aj6ERiBzV52OHC4hZZ5DMEtL4b3AUe+wrmPJKnLEQGGU/9Wk8KuDfgZOiqP1t uU8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=tAMcer/o92OFVt119e6yifT3N3R3a5gfAH/A3YrhyPY=; b=bTXMRdG9SCKolzuYwCdh6QueSN87mfor8Z2xi6EtQ9DqEpzbDD+4zUNc6Q8x7T045h pSrAPsBQFGgnStnRI/gvWm1pd2rL2tp3bQgYHKbFpzraMUWbnjO1otYZPKGdyhIQo/p5 3aEiIrgH+ieUDV33iGrFevzMzptipKVslmLMl0nYAE/hMlM06KVw9CjO1vckoifQ1kbE 5odUiYqgsOn2WmcQetCeB4Yd5Ds+9KHrTR0/+9CT1Ss65qvU5LeghNGba4F4ERn1Dmo4 HEYTeoqga8T5pDUgQyK0vtD+twx2k1KmHNLR15vEHccA3HS2XS2AOmNtDAVrfhe7IHEP 0JoQ== X-Gm-Message-State: APjAAAX4Uq7B1jt0kCqQqstgrAJDH8ATIF4lGB8iefw9okf86qIwGWwr kXyAyXpqcUthQlQItObmJww5ybUYNqGnkL3ZQlk= X-Google-Smtp-Source: APXvYqygM7bjRf5/q1NDCo6IIUu3Bn2fMgeKwA4WxUFuObu4eHPKtzeqoPz3euiFSNDs1KzoNjNAGmGQjtQzrhuFJUM= X-Received: by 2002:a50:fb0a:: with SMTP id d10mr5479243edq.124.1563305190476; Tue, 16 Jul 2019 12:26:30 -0700 (PDT) MIME-Version: 1.0 References: <20190716165641.6990-1-pasha.tatashin@soleen.com> In-Reply-To: From: Pavel Tatashin Date: Tue, 16 Jul 2019 15:26:19 -0400 Message-ID: Subject: Re: [RFC v1 0/4] arm64: MMU enabled kexec kernel relocation To: Bhupesh Sharma X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190716_122632_650077_FAE0341E X-CRM114-Status: GOOD ( 25.96 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Sasha Levin , Jonathan Corbet , Catalin Marinas , Linux Doc Mailing List , kexec mailing list , Linux Kernel Mailing List , James Morris , Eric Biederman , will@kernel.org, linux-arm-kernel Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, Jul 16, 2019 at 3:14 PM Bhupesh Sharma wrote: > > Hi Pavel, > > On Tue, Jul 16, 2019 at 10:26 PM Pavel Tatashin > wrote: > > > > Added identity mapped page table, and keep MMU enabled while > > kernel is being relocated from sparse pages to the final > > destination during kexec. > > > > More description about the problem I am trying to solve here, can be > > found here: > > https://lore.kernel.org/lkml/20190709182014.16052-1-pasha.tatashin@soleen.com/ > > > > This patch series works in terms, that I can kexec-reboot both in QEMU > > and on a physical machine. However, I do not see performance improvement > > during relocation. The performance is just as slow as before with disabled > > caches. > > Thanks for the patchset, but if the changes still don't positively > impact the kexec-reboot timings, I am not sure we if gain by adding > these to the kernel. Hi Bhupesh, I am not asking to add these to the kernel (hence RFC), I am looking for help to figure out why the relocation is still slow, once that is understood I will submit the patches for integration. My previous patch series fixed the relocation problem by pre-reserving space, but because the culprit of the problem was narrowed down to disabled caches it was decided that a better fix would be to do relocation with MMU still enabled, this is why I created this new series. > > Like I mentioned in the previous threads, we have been carrying some > relevant fixes for the same in Linux distros. I have been trying to > find time to fix them and send them upstream, but I am caught up with > some nasty kexec_file_load() issues on arm64 currently. As I understood, the fixes were for slow purgatory checksum checking, and not for relocation of there kernel. Are you saying redhat is carrying some patches that address slow relocation problem as well? Thank you, Pasha > > So, I will find some time to work on them (may be next week) and will > Cc you when I post them out after some checks on real physical > hardware. > > Thanks, > Bhupesh > > > Am I missing something? Perhaps, there is some flag that I should also > > enable in page table? Please provide me with any suggestions. > > > > Pavel Tatashin (4): > > arm64, mm: identity mapped page table > > arm64, kexec: interface preparation for mmu enabled kexec > > arm64, kexec: add kexec's own identity page table > > arm64: Keep MMU on while kernel is being relocated > > > > arch/arm64/include/asm/ident_map.h | 26 ++++++ > > arch/arm64/include/asm/kexec.h | 5 +- > > arch/arm64/kernel/cpu-reset.S | 8 -- > > arch/arm64/kernel/cpu-reset.h | 7 +- > > arch/arm64/kernel/machine_kexec.c | 128 +++++++++++++++++++++------- > > arch/arm64/kernel/relocate_kernel.S | 36 +++++--- > > arch/arm64/mm/Makefile | 1 + > > arch/arm64/mm/ident_map.c | 99 +++++++++++++++++++++ > > 8 files changed, 255 insertions(+), 55 deletions(-) > > create mode 100644 arch/arm64/include/asm/ident_map.h > > create mode 100644 arch/arm64/mm/ident_map.c > > > > -- > > 2.22.0 > > > > > > _______________________________________________ > > kexec mailing list > > kexec@lists.infradead.org > > http://lists.infradead.org/mailman/listinfo/kexec _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel