hwrng: cn10k - Optimize cn10k_rng_read()
commit d26a602acfdc543a196ec1d12463c8e5de6ff73a from git@git.assembla.com:cavium/WindRiver.linux.git This function assumes that sizeof(void) is 1 and arithmetic works for void pointers. This is a GNU C extention and may not work with other compilers. Change this by using an u8 pointer. Also move cn10k_read_trng() out of a loop thus saving some cycles. Change-Id: I3ddfd9e2142764d90b6ed7b8ad996cc4d3f7b2e4 Fixes: 38e9791a ("hwrng: cn10k - Add random number generator support") Signed-off-by:Vladis Dronov <vdronov@redhat.com> Signed-off-by:
Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by:
Anil Kumar Reddy <areddy3@marvell.com> Reviewed-on: https://sj1git1.cavium.com/c/IP/SW/kernel/linux/+/87095 Reviewed-by:
Sunil Kovvuri Goutham <sgoutham@marvell.com> Tested-by:
Sunil Kovvuri Goutham <sgoutham@marvell.com> Signed-off-by:
Ruiqiang Hao <Ruiqiang.Hao@windriver.com>
Loading
Please register or sign in to comment