]> git.baikalelectronics.ru Git - kernel.git/commit
xfrm: Fix replay window size calculation on initialization
authorSteffen Klassert <steffen.klassert@secunet.com>
Mon, 25 Apr 2011 19:39:24 +0000 (19:39 +0000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 26 Apr 2011 19:46:03 +0000 (12:46 -0700)
commit87e3af77ba9957291f480b18f4b60099784854ed
tree743671d99f90e3d2ffc2c915c2aa91b20abada43
parentc0566b5aa95a2db206a1b134b1a37429916c1803
xfrm: Fix replay window size calculation on initialization

On replay initialization, we compute the size of the replay
buffer to see if the replay window fits into the buffer.
This computation lacks a mutliplication by 8 because we need
the size in bit, not in byte. So we might return an error
even though the replay window would fit into the buffer.
This patch fixes this issue.

Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/xfrm/xfrm_replay.c