From: Mark Spender Date: Thu, 16 Nov 2017 08:04:15 +0000 (+0000) Subject: net/sfc/base: use MCDIv2 for requests with too long response X-Git-Tag: spdx-start~658 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=0f55ea2b7a52b7666cd30c4be9aeb6c28dda4085;p=dpdk.git net/sfc/base: use MCDIv2 for requests with too long response Use MCDIv2 for requests with a response size too long for MCDIv1. Required for MC_CMD_MAC_STATS to reports the stats without using DMA. Signed-off-by: Mark Spender Signed-off-by: Andrew Rybchenko --- diff --git a/drivers/net/sfc/base/efx_mcdi.c b/drivers/net/sfc/base/efx_mcdi.c index c61b943c12..888a47b213 100644 --- a/drivers/net/sfc/base/efx_mcdi.c +++ b/drivers/net/sfc/base/efx_mcdi.c @@ -290,7 +290,8 @@ efx_mcdi_request_start( */ if ((max_version >= 2) && ((emrp->emr_cmd > MC_CMD_CMD_SPACE_ESCAPE_7) || - (emrp->emr_in_length > MCDI_CTL_SDU_LEN_MAX_V1))) { + (emrp->emr_in_length > MCDI_CTL_SDU_LEN_MAX_V1) || + (emrp->emr_out_length > MCDI_CTL_SDU_LEN_MAX_V1))) { /* Construct MCDI v2 header */ hdr_len = sizeof (hdr); EFX_POPULATE_DWORD_8(hdr[0],