net/sfc: fix MTU change to check Rx scatter consistency
authorIgor Romanov <igor.romanov@oktetlabs.ru>
Tue, 23 Apr 2019 08:14:30 +0000 (09:14 +0100)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 3 May 2019 16:45:22 +0000 (18:45 +0200)
commit6c0cc77a2dd3806c5366586d818b1796a610e260
tree9c2d214b7f2ec9acfb9164eb703ba37adb82d596
parentf4a9349da80f8076d060498c3a9f673032e8662c
net/sfc: fix MTU change to check Rx scatter consistency

Rx queue setup function checks configured MTU to make sure that
no oversized packets can be received. But a following call to
set MTU function might make this check irrelevant.

Add a function to check MTU size against Rx buffer size and
additional Rx queue info, including Rx scatter offload.

Fixes: e961cf425e02 ("net/sfc: support MTU change")
Cc: stable@dpdk.org
Signed-off-by: Igor Romanov <igor.romanov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
drivers/net/sfc/sfc_ethdev.c
drivers/net/sfc/sfc_rx.c
drivers/net/sfc/sfc_rx.h