From patchwork Mon Jan 5 06:51:29 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ding Tianhong X-Patchwork-Id: 42730 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-we0-f198.google.com (mail-we0-f198.google.com [74.125.82.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 8D16C26CF2 for ; Mon, 5 Jan 2015 06:52:31 +0000 (UTC) Received: by mail-we0-f198.google.com with SMTP id q59sf3484631wes.9 for ; Sun, 04 Jan 2015 22:52:30 -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=q/3Xg1RSjnV81oDPGGK+TanY+LfLYAr6bp8bvqylFgI=; b=cBiuHldet9BTLJvS77rxvkZ2qxPmBnKts/pjPX0H0LOOLvUfPbEWdw+70fqDdivaBI z+XwFJsQ/iuzkWekL2PZ59c7hPZwG+7CN56zaQ+nIHuFbho+fndn96L1+5Zfo2Zmm4e0 011PQfpbCFUwbqThyeZCvC2WV3CtbsVBsOePt9xmqfB9Z/hqqBy5petywRt2y4qZjXDD q4FPzGdRSWsyzDV9wMxBi41ovO8BActdiAGsJ9zrJNeMenaZ1DAUyfvnfJDMzG6ousTl QAbaFt6x3DGfP6ZjqUwGctoXPmFsZZAjv34jY4OsnFy9MbGxXxwZq0/E2kKX1swttGzh U5ow== X-Gm-Message-State: ALoCoQm3OfQjmpAseeK827Ia7WnjsyikMxFbZlE3QIyqWQKQQyWrQk1CQ41DsxtSMro8aLsoKIQj X-Received: by 10.180.82.34 with SMTP id f2mr1235733wiy.1.1420440750876; Sun, 04 Jan 2015 22:52:30 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.2.137 with SMTP id 9ls1884272lau.26.gmail; Sun, 04 Jan 2015 22:52:30 -0800 (PST) X-Received: by 10.153.11.170 with SMTP id ej10mr90411856lad.24.1420440750618; Sun, 04 Jan 2015 22:52:30 -0800 (PST) Received: from mail-lb0-f169.google.com (mail-lb0-f169.google.com. [209.85.217.169]) by mx.google.com with ESMTPS id xo10si25584936lbb.34.2015.01.04.22.52.30 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 04 Jan 2015 22:52:30 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.169 as permitted sender) client-ip=209.85.217.169; Received: by mail-lb0-f169.google.com with SMTP id p9so17371380lbv.0 for ; Sun, 04 Jan 2015 22:52:30 -0800 (PST) X-Received: by 10.112.104.4 with SMTP id ga4mr20534177lbb.24.1420440750523; Sun, 04 Jan 2015 22:52:30 -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 c8csp798886lbb; Sun, 4 Jan 2015 22:52:29 -0800 (PST) X-Received: by 10.70.89.105 with SMTP id bn9mr143636620pdb.155.1420440745482; Sun, 04 Jan 2015 22:52:25 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w5si51741549pdp.207.2015.01.04.22.52.24; Sun, 04 Jan 2015 22:52:25 -0800 (PST) Received-SPF: none (google.com: netdev-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 S1753214AbbAEGwT (ORCPT + 3 others); Mon, 5 Jan 2015 01:52:19 -0500 Received: from szxga02-in.huawei.com ([119.145.14.65]:63383 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753167AbbAEGwF (ORCPT ); Mon, 5 Jan 2015 01:52:05 -0500 Received: from 172.24.2.119 (EHLO szxeml460-hub.china.huawei.com) ([172.24.2.119]) by szxrg02-dlp.huawei.com (MOS 4.3.7-GA FastPath queued) with ESMTP id CEX79706; Mon, 05 Jan 2015 14:51:51 +0800 (CST) Received: from localhost (10.177.22.246) by szxeml460-hub.china.huawei.com (10.82.67.203) with Microsoft SMTP Server id 14.3.158.1; Mon, 5 Jan 2015 14:51:38 +0800 From: Ding Tianhong To: , , , CC: , , , , , , , Subject: [PATCH net-next v10 1/3] Documentation: add Device tree bindings for Hisilicon hip04 ethernet Date: Mon, 5 Jan 2015 14:51:29 +0800 Message-ID: <1420440691-20928-2-git-send-email-dingtianhong@huawei.com> X-Mailer: git-send-email 1.8.5.2.msysgit.0 In-Reply-To: <1420440691-20928-1-git-send-email-dingtianhong@huawei.com> References: <1420440691-20928-1-git-send-email-dingtianhong@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.177.22.246] X-CFilter-Loop: Reflected Sender: netdev-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: netdev@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.217.169 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>; + };