From: Iuliana Prodan <iuliana.prodan@nxp.com>
To: Herbert Xu <herbert@gondor.apana.org.au>,
Horia Geanta <horia.geanta@nxp.com>,
Aymen Sghaier <aymen.sghaier@nxp.com>
Cc: "David S. Miller" <davem@davemloft.net>,
linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-imx <linux-imx@nxp.com>
Subject: [PATCH] crypto: caam - move shared symbols in a common location
Date: Thu, 18 Jul 2019 17:49:09 +0300 [thread overview]
Message-ID: <1563461349-24876-1-git-send-email-iuliana.prodan@nxp.com> (raw)
Moved to a common location the symbols shared by all CAAM drivers (jr,
qi, qi2).
Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
---
This patch depends on series:
https://patchwork.kernel.org/project/linux-crypto/list/?series=147479
drivers/crypto/caam/common_if.c | 7 +++++++
drivers/crypto/caam/common_if.h | 7 +++++++
drivers/crypto/caam/error.c | 6 ------
drivers/crypto/caam/error.h | 5 -----
4 files changed, 14 insertions(+), 11 deletions(-)
diff --git a/drivers/crypto/caam/common_if.c b/drivers/crypto/caam/common_if.c
index 1291d3d..071b08d 100644
--- a/drivers/crypto/caam/common_if.c
+++ b/drivers/crypto/caam/common_if.c
@@ -7,6 +7,13 @@
#include "compat.h"
#include "common_if.h"
+#include <linux/types.h>
+
+bool caam_little_end;
+EXPORT_SYMBOL(caam_little_end);
+
+bool caam_imx;
+EXPORT_SYMBOL(caam_imx);
/*
* validate key length for AES algorithms
diff --git a/drivers/crypto/caam/common_if.h b/drivers/crypto/caam/common_if.h
index 61d5516..5fb8840 100644
--- a/drivers/crypto/caam/common_if.h
+++ b/drivers/crypto/caam/common_if.h
@@ -8,6 +8,8 @@
#ifndef CAAM_COMMON_LOCATION_H
#define CAAM_COMMON_LOCATION_H
+#include "desc.h"
+
int check_aes_keylen(unsigned int keylen);
int check_gcm_authsize(unsigned int authsize);
@@ -16,4 +18,9 @@ int check_rfc4106_authsize(unsigned int authsize);
int check_ipsec_assoclen(unsigned int assoclen);
+static inline bool is_mdha(u32 algtype)
+{
+ return (algtype & OP_ALG_ALGSEL_MASK & ~OP_ALG_ALGSEL_SUBMASK) ==
+ OP_ALG_CHA_MDHA;
+}
#endif /* CAAM_COMMON_LOCATION_H */
diff --git a/drivers/crypto/caam/error.c b/drivers/crypto/caam/error.c
index b7fbf1b..b901872 100644
--- a/drivers/crypto/caam/error.c
+++ b/drivers/crypto/caam/error.c
@@ -50,12 +50,6 @@ void caam_dump_sg(const char *prefix_str, int prefix_type,
#endif /* DEBUG */
EXPORT_SYMBOL(caam_dump_sg);
-bool caam_little_end;
-EXPORT_SYMBOL(caam_little_end);
-
-bool caam_imx;
-EXPORT_SYMBOL(caam_imx);
-
static const struct {
u8 value;
const char *error_text;
diff --git a/drivers/crypto/caam/error.h b/drivers/crypto/caam/error.h
index 16809fa..e2f6ed8 100644
--- a/drivers/crypto/caam/error.h
+++ b/drivers/crypto/caam/error.h
@@ -21,9 +21,4 @@ void caam_dump_sg(const char *prefix_str, int prefix_type,
int rowsize, int groupsize, struct scatterlist *sg,
size_t tlen, bool ascii);
-static inline bool is_mdha(u32 algtype)
-{
- return (algtype & OP_ALG_ALGSEL_MASK & ~OP_ALG_ALGSEL_SUBMASK) ==
- OP_ALG_CHA_MDHA;
-}
#endif /* CAAM_ERROR_H */
--
2.1.0
next reply other threads:[~2019-07-18 14:49 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-18 14:49 Iuliana Prodan [this message]
2019-07-19 16:54 ` [PATCH] crypto: caam - move shared symbols in a common location Horia Geanta
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1563461349-24876-1-git-send-email-iuliana.prodan@nxp.com \
--to=iuliana.prodan@nxp.com \
--cc=aymen.sghaier@nxp.com \
--cc=davem@davemloft.net \
--cc=herbert@gondor.apana.org.au \
--cc=horia.geanta@nxp.com \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-imx@nxp.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).