Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp36341imm; Tue, 12 Jun 2018 17:59:32 -0700 (PDT) X-Google-Smtp-Source: ADUXVKIM5VYMj41zHwv26PAVy9wFWnXLak7Eyd3VL9L6voku7JvFoPxDPawWZE1OATgurWGYlfWv X-Received: by 2002:a62:a50c:: with SMTP id v12-v6mr2627965pfm.237.1528851572875; Tue, 12 Jun 2018 17:59:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528851572; cv=none; d=google.com; s=arc-20160816; b=mxTGM7yGUP6oUT69EEdl4cfnMEO1lqUIP1xiwtsu8C55IYGG2hYanbyyVfBF+5h4ID zV2l601FMGmJMWTxYwf3RmZSfovlLfG2LMlM9JTKYC4jfHNb5myti9w9v+RugiH2mbvX 8m3PE0R9pfKKCFJA2X/rh7tYPi/qihnPUVeDsAMzDS7Wffg+US3vt05gF9PiXNt8xEzP 6fMRL+JWlpr+3t9mW+0lSci8zyH+b0uz0fJMRTGBmmoRj5s2cd2yRD2z87k+WCXrYsnj ImtO0ZWpf4wUyF2pMffd/pJl1DD0bDKhYjAkzsmqhv5THO/4hCSc41fjnyXOSHJewAGK bTWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=bw7EPcHksVLHhznl2yJnAupdrrKiZStJlikTkXMkdug=; b=BpEP6nD2BwiuGbQ+dN1sdgvTNU+AjsfxTEgec9lxBG4etUL67xkd6iRmqSAi7XfSuK mOO9cWHWpqZobfD9nJOx11RfBRJtVCNNRDJNTOijb1N85ov1pJvw45JLsensy2RRYuJO OoUjk0bWbVroZlBMVwsAQVUOQldxGcHm/GP5lgfimJIUgFmDg/RK/B5X54Oxez/R6CES UqXpIoa49xVL9MmBmfsmHXnnSDMTr/nUVcggpt+ctux3iBok9cKzFee9kMkmMTlovE6t 8wNBsL5sgzhBdtA6z+sO/7dKbfyGDGBczNOKhnd7CBUvB4dXrE1CKfiv9F743ASUJN7Z Yk5Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=MQOYhSfU; 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 n9-v6si1137544pgf.497.2018.06.12.17.59.16; Tue, 12 Jun 2018 17:59:32 -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=MQOYhSfU; 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 S935009AbeFMA6v (ORCPT + 99 others); Tue, 12 Jun 2018 20:58:51 -0400 Received: from mail.kernel.org ([198.145.29.99]:43138 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934873AbeFMA6t (ORCPT ); Tue, 12 Jun 2018 20:58:49 -0400 Received: from mail-it0-f48.google.com (mail-it0-f48.google.com [209.85.214.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 3591F2086D; Wed, 13 Jun 2018 00:58:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1528851529; bh=buzK2ilUfmUUt4bukUGi7TizpqIyFfV8Td4QI8rjAk8=; h=In-Reply-To:References:From:Date:Subject:To:Cc:From; b=MQOYhSfUyzGtEzdFlHuyePq5W64doizfQNVZEbcr+w5AL1ZBU0ypLsYGM39SfZAVN 3nZazo6WJskJVhf7fdRkcn4AN6OXr6KSFoLED0mysgStxP5v2ehqnl+jDZpq7GrpNI T8MhbtKrjmzFMNEQMs+WO+SszVRwhNJWjqfBATwk= Received: by mail-it0-f48.google.com with SMTP id 188-v6so1715672ita.5; Tue, 12 Jun 2018 17:58:49 -0700 (PDT) X-Gm-Message-State: APt69E3a5jSmW7O2vCDj7epSxmmoRZj6Z1+2CTv6BH9CdVAXzB52FIvC LZdLgcWHKOFigOiYF+ja5zLiqRN/yPjWSahs4Q== X-Received: by 2002:a24:f04e:: with SMTP id p14-v6mr2763444iti.106.1528851528623; Tue, 12 Jun 2018 17:58:48 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a4f:6403:0:0:0:0:0 with HTTP; Tue, 12 Jun 2018 17:58:28 -0700 (PDT) In-Reply-To: <1528843243-29782-3-git-send-email-mars.cheng@mediatek.com> References: <1528843243-29782-1-git-send-email-mars.cheng@mediatek.com> <1528843243-29782-3-git-send-email-mars.cheng@mediatek.com> From: Rob Herring Date: Tue, 12 Jun 2018 18:58:28 -0600 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 2/2] arm64: dts: mediatek: add mt6765 support To: Mars Cheng Cc: Matthias Brugger , CC Hwang , Loda Chou , Miles Chen , Jades Shih , Yingjoe Chen , My Chuang , "linux-kernel@vger.kernel.org" , linux-mediatek@lists.infradead.org, devicetree@vger.kernel.org, wsd_upstream@mediatek.com Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 12, 2018 at 4:40 PM, Mars Cheng wrote: > This adds basic chip support for MT6765 SoC. > > Signed-off-by: Mars Cheng > --- > arch/arm64/boot/dts/mediatek/Makefile | 1 + > arch/arm64/boot/dts/mediatek/mt6765-evb.dts | 39 +++++++ > arch/arm64/boot/dts/mediatek/mt6765.dtsi | 148 +++++++++++++++++++++++++++ > 3 files changed, 188 insertions(+) > create mode 100644 arch/arm64/boot/dts/mediatek/mt6765-evb.dts > create mode 100644 arch/arm64/boot/dts/mediatek/mt6765.dtsi > > diff --git a/arch/arm64/boot/dts/mediatek/Makefile b/arch/arm64/boot/dts/mediatek/Makefile > index ac17f60..7506b0d 100644 > --- a/arch/arm64/boot/dts/mediatek/Makefile > +++ b/arch/arm64/boot/dts/mediatek/Makefile > @@ -1,6 +1,7 @@ > # SPDX-License-Identifier: GPL-2.0 > dtb-$(CONFIG_ARCH_MEDIATEK) += mt2712-evb.dtb > dtb-$(CONFIG_ARCH_MEDIATEK) += mt6755-evb.dtb > +dtb-$(CONFIG_ARCH_MEDIATEK) += mt6765-evb.dtb > dtb-$(CONFIG_ARCH_MEDIATEK) += mt6795-evb.dtb > dtb-$(CONFIG_ARCH_MEDIATEK) += mt6797-evb.dtb > dtb-$(CONFIG_ARCH_MEDIATEK) += mt7622-rfb1.dtb > diff --git a/arch/arm64/boot/dts/mediatek/mt6765-evb.dts b/arch/arm64/boot/dts/mediatek/mt6765-evb.dts > new file mode 100644 > index 0000000..e5efbe5 > --- /dev/null > +++ b/arch/arm64/boot/dts/mediatek/mt6765-evb.dts > @@ -0,0 +1,39 @@ > +// SPDX-License-Identifier: GPL-2.0 > +/* > + * Copyright (c) 2018 MediaTek Inc. > + * Author: Mars.C > + * > + * This program is free software; you can redistribute it and/or modify > + * it under the terms of the GNU General Public License version 2 as > + * published by the Free Software Foundation. > + * > + * This program is distributed in the hope that it will be useful, > + * but WITHOUT ANY WARRANTY; without even the implied warranty of > + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the > + * GNU General Public License for more details. With the SPDX tag, you can drop the license text. > + */ > + > +/dts-v1/; > +#include "mt6765.dtsi" > + > +/ { > + model = "MediaTek MT6765 EVB"; > + compatible = "mediatek,mt6765-evb", "mediatek,mt6765"; > + > + aliases { > + serial0 = &uart0; > + }; > + > + memory@40000000 { > + device_type = "memory"; > + reg = <0 0x40000000 0 0x1e800000>; > + }; > + > + chosen { > + stdout-path = "serial0:921600n8"; > + }; > +}; > + > +&uart0 { > + status = "okay"; > +}; > diff --git a/arch/arm64/boot/dts/mediatek/mt6765.dtsi b/arch/arm64/boot/dts/mediatek/mt6765.dtsi > new file mode 100644 > index 0000000..7222a5e > --- /dev/null > +++ b/arch/arm64/boot/dts/mediatek/mt6765.dtsi > @@ -0,0 +1,148 @@ > +// SPDX-License-Identifier: GPL-2.0 > +/* > + * Copyright (c) 2018 MediaTek Inc. > + * Author: Mars.C > + * > + * This program is free software; you can redistribute it and/or modify > + * it under the terms of the GNU General Public License version 2 as > + * published by the Free Software Foundation. > + * > + * This program is distributed in the hope that it will be useful, > + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the > + * GNU General Public License for more details. ditto > + */ > + > +#include > +#include > + > +/ { > + compatible = "mediatek,mt6765"; > + interrupt-parent = <&sysirq>; > + #address-cells = <2>; > + #size-cells = <2>; > + > + psci { > + compatible = "arm,psci-0.2"; > + method = "smc"; > + }; > + > + cpus { > + #address-cells = <1>; > + #size-cells = <0>; > + > + cpu0: cpu@0 { > + device_type = "cpu"; > + compatible = "arm,cortex-a53"; > + enable-method = "psci"; > + reg = <0x000>; > + }; > + > + cpu1: cpu@1 { > + device_type = "cpu"; > + compatible = "arm,cortex-a53"; > + enable-method = "psci"; > + reg = <0x001>; > + }; > + > + cpu2: cpu@2 { > + device_type = "cpu"; > + compatible = "arm,cortex-a53"; > + enable-method = "psci"; > + reg = <0x002>; > + }; > + > + cpu3: cpu@3 { > + device_type = "cpu"; > + compatible = "arm,cortex-a53"; > + enable-method = "psci"; > + reg = <0x003>; > + }; > + > + cpu4: cpu@100 { > + device_type = "cpu"; > + compatible = "arm,cortex-a53"; > + enable-method = "psci"; > + reg = <0x100>; > + }; > + > + cpu5: cpu@101 { > + device_type = "cpu"; > + compatible = "arm,cortex-a53"; > + enable-method = "psci"; > + reg = <0x101>; > + }; > + > + cpu6: cpu@102 { > + device_type = "cpu"; > + compatible = "arm,cortex-a53"; > + enable-method = "psci"; > + reg = <0x102>; > + }; > + > + cpu7: cpu@103 { > + device_type = "cpu"; > + compatible = "arm,cortex-a53"; > + enable-method = "psci"; > + reg = <0x103>; > + }; > + }; > + > + uart_clk: dummy26m { > + compatible = "fixed-clock"; > + clock-frequency = <26000000>; > + #clock-cells = <0>; > + }; > + > + timer { > + compatible = "arm,armv8-timer"; > + interrupt-parent = <&gic>; > + interrupts = + (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>, > + + (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>, > + + (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>, > + + (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>; > + }; > + > + sysirq: intpol-controller@10200a80 { This and others with an address should go under a simple-bus node. Node name should be 'interrupt-controller@...' > + compatible = "mediatek,mt6765-sysirq", > + "mediatek,mt6577-sysirq"; > + interrupt-controller; > + #interrupt-cells = <3>; > + interrupt-parent = <&gic>; > + reg = <0 0x10200a80 0 0x50>; > + }; > + > + gic: interrupt-controller@0c000000 { Drop the leading 0. > + compatible = "arm,gic-v3"; > + #interrupt-cells = <3>; > + #address-cells = <2>; > + #size-cells = <2>; > + #redistributor-regions = <1>; > + interrupt-parent = <&gic>; > + interrupt-controller; > + reg = <0 0x0c000000 0 0x40000>, // distributor > + <0 0x0c100000 0 0x200000>; // redistributor > + interrupts = ; > + }; > + > + uart0: serial@11002000 { > + compatible = "mediatek,mt6765-uart", > + "mediatek,mt6577-uart"; > + reg = <0 0x11002000 0 0x400>; > + interrupts = ; > + clocks = <&uart_clk>; > + status = "disabled"; > + }; > + > + uart1: serial@11003000 { > + compatible = "mediatek,mt6765-uart", > + "mediatek,mt6577-uart"; > + reg = <0 0x11003000 0 0x400>; > + interrupts = ; > + clocks = <&uart_clk>; > + status = "disabled"; > + }; > +}; > -- > 1.7.9.5 >