apm821xx: backport crypto4xx patches from 4.15
[oweals/openwrt.git] / target / linux / apm821xx / patches-4.14 / 020-0015-crypto-crypto4xx-fix-type-mismatch-compiler-error.patch
1 From 333eb3edda3842f3e5dbd723cb18bbe47eb0508b Mon Sep 17 00:00:00 2001
2 From: Christian Lamparter <chunkeey@gmail.com>
3 Date: Wed, 4 Oct 2017 01:00:07 +0200
4 Subject: [PATCH 15/25] crypto: crypto4xx - fix type mismatch compiler error
5
6 This patch fixes a type mismatch error that I accidentally
7 introduced when I moved and refactored the dynamic_contents
8 helpers.
9
10 Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
11 Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
12 ---
13  drivers/crypto/amcc/crypto4xx_sa.h | 4 ++--
14  1 file changed, 2 insertions(+), 2 deletions(-)
15
16 --- a/drivers/crypto/amcc/crypto4xx_sa.h
17 +++ b/drivers/crypto/amcc/crypto4xx_sa.h
18 @@ -266,9 +266,9 @@ get_dynamic_sa_offset_state_ptr_field(st
19         return sizeof(struct dynamic_sa_ctl) + offset * 4;
20  }
21  
22 -static inline u8 *get_dynamic_sa_key_field(struct dynamic_sa_ctl *cts)
23 +static inline u32 *get_dynamic_sa_key_field(struct dynamic_sa_ctl *cts)
24  {
25 -       return (u8 *) ((unsigned long)cts + sizeof(struct dynamic_sa_ctl));
26 +       return (u32 *) ((unsigned long)cts + sizeof(struct dynamic_sa_ctl));
27  }
28  
29  #endif