Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp2096168imm; Thu, 27 Sep 2018 07:22:38 -0700 (PDT) X-Google-Smtp-Source: ACcGV608fQi7VPT9sTpqJK5OUAc+Y1j2/BYAbCpo5AtOkEAfVgVwYwkBMfM7c4+yLuL67QwYoSWq X-Received: by 2002:a62:c40f:: with SMTP id y15-v6mr11278647pff.161.1538058158345; Thu, 27 Sep 2018 07:22:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538058158; cv=none; d=google.com; s=arc-20160816; b=W7zVdF2jUelCdXs3rtP+ItutMRS4rBQ9PAOT7W2yS0f9Oja14aYUN7PhkhCs5jWSMx FeXB/9xuFqGiayg/ekN3K/11J462Wcmbfr54XuzuqaKiX54oE8lZR+MhynIUabtMgOV3 86FWvKYmdqHj2lvyLRQ19ZXfDFYFIIpHLveEhFUaBYF/qFe1dXElm6f1oUtZIeVEaVkx GTsU40RooMMDIHdvAm8Sn9gjJQXlP+uZ7+qM4zmtEC9A5nvNTa3bL91baGerp/5SfUEG erXRZzjGnbj6GjFkIxsfrlpYF7AqU4RbNwQ7C56P2oMzqlBgU9pB9wcBWWhWu9W5NwIz 82xg== 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 :user-agent:message-id:date:cc:to:from:subject:dkim-signature; bh=6KX6f0UnMSGIM+35bMCzcRnBST5BWUrUTtsGGwvAgAM=; b=wjuuRbL1H8vQVx6AMuUHBYDffXDSX09CJ4aNKTF56Sqs0NdeztwwTnlQ+N6ff3WJw6 X5dy3xeRn/LubsB+QG/AwEfX7kTvzHxsVqdfPa59TckUt/WqGmXUxwPz1M/okbjfjAFU d+BCAzKX7F8q+mM3B9mK+Mdksz7E4vN/FoHNo0nah7gq/OyykCAyt0+gC71LFqBtSOZg 0VUAy7f/x4z7hqukRo9Cg1Z291EvwXQrP2EwKwwox5JWHoFnp60orP5JrWtckXCZ9Bi4 /n7ew4MlMiAw63lrPD7HMJB5PQyL0CKh+wDuc8c1HiV1iPbjgcoHxpFuOevNoKBIgTtf rX3w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="lMF/AHop"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m64-v6si2517295pfc.17.2018.09.27.07.22.11; Thu, 27 Sep 2018 07:22:38 -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; dkim=pass header.i=@kernel.org header.s=default header.b="lMF/AHop"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727771AbeI0UkU (ORCPT + 99 others); Thu, 27 Sep 2018 16:40:20 -0400 Received: from mail.kernel.org ([198.145.29.99]:41250 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727263AbeI0UkU (ORCPT ); Thu, 27 Sep 2018 16:40:20 -0400 Received: from localhost (173-25-171-118.client.mchsi.com [173.25.171.118]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 3F9CE21531; Thu, 27 Sep 2018 14:21:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1538058110; bh=IGYifjdq7PLyF9YCBvjqmzsSAaBorejftAxtkGDDm+M=; h=Subject:From:To:Cc:Date:From; b=lMF/AHopqCufRNLj1huc3VRh6irO9SRSVWn1+MkfiCzrW6umZmcSvahZeUVzcoIyR GF+XiPsk7Dor0V7o80lhyXd8yamhOvQvYIfx9e2Mf8h2inNg1W64aTmRdaZTHnkzWt YAd6+NWOccHOQDHP0hAtzsBFPtJ1AiX8ec8RbsCI= Subject: [PATCH 0/3] find_next_iomem_res() fixes From: Bjorn Helgaas To: linux-kernel@vger.kernel.org Cc: Lianbo Jiang , Vivek Goyal , kexec@lists.infradead.org, tglx@linutronix.de, mingo@redhat.com, hpa@zytor.com, x86@kernel.org, akpm@linux-foundation.org, dan.j.williams@intel.com, thomas.lendacky@amd.com, baiyaowei@cmss.chinamobile.com, tiwai@suse.de, bp@suse.de, brijesh.singh@amd.com, dyoung@redhat.com, bhe@redhat.com Date: Thu, 27 Sep 2018 09:21:49 -0500 Message-ID: <153805773703.1157.14773321497580233478.stgit@bhelgaas-glaptop.roam.corp.google.com> User-Agent: StGit/0.18 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org These fix: - A kexec off-by-one error that we probably never see in practice (only affects a resource starting at exactly 640KB). - A corner case in walk_iomem_res_desc(), walk_system_ram_res(), etc that we probably also never see in practice (only affects a single byte resource at the very end of the region we're searching) - An issue in walk_iomem_res_desc() that apparently causes a kdump issue (see Lianbo's note at [1]). I think we need to fix the kdump issue either by these patches (specifically the last one) or by the patch Lianbo posted [2]. I'm hoping to avoid deciding and merging these myself, but I'm not sure who really wants to own kernel/resource.c. [1] https://lore.kernel.org/lkml/01551d06-c421-5df3-b19f-fc66f3639e4f@redhat.com [2] https://lore.kernel.org/lkml/20180921073211.20097-2-lijiang@redhat.com --- Bjorn Helgaas (3): x86/kexec: Correct KEXEC_BACKUP_SRC_END off-by-one error resource: Include resource end in walk_*() interfaces resource: Fix find_next_iomem_res() iteration issue arch/x86/include/asm/kexec.h | 2 - kernel/resource.c | 96 ++++++++++++++++++------------------------ 2 files changed, 43 insertions(+), 55 deletions(-)