From: Danylo Vodopianov <dvo-...@napatech.com>

The issue with modification of the DSCP field
for IPV4 and IPV6 is fixed by adding
copying the DSCP value to the flow handler.

Fixes: 6fec9a9a12e1 ("net/ntnic: add infrastructure for flow actions and items")

Signed-off-by: Danylo Vodopianov <dvo-...@napatech.com>
---
 .../nthw/flow_api/profile_inline/flow_api_profile_inline.c    | 4 ++++
 1 file changed, 4 insertions(+)

diff --git 
a/drivers/net/ntnic/nthw/flow_api/profile_inline/flow_api_profile_inline.c 
b/drivers/net/ntnic/nthw/flow_api/profile_inline/flow_api_profile_inline.c
index a34839e00c..683610445d 100644
--- a/drivers/net/ntnic/nthw/flow_api/profile_inline/flow_api_profile_inline.c
+++ b/drivers/net/ntnic/nthw/flow_api/profile_inline/flow_api_profile_inline.c
@@ -3057,6 +3057,10 @@ static void copy_fd_to_fh_flm(struct flow_handle *fh, 
const struct nic_flow_def
        for (unsigned int i = 0; i < fd->modify_field_count; ++i) {
                switch (fd->modify_field[i].select) {
                case CPY_SELECT_DSCP_IPV4:
+               case CPY_SELECT_DSCP_IPV6:
+                       fh->flm_dscp = fd->modify_field[i].value8[0];
+                       break;
+
                case CPY_SELECT_RQI_QFI:
                        fh->flm_rqi = (fd->modify_field[i].value8[0] >> 6) & 
0x1;
                        fh->flm_qfi = fd->modify_field[i].value8[0] & 0x3f;
-- 
2.45.0

Reply via email to