From: Nithin Dabilpuram <[email protected]>

Modify aura batch free operation in RX fastpath as per
COUNT_EOT bits update in NPA_LF_AURA_BATCH_FREE0 CSR
for cn20k platform.

Signed-off-by: Nithin Dabilpuram <[email protected]>
---
Changes in v2: Updated commit message.

 drivers/net/cnxk/cn20k_rx.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/net/cnxk/cn20k_rx.h b/drivers/net/cnxk/cn20k_rx.h
index ea8675be00..eed8d59a14 100644
--- a/drivers/net/cnxk/cn20k_rx.h
+++ b/drivers/net/cnxk/cn20k_rx.h
@@ -112,7 +112,7 @@ nix_sec_flush_meta(uintptr_t laddr, uint16_t lmt_id, 
uint8_t loff, uintptr_t aur

        /* Update aura handle */
        *(uint64_t *)laddr =
-               (((uint64_t)(loff & 0x1) << 32) | 
roc_npa_aura_handle_to_aura(aura_handle));
+               (((uint64_t)(loff & 0x3) << 32) | 
roc_npa_aura_handle_to_aura(aura_handle));

        pa |= ((uint64_t)(loff >> 1) << 4);
        roc_lmt_submit_steorl(lmt_id, pa);
@@ -1561,7 +1561,7 @@ cn20k_nix_recv_pkts_vector(void *args, struct rte_mbuf 
**mbufs, uint16_t pkts, c
                        /* Check if lmtline border is crossed and adjust lnum */
                        if (loff > 15) {
                                /* Update aura handle */
-                               *(uint64_t *)(laddr - 8) = (((uint64_t)(15 & 
0x1) << 32) |
+                               *(uint64_t *)(laddr - 8) = (((uint64_t)(15 & 
0x3) << 32) |
                                                            
roc_npa_aura_handle_to_aura(meta_aura));
                                loff = loff - 15;
                                shft += 3;
@@ -1582,7 +1582,7 @@ cn20k_nix_recv_pkts_vector(void *args, struct rte_mbuf 
**mbufs, uint16_t pkts, c
                                uint64_t data = BIT_ULL(48) - 1;

                                /* Update aura handle */
-                               *(uint64_t *)(laddr - 8) = (((uint64_t)(loff & 
0x1) << 32) |
+                               *(uint64_t *)(laddr - 8) = (((uint64_t)(loff & 
0x3) << 32) |
                                                            
roc_npa_aura_handle_to_aura(meta_aura));

                                data = (data & ~(0x7UL << shft)) | 
(((uint64_t)loff >> 1) << shft);
@@ -1605,7 +1605,7 @@ cn20k_nix_recv_pkts_vector(void *args, struct rte_mbuf 
**mbufs, uint16_t pkts, c

                /* Update aura handle */
                *(uint64_t *)(laddr - 8) =
-                       (((uint64_t)(loff & 0x1) << 32) | 
roc_npa_aura_handle_to_aura(meta_aura));
+                       (((uint64_t)(loff & 0x3) << 32) | 
roc_npa_aura_handle_to_aura(meta_aura));

                data = (data & ~(0x7UL << shft)) | (((uint64_t)loff >> 1) << 
shft);

--
2.34.1

Reply via email to