From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751990AbcF3SHz (ORCPT ); Thu, 30 Jun 2016 14:07:55 -0400 Received: from mail-pf0-f178.google.com ([209.85.192.178]:35542 "EHLO mail-pf0-f178.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750969AbcF3SHx (ORCPT ); Thu, 30 Jun 2016 14:07:53 -0400 Subject: Re: [RFC 6/7] dt-bindings: net: bgmac: add bindings documentation for bgmac To: Jon Mason , zajec5@gmail.com References: <1467142484-11161-1-git-send-email-jon.mason@broadcom.com> <1467142484-11161-7-git-send-email-jon.mason@broadcom.com> Cc: davem@davemloft.net, f.fainelli@gmail.com, hauke@hauke-m.de, bcm-kernel-feedback-list@broadcom.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org From: Ray Jui Message-ID: Date: Thu, 30 Jun 2016 11:06:52 -0700 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:47.0) Gecko/20100101 Thunderbird/47.0 MIME-Version: 1.0 In-Reply-To: <1467142484-11161-7-git-send-email-jon.mason@broadcom.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Jon, On 6/28/2016 12:34 PM, Jon Mason wrote: > Signed-off-by: Jon Mason > --- > .../devicetree/bindings/net/brcm,bgmac-enet.txt | 21 +++++++++++++++++++++ > 1 file changed, 21 insertions(+) > create mode 100644 Documentation/devicetree/bindings/net/brcm,bgmac-enet.txt > > diff --git a/Documentation/devicetree/bindings/net/brcm,bgmac-enet.txt b/Documentation/devicetree/bindings/net/brcm,bgmac-enet.txt > new file mode 100644 > index 0000000..efd36d5 > --- /dev/null > +++ b/Documentation/devicetree/bindings/net/brcm,bgmac-enet.txt > @@ -0,0 +1,21 @@ > +Broadcom GMAC Ethernet Controller Device Tree Bindings > +------------------------------------------------------------- > + > +Required properties: > + - compatible: "brcm,bgmac-enet" > + - reg: Address and length of the GMAC registers, > + Address and length of the GMAC IDM registers As we know there will be additional optional register banks required for some of the other SoCs that the current driver has not yet supported. In my opinion, we should consider to make "reg-names" a mandatory property now and map the register blocks based on names. I think this will help to make our life easier in the future when new optional SoC specific register blocks are added, such that we can map the register blocks based on names instead of indices, which will change and be different among different SoCs and will require much more complex logic in the driver to deal with. > + - interrupts: Interrupt number > + > +Optional properties: > +- mac-address: mac address to be assigned to the device > + > +Examples: > + > +gmac0: enet@18022000 { > + compatible = "brcm,bgmac-enet"; > + reg = <0x18022000 0x1000>, > + <0x18110000 0x1000>; > + interrupts = ; > + status = "disabled"; > +}; > Btw, I think Rob Herring should be included in the review for device tree binding document changes. Thanks, Ray