From: Pavan Nikhilesh Date: Mon, 11 Nov 2019 13:19:07 +0000 (+0530) Subject: ethdev: validate offloads set by PMD X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=1daa33805824e2fb6c93723604750d7b4013a355;hp=1daa33805824e2fb6c93723604750d7b4013a355;p=dpdk.git ethdev: validate offloads set by PMD Some PMDs cannot work when certain offloads are enable/disabled, as a workaround PMDs auto enable/disable offloads internally and expose it through dev->data->dev_conf.rxmode.offloads. After device specific dev_configure is called compare the requested offloads to the offloads exposed by the PMD and, if the PMD failed to enable a given offload then log it and return -EINVAL from rte_eth_dev_configure, else if the PMD failed to disable a given offload log and continue with rte_eth_dev_configure. Suggested-by: Andrew Rybchenko Signed-off-by: Pavan Nikhilesh Reviewed-by: Andrew Rybchenko ---