diff options
author | 2017-05-03 08:47:00 +0100 | |
---|---|---|
committer | 2017-05-09 17:46:44 +0100 | |
commit | 36d90e3aa7ad9a72f7acbefa4d409a71d78bfd25 (patch) | |
tree | 4e1dbfa21507b83276e5e2ef06b1c8fc74cba51d /examples/l4fwd | |
parent | 9fa82a63e47e4ee274c54af366e6fce055a0cbab (diff) |
two fixes. - allow conditional jumbo frame based on rx_max_pkt_len - fix mss size for rx_synack
Change-Id: I47b7775445bc4ba647f9da9edafc4b255082e926
Signed-off-by: Mohammad Abdul Awal <mohammad.abdul.awal@intel.com>
Diffstat (limited to 'examples/l4fwd')
-rw-r--r-- | examples/l4fwd/main.c | 3 | ||||
-rw-r--r-- | examples/l4fwd/parse.c | 2 | ||||
-rw-r--r-- | examples/l4fwd/port.h | 2 |
3 files changed, 4 insertions, 3 deletions
diff --git a/examples/l4fwd/main.c b/examples/l4fwd/main.c index 37bd03e..7613a95 100644 --- a/examples/l4fwd/main.c +++ b/examples/l4fwd/main.c @@ -68,9 +68,8 @@ static char proto_name[3][10] = {"udp", "tcp", ""}; static const struct rte_eth_conf port_conf_default = { .rxmode = { - .max_rx_pkt_len = ETHER_MAX_VLAN_FRAME_LEN, .hw_vlan_strip = 1, - .jumbo_frame = 1, + .jumbo_frame = 0, }, }; diff --git a/examples/l4fwd/parse.c b/examples/l4fwd/parse.c index ac11517..4850312 100644 --- a/examples/l4fwd/parse.c +++ b/examples/l4fwd/parse.c @@ -309,7 +309,7 @@ parse_netbe_arg(struct netbe_port *prt, const char *arg, rte_cpuset_t *pcpu) union parse_val val[RTE_DIM(hndl)]; memset(val, 0, sizeof(val)); - val[2].u64 = ETHER_MAX_VLAN_FRAME_LEN - ETHER_CRC_LEN; + val[2].u64 = ETHER_MAX_LEN - ETHER_CRC_LEN; rc = parse_kvargs(arg, keys_man, RTE_DIM(keys_man), keys_opt, RTE_DIM(keys_opt), hndl, val); diff --git a/examples/l4fwd/port.h b/examples/l4fwd/port.h index bc13dca..04f3ec2 100644 --- a/examples/l4fwd/port.h +++ b/examples/l4fwd/port.h @@ -181,6 +181,8 @@ port_init(struct netbe_port *uprt, uint32_t proto) port_conf.rxmode.hw_ip_checksum = 1; } port_conf.rxmode.max_rx_pkt_len = uprt->mtu + ETHER_CRC_LEN; + if (port_conf.rxmode.max_rx_pkt_len > ETHER_MAX_LEN) + port_conf.rxmode.jumbo_frame = 1; rc = update_rss_conf(uprt, &dev_info, &port_conf, proto); if (rc != 0) |