xref: /linux/Documentation/devicetree/bindings/net/cpsw.txt (revision d9ba8f9e6298af71ec1c1fd3d88c3ef68abd0ec3)
12eb32b0aSMugunthan V NTI SoC Ethernet Switch Controller Device Tree Bindings
22eb32b0aSMugunthan V N------------------------------------------------------
32eb32b0aSMugunthan V N
42eb32b0aSMugunthan V NRequired properties:
52eb32b0aSMugunthan V N- compatible		: Should be "ti,cpsw"
62eb32b0aSMugunthan V N- reg			: physical base address and size of the cpsw
72eb32b0aSMugunthan V N			  registers map
82eb32b0aSMugunthan V N- interrupts		: property with a value describing the interrupt
92eb32b0aSMugunthan V N			  number
102eb32b0aSMugunthan V N- interrupt-parent	: The parent interrupt controller
112eb32b0aSMugunthan V N- cpdma_channels 	: Specifies number of channels in CPDMA
122eb32b0aSMugunthan V N- ale_entries		: Specifies No of entries ALE can hold
132eb32b0aSMugunthan V N- bd_ram_size		: Specifies internal descriptor RAM size
142eb32b0aSMugunthan V N- rx_descs		: Specifies number of Rx descriptors
152eb32b0aSMugunthan V N- mac_control		: Specifies Default MAC control register content
162eb32b0aSMugunthan V N			  for the specific platform
172eb32b0aSMugunthan V N- slaves		: Specifies number for slaves
1878ca0b28SRichard Cochran- cpts_active_slave	: Specifies the slave to use for time stamping
1900ab94eeSRichard Cochran- cpts_clock_mult	: Numerator to convert input clock ticks into nanoseconds
2000ab94eeSRichard Cochran- cpts_clock_shift	: Denominator to convert input clock ticks into nanoseconds
212eb32b0aSMugunthan V N- phy_id		: Specifies slave phy id
222eb32b0aSMugunthan V N- mac-address		: Specifies slave MAC address
232eb32b0aSMugunthan V N
242eb32b0aSMugunthan V NOptional properties:
252eb32b0aSMugunthan V N- ti,hwmods		: Must be "cpgmac0"
262eb32b0aSMugunthan V N- no_bd_ram		: Must be 0 or 1
27*d9ba8f9eSMugunthan V N- dual_emac		: Specifies Switch to act as Dual EMAC
28*d9ba8f9eSMugunthan V N- dual_emac_res_vlan	: Specifies VID to be used to segregate the ports
292eb32b0aSMugunthan V N
302eb32b0aSMugunthan V NNote: "ti,hwmods" field is used to fetch the base address and irq
312eb32b0aSMugunthan V Nresources from TI, omap hwmod data base during device registration.
322eb32b0aSMugunthan V NFuture plan is to migrate hwmod data base contents into device tree
332eb32b0aSMugunthan V Nblob so that, all the required data will be used from device tree dts
342eb32b0aSMugunthan V Nfile.
352eb32b0aSMugunthan V N
362eb32b0aSMugunthan V NExamples:
372eb32b0aSMugunthan V N
382eb32b0aSMugunthan V N	mac: ethernet@4A100000 {
392eb32b0aSMugunthan V N		compatible = "ti,cpsw";
402eb32b0aSMugunthan V N		reg = <0x4A100000 0x1000>;
412eb32b0aSMugunthan V N		interrupts = <55 0x4>;
422eb32b0aSMugunthan V N		interrupt-parent = <&intc>;
43e07b94f1SMugunthan V N		cpdma_channels = <8>;
44e07b94f1SMugunthan V N		ale_entries = <1024>;
45e07b94f1SMugunthan V N		bd_ram_size = <0x2000>;
46e07b94f1SMugunthan V N		no_bd_ram = <0>;
47e07b94f1SMugunthan V N		rx_descs = <64>;
48e07b94f1SMugunthan V N		mac_control = <0x20>;
49e07b94f1SMugunthan V N		slaves = <2>;
5078ca0b28SRichard Cochran		cpts_active_slave = <0>;
5100ab94eeSRichard Cochran		cpts_clock_mult = <0x80000000>;
5200ab94eeSRichard Cochran		cpts_clock_shift = <29>;
53e07b94f1SMugunthan V N		cpsw_emac0: slave@0 {
54549985eeSRichard Cochran			phy_id = <&davinci_mdio>, <0>;
55e07b94f1SMugunthan V N			/* Filled in by U-Boot */
56e07b94f1SMugunthan V N			mac-address = [ 00 00 00 00 00 00 ];
572eb32b0aSMugunthan V N		};
58e07b94f1SMugunthan V N		cpsw_emac1: slave@1 {
59549985eeSRichard Cochran			phy_id = <&davinci_mdio>, <1>;
60e07b94f1SMugunthan V N			/* Filled in by U-Boot */
61e07b94f1SMugunthan V N			mac-address = [ 00 00 00 00 00 00 ];
622eb32b0aSMugunthan V N		};
632eb32b0aSMugunthan V N	};
642eb32b0aSMugunthan V N
652eb32b0aSMugunthan V N(or)
662eb32b0aSMugunthan V N	mac: ethernet@4A100000 {
672eb32b0aSMugunthan V N		compatible = "ti,cpsw";
682eb32b0aSMugunthan V N		ti,hwmods = "cpgmac0";
69e07b94f1SMugunthan V N		cpdma_channels = <8>;
70e07b94f1SMugunthan V N		ale_entries = <1024>;
71e07b94f1SMugunthan V N		bd_ram_size = <0x2000>;
72e07b94f1SMugunthan V N		no_bd_ram = <0>;
73e07b94f1SMugunthan V N		rx_descs = <64>;
74e07b94f1SMugunthan V N		mac_control = <0x20>;
75e07b94f1SMugunthan V N		slaves = <2>;
7678ca0b28SRichard Cochran		cpts_active_slave = <0>;
7700ab94eeSRichard Cochran		cpts_clock_mult = <0x80000000>;
7800ab94eeSRichard Cochran		cpts_clock_shift = <29>;
79e07b94f1SMugunthan V N		cpsw_emac0: slave@0 {
80549985eeSRichard Cochran			phy_id = <&davinci_mdio>, <0>;
81e07b94f1SMugunthan V N			/* Filled in by U-Boot */
82e07b94f1SMugunthan V N			mac-address = [ 00 00 00 00 00 00 ];
832eb32b0aSMugunthan V N		};
84e07b94f1SMugunthan V N		cpsw_emac1: slave@1 {
85549985eeSRichard Cochran			phy_id = <&davinci_mdio>, <1>;
86e07b94f1SMugunthan V N			/* Filled in by U-Boot */
87e07b94f1SMugunthan V N			mac-address = [ 00 00 00 00 00 00 ];
882eb32b0aSMugunthan V N		};
892eb32b0aSMugunthan V N	};
90