• Jakub Kicinski's avatar
    nfp: add async reconfiguration mechanism · 3d780b92
    Jakub Kicinski authored
    Some callers of nfp_net_reconfig() are in atomic context so
    we used to busy wait for commands to complete.  In worst case
    scenario that means locking up a core for up to 5 seconds
    when a command times out.  Lets add a timer-based mechanism
    of asynchronously checking whether reconfiguration completed
    successfully for atomic callers to use.  Non-atomic callers
    can now just sleep.
    
    The approach taken is quite simple because (1) synchronous
    reconfigurations always happen under RTNL (or before device
    is registered); (2) we can coalesce pending reconfigs.
    There is no need for request queues, timer which eventually
    takes a look at reconfiguration result to report errors is
    good enough.
    Signed-off-by: default avatarJakub Kicinski <jakub.kicinski@netronome.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    3d780b92
nfp_net.h 23.6 KB