From patchwork Fri Aug 26 20:23:13 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergei Shtylyov X-Patchwork-Id: 9302027 X-Patchwork-Delegate: horms@verge.net.au Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id CDD2D608A7 for ; Fri, 26 Aug 2016 20:24:09 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C082F29651 for ; Fri, 26 Aug 2016 20:24:09 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B531729653; Fri, 26 Aug 2016 20:24:09 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4F34E29652 for ; Fri, 26 Aug 2016 20:24:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751449AbcHZUYG (ORCPT ); Fri, 26 Aug 2016 16:24:06 -0400 Received: from mail-lf0-f51.google.com ([209.85.215.51]:34950 "EHLO mail-lf0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751584AbcHZUXR (ORCPT ); Fri, 26 Aug 2016 16:23:17 -0400 Received: by mail-lf0-f51.google.com with SMTP id f93so64320326lfi.2 for ; Fri, 26 Aug 2016 13:23:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cogentembedded-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:organization:user-agent :in-reply-to:references:mime-version:content-transfer-encoding; bh=XDyWUsn8T9djG0pyozuNOR5W8HJ2qrhaLqg6xVCnWMA=; b=T1nbbFAQlNEHkM+smi8mf7QgM8lATvVCh/ajwdse3p87Y2mJdERrrCqdEwlyrXWr6V 6s1SXVwh0ekDgDpNH+cIop86lJ1dYxFnymcbTGvtlc7AYgmsqt3MazawENayK5wfSTUS bGrPRvAcand/W0xmYClvY0oLZOLw7ZBDCUUuKe6JcZAjnfRNRb0s4nH4VJkZUqQjZ36h jdLujX84xHf5CaWxN9q8zBUSnfkstfyIWAf83r4eEzUsIYPmXCBVDgN8bP45fidjunZd khYfez+n0gHC0okRReX6JruJZ7Lgh++1al6O7Jt1uOE+x8fKiHh49dfSv4c2y6reqU+m gGGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:organization :user-agent:in-reply-to:references:mime-version :content-transfer-encoding; bh=XDyWUsn8T9djG0pyozuNOR5W8HJ2qrhaLqg6xVCnWMA=; b=Jry7WBurjKaH+NXQAFollzyegi/MoVHrdiUCy11vETAwylrCCzlcrNC/bYljHFdMWQ LtJxzzL1zkIGBM6G4paTdRYWTIITqtAsIOVJ72kK3q1tJWMPapND78jKxHTKdPbExZuo tVkt+wjGEp+sCQldFFVJxdwZQw0h0SCRnu/cPeyMbA11+fE4FoCczpr5oZ578ARAAoX4 PXdfPoVOAX+kI3/1q5sYcSBP6vA1yjGTnP17p7vpBAfoCiZ/DKxlUSYwhfmR5HebxQYQ m+kTuD6RoVXSl5G0ynDzvMGcB5jfNQsMh7w16pFjskLhxqB7pdeG5H0ts3isghIiIclX EXxQ== X-Gm-Message-State: AE9vXwPSfL8Ub/WFDYRZ3+/nTIbXKpXPZ8UyniK9jF2nh0dJ3lYJQuz5AaadRLE9dyFOcA== X-Received: by 10.46.1.222 with SMTP id f91mr2158168lji.1.1472242995548; Fri, 26 Aug 2016 13:23:15 -0700 (PDT) Received: from wasted.cogentembedded.com ([31.173.81.21]) by smtp.gmail.com with ESMTPSA id 205sm4322030ljj.47.2016.08.26.13.23.14 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 26 Aug 2016 13:23:14 -0700 (PDT) From: Sergei Shtylyov To: horms@verge.net.au, linux-renesas-soc@vger.kernel.org, robh+dt@kernel.org, mark.rutland@arm.com, devicetree@vger.kernel.org Cc: magnus.damm@gmail.com, linux@arm.linux.org.uk, linux-arm-kernel@lists.infradead.org Subject: [PATCH 3/3] ARM: dts: wheat: add Ethernet support Date: Fri, 26 Aug 2016 23:23:13 +0300 Message-ID: <6321460.7sCGaKUd5m@wasted.cogentembedded.com> Organization: Cogent Embedded Inc. User-Agent: KMail/4.14.10 (Linux/4.6.6-200.fc23.x86_64; KDE/4.14.20; x86_64; ; ) In-Reply-To: <3665116.9BjHTnhfR3@wasted.cogentembedded.com> References: <3665116.9BjHTnhfR3@wasted.cogentembedded.com> MIME-Version: 1.0 Sender: linux-renesas-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-renesas-soc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP R8A7792 SoC doesn't have the EtherMAC core, so SMSC LAN89218 Ethernet chip was used instead on the Wheat debug board; this chip is compatible with SMSC LAN9115 for which there's a (device tree aware) driver. Describe the chip in the Wheat device tree unconditionally (the driver should fail the probe if the debug board isn't connected); enable DHCP and NFS root in the command line for the kernel boot... Based on the original (and large) patch by Vladimir Barinov . Signed-off-by: Sergei Shtylyov Reviewed-by: Geert Uytterhoeven --- arch/arm/boot/dts/r8a7792-wheat.dts | 38 +++++++++++++++++++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) Index: renesas/arch/arm/boot/dts/r8a7792-wheat.dts =================================================================== --- renesas.orig/arch/arm/boot/dts/r8a7792-wheat.dts +++ renesas/arch/arm/boot/dts/r8a7792-wheat.dts @@ -21,7 +21,7 @@ }; chosen { - bootargs = "ignore_loglevel"; + bootargs = "ignore_loglevel rw root=/dev/nfs ip=dhcp"; stdout-path = "serial0:115200n8"; }; @@ -29,6 +29,31 @@ device_type = "memory"; reg = <0 0x40000000 0 0x40000000>; }; + + d3_3v: regulator-3v3 { + compatible = "regulator-fixed"; + regulator-name = "D3.3V"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + regulator-boot-on; + regulator-always-on; + }; + + ethernet@18000000 { + compatible = "smsc,lan89218", "smsc,lan9115"; + reg = <0 0x18000000 0 0x100>; + phy-mode = "mii"; + interrupt-parent = <&irqc>; + interrupts = <0 IRQ_TYPE_EDGE_FALLING>; + smsc,irq-push-pull; + smsc,save-mac-address; + reg-io-width = <4>; + vddvario-supply = <&d3_3v>; + vdd33a-supply = <&d3_3v>; + + pinctrl-0 = <&lan89218_pins>; + pinctrl-names = "default"; + }; }; &extal_clk { @@ -40,6 +65,17 @@ groups = "scif0_data"; function = "scif0"; }; + + lan89218_pins: lan89218 { + intc { + groups = "intc_irq0"; + function = "intc"; + }; + lbsc { + groups = "lbsc_ex_cs0"; + function = "lbsc"; + }; + }; }; &scif0 {