lkml.org 
[lkml]   [2016]   [Jun]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH v4 02/29] rxrpc: Avoid using stack memory in SG lists in rxkad
    On Tue, Jun 28, 2016 at 08:32:46AM +0100, David Howells wrote:
    > Andy Lutomirski <luto@kernel.org> wrote:
    >
    > > @@ -277,6 +277,7 @@ struct rxrpc_connection {
    > > struct key *key; /* security for this connection (client) */
    > > struct key *server_key; /* security for this service */
    > > struct crypto_skcipher *cipher; /* encryption handle */
    > > + struct rxrpc_crypt csum_iv_head; /* leading block for csum_iv */
    > > struct rxrpc_crypt csum_iv; /* packet checksum base */
    > > unsigned long events;
    > > #define RXRPC_CONN_CHALLENGE 0 /* send challenge packet */
    >
    > NAK. This won't work. csum_iv_head is per packet being processed, but you've
    > put it in rxrpc_connection which is shared amongst several creators/digestors
    > of packets. Putting it in rxrpc_call won't work either since it's also needed
    > for connection level packets.

    Huh? If you can't write to csum_iv_head without clobbering others
    then by the same reasoning you can't write to csum_iv either. So
    unless you're saying the existing code is already broken then there
    is nothing wrong with the patch.
    --
    Email: Herbert Xu <herbert@gondor.apana.org.au>
    Home Page: http://gondor.apana.org.au/~herbert/
    PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

    \
     
     \ /
      Last update: 2016-06-28 10:21    [W:4.441 / U:0.184 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site