From patchwork Tue Mar 18 08:40:15 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zhangfei Gao X-Patchwork-Id: 26463 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pd0-f200.google.com (mail-pd0-f200.google.com [209.85.192.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 52276202FA for ; Tue, 18 Mar 2014 08:40:55 +0000 (UTC) Received: by mail-pd0-f200.google.com with SMTP id p10sf16220102pdj.3 for ; Tue, 18 Mar 2014 01:40:54 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=uRnc2SwTKG3JzGf3d6M0Z5GMxYANK761edc5dNRNScw=; b=DuJnG4Y3eJ2qFleMnu3iS/Z3rVE1f0vTqC/7M9HMDi5IMNWfQyBZ/3QxRVjnGXw4Yb h4+wuPGTbtNNcexRxHGmfLvTpRGGXdMeTkT2RmnY8GigA7ZxflqaeIwX4UPZejlljh3s F/cuWR9tsd4kUzADjPG7BCZwa/ImkTqx4cDZAnUuypoHFzz+siGnL6whVVrGZsc5hoEj 4FhL8hN5dJYQjuzjpYf/aMg9W4o+dvfcJX5XhMv6UfApp09fbmgjEYXmD3by5bHPXYDu Ykvec3bE0rwrypVN3EiZUd+McQq+/9v5cC5dWuh0TQsQaJtWfTJiAk+PYEiUjDjpe4D7 0TUw== X-Gm-Message-State: ALoCoQmnRyP/iu2ConlzfFxy8e9iJDa+f/kvQYdNVTdVtKu3udbi4xrvnQCVLfOkBLFcZs/tsLe4 X-Received: by 10.66.157.35 with SMTP id wj3mr11733411pab.11.1395132054406; Tue, 18 Mar 2014 01:40:54 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.46.37 with SMTP id j34ls1756689qga.73.gmail; Tue, 18 Mar 2014 01:40:54 -0700 (PDT) X-Received: by 10.52.247.231 with SMTP id yh7mr3904779vdc.34.1395132054303; Tue, 18 Mar 2014 01:40:54 -0700 (PDT) Received: from mail-vc0-f178.google.com (mail-vc0-f178.google.com [209.85.220.178]) by mx.google.com with ESMTPS id cl8si6269882vcb.1.2014.03.18.01.40.54 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 18 Mar 2014 01:40:54 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.178 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.178; Received: by mail-vc0-f178.google.com with SMTP id im17so7045569vcb.9 for ; Tue, 18 Mar 2014 01:40:54 -0700 (PDT) X-Received: by 10.58.90.99 with SMTP id bv3mr954660veb.34.1395132054155; Tue, 18 Mar 2014 01:40:54 -0700 (PDT) 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.220.78.9 with SMTP id i9csp187750vck; Tue, 18 Mar 2014 01:40:52 -0700 (PDT) X-Received: by 10.68.34.225 with SMTP id c1mr31898927pbj.116.1395132051534; Tue, 18 Mar 2014 01:40:51 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f1si15609331pbn.346.2014.03.18.01.40.51; Tue, 18 Mar 2014 01:40:51 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754263AbaCRIkh (ORCPT + 4 others); Tue, 18 Mar 2014 04:40:37 -0400 Received: from mail-pb0-f43.google.com ([209.85.160.43]:62239 "EHLO mail-pb0-f43.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753753AbaCRIke (ORCPT ); Tue, 18 Mar 2014 04:40:34 -0400 Received: by mail-pb0-f43.google.com with SMTP id um1so6949835pbc.2 for ; Tue, 18 Mar 2014 01:40:34 -0700 (PDT) X-Received: by 10.69.1.69 with SMTP id be5mr31067485pbd.126.1395132034045; Tue, 18 Mar 2014 01:40:34 -0700 (PDT) Received: from localhost.localdomain ([180.150.157.4]) by mx.google.com with ESMTPSA id aj7sm84314764pad.29.2014.03.18.01.40.30 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 18 Mar 2014 01:40:33 -0700 (PDT) From: Zhangfei Gao To: "David S. Miller" Cc: linux-arm-kernel@lists.infradead.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, Zhangfei Gao Subject: [PATCH 1/3] Documentation: add Device tree bindings for Hisilicon hip04 ethernet Date: Tue, 18 Mar 2014 16:40:15 +0800 Message-Id: <1395132017-15928-2-git-send-email-zhangfei.gao@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1395132017-15928-1-git-send-email-zhangfei.gao@linaro.org> References: <1395132017-15928-1-git-send-email-zhangfei.gao@linaro.org> 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: zhangfei.gao@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.178 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) 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: , This patch adds the Device Tree bindings for the Hisilicon hip04 Ethernet controller, including 100M / 1000M controller. Signed-off-by: Zhangfei Gao --- .../bindings/net/hisilicon-hip04-net.txt | 74 ++++++++++++++++++++ 1 file changed, 74 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..c918f08 --- /dev/null +++ b/Documentation/devicetree/bindings/net/hisilicon-hip04-net.txt @@ -0,0 +1,74 @@ +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: ppe port number connected to the controller: range from 0 to 31. +- speed: 100 (100M) or 1000 (1000M). +- id: should be different and fe should be 0. + +Optional Properties: +- phy-handle : the phandle to a PHY node + + +* Ethernet ppe node: control rx & tx fifos of all ethernet controllers + +Required properties: +- compatible: should be "hisilicon,hip04-ppebase". +- reg: address and length of the register set for the node. + + +* MDIO bus node: + +Required properties: + +- compatible: "hisilicon,hip04-mdio" +- Inherets from MDIO bus node binding[1] +[1] 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 { + reg = <0>; + marvell,reg-init = <18 0x14 0 0x8001>; + device_type = "ethernet-phy"; + }; + + phy1: ethernet-phy@1 { + reg = <1>; + marvell,reg-init = <18 0x14 0 0x8001>; + device_type = "ethernet-phy"; + }; + }; + + ppebase: ppebase@28c0000 { + compatible = "hisilicon,hip04-ppebase"; + reg = <0x28c0000 0x10000>; + }; + + fe: ethernet@28b0000 { + compatible = "hisilicon,hip04-mac"; + reg = <0x28b0000 0x10000>; + interrupts = <0 413 4>; + port = <31>; + speed = <100>; + id = <0>; + }; + + ge0: ethernet@2800000 { + compatible = "hisilicon,hip04-mac"; + reg = <0x2800000 0x10000>; + interrupts = <0 402 4>; + port = <0>; + speed = <1000>; + id = <1>; + phy-handle = <&phy0>; + };