diff options
author | Ioana Ciornei <ioana.ciornei@nxp.com> | 2019-02-23 03:48:55 -0500 |
---|---|---|
committer | Li Yang <leoyang.li@nxp.com> | 2019-02-26 15:53:30 -0500 |
commit | f8b995853444aba9c16c1ccdccdd397527fde96d (patch) | |
tree | 3e07d4680b2a8907551c064ad223434b1923de1c | |
parent | 51da14e96e9b5187bd42148e37628e59486e267f (diff) |
dpaa2-eth: configure the cache stashing amount on a queue
Configure the amount of 64 bytes of frame, annotation and context data
that will be cache stashed for a specific frame queue. Since the frame
context is not used, configure that only 64 bytes of frame data and 64
bytes of annotation will be stashed.
Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
-rw-r--r-- | drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c b/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c index c500ea77aaa0..3c03fca83b70 100644 --- a/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c +++ b/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c | |||
@@ -2303,9 +2303,14 @@ static int setup_rx_flow(struct dpaa2_eth_priv *priv, | |||
2303 | queue.destination.type = DPNI_DEST_DPCON; | 2303 | queue.destination.type = DPNI_DEST_DPCON; |
2304 | queue.destination.priority = 1; | 2304 | queue.destination.priority = 1; |
2305 | queue.user_context = (u64)(uintptr_t)fq; | 2305 | queue.user_context = (u64)(uintptr_t)fq; |
2306 | queue.flc.stash_control = 1; | ||
2307 | queue.flc.value &= 0xFFFFFFFFFFFFFFC0; | ||
2308 | /* 01 01 00 - data, annotation, flow context */ | ||
2309 | queue.flc.value |= 0x14; | ||
2306 | err = dpni_set_queue(priv->mc_io, 0, priv->mc_token, | 2310 | err = dpni_set_queue(priv->mc_io, 0, priv->mc_token, |
2307 | DPNI_QUEUE_RX, 0, fq->flowid, | 2311 | DPNI_QUEUE_RX, 0, fq->flowid, |
2308 | DPNI_QUEUE_OPT_USER_CTX | DPNI_QUEUE_OPT_DEST, | 2312 | DPNI_QUEUE_OPT_USER_CTX | DPNI_QUEUE_OPT_DEST | |
2313 | DPNI_QUEUE_OPT_FLC, | ||
2309 | &queue); | 2314 | &queue); |
2310 | if (err) { | 2315 | if (err) { |
2311 | dev_err(dev, "dpni_set_queue(RX) failed\n"); | 2316 | dev_err(dev, "dpni_set_queue(RX) failed\n"); |