Mandeep Singh Baines 1eb19a12bd lib/sha1: use the git implementation of SHA-1
For ChromiumOS, we use SHA-1 to verify the integrity of the root
filesystem.  The speed of the kernel sha-1 implementation has a major
impact on our boot performance.

To improve boot performance, we investigated using the heavily optimized
sha-1 implementation used in git.  With the git sha-1 implementation, we
see a 11.7% improvement in boot time.

10 reboots, remove slowest/fastest.

Before:

  Mean: 6.58 seconds Stdev: 0.14

After (with git sha-1, this patch):

  Mean: 5.89 seconds Stdev: 0.07

The other cool thing about the git SHA-1 implementation is that it only
needs 64 bytes of stack for the workspace while the original kernel
implementation needed 320 bytes.

Signed-off-by: Mandeep Singh Baines <msb@chromium.org>
Cc: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Cc: Nicolas Pitre <nico@cam.org>
Cc: Herbert Xu <herbert@gondor.apana.org.au>
Cc: David S. Miller <davem@davemloft.net>
Cc: linux-crypto@vger.kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-08-06 11:26:52 -07:00
..
2011-07-26 16:49:47 -07:00
2011-07-26 16:49:47 -07:00
2011-03-11 14:25:50 +00:00
2011-08-03 11:30:42 -04:00
2011-03-31 11:26:23 -03:00
2011-07-26 16:49:47 -07:00
2011-07-26 16:49:47 -07:00
2011-03-31 11:26:23 -03:00
2011-07-25 20:57:14 -07:00
2009-06-18 13:04:05 -07:00
2010-05-25 08:07:06 -07:00
2010-04-06 15:52:11 -07:00
2010-08-09 20:45:05 -07:00
2011-08-03 11:30:42 -04:00
2010-11-22 13:25:13 +10:00
2011-07-25 20:57:16 -07:00
2011-07-25 20:57:15 -07:00
2011-08-03 11:30:42 -04:00
2011-03-31 11:26:23 -03:00
2010-06-16 18:08:13 +02:00
2010-01-11 09:34:05 -08:00
2011-03-31 11:26:23 -03:00
2010-05-19 22:40:47 -04:00
2011-07-25 21:00:19 -07:00