• Herbert Xu's avatar
    [XFRM]: Probe selected algorithm only. · d113f0f0
    Herbert Xu authored
    This patch removes an annoying problem in xfrm_user.  As it is every
    time an SA is added it probes every known algorithm in the universe.
    Now if they all existed it would be OK.  However, for the ones which
    don't actually exist this causes multiple /sbin/modprobe processes to
    be spawned which slows the system down when you're adding hundreds of
    SAs.
    
    Since we know the type of algorithm required when we're adding a new
    SA, we can get away with only probing the selected algorithms.  This
    is what the following patch does for xfrm_user.
    Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
    Signed-off-by: default avatarJames Morris <jmorris@redhat.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    d113f0f0
xfrm_user.c 26 KB