12eb32b0aSMugunthan V NTI SoC Ethernet Switch Controller Device Tree Bindings 22eb32b0aSMugunthan V N------------------------------------------------------ 32eb32b0aSMugunthan V N 42eb32b0aSMugunthan V NRequired properties: 5*472204feSMugunthan V N- compatible : Should be one of the below:- 6*472204feSMugunthan V N "ti,cpsw" for backward compatible 7*472204feSMugunthan V N "ti,am335x-cpsw" for AM335x controllers 8*472204feSMugunthan V N "ti,am4372-cpsw" for AM437x controllers 9*472204feSMugunthan V N "ti,dra7-cpsw" for DRA7x controllers 102eb32b0aSMugunthan V N- reg : physical base address and size of the cpsw 112eb32b0aSMugunthan V N registers map 122eb32b0aSMugunthan V N- interrupts : property with a value describing the interrupt 132eb32b0aSMugunthan V N number 142eb32b0aSMugunthan V N- interrupt-parent : The parent interrupt controller 152eb32b0aSMugunthan V N- cpdma_channels : Specifies number of channels in CPDMA 162eb32b0aSMugunthan V N- ale_entries : Specifies No of entries ALE can hold 172eb32b0aSMugunthan V N- bd_ram_size : Specifies internal descriptor RAM size 182eb32b0aSMugunthan V N- rx_descs : Specifies number of Rx descriptors 192eb32b0aSMugunthan V N- mac_control : Specifies Default MAC control register content 202eb32b0aSMugunthan V N for the specific platform 212eb32b0aSMugunthan V N- slaves : Specifies number for slaves 22e86ac13bSMugunthan V N- active_slave : Specifies the slave to use for time stamping, 23e86ac13bSMugunthan V N ethtool and SIOCGMIIPHY 2400ab94eeSRichard Cochran- cpts_clock_mult : Numerator to convert input clock ticks into nanoseconds 2500ab94eeSRichard Cochran- cpts_clock_shift : Denominator to convert input clock ticks into nanoseconds 262eb32b0aSMugunthan V N 272eb32b0aSMugunthan V NOptional properties: 282eb32b0aSMugunthan V N- ti,hwmods : Must be "cpgmac0" 292eb32b0aSMugunthan V N- no_bd_ram : Must be 0 or 1 30d9ba8f9eSMugunthan V N- dual_emac : Specifies Switch to act as Dual EMAC 310ba517b1SMarkus Pargmann- syscon : Phandle to the system control device node, which is 320ba517b1SMarkus Pargmann the control module device of the am33x 33470d1474SMugunthan V N 34470d1474SMugunthan V NSlave Properties: 35470d1474SMugunthan V NRequired properties: 36470d1474SMugunthan V N- phy_id : Specifies slave phy id 37e8f08ee0SSergei Shtylyov- phy-mode : See ethernet.txt file in the same directory 38470d1474SMugunthan V N 39470d1474SMugunthan V NOptional properties: 40d9ba8f9eSMugunthan V N- dual_emac_res_vlan : Specifies VID to be used to segregate the ports 41e4a9839bSMarkus Pargmann- mac-address : See ethernet.txt file in the same directory 422eb32b0aSMugunthan V N 432eb32b0aSMugunthan V NNote: "ti,hwmods" field is used to fetch the base address and irq 442eb32b0aSMugunthan V Nresources from TI, omap hwmod data base during device registration. 452eb32b0aSMugunthan V NFuture plan is to migrate hwmod data base contents into device tree 462eb32b0aSMugunthan V Nblob so that, all the required data will be used from device tree dts 472eb32b0aSMugunthan V Nfile. 482eb32b0aSMugunthan V N 492eb32b0aSMugunthan V NExamples: 502eb32b0aSMugunthan V N 512eb32b0aSMugunthan V N mac: ethernet@4A100000 { 522eb32b0aSMugunthan V N compatible = "ti,cpsw"; 532eb32b0aSMugunthan V N reg = <0x4A100000 0x1000>; 542eb32b0aSMugunthan V N interrupts = <55 0x4>; 552eb32b0aSMugunthan V N interrupt-parent = <&intc>; 56e07b94f1SMugunthan V N cpdma_channels = <8>; 57e07b94f1SMugunthan V N ale_entries = <1024>; 58e07b94f1SMugunthan V N bd_ram_size = <0x2000>; 59e07b94f1SMugunthan V N no_bd_ram = <0>; 60e07b94f1SMugunthan V N rx_descs = <64>; 61e07b94f1SMugunthan V N mac_control = <0x20>; 62e07b94f1SMugunthan V N slaves = <2>; 63e86ac13bSMugunthan V N active_slave = <0>; 6400ab94eeSRichard Cochran cpts_clock_mult = <0x80000000>; 6500ab94eeSRichard Cochran cpts_clock_shift = <29>; 660ba517b1SMarkus Pargmann syscon = <&cm>; 67e07b94f1SMugunthan V N cpsw_emac0: slave@0 { 68549985eeSRichard Cochran phy_id = <&davinci_mdio>, <0>; 69c5ceea7aSMugunthan V N phy-mode = "rgmii-txid"; 70e07b94f1SMugunthan V N /* Filled in by U-Boot */ 71e07b94f1SMugunthan V N mac-address = [ 00 00 00 00 00 00 ]; 722eb32b0aSMugunthan V N }; 73e07b94f1SMugunthan V N cpsw_emac1: slave@1 { 74549985eeSRichard Cochran phy_id = <&davinci_mdio>, <1>; 75c5ceea7aSMugunthan V N phy-mode = "rgmii-txid"; 76e07b94f1SMugunthan V N /* Filled in by U-Boot */ 77e07b94f1SMugunthan V N mac-address = [ 00 00 00 00 00 00 ]; 782eb32b0aSMugunthan V N }; 792eb32b0aSMugunthan V N }; 802eb32b0aSMugunthan V N 812eb32b0aSMugunthan V N(or) 822eb32b0aSMugunthan V N mac: ethernet@4A100000 { 832eb32b0aSMugunthan V N compatible = "ti,cpsw"; 842eb32b0aSMugunthan V N ti,hwmods = "cpgmac0"; 85e07b94f1SMugunthan V N cpdma_channels = <8>; 86e07b94f1SMugunthan V N ale_entries = <1024>; 87e07b94f1SMugunthan V N bd_ram_size = <0x2000>; 88e07b94f1SMugunthan V N no_bd_ram = <0>; 89e07b94f1SMugunthan V N rx_descs = <64>; 90e07b94f1SMugunthan V N mac_control = <0x20>; 91e07b94f1SMugunthan V N slaves = <2>; 92e86ac13bSMugunthan V N active_slave = <0>; 9300ab94eeSRichard Cochran cpts_clock_mult = <0x80000000>; 9400ab94eeSRichard Cochran cpts_clock_shift = <29>; 950ba517b1SMarkus Pargmann syscon = <&cm>; 96e07b94f1SMugunthan V N cpsw_emac0: slave@0 { 97549985eeSRichard Cochran phy_id = <&davinci_mdio>, <0>; 98c5ceea7aSMugunthan V N phy-mode = "rgmii-txid"; 99e07b94f1SMugunthan V N /* Filled in by U-Boot */ 100e07b94f1SMugunthan V N mac-address = [ 00 00 00 00 00 00 ]; 1012eb32b0aSMugunthan V N }; 102e07b94f1SMugunthan V N cpsw_emac1: slave@1 { 103549985eeSRichard Cochran phy_id = <&davinci_mdio>, <1>; 104c5ceea7aSMugunthan V N phy-mode = "rgmii-txid"; 105e07b94f1SMugunthan V N /* Filled in by U-Boot */ 106e07b94f1SMugunthan V N mac-address = [ 00 00 00 00 00 00 ]; 1072eb32b0aSMugunthan V N }; 1082eb32b0aSMugunthan V N }; 109