Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp1708755imm; Fri, 11 May 2018 22:29:26 -0700 (PDT) X-Google-Smtp-Source: AB8JxZoY8xYyMSV4oOxa+KEFLKjv5CYZAD0DR8BbLi7qqI6TVrN8EAPiB7lcAfO8uobwv0CF6btt X-Received: by 2002:a62:3d54:: with SMTP id k81-v6mr1734154pfa.193.1526102966074; Fri, 11 May 2018 22:29:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526102966; cv=none; d=google.com; s=arc-20160816; b=0xWnfLjimm3Y4c3zj70259lCQOA7Bqixvh3Ye+s1ZRm3unsvFjpM3yWo2DoryP5EfN rSk6fzUdBRWYoxo8MoZGmg3relE++f+A3+j1hKK54KBoRw33gSKpIlgxFBtBW76gjrlV Ul1FkOOYY7v6I7OWJJ1N93yFHzBfj8cmFkXnkbZ+s/gzWvlb5iQb514h8ABEjoQj2SIC QRcV9hTueSw+I6sBWZuKlmcLNp9uIfQ4FnrWAYpSc5xR9EHZsqAnwtZWz/ar6wILGX4w DhVQcLpzeeNVies8QMm6/hMVezk5xKm6KxSykkm80L8HtoKnwqTmnS51qSrUYX50B8Z9 ZPow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :references:in-reply-to:date:cc:to:from:subject:message-id :arc-authentication-results; bh=LijYrHavUOulVaUCTWN6VLB958UEatAjpefP3kRstWo=; b=FK+8HORtccMfgX1tjQ6/QXDU7gEC6DMbGMuyKb17hp4+eSM9Hem4+kD2GAbaECg9QZ stQ+SEsOW3iVvOsZSHt6yRmA1WmjuFzF5JVcKT9fp57oZsZYv6ra5hTF4Z8018ChvmeW z4XE7Olbom1tNg1u2i2Fu5wFvre6Ey2gvZWMWCjxh56S0brGT697eJs/8a/BTbq2uc+8 MtD1Gc6uebqQRkmolzesSSbqX+h1RiQ0REd1lNHDD/eDSuaDYt0CeFLNwWB81prXbaPK j0pXfHC/xlKTjZDn1cloXbF9J4uWMVjrfDb92P8XUkSrr/6vqbpNKWq3IYEpottM6MZt S1tg== 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 t13-v6si59615pgq.358.2018.05.11.22.28.43; Fri, 11 May 2018 22:29:26 -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; 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 S1750854AbeELF2d (ORCPT + 99 others); Sat, 12 May 2018 01:28:33 -0400 Received: from mailgw02.mediatek.com ([210.61.82.184]:53765 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1750722AbeELF2b (ORCPT ); Sat, 12 May 2018 01:28:31 -0400 X-UUID: 0e62b9a22dd84c5fad6758f09bb4a92e-20180512 Received: from mtkcas09.mediatek.inc [(172.21.101.178)] by mailgw02.mediatek.com (envelope-from ) (mhqrelay.mediatek.com ESMTP with TLS) with ESMTP id 935934310; Sat, 12 May 2018 13:28:29 +0800 Received: from mtkcas07.mediatek.inc (172.21.101.84) by mtkexhb01.mediatek.inc (172.21.101.102) with Microsoft SMTP Server (TLS) id 15.0.1210.3; Sat, 12 May 2018 13:28:27 +0800 Received: from mtkcas07.mediatek.inc (172.21.101.84) by mtkcas07.mediatek.inc (172.21.101.84) with Microsoft SMTP Server (TLS) id 15.0.1210.3; Sat, 12 May 2018 13:28:26 +0800 Received: from [172.21.77.33] (172.21.77.33) by mtkcas07.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1210.3 via Frontend Transport; Sat, 12 May 2018 13:28:26 +0800 Message-ID: <1526102906.18877.42.camel@mtkswgap22> Subject: Re: [PATCH v2 03/12] arm: dts: mt7623: fix invalid memory node being generated From: Sean Wang To: Matthias Brugger CC: , , , , , , Date: Sat, 12 May 2018 13:28:26 +0800 In-Reply-To: <4dcb0435-1f98-0753-0feb-d17ad02077ae@gmail.com> References: <4dcb0435-1f98-0753-0feb-d17ad02077ae@gmail.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.2.3-0ubuntu6 Content-Transfer-Encoding: 7bit MIME-Version: 1.0 X-MTK: N Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 2018-05-11 at 17:03 +0200, Matthias Brugger wrote: > > On 04/11/2018 10:53 AM, sean.wang@mediatek.com wrote: > > From: Sean Wang > > > > Below two wrong nodes in existing DTS files would cause a fail boot since > > in fact the address 0 is not the correct place the memory device locates > > at. > > > > memory { > > device_type = "memory"; > > reg = <0x0 0x0 0x0 0x0>; > > }; > > > > memory@80000000 { > > reg = <0x0 0x80000000 0x0 0x40000000>; > > }; > > > > In order to avoid having a memory node starting at address 0, we can't > > include file skeleton64.dtsi and instead need to explicitly manually > > define a few of properties the DTS relies on such as #address-cells > > and #size-cells in root node and device_type in the node memory@80000000. > > > > Cc: stable@vger.kernel.org > > Fixes: 31ac0d69a1d4 ("ARM: dts: mediatek: add MT7623 basic support") > > Signed-off-by: Sean Wang > > Cc: Rob Herring > > --- > > arch/arm/boot/dts/mt7623.dtsi | 3 ++- > > arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts | 1 + > > arch/arm/boot/dts/mt7623n-rfb.dtsi | 1 + > > 3 files changed, 4 insertions(+), 1 deletion(-) > > > > merged. We would need this at least for mt2701 as well, correct? > Would you mind to provide a patch. > > Regards, > Matthias > Thanks! I totally think the same problem could happen on mt2701, so I'm happy to come up with a patch for that. Sean > > diff --git a/arch/arm/boot/dts/mt7623.dtsi b/arch/arm/boot/dts/mt7623.dtsi > > index fec4715..406a9f3 100644 > > --- a/arch/arm/boot/dts/mt7623.dtsi > > +++ b/arch/arm/boot/dts/mt7623.dtsi > > @@ -15,11 +15,12 @@ > > #include > > #include > > #include > > -#include "skeleton64.dtsi" > > > > / { > > compatible = "mediatek,mt7623"; > > interrupt-parent = <&sysirq>; > > + #address-cells = <2>; > > + #size-cells = <2>; > > > > cpu_opp_table: opp-table { > > compatible = "operating-points-v2"; > > diff --git a/arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts b/arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts > > index bbf56f8..5938e4c 100644 > > --- a/arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts > > +++ b/arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts > > @@ -109,6 +109,7 @@ > > }; > > > > memory@80000000 { > > + device_type = "memory"; > > reg = <0 0x80000000 0 0x40000000>; > > }; > > }; > > diff --git a/arch/arm/boot/dts/mt7623n-rfb.dtsi b/arch/arm/boot/dts/mt7623n-rfb.dtsi > > index a199ae7..343e8ef 100644 > > --- a/arch/arm/boot/dts/mt7623n-rfb.dtsi > > +++ b/arch/arm/boot/dts/mt7623n-rfb.dtsi > > @@ -40,6 +40,7 @@ > > }; > > > > memory@80000000 { > > + device_type = "memory"; > > reg = <0 0x80000000 0 0x40000000>; > > }; > > > >