• Alan Brady's avatar
    i40e/i40evf: don't trust VF to reset itself · 17a9422d
    Alan Brady authored
    When using 'ethtool -L' on a VF to change number of requested queues
    from PF, we shouldn't trust the VF to reset itself after making the
    request.  Doing it that way opens the door for a potentially malicious
    VF to do nasty things to the PF which should never be the case.
    
    This makes it such that after VF makes a successful request, PF will
    then reset the VF to institute required changes.  Only if the request
    fails will PF send a message back to VF letting it know the request was
    unsuccessful.
    
    Testing-hints:
    There should be no real functional changes.  This is simply hardening
    against a potentially malicious VF.
    Signed-off-by: default avatarAlan Brady <alan.brady@intel.com>
    Tested-by: default avatarAndrew Bowers <andrewx.bowers@intel.com>
    Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
    17a9422d
i40e_virtchnl_pf.c 89.8 KB