staging: ccree: use array for double buffer
authorGilad Ben-Yossef <gilad@benyossef.com>
Sun, 7 Jan 2018 12:14:28 +0000 (12:14 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 8 Jan 2018 15:27:23 +0000 (16:27 +0100)
commit89c2db889d2901955c86f36c0d6bb39b6547f05d
tree6beb5f517157d68128f7d0493d658ef706abbc0d
parent46856e6cf237c5f42f850facd1e059533ac7adad
staging: ccree: use array for double buffer

The ccree hash code is using a double buffer to hold data
for processing but manages the buffers and their associated
data count in two separate fields and uses a predicate to
chose which to use.

Move to using a proper 2 members array for a much cleaner code.

Signed-off-by: Gilad Ben-Yossef <gilad@benyossef.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/ccree/ssi_buffer_mgr.c
drivers/staging/ccree/ssi_hash.c
drivers/staging/ccree/ssi_hash.h