mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Herbert Xu <herbert@gondor.apana.org.au>
To: Eric Biggers <ebiggers3@gmail.com>
Cc: Jason@zx2c4.com, davem@davemloft.net, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org, jeanphilippe.aumasson@gmail.com,
	torvalds@linux-foundation.org, David.Laight@aculab.com,
	eric.dumazet@gmail.com
Subject: Re: [PATCH net-next 1/4] siphash: add cryptographically secure PRF
Date: Thu, 12 Jan 2017 23:04:17 +0800	[thread overview]
Message-ID: <20170112150417.GA15951@gondor.apana.org.au> (raw)
In-Reply-To: <20170107040459.GA575@zzz>

Eric Biggers <ebiggers3@gmail.com> wrote:
> Hi Jason, just a few comments:
> 
> On Fri, Jan 06, 2017 at 09:10:52PM +0100, Jason A. Donenfeld wrote:
>> +#define SIPHASH_ALIGNMENT __alignof__(u64)
>> +typedef u64 siphash_key_t[2];
> 
> I was confused by all the functions passing siphash_key_t "by value" until I saw
> that it's actually typedefed to u64[2].  Have you considered making it a struct
> instead, something like this?
> 
> typedef struct {
>        u64 v[2];
> } siphash_key_t;

If it's just an 128-bit value then we have u128 in crypto/b128ops.h
that could be generalised for this.

Cheers,
-- 
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

  parent reply	other threads:[~2017-01-12 15:30 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-06 18:37 Jason A. Donenfeld
2017-01-06 18:37 ` [PATCH net-next 2/4] siphash: implement HalfSipHash1-3 for hash tables Jason A. Donenfeld
2017-01-06 18:37 ` [PATCH net-next 3/4] secure_seq: use SipHash in place of MD5 Jason A. Donenfeld
2017-01-06 18:37 ` [PATCH net-next 4/4] syncookies: use SipHash in place of SHA1 Jason A. Donenfeld
2017-01-06 19:57 ` [PATCH net-next 1/4] siphash: add cryptographically secure PRF David Miller
2017-01-06 20:03   ` Jason A. Donenfeld
2017-01-06 20:10   ` [PATCH net-next 0/4] Introduce The SipHash PRF Jason A. Donenfeld
2017-01-06 20:10     ` [PATCH net-next 1/4] siphash: add cryptographically secure PRF Jason A. Donenfeld
2017-01-06 20:32       ` Jean-Philippe Aumasson
2017-01-06 20:41         ` David Miller
2017-01-07  4:04       ` Eric Biggers
2017-01-07 13:11         ` Jason A. Donenfeld
2017-01-12 15:04         ` Herbert Xu [this message]
2017-01-12 18:30           ` Jason A. Donenfeld
2017-01-06 20:10     ` [PATCH net-next 2/4] siphash: implement HalfSipHash1-3 for hash tables Jason A. Donenfeld
2017-01-06 20:33       ` Jean-Philippe Aumasson
2017-01-06 20:10     ` [PATCH net-next 3/4] secure_seq: use SipHash in place of MD5 Jason A. Donenfeld
2017-01-06 20:10     ` [PATCH net-next 4/4] syncookies: use SipHash in place of SHA1 Jason A. Donenfeld

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170112150417.GA15951@gondor.apana.org.au \
    --to=herbert@gondor.apana.org.au \
    --cc=David.Laight@aculab.com \
    --cc=Jason@zx2c4.com \
    --cc=davem@davemloft.net \
    --cc=ebiggers3@gmail.com \
    --cc=eric.dumazet@gmail.com \
    --cc=jeanphilippe.aumasson@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®