diff options
author | Brett Creeley <[email protected]> | 2019-11-13 11:28:17 -0800 |
---|---|---|
committer | Jeff Kirsher <[email protected]> | 2020-01-09 09:21:40 -0800 |
commit | d9d6a9aed3f66f8ce5fa3ca6ca26007d75032296 (patch) | |
tree | 4f67fd4a49b3550ac7dd2c8fe8355fdd12b6aae4 /drivers/fpga/fpga-mgr.c | |
parent | 9546a0b7ce0077d827470f603f2522b845ce5954 (diff) |
i40e: Fix virtchnl_queue_select bitmap validation
Currently in i40e_vc_disable_queues_msg() we are incorrectly
validating the virtchnl queue select bitmaps. The
virtchnl_queue_select rx_queues and tx_queue bitmap is being
compared against ICE_MAX_VF_QUEUES, but the problem is that
these bitmaps can have a value greater than I40E_MAX_VF_QUEUES.
Fix this by comparing the bitmaps against BIT(I40E_MAX_VF_QUEUES).
Also, add the function i40e_vc_validate_vqs_bitmaps() that checks to see
if both virtchnl_queue_select bitmaps are empty along with checking that
the bitmaps only have valid bits set. This function can then be used in
both the queue enable and disable flows.
Suggested-by: Arkady Gilinksky <[email protected]>
Signed-off-by: Brett Creeley <[email protected]>
Tested-by: Andrew Bowers <[email protected]>
Signed-off-by: Jeff Kirsher <[email protected]>
Diffstat (limited to 'drivers/fpga/fpga-mgr.c')
0 files changed, 0 insertions, 0 deletions