aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/networking/stmmac.txt
diff options
context:
space:
mode:
authorDeepak SIKRI <deepak.sikri@st.com>2012-04-04 00:33:23 -0400
committerDavid S. Miller <davem@davemloft.net>2012-04-04 18:39:24 -0400
commit8327eb65e795ba4f922bf7e531cd312875f0dc29 (patch)
treea527c090d553ee9df37de620f05e03ee15d905d9 /Documentation/networking/stmmac.txt
parentfaeae3fa0f3a243f677cf606aa87d0d99c225165 (diff)
stmmac: re-work the internal GMAC DMA platf parameters
This patch re-works the internal GMAC DMA parameters passed from the platform. In the past, we only passed the pbl but, with new core, other parameters can be passed and are mandatory on some platforms. New parameters are documented in stmmac.txt because this patch has an impact for many platforms. Signed-off-by: Shiraz Hashim <shiraz.hashim@st.com> Signed-off-by: Vikas Manocha <vikas.manocha@st.com> Signed-off-by: Deepak Sikri <deepak.sikri@st.com> Hacked-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'Documentation/networking/stmmac.txt')
-rw-r--r--Documentation/networking/stmmac.txt24
1 files changed, 21 insertions, 3 deletions
diff --git a/Documentation/networking/stmmac.txt b/Documentation/networking/stmmac.txt
index 61f40a3fa7ea..eacb640286b1 100644
--- a/Documentation/networking/stmmac.txt
+++ b/Documentation/networking/stmmac.txt
@@ -111,7 +111,7 @@ and detailed below as well:
111 int phy_addr; 111 int phy_addr;
112 int interface; 112 int interface;
113 struct stmmac_mdio_bus_data *mdio_bus_data; 113 struct stmmac_mdio_bus_data *mdio_bus_data;
114 int pbl; 114 struct stmmac_dma_cfg *dma_cfg;
115 int clk_csr; 115 int clk_csr;
116 int has_gmac; 116 int has_gmac;
117 int enh_desc; 117 int enh_desc;
@@ -163,7 +163,7 @@ Where:
163 o custom_cfg: this is a custom configuration that can be passed while 163 o custom_cfg: this is a custom configuration that can be passed while
164 initialising the resources. 164 initialising the resources.
165 165
166The we have: 166For MDIO bus The we have:
167 167
168 struct stmmac_mdio_bus_data { 168 struct stmmac_mdio_bus_data {
169 int bus_id; 169 int bus_id;
@@ -180,10 +180,28 @@ Where:
180 o irqs: list of IRQs, one per PHY. 180 o irqs: list of IRQs, one per PHY.
181 o probed_phy_irq: if irqs is NULL, use this for probed PHY. 181 o probed_phy_irq: if irqs is NULL, use this for probed PHY.
182 182
183
184For DMA engine we have the following internal fields that should be
185tuned according to the HW capabilities.
186
187struct stmmac_dma_cfg {
188 int pbl;
189 int fixed_burst;
190 int burst_len_supported;
191};
192
193Where:
194 o pbl: Programmable Burst Length
195 o fixed_burst: program the DMA to use the fixed burst mode
196 o burst_len: this is the value we put in the register
197 supported values are provided as macros in
198 linux/stmmac.h header file.
199
200---
201
183Below an example how the structures above are using on ST platforms. 202Below an example how the structures above are using on ST platforms.
184 203
185 static struct plat_stmmacenet_data stxYYY_ethernet_platform_data = { 204 static struct plat_stmmacenet_data stxYYY_ethernet_platform_data = {
186 .pbl = 32,
187 .has_gmac = 0, 205 .has_gmac = 0,
188 .enh_desc = 0, 206 .enh_desc = 0,
189 .fix_mac_speed = stxYYY_ethernet_fix_mac_speed, 207 .fix_mac_speed = stxYYY_ethernet_fix_mac_speed,