• Jack Morgenstein's avatar
    mlx4_core: Adjustments to Flow Steering activation logic for SR-IOV · 7b8157be
    Jack Morgenstein authored
    Separate flow steering capability detection from the decision to activate.
    
    For the master (and for native), detect the flow steering capability
    in mlx4_dev_cap, but activate the appropriate steering type in a new
    function choose_flow_steering() based on detected data.
    
    For VFs, activate flow steering based on what was actually activated
    by the master, where that info is obtained via QUERY_HCA. This fixes
    the current VF detection which is wrongly based on QUERY_DEV_CAP.
    
    Also, for SR-IOV mode, if flow steering may be activated, do so only
    if the max number of QPs per rule is sufficient to satisfy one
    subscription per VF.  If not, fall back to B0 mode. This is needed to
    serve registrations done by L2 network drivers such as mlx4_en and
    IPoIB when the network stack attempts to join to multicast groups such
    as all-hosts or the IPoIB broadcast group.
    Signed-off-by: default avatarJack Morgenstein <jackm@dev.mellanox.co.il>
    Signed-off-by: default avatarOr Gerlitz <ogerlitz@mellanox.com>
    Signed-off-by: default avatarRoland Dreier <roland@purestorage.com>
    7b8157be
fw.h 5.84 KB