Skip to content

Commit f8b9958

Browse files
IoanaCiorneiLi Yang
authored andcommitted
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>
1 parent 51da14e commit f8b9958

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2303,9 +2303,14 @@ static int setup_rx_flow(struct dpaa2_eth_priv *priv,
23032303
queue.destination.type = DPNI_DEST_DPCON;
23042304
queue.destination.priority = 1;
23052305
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;
23062310
err = dpni_set_queue(priv->mc_io, 0, priv->mc_token,
23072311
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,
23092314
&queue);
23102315
if (err) {
23112316
dev_err(dev, "dpni_set_queue(RX) failed\n");

0 commit comments

Comments
 (0)