• Maxime Chevallier's avatar
    net: mvpp2: cls: Use RSS contexts to handle RSS tables · 895586d5
    Maxime Chevallier authored
    The PPv2 controller has 8 RSS tables that are shared across all ports on
    a given PPv2 instance. The previous implementation allocated one table
    per port, leaving others unused.
    
    By using RSS contexts, we can make use of multiple RSS tables per
    port, one being the default table (always id 0), the other ones being
    used as destinations for flow steering, in the same way as rx rings.
    
    This commit introduces RSS contexts management in the PPv2 driver. We
    always reserve one table per port, allocated when the port is probed.
    
    The global table list is stored in the struct mvpp2, as it's a global
    resource. Each port then maintains a list of indices in that global
    table, that way each port can have it's own numbering scheme starting
    from 0.
    
    One limitation that seems unavoidable is that the hashing parameters are
    shared across all RSS contexts for a given port. Hashing parameters for
    ctx 0 will be applied to all contexts.
    Signed-off-by: default avatarMaxime Chevallier <maxime.chevallier@bootlin.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    895586d5
mvpp2_main.c 153 KB