About Kernel Documentation Linux Kernel Contact Linux Resources Linux Blog

Documentation / devicetree / bindings / net / cpsw.txt




Custom Search

Based on kernel version 4.13.3. Page generated on 2017-09-23 13:55 EST.

1	TI SoC Ethernet Switch Controller Device Tree Bindings
2	------------------------------------------------------
3	
4	Required properties:
5	- compatible		: Should be one of the below:-
6				  "ti,cpsw" for backward compatible
7				  "ti,am335x-cpsw" for AM335x controllers
8				  "ti,am4372-cpsw" for AM437x controllers
9				  "ti,dra7-cpsw" for DRA7x controllers
10	- reg			: physical base address and size of the cpsw
11				  registers map
12	- interrupts		: property with a value describing the interrupt
13				  number
14	- interrupt-parent	: The parent interrupt controller
15	- cpdma_channels 	: Specifies number of channels in CPDMA
16	- ale_entries		: Specifies No of entries ALE can hold
17	- bd_ram_size		: Specifies internal descriptor RAM size
18	- mac_control		: Specifies Default MAC control register content
19				  for the specific platform
20	- slaves		: Specifies number for slaves
21	- active_slave		: Specifies the slave to use for time stamping,
22				  ethtool and SIOCGMIIPHY
23	
24	Optional properties:
25	- ti,hwmods		: Must be "cpgmac0"
26	- dual_emac		: Specifies Switch to act as Dual EMAC
27	- syscon		: Phandle to the system control device node, which is
28				  the control module device of the am33x
29	- mode-gpios		: Should be added if one/multiple gpio lines are
30				  required to be driven so that cpsw data lines
31				  can be connected to the phy via selective mux.
32				  For example in dra72x-evm, pcf gpio has to be
33				  driven low so that cpsw slave 0 and phy data
34				  lines are connected via mux.
35	- cpts_clock_mult	: Numerator to convert input clock ticks into nanoseconds
36	- cpts_clock_shift	: Denominator to convert input clock ticks into nanoseconds
37				  Mult and shift will be calculated basing on CPTS
38				  rftclk frequency if both cpts_clock_shift and
39				  cpts_clock_mult properties are not provided.
40	
41	Slave Properties:
42	Required properties:
43	- phy-mode		: See ethernet.txt file in the same directory
44	
45	Optional properties:
46	- dual_emac_res_vlan	: Specifies VID to be used to segregate the ports
47	- mac-address		: See ethernet.txt file in the same directory
48	- phy_id		: Specifies slave phy id (deprecated, use phy-handle)
49	- phy-handle		: See ethernet.txt file in the same directory
50	
51	Slave sub-nodes:
52	- fixed-link		: See fixed-link.txt file in the same directory
53	
54	Note: Exactly one of phy_id, phy-handle, or fixed-link must be specified.
55	
56	Note: "ti,hwmods" field is used to fetch the base address and irq
57	resources from TI, omap hwmod data base during device registration.
58	Future plan is to migrate hwmod data base contents into device tree
59	blob so that, all the required data will be used from device tree dts
60	file.
61	
62	Examples:
63	
64		mac: ethernet@4A100000 {
65			compatible = "ti,cpsw";
66			reg = <0x4A100000 0x1000>;
67			interrupts = <55 0x4>;
68			interrupt-parent = <&intc>;
69			cpdma_channels = <8>;
70			ale_entries = <1024>;
71			bd_ram_size = <0x2000>;
72			rx_descs = <64>;
73			mac_control = <0x20>;
74			slaves = <2>;
75			active_slave = <0>;
76			cpts_clock_mult = <0x80000000>;
77			cpts_clock_shift = <29>;
78			syscon = <&cm>;
79			cpsw_emac0: slave@0 {
80				phy_id = <&davinci_mdio>, <0>;
81				phy-mode = "rgmii-txid";
82				/* Filled in by U-Boot */
83				mac-address = [ 00 00 00 00 00 00 ];
84			};
85			cpsw_emac1: slave@1 {
86				phy_id = <&davinci_mdio>, <1>;
87				phy-mode = "rgmii-txid";
88				/* Filled in by U-Boot */
89				mac-address = [ 00 00 00 00 00 00 ];
90			};
91		};
92	
93	(or)
94		mac: ethernet@4A100000 {
95			compatible = "ti,cpsw";
96			ti,hwmods = "cpgmac0";
97			cpdma_channels = <8>;
98			ale_entries = <1024>;
99			bd_ram_size = <0x2000>;
100			rx_descs = <64>;
101			mac_control = <0x20>;
102			slaves = <2>;
103			active_slave = <0>;
104			cpts_clock_mult = <0x80000000>;
105			cpts_clock_shift = <29>;
106			syscon = <&cm>;
107			cpsw_emac0: slave@0 {
108				phy_id = <&davinci_mdio>, <0>;
109				phy-mode = "rgmii-txid";
110				/* Filled in by U-Boot */
111				mac-address = [ 00 00 00 00 00 00 ];
112			};
113			cpsw_emac1: slave@1 {
114				phy_id = <&davinci_mdio>, <1>;
115				phy-mode = "rgmii-txid";
116				/* Filled in by U-Boot */
117				mac-address = [ 00 00 00 00 00 00 ];
118			};
119		};
Hide Line Numbers
About Kernel Documentation Linux Kernel Contact Linux Resources Linux Blog

Information is copyright its respective author. All material is available from the Linux Kernel Source distributed under a GPL License. This page is provided as a free service by mjmwired.net.