* [PATCH] DRBG: fix sparse warning for cpu_to_be[32|64] [not found] <53fc2da5.AS8xtJ0DprRMVjVq%fengguang.wu@intel.com> @ 2014-08-26 7:32 ` Stephan Mueller 2014-08-26 7:34 ` Herbert Xu 0 siblings, 1 reply; 2+ messages in thread From: Stephan Mueller @ 2014-08-26 7:32 UTC (permalink / raw) To: Herbert Xu; +Cc: kbuild test robot, kbuild-all, linux-crypto, linux-kernel The sparse tool complained that the cpu_to_be[32|64] functions return __be[32|64] instead of __u32 or __u64. The patch replaces the __u32 and __u64 with __be32 and __be64. Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Stephan Mueller <smueller@chronox.de> --- crypto/drbg.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crypto/drbg.c b/crypto/drbg.c index 9fd239f..39ed918 100644 --- a/crypto/drbg.c +++ b/crypto/drbg.c @@ -277,7 +277,7 @@ static bool drbg_fips_continuous_test(struct drbg_state *drbg, static inline void drbg_cpu_to_be32(__u32 val, unsigned char *buf) { struct s { - __u32 conv; + __be32 conv; }; struct s *conversion = (struct s *) buf; @@ -989,7 +989,7 @@ static int drbg_hash_generate(struct drbg_state *drbg, int ret = 0; union { unsigned char req[8]; - __u64 req_int; + __be64 req_int; } u; unsigned char prefix = DRBG_PREFIX3; struct drbg_string data1, data2; -- 1.9.3 ^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] DRBG: fix sparse warning for cpu_to_be[32|64] 2014-08-26 7:32 ` [PATCH] DRBG: fix sparse warning for cpu_to_be[32|64] Stephan Mueller @ 2014-08-26 7:34 ` Herbert Xu 0 siblings, 0 replies; 2+ messages in thread From: Herbert Xu @ 2014-08-26 7:34 UTC (permalink / raw) To: Stephan Mueller; +Cc: kbuild test robot, kbuild-all, linux-crypto, linux-kernel On Tue, Aug 26, 2014 at 09:32:24AM +0200, Stephan Mueller wrote: > The sparse tool complained that the cpu_to_be[32|64] functions return > __be[32|64] instead of __u32 or __u64. The patch replaces the __u32 and > __u64 with __be32 and __be64. > > Reported-by: kbuild test robot <fengguang.wu@intel.com> > Signed-off-by: Stephan Mueller <smueller@chronox.de> Patch applied. Thanks. -- 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 ^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-08-26 7:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <53fc2da5.AS8xtJ0DprRMVjVq%fengguang.wu@intel.com>
2014-08-26 7:32 ` [PATCH] DRBG: fix sparse warning for cpu_to_be[32|64] Stephan Mueller
2014-08-26 7:34 ` Herbert Xu
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox