From patchwork Mon Jan 12 08:03:50 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ding Tianhong X-Patchwork-Id: 42958 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ee0-f69.google.com (mail-ee0-f69.google.com [74.125.83.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 7EA6926C86 for ; Mon, 12 Jan 2015 08:04:35 +0000 (UTC) Received: by mail-ee0-f69.google.com with SMTP id d49sf12842446eek.0 for ; Mon, 12 Jan 2015 00:04:34 -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=EyQRM2QIHO3JdWAI1X0plhCHtjdkmQa4XNbkyz1MsC49DLLxN8ACyxZX09pO7iIRe7 kv1xz4p5OyF5kIVl4KKNNKEGD8ruFotDwTjYZBz4e7gwqP/6pqh4/ggK4Zgh63MAx4qZ jo6ObN39onQMos/cx2tS8r9b5zfaSoIsxYCLQwZBik0F8G5/HwRAdPL6ekTMGC0XZmwA slp0ZsNrFUTSiTrhHVC26sWIiNesNSubPImLxz5updt7gDPq/ZXzKH/T3zfkhDR2dVXs aNrAxa4MVI3zijm0L5wfecRo58rLGkKdZB+6GXX734rDChZ2M2ShHr3gJabSNDgqyeqn EpRw== X-Gm-Message-State: ALoCoQloSFkpF34IBK18qhhqQ8aBgngsy+OlN6MvlzGe1dW/Tgp8PudC2u8wTO7IniTUUa2XLuRE X-Received: by 10.180.93.165 with SMTP id cv5mr1833824wib.6.1421049874772; Mon, 12 Jan 2015 00:04:34 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.43.97 with SMTP id v1ls230658lal.29.gmail; Mon, 12 Jan 2015 00:04:34 -0800 (PST) X-Received: by 10.112.200.103 with SMTP id jr7mr35102044lbc.0.1421049874542; Mon, 12 Jan 2015 00:04:34 -0800 (PST) Received: from mail-la0-f43.google.com (mail-la0-f43.google.com. [209.85.215.43]) by mx.google.com with ESMTPS id g1si20549571lag.18.2015.01.12.00.04.34 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 12 Jan 2015 00:04:34 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.43 as permitted sender) client-ip=209.85.215.43; Received: by mail-la0-f43.google.com with SMTP id s18so22722033lam.2 for ; Mon, 12 Jan 2015 00:04:34 -0800 (PST) X-Received: by 10.152.18.135 with SMTP id w7mr34179441lad.47.1421049874450; Mon, 12 Jan 2015 00:04:34 -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 c8csp1004202lbb; Mon, 12 Jan 2015 00:04:33 -0800 (PST) X-Received: by 10.68.135.136 with SMTP id ps8mr42651217pbb.130.1421049872647; Mon, 12 Jan 2015 00:04:32 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id kj4si22575707pdb.21.2015.01.12.00.04.31; Mon, 12 Jan 2015 00:04:32 -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 S1751907AbbALIE3 (ORCPT + 4 others); Mon, 12 Jan 2015 03:04:29 -0500 Received: from szxga02-in.huawei.com ([119.145.14.65]:47305 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751891AbbALIE0 (ORCPT ); Mon, 12 Jan 2015 03:04:26 -0500 Received: from 172.24.2.119 (EHLO szxeml418-hub.china.huawei.com) ([172.24.2.119]) by szxrg02-dlp.huawei.com (MOS 4.3.7-GA FastPath queued) with ESMTP id CFJ93447; Mon, 12 Jan 2015 16:04:07 +0800 (CST) Received: from localhost (10.177.22.246) by szxeml418-hub.china.huawei.com (10.82.67.157) with Microsoft SMTP Server id 14.3.158.1; Mon, 12 Jan 2015 16:03:57 +0800 From: Ding Tianhong To: , , , CC: , , , , , , , Subject: [PATCH net-next v11 1/3] Documentation: add Device tree bindings for Hisilicon hip04 ethernet Date: Mon, 12 Jan 2015 16:03:50 +0800 Message-ID: <1421049832-6224-2-git-send-email-dingtianhong@huawei.com> X-Mailer: git-send-email 1.8.5.2.msysgit.0 In-Reply-To: <1421049832-6224-1-git-send-email-dingtianhong@huawei.com> References: <1421049832-6224-1-git-send-email-dingtianhong@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.177.22.246] X-CFilter-Loop: Reflected 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.43 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>; + };