ipsec: support 3DES-CBC
[dpdk.git] / examples / flow_filtering / main.c
index e0ee516..a582ac0 100644 (file)
@@ -121,8 +121,6 @@ init_port(void)
        struct rte_eth_conf port_conf = {
                .rxmode = {
                        .split_hdr_size = 0,
-                       .ignore_offload_bitfield = 1,
-                       .offloads = DEV_RX_OFFLOAD_CRC_STRIP,
                },
                .txmode = {
                        .offloads =
@@ -138,6 +136,8 @@ init_port(void)
        struct rte_eth_rxconf rxq_conf;
        struct rte_eth_dev_info dev_info;
 
+       rte_eth_dev_info_get(port_id, &dev_info);
+       port_conf.txmode.offloads &= dev_info.tx_offload_capa;
        printf(":: initializing port: %d\n", port_id);
        ret = rte_eth_dev_configure(port_id,
                                nr_queues, nr_queues, &port_conf);
@@ -147,7 +147,6 @@ init_port(void)
                        ret, port_id);
        }
 
-       rte_eth_dev_info_get(port_id, &dev_info);
        rxq_conf = dev_info.default_rxconf;
        rxq_conf.offloads = port_conf.rxmode.offloads;
        /* only set Rx queues: something we care only so far */