All of lore.kernel.org
 help / color / mirror / Atom feed
From: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
To: herbert@gondor.apana.org.au
Cc: linux-crypto@vger.kernel.org, qat-linux@intel.com,
	Vlad Dronov <vdronov@redhat.com>,
	Giovanni Cabiddu <giovanni.cabiddu@intel.com>,
	Wojciech Ziemba <wojciech.ziemba@intel.com>,
	Adam Guerin <adam.guerin@intel.com>
Subject: [PATCH 6/9] crypto: qat - relocate qat_algs_alloc_flags()
Date: Thu, 18 Aug 2022 19:01:17 +0100	[thread overview]
Message-ID: <20220818180120.63452-7-giovanni.cabiddu@intel.com> (raw)
In-Reply-To: <20220818180120.63452-1-giovanni.cabiddu@intel.com>

Move qat_algs_alloc_flags() from qat_crypto.h to qat_bl.h as this will
be used also by the compression logic.

Signed-off-by: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Reviewed-by: Wojciech Ziemba <wojciech.ziemba@intel.com>
Reviewed-by: Adam Guerin <adam.guerin@intel.com>
---
 drivers/crypto/qat/qat_common/qat_bl.h     | 6 ++++++
 drivers/crypto/qat/qat_common/qat_crypto.h | 5 -----
 2 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/drivers/crypto/qat/qat_common/qat_bl.h b/drivers/crypto/qat/qat_common/qat_bl.h
index e8c02a02415a..6033c79cb93c 100644
--- a/drivers/crypto/qat/qat_common/qat_bl.h
+++ b/drivers/crypto/qat/qat_common/qat_bl.h
@@ -2,6 +2,7 @@
 /* Copyright(c) 2014 - 2022 Intel Corporation */
 #ifndef QAT_BL_H
 #define QAT_BL_H
+#include <linux/crypto.h>
 #include <linux/scatterlist.h>
 #include <linux/types.h>
 
@@ -52,4 +53,9 @@ int qat_alg_sgl_to_bufl(struct adf_accel_dev *accel_dev,
 			struct qat_sgl_to_bufl_params *params,
 			gfp_t flags);
 
+static inline gfp_t qat_algs_alloc_flags(struct crypto_async_request *req)
+{
+	return req->flags & CRYPTO_TFM_REQ_MAY_SLEEP ? GFP_KERNEL : GFP_ATOMIC;
+}
+
 #endif
diff --git a/drivers/crypto/qat/qat_common/qat_crypto.h b/drivers/crypto/qat/qat_common/qat_crypto.h
index 505e881022a7..6a0e961bb9dc 100644
--- a/drivers/crypto/qat/qat_common/qat_crypto.h
+++ b/drivers/crypto/qat/qat_common/qat_crypto.h
@@ -65,9 +65,4 @@ static inline bool adf_hw_dev_has_crypto(struct adf_accel_dev *accel_dev)
 	return true;
 }
 
-static inline gfp_t qat_algs_alloc_flags(struct crypto_async_request *req)
-{
-	return req->flags & CRYPTO_TFM_REQ_MAY_SLEEP ? GFP_KERNEL : GFP_ATOMIC;
-}
-
 #endif
-- 
2.37.1


  parent reply	other threads:[~2022-08-18 18:02 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-18 18:01 [PATCH 0/9] crypto: qat - enable compression deflate algorithm Giovanni Cabiddu
2022-08-18 18:01 ` [PATCH 1/9] crypto: qat - relocate bufferlist logic Giovanni Cabiddu
2022-08-18 18:01 ` [PATCH 2/9] crypto: qat - change bufferlist logic interface Giovanni Cabiddu
2022-08-18 18:01 ` [PATCH 3/9] crypto: qat - generalize crypto request buffers Giovanni Cabiddu
2022-08-18 18:01 ` [PATCH 4/9] crypto: qat - extend buffer list interface Giovanni Cabiddu
2022-08-18 18:01 ` [PATCH 5/9] crypto: qat - relocate backlog related structures Giovanni Cabiddu
2022-08-18 18:01 ` Giovanni Cabiddu [this message]
2022-08-18 18:01 ` [PATCH 7/9] crypto: qat - rename and relocate GEN2 config function Giovanni Cabiddu
2022-08-18 18:01 ` [PATCH 8/9] crypto: qat - expose deflate through acomp api for QAT GEN2 Giovanni Cabiddu
2022-08-26 10:28   ` Herbert Xu
2022-08-26 14:21     ` Giovanni Cabiddu
2022-08-30  9:08       ` Herbert Xu
2022-09-15 13:09         ` Giovanni Cabiddu
2022-09-16  9:41           ` Herbert Xu
2022-08-18 18:01 ` [PATCH 9/9] crypto: qat - enable deflate for QAT GEN4 Giovanni Cabiddu

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=20220818180120.63452-7-giovanni.cabiddu@intel.com \
    --to=giovanni.cabiddu@intel.com \
    --cc=adam.guerin@intel.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=qat-linux@intel.com \
    --cc=vdronov@redhat.com \
    --cc=wojciech.ziemba@intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.