From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751509AbdANQLI (ORCPT ); Sat, 14 Jan 2017 11:11:08 -0500 Received: from mailgw02.mediatek.com ([210.61.82.184]:11937 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1751031AbdANQLH (ORCPT ); Sat, 14 Jan 2017 11:11:07 -0500 Message-ID: <1484410249.3343.25.camel@mtkswgap22> Subject: Re: [PATCH v2 5/6] arm: dts: mt2701: Add ethernet device node. From: Sean Wang To: John Crispin CC: Erin Lo , Matthias Brugger , , , , , Date: Sun, 15 Jan 2017 00:10:49 +0800 In-Reply-To: References: <1484296978-18572-1-git-send-email-erin.lo@mediatek.com> <1484296978-18572-6-git-send-email-erin.lo@mediatek.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 List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi John, the watchdog driver should just be the driver that includes reset functions called from driver and then send reset signal to abnormal hw.. however luckily ETHDMA_RST provided from watchdog is not required and even actually the latest driver didn't refer to the property no longer. So i will remove it from dtsi in the next version Sean On Sat, 2017-01-14 at 11:32 +0100, John Crispin wrote: > Hi Erin, > > small comment inline > > On 13/01/2017 09:42, Erin Lo wrote: > > From: Sean Wang > > > > Add ethernet device node for MT2701. > > > > Signed-off-by: Sean Wang > > Signed-off-by: Erin Lo > > --- > > arch/arm/boot/dts/mt2701-evb.dts | 40 ++++++++++++++++++++++++++++++++++++++++ > > arch/arm/boot/dts/mt2701.dtsi | 22 ++++++++++++++++++++++ > > 2 files changed, 62 insertions(+) > > > > diff --git a/arch/arm/boot/dts/mt2701-evb.dts b/arch/arm/boot/dts/mt2701-evb.dts > > index a483798..40abd3b 100644 > > --- a/arch/arm/boot/dts/mt2701-evb.dts > > +++ b/arch/arm/boot/dts/mt2701-evb.dts > > @@ -28,7 +28,47 @@ > > status = "okay"; > > }; > > > > +ð { > > + mac-address = [00 00 00 00 00 00]; > > + status = "okay"; > > + pinctrl-names = "default"; > > + pinctrl-0 = <&gmac1_pins>; > > + gmac1: mac@1 { > > + compatible = "mediatek,eth-mac"; > > + reg = <1>; > > + phy-handle = <&phy5>; > > + }; > > + > > + mdio-bus { > > + #address-cells = <1>; > > + #size-cells = <0>; > > + phy5: ethernet-phy@5 { > > + reg = <5>; > > + phy-mode = "rgmii-rxid"; > > + }; > > + }; > > +}; > > + > > &pio { > > + gmac1_pins: eth@0 { > > + pins_eth { > > + pinmux = , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + ; > > + }; > > + }; > > + > > spi_pins_a: spi0@0 { > > pins_spi { > > pinmux = , > > diff --git a/arch/arm/boot/dts/mt2701.dtsi b/arch/arm/boot/dts/mt2701.dtsi > > index 4f52019..3847f70 100644 > > --- a/arch/arm/boot/dts/mt2701.dtsi > > +++ b/arch/arm/boot/dts/mt2701.dtsi > > @@ -381,6 +381,28 @@ > > #clock-cells = <1>; > > }; > > > > + eth: ethernet@1b100000 { > > + compatible = "mediatek,mt7623-eth"; > > + reg = <0 0x1b100000 0 0x20000>; > > + interrupts = , > > + , > > + ; > > + clocks = <&topckgen CLK_TOP_ETHIF_SEL>, > > + <&apmixedsys CLK_APMIXED_TRGPLL>, > > + <ðsys CLK_ETHSYS_ESW>, > > + <ðsys CLK_ETHSYS_GP2>, > > + <ðsys CLK_ETHSYS_GP1>; > > + clock-names = "ethif", "trgpll", "esw", "gp2", "gp1"; > > + power-domains = <&scpsys MT2701_POWER_DOMAIN_ETH>; > > + resets = <&watchdog MT2701_TOPRGU_ETHDMA_RST>; > > are you sure this is correct ? on mt7623 we point the reset at ethsys > and not the watchdog. > > John > > > + reset-names = "eth"; > > + mediatek,ethsys = <ðsys>; > > + mediatek,pctl = <&syscfg_pctl_a>; > > + #address-cells = <1>; > > + #size-cells = <0>; > > + status = "disabled"; > > + }; > > + > > bdpsys: syscon@1c000000 { > > compatible = "mediatek,mt2701-bdpsys", "syscon"; > > reg = <0 0x1c000000 0 0x1000>; > > From mboxrd@z Thu Jan 1 00:00:00 1970 From: Sean Wang Subject: Re: [PATCH v2 5/6] arm: dts: mt2701: Add ethernet device node. Date: Sun, 15 Jan 2017 00:10:49 +0800 Message-ID: <1484410249.3343.25.camel@mtkswgap22> References: <1484296978-18572-1-git-send-email-erin.lo@mediatek.com> <1484296978-18572-6-git-send-email-erin.lo@mediatek.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org To: John Crispin Cc: Erin Lo , Matthias Brugger , devicetree@vger.kernel.org, srv_heupstream@mediatek.com, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org List-Id: devicetree@vger.kernel.org Hi John, the watchdog driver should just be the driver that includes reset functions called from driver and then send reset signal to abnormal hw.. however luckily ETHDMA_RST provided from watchdog is not required and even actually the latest driver didn't refer to the property no longer. So i will remove it from dtsi in the next version Sean On Sat, 2017-01-14 at 11:32 +0100, John Crispin wrote: > Hi Erin, > > small comment inline > > On 13/01/2017 09:42, Erin Lo wrote: > > From: Sean Wang > > > > Add ethernet device node for MT2701. > > > > Signed-off-by: Sean Wang > > Signed-off-by: Erin Lo > > --- > > arch/arm/boot/dts/mt2701-evb.dts | 40 ++++++++++++++++++++++++++++++++++++++++ > > arch/arm/boot/dts/mt2701.dtsi | 22 ++++++++++++++++++++++ > > 2 files changed, 62 insertions(+) > > > > diff --git a/arch/arm/boot/dts/mt2701-evb.dts b/arch/arm/boot/dts/mt2701-evb.dts > > index a483798..40abd3b 100644 > > --- a/arch/arm/boot/dts/mt2701-evb.dts > > +++ b/arch/arm/boot/dts/mt2701-evb.dts > > @@ -28,7 +28,47 @@ > > status = "okay"; > > }; > > > > +ð { > > + mac-address = [00 00 00 00 00 00]; > > + status = "okay"; > > + pinctrl-names = "default"; > > + pinctrl-0 = <&gmac1_pins>; > > + gmac1: mac@1 { > > + compatible = "mediatek,eth-mac"; > > + reg = <1>; > > + phy-handle = <&phy5>; > > + }; > > + > > + mdio-bus { > > + #address-cells = <1>; > > + #size-cells = <0>; > > + phy5: ethernet-phy@5 { > > + reg = <5>; > > + phy-mode = "rgmii-rxid"; > > + }; > > + }; > > +}; > > + > > &pio { > > + gmac1_pins: eth@0 { > > + pins_eth { > > + pinmux = , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + ; > > + }; > > + }; > > + > > spi_pins_a: spi0@0 { > > pins_spi { > > pinmux = , > > diff --git a/arch/arm/boot/dts/mt2701.dtsi b/arch/arm/boot/dts/mt2701.dtsi > > index 4f52019..3847f70 100644 > > --- a/arch/arm/boot/dts/mt2701.dtsi > > +++ b/arch/arm/boot/dts/mt2701.dtsi > > @@ -381,6 +381,28 @@ > > #clock-cells = <1>; > > }; > > > > + eth: ethernet@1b100000 { > > + compatible = "mediatek,mt7623-eth"; > > + reg = <0 0x1b100000 0 0x20000>; > > + interrupts = , > > + , > > + ; > > + clocks = <&topckgen CLK_TOP_ETHIF_SEL>, > > + <&apmixedsys CLK_APMIXED_TRGPLL>, > > + <ðsys CLK_ETHSYS_ESW>, > > + <ðsys CLK_ETHSYS_GP2>, > > + <ðsys CLK_ETHSYS_GP1>; > > + clock-names = "ethif", "trgpll", "esw", "gp2", "gp1"; > > + power-domains = <&scpsys MT2701_POWER_DOMAIN_ETH>; > > + resets = <&watchdog MT2701_TOPRGU_ETHDMA_RST>; > > are you sure this is correct ? on mt7623 we point the reset at ethsys > and not the watchdog. > > John > > > + reset-names = "eth"; > > + mediatek,ethsys = <ðsys>; > > + mediatek,pctl = <&syscfg_pctl_a>; > > + #address-cells = <1>; > > + #size-cells = <0>; > > + status = "disabled"; > > + }; > > + > > bdpsys: syscon@1c000000 { > > compatible = "mediatek,mt2701-bdpsys", "syscon"; > > reg = <0 0x1c000000 0 0x1000>; > > From mboxrd@z Thu Jan 1 00:00:00 1970 From: sean.wang@mediatek.com (Sean Wang) Date: Sun, 15 Jan 2017 00:10:49 +0800 Subject: [PATCH v2 5/6] arm: dts: mt2701: Add ethernet device node. In-Reply-To: References: <1484296978-18572-1-git-send-email-erin.lo@mediatek.com> <1484296978-18572-6-git-send-email-erin.lo@mediatek.com> Message-ID: <1484410249.3343.25.camel@mtkswgap22> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Hi John, the watchdog driver should just be the driver that includes reset functions called from driver and then send reset signal to abnormal hw.. however luckily ETHDMA_RST provided from watchdog is not required and even actually the latest driver didn't refer to the property no longer. So i will remove it from dtsi in the next version Sean On Sat, 2017-01-14 at 11:32 +0100, John Crispin wrote: > Hi Erin, > > small comment inline > > On 13/01/2017 09:42, Erin Lo wrote: > > From: Sean Wang > > > > Add ethernet device node for MT2701. > > > > Signed-off-by: Sean Wang > > Signed-off-by: Erin Lo > > --- > > arch/arm/boot/dts/mt2701-evb.dts | 40 ++++++++++++++++++++++++++++++++++++++++ > > arch/arm/boot/dts/mt2701.dtsi | 22 ++++++++++++++++++++++ > > 2 files changed, 62 insertions(+) > > > > diff --git a/arch/arm/boot/dts/mt2701-evb.dts b/arch/arm/boot/dts/mt2701-evb.dts > > index a483798..40abd3b 100644 > > --- a/arch/arm/boot/dts/mt2701-evb.dts > > +++ b/arch/arm/boot/dts/mt2701-evb.dts > > @@ -28,7 +28,47 @@ > > status = "okay"; > > }; > > > > +ð { > > + mac-address = [00 00 00 00 00 00]; > > + status = "okay"; > > + pinctrl-names = "default"; > > + pinctrl-0 = <&gmac1_pins>; > > + gmac1: mac at 1 { > > + compatible = "mediatek,eth-mac"; > > + reg = <1>; > > + phy-handle = <&phy5>; > > + }; > > + > > + mdio-bus { > > + #address-cells = <1>; > > + #size-cells = <0>; > > + phy5: ethernet-phy at 5 { > > + reg = <5>; > > + phy-mode = "rgmii-rxid"; > > + }; > > + }; > > +}; > > + > > &pio { > > + gmac1_pins: eth at 0 { > > + pins_eth { > > + pinmux = , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + , > > + ; > > + }; > > + }; > > + > > spi_pins_a: spi0 at 0 { > > pins_spi { > > pinmux = , > > diff --git a/arch/arm/boot/dts/mt2701.dtsi b/arch/arm/boot/dts/mt2701.dtsi > > index 4f52019..3847f70 100644 > > --- a/arch/arm/boot/dts/mt2701.dtsi > > +++ b/arch/arm/boot/dts/mt2701.dtsi > > @@ -381,6 +381,28 @@ > > #clock-cells = <1>; > > }; > > > > + eth: ethernet at 1b100000 { > > + compatible = "mediatek,mt7623-eth"; > > + reg = <0 0x1b100000 0 0x20000>; > > + interrupts = , > > + , > > + ; > > + clocks = <&topckgen CLK_TOP_ETHIF_SEL>, > > + <&apmixedsys CLK_APMIXED_TRGPLL>, > > + <ðsys CLK_ETHSYS_ESW>, > > + <ðsys CLK_ETHSYS_GP2>, > > + <ðsys CLK_ETHSYS_GP1>; > > + clock-names = "ethif", "trgpll", "esw", "gp2", "gp1"; > > + power-domains = <&scpsys MT2701_POWER_DOMAIN_ETH>; > > + resets = <&watchdog MT2701_TOPRGU_ETHDMA_RST>; > > are you sure this is correct ? on mt7623 we point the reset at ethsys > and not the watchdog. > > John > > > + reset-names = "eth"; > > + mediatek,ethsys = <ðsys>; > > + mediatek,pctl = <&syscfg_pctl_a>; > > + #address-cells = <1>; > > + #size-cells = <0>; > > + status = "disabled"; > > + }; > > + > > bdpsys: syscon at 1c000000 { > > compatible = "mediatek,mt2701-bdpsys", "syscon"; > > reg = <0 0x1c000000 0 0x1000>; > >