From patchwork Wed Jan 14 06:34:12 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ding Tianhong X-Patchwork-Id: 43091 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f70.google.com (mail-la0-f70.google.com [209.85.215.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id DFB60202DD for ; Wed, 14 Jan 2015 06:34:39 +0000 (UTC) Received: by mail-la0-f70.google.com with SMTP id hs14sf3821173lab.1 for ; Tue, 13 Jan 2015 22:34:38 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-type:sender:precedence :list-id:x-original-sender:x-original-authentication-results :mailing-list:list-post:list-help:list-archive:list-unsubscribe; bh=+95pKZtJYDk9yky2DmBUbNZT2R3zdMwTEsNGLNVMkvM=; b=lG+zJnfYryk4O56MLT0rcu0+JVL6dqmVPTN6OKg09Eo/2RrR9fkgbFrSm9NHFf/hN1 RuLe61SAE9OkP1ycP0T5KY9Isqn7Fdk2qlLN1lWvqBj+PDFDXW3vA+vMnGEfiLNRA4aa yVP2Vg41xPkYmZtaP4C3CifyYZggVUKgRh13buodUmsKDZCkVE2QyJg5G4NyGfNOGrTf lxlCTG/KtMV4M+/Ts6RUax+phgL0AMV2I0wbVulCoAbBit7S2XV4Rdj1ThTE1XWXb7IO PUyZ6v3WYilXcfiaiYBcK3AXsKrCJd9Ou83s92Mq3fi1DA+672LJ8vw8z7UKYgOBZpfm 6aCA== X-Gm-Message-State: ALoCoQkO7v7+dTJDqkxhw2sJbetBBx/x4ELz0qMKMvcX4jwabGEjQ58G9RWqi8dp349z4+6cNbwU X-Received: by 10.180.77.167 with SMTP id t7mr3345190wiw.6.1421217278781; Tue, 13 Jan 2015 22:34:38 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.7.232 with SMTP id m8ls72095laa.45.gmail; Tue, 13 Jan 2015 22:34:38 -0800 (PST) X-Received: by 10.152.5.226 with SMTP id v2mr2234617lav.34.1421217278476; Tue, 13 Jan 2015 22:34:38 -0800 (PST) Received: from mail-la0-f50.google.com (mail-la0-f50.google.com. [209.85.215.50]) by mx.google.com with ESMTPS id s4si4868675las.118.2015.01.13.22.34.38 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 13 Jan 2015 22:34:38 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.50 as permitted sender) client-ip=209.85.215.50; Received: by mail-la0-f50.google.com with SMTP id pn19so6453834lab.9 for ; Tue, 13 Jan 2015 22:34:38 -0800 (PST) X-Received: by 10.112.125.41 with SMTP id mn9mr2154008lbb.80.1421217278337; Tue, 13 Jan 2015 22:34:38 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.9.200 with SMTP id c8csp1598629lbb; Tue, 13 Jan 2015 22:34:37 -0800 (PST) X-Received: by 10.66.164.200 with SMTP id ys8mr3301521pab.130.1421217276145; Tue, 13 Jan 2015 22:34:36 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id lu17si29573526pab.157.2015.01.13.22.34.35; Tue, 13 Jan 2015 22:34:36 -0800 (PST) Received-SPF: none (google.com: devicetree-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750920AbbANGee (ORCPT + 4 others); Wed, 14 Jan 2015 01:34:34 -0500 Received: from szxga03-in.huawei.com ([119.145.14.66]:4776 "EHLO szxga03-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750838AbbANGed (ORCPT ); Wed, 14 Jan 2015 01:34:33 -0500 Received: from 172.24.2.119 (EHLO szxeml463-hub.china.huawei.com) ([172.24.2.119]) by szxrg03-dlp.huawei.com (MOS 4.4.3-GA FastPath queued) with ESMTP id BAE22739; Wed, 14 Jan 2015 14:34:28 +0800 (CST) Received: from localhost (10.177.22.246) by szxeml463-hub.china.huawei.com (10.82.67.206) with Microsoft SMTP Server id 14.3.158.1; Wed, 14 Jan 2015 14:34:18 +0800 From: Ding Tianhong To: , , , , CC: , , , , , , , Subject: [PATCH net-next v13 1/3] Documentation: add Device tree bindings for Hisilicon hip04 ethernet Date: Wed, 14 Jan 2015 14:34:12 +0800 Message-ID: <1421217254-12008-2-git-send-email-dingtianhong@huawei.com> X-Mailer: git-send-email 1.8.5.2.msysgit.0 In-Reply-To: <1421217254-12008-1-git-send-email-dingtianhong@huawei.com> References: <1421217254-12008-1-git-send-email-dingtianhong@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.177.22.246] X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A020201.54B60DF6.0027, ss=1, re=0.001, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0, ip=0.0.0.0, so=2013-05-26 15:14:31, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: f2ebfb64ea0fa11b6ac1ac838436219e Sender: devicetree-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: devicetree@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: dingtianhong@huawei.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.50 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Zhangfei Gao This patch adds the Device Tree bindings for the Hisilicon hip04 Ethernet controller, including 100M / 1000M controller. Signed-off-by: Zhangfei Gao Signed-off-by: Ding Tianhong --- .../bindings/net/hisilicon-hip04-net.txt | 88 ++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 Documentation/devicetree/bindings/net/hisilicon-hip04-net.txt diff --git a/Documentation/devicetree/bindings/net/hisilicon-hip04-net.txt b/Documentation/devicetree/bindings/net/hisilicon-hip04-net.txt new file mode 100644 index 0000000..988fc69 --- /dev/null +++ b/Documentation/devicetree/bindings/net/hisilicon-hip04-net.txt @@ -0,0 +1,88 @@ +Hisilicon hip04 Ethernet Controller + +* Ethernet controller node + +Required properties: +- compatible: should be "hisilicon,hip04-mac". +- reg: address and length of the register set for the device. +- interrupts: interrupt for the device. +- port-handle: + phandle, specifies a reference to the syscon ppe node + port, port number connected to the controller + channel, recv channel start from channel * number (RX_DESC_NUM) +- phy-mode: see ethernet.txt [1]. + +Optional properties: +- phy-handle: see ethernet.txt [1]. + +[1] Documentation/devicetree/bindings/net/ethernet.txt + + +* Ethernet ppe node: +Control rx & tx fifos of all ethernet controllers. +Have 2048 recv channels shared by all ethernet controllers, only if no overlap. +Each controller's recv channel start from channel * number (RX_DESC_NUM). + +Required properties: +- compatible: "hisilicon,hip04-ppe", "syscon". +- reg: address and length of the register set for the device. + + +* MDIO bus node: + +Required properties: + +- compatible: should be "hisilicon,hip04-mdio". +- Inherits from MDIO bus node binding [2] +[2] Documentation/devicetree/bindings/net/phy.txt + +Example: + mdio { + compatible = "hisilicon,hip04-mdio"; + reg = <0x28f1000 0x1000>; + #address-cells = <1>; + #size-cells = <0>; + + phy0: ethernet-phy@0 { + compatible = "ethernet-phy-ieee802.3-c22"; + reg = <0>; + marvell,reg-init = <18 0x14 0 0x8001>; + }; + + phy1: ethernet-phy@1 { + compatible = "ethernet-phy-ieee802.3-c22"; + reg = <1>; + marvell,reg-init = <18 0x14 0 0x8001>; + }; + }; + + ppe: ppe@28c0000 { + compatible = "hisilicon,hip04-ppe", "syscon"; + reg = <0x28c0000 0x10000>; + }; + + fe: ethernet@28b0000 { + compatible = "hisilicon,hip04-mac"; + reg = <0x28b0000 0x10000>; + interrupts = <0 413 4>; + phy-mode = "mii"; + port-handle = <&ppe 31 0>; + }; + + ge0: ethernet@2800000 { + compatible = "hisilicon,hip04-mac"; + reg = <0x2800000 0x10000>; + interrupts = <0 402 4>; + phy-mode = "sgmii"; + port-handle = <&ppe 0 1>; + phy-handle = <&phy0>; + }; + + ge8: ethernet@2880000 { + compatible = "hisilicon,hip04-mac"; + reg = <0x2880000 0x10000>; + interrupts = <0 410 4>; + phy-mode = "sgmii"; + port-handle = <&ppe 8 2>; + phy-handle = <&phy1>; + };