• Jakub Kicinski's avatar
    tls: rx: decrypt into a fresh skb · fd31f399
    Jakub Kicinski authored
    We currently CoW Rx skbs whenever we can't decrypt to a user
    space buffer. The skbs can be enormous (64kB) and CoW does
    a linear alloc which has a strong chance of failing under
    memory pressure. Or even without, skb_cow_data() assumes
    GFP_ATOMIC.
    
    Allocate a new frag'd skb and decrypt into it. We finally
    take advantage of the decrypted skb getting returned via
    darg.
    Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    fd31f399
tls_sw.c 67.1 KB