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=-7.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED autolearn=unavailable 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 E14C1C433E1 for ; Tue, 26 May 2020 21:18:06 +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 B1BDE20888 for ; Tue, 26 May 2020 21:18:06 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="cHqU8CWw" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org B1BDE20888 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org 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:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=hPeVMmwHXJuiS6tKo63e/WxJeD5Vv/GtZobxMrlNJZ4=; b=cHqU8CWwfaGUII OShnBZlofuX6Epo+pK56BYlEhX0V1VgPmyCSthr89luFf3NDuTIjWgqbU8zM0+iUBKwOO2W7iarky aD/rI02ZIMUXzhERBwpzJPM9zBB4/zwq1nfdvftzdBLOoYTx6wtmU+Nz8/ClSHPFtXa5a7kPeZExf kPvi8ewUs7QdYTYxMR54CPiiMXUVfpvUVpeS9rGuw3XPPVhWkxDZ2F0E9iwQrRi71UrqPxOjNCph/ olQcaOJ4izBKOrLqZYmP4W225ifXEkEje5pK72kXDc/WGy0e658sj0oi3fl/xUddyyekhc9hn7r6p 1PV9GP2QI5NewqpTNxWQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jdgxZ-0001hm-Mr; Tue, 26 May 2020 21:18:05 +0000 Received: from mail-io1-f68.google.com ([209.85.166.68]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jdgxX-0001hO-7y; Tue, 26 May 2020 21:18:04 +0000 Received: by mail-io1-f68.google.com with SMTP id d7so23714715ioq.5; Tue, 26 May 2020 14:18:03 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=lVVBuWO3qFEQRVDuoZfe9DGQFjStmCr4atb2ZbHcO8E=; b=iuI7131Oil4BH59VFHV2kfjmSJjDqDajkoIe6/8Xl0268LhZ0etWEtpbuWw35kGDWz mcvQeq0xp4yL6y1TddLDUXFM6vg06eVDPV7qXpnimqQueJ4UXzkQXkA1UVzS0koNPr/C YV804QvY4dtbbflNweBzLSz9D5PFqY+f3dyyrtfaenxU+uKqq78XgXsFzgQInJrA/+XV d5y34dC4SccIN2AgO47JpdjQp/nSWg12+FIV4DfXAdnmBkexBZc60QcBH1+OJmtRGSGX SxIbi3rk8jwVER76Z3XZE3q91AqTGQdTmy5Xp/KlRSUrLDvrUcdNgsuKyGU6HsFNB54b W+rw== X-Gm-Message-State: AOAM533tN6w61Z+ZKhFuNZ7gCCBjHFRgW4Pu+TY9Xag8DLTXDtXDs9e9 uGyjAX25cjb9Vh1P/iVIEw== X-Google-Smtp-Source: ABdhPJwQrpel77itHrejAW3V1OCVBywOqev2wghw6aLmvMslUJY88azNYlGgJ1qYFsSmB5E2n/qkqA== X-Received: by 2002:a6b:7017:: with SMTP id l23mr4256428ioc.140.1590527882382; Tue, 26 May 2020 14:18:02 -0700 (PDT) Received: from xps15 ([64.188.179.252]) by smtp.gmail.com with ESMTPSA id x22sm567394ill.9.2020.05.26.14.18.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 26 May 2020 14:18:01 -0700 (PDT) Received: (nullmailer pid 389955 invoked by uid 1000); Tue, 26 May 2020 21:18:00 -0000 Date: Tue, 26 May 2020 15:18:00 -0600 From: Rob Herring To: chenzhou , James Morse Subject: Re: [PATCH v8 5/5] dt-bindings: chosen: Document linux,low-memory-range for arm64 kdump Message-ID: <20200526211800.GA352001@bogus> References: <20200521093805.64398-1-chenzhou10@huawei.com> <20200521093805.64398-6-chenzhou10@huawei.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200526_141803_285675_DF3F1C5C X-CRM114-Status: GOOD ( 23.81 ) 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: Simon Horman , John.p.donnelly@oracle.com, Baoquan He , Will Deacon , devicetree@vger.kernel.org, Catalin Marinas , Linux Doc Mailing List , kexec@lists.infradead.org, "linux-kernel@vger.kernel.org" , Ingo Molnar , Arnd Bergmann , Hanjun Guo , Thomas Gleixner , pkushwaha@marvell.com, dyoung@redhat.com, "moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE" 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 Fri, May 22, 2020 at 11:24:11AM +0800, chenzhou wrote: > Hi Rob, +James M (It's nice to Cc folks if you mention/quote them) > On 2020/5/21 21:29, Rob Herring wrote: > > On Thu, May 21, 2020 at 3:35 AM Chen Zhou wrote: > >> Add documentation for DT property used by arm64 kdump: > >> linux,low-memory-range. > >> "linux,low-memory-range" is an another memory region used for crash > >> dump kernel devices. > >> > >> Signed-off-by: Chen Zhou > >> --- > >> Documentation/devicetree/bindings/chosen.txt | 25 ++++++++++++++++++++ > >> 1 file changed, 25 insertions(+) > > chosen is now a schema documented here[1]. > Ok, that is, i don't need to modify the doc in kernel, just create a pull request in github [1]? > > > > >> diff --git a/Documentation/devicetree/bindings/chosen.txt b/Documentation/devicetree/bindings/chosen.txt > >> index 45e79172a646..bfe6fb6976e6 100644 > >> --- a/Documentation/devicetree/bindings/chosen.txt > >> +++ b/Documentation/devicetree/bindings/chosen.txt > >> @@ -103,6 +103,31 @@ While this property does not represent a real hardware, the address > >> and the size are expressed in #address-cells and #size-cells, > >> respectively, of the root node. > >> > >> +linux,low-memory-range > >> +---------------------- > >> +This property (arm64 only) holds a base address and size, describing a > >> +limited region below 4G. Similar to "linux,usable-memory-range", it is > >> +an another memory range which may be considered available for use by the > >> +kernel. > > Why can't you just add a range to "linux,usable-memory-range"? It > > shouldn't be hard to figure out which part is below 4G. > I did like this in my previous version, such as v5. After discussed with James, i modified it to the current way. > > We think the existing behavior should be unchanged, which helps with keeping compatibility with existing > user-space and older kdump kernels. > > The comments from James: > > linux,usable-memory-range = . > Won't this break if your kdump kernel doesn't know what the extra parameters are? > Or if it expects two ranges, but only gets one? These DT properties should be treated as > ABI between kernel versions, we can't really change it like this. > > I think the 'low' region is an optional-extra, that is never mapped by the first kernel. I > think the simplest thing to do is to add an 'linux,low-memory-range' that we > memblock_add() after memblock_cap_memory_range() has been called. > If its missing, or the new kernel doesn't know what its for, everything keeps working. I don't think there's a compatibility issue here though. The current kernel doesn't care if the property is longer than 1 base+size. It only checks if the size is less than 1 base+size. And yes, we can rely on that implementation detail. It's only an ABI if an existing user notices. Now, if the low memory is listed first, then an older kdump kernel would get a different memory range. If that's a problem, then define that low memory goes last. Rob _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel