From: David Marchand <david.marchand@redhat.com>
To: dev@dpdk.org
Cc: Declan Doherty <declan.doherty@intel.com>,
Gagandeep Singh <g.singh@nxp.com>,
Hemant Agrawal <hemant.agrawal@nxp.com>,
Akhil Goyal <akhil.goyal@nxp.com>,
Pablo de Lara <pablo.de.lara.guarch@intel.com>,
Tomasz Duszynski <tdu@semihalf.com>,
Michael Shamis <michaelsh@marvell.com>,
Liron Himi <lironh@marvell.com>,
Anoob Joseph <anoobj@marvell.com>,
Fan Zhang <roy.fan.zhang@intel.com>,
Jay Zhou <jianjay.zhou@huawei.com>
Subject: [dpdk-dev] [PATCH 07/11] drivers/crypto: use new logtype wrapper
Date: Mon, 19 Aug 2019 13:41:55 +0200 [thread overview]
Message-ID: <1566214919-32250-8-git-send-email-david.marchand@redhat.com> (raw)
In-Reply-To: <1566214919-32250-1-git-send-email-david.marchand@redhat.com>
Make use of the newly introduced wrapper.
Signed-off-by: David Marchand <david.marchand@redhat.com>
---
drivers/crypto/aesni_gcm/aesni_gcm_pmd.c | 7 ++---
drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c | 6 ++--
drivers/crypto/caam_jr/caam_jr.c | 8 ++---
drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c | 9 ++----
drivers/crypto/dpaa_sec/dpaa_sec.c | 8 ++---
drivers/crypto/kasumi/rte_kasumi_pmd.c | 6 ++--
drivers/crypto/mvsam/rte_mrvl_pmd.c | 6 ++--
drivers/crypto/null/null_crypto_pmd.c | 6 ++--
drivers/crypto/octeontx/otx_cryptodev.c | 9 ++----
drivers/crypto/openssl/rte_openssl_pmd.c | 6 ++--
drivers/crypto/scheduler/rte_cryptodev_scheduler.c | 6 ++--
drivers/crypto/snow3g/rte_snow3g_pmd.c | 6 ++--
drivers/crypto/virtio/virtio_cryptodev.c | 35 +++++++---------------
drivers/crypto/zuc/rte_zuc_pmd.c | 6 ++--
14 files changed, 36 insertions(+), 88 deletions(-)
diff --git a/drivers/crypto/aesni_gcm/aesni_gcm_pmd.c b/drivers/crypto/aesni_gcm/aesni_gcm_pmd.c
index 1006a5c..0d855d2 100644
--- a/drivers/crypto/aesni_gcm/aesni_gcm_pmd.c
+++ b/drivers/crypto/aesni_gcm/aesni_gcm_pmd.c
@@ -663,8 +663,5 @@ RTE_PMD_REGISTER_PARAM_STRING(CRYPTODEV_NAME_AESNI_GCM_PMD,
RTE_PMD_REGISTER_CRYPTO_DRIVER(aesni_gcm_crypto_drv, aesni_gcm_pmd_drv.driver,
cryptodev_driver_id);
-
-RTE_INIT(aesni_gcm_init_log)
-{
- aesni_gcm_logtype_driver = rte_log_register("pmd.crypto.aesni_gcm");
-}
+RTE_LOG_REGISTER(aesni_gcm_logtype_driver, "pmd.crypto.aesni_gcm",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c b/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c
index b495a96..1cf9d5d 100644
--- a/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c
+++ b/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c
@@ -1380,7 +1380,5 @@ RTE_PMD_REGISTER_CRYPTO_DRIVER(aesni_mb_crypto_drv,
cryptodev_aesni_mb_pmd_drv.driver,
cryptodev_driver_id);
-RTE_INIT(aesni_mb_init_log)
-{
- aesni_mb_logtype_driver = rte_log_register("pmd.crypto.aesni_mb");
-}
+RTE_LOG_REGISTER(aesni_mb_logtype_driver, "pmd.crypto.aesni_mb",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/caam_jr/caam_jr.c b/drivers/crypto/caam_jr/caam_jr.c
index 77c0303..4824e13 100644
--- a/drivers/crypto/caam_jr/caam_jr.c
+++ b/drivers/crypto/caam_jr/caam_jr.c
@@ -2500,9 +2500,5 @@ RTE_PMD_REGISTER_PARAM_STRING(CRYPTODEV_NAME_CAAM_JR_PMD,
RTE_PMD_REGISTER_CRYPTO_DRIVER(caam_jr_crypto_drv, cryptodev_caam_jr_drv.driver,
cryptodev_driver_id);
-RTE_INIT(caam_jr_init_log)
-{
- caam_jr_logtype = rte_log_register("pmd.crypto.caam");
- if (caam_jr_logtype >= 0)
- rte_log_set_level(caam_jr_logtype, RTE_LOG_NOTICE);
-}
+RTE_LOG_REGISTER(caam_jr_logtype, "pmd.crypto.caam",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c b/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
index 26458e5..3cb7b08 100644
--- a/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
+++ b/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
@@ -3454,10 +3454,5 @@ RTE_PMD_REGISTER_DPAA2(CRYPTODEV_NAME_DPAA2_SEC_PMD, rte_dpaa2_sec_driver);
RTE_PMD_REGISTER_CRYPTO_DRIVER(dpaa2_sec_crypto_drv,
rte_dpaa2_sec_driver.driver, cryptodev_driver_id);
-RTE_INIT(dpaa2_sec_init_log)
-{
- /* Bus level logs */
- dpaa2_logtype_sec = rte_log_register("pmd.crypto.dpaa2");
- if (dpaa2_logtype_sec >= 0)
- rte_log_set_level(dpaa2_logtype_sec, RTE_LOG_NOTICE);
-}
+RTE_LOG_REGISTER(dpaa2_logtype_sec, "pmd.crypto.dpaa2",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/dpaa_sec/dpaa_sec.c b/drivers/crypto/dpaa_sec/dpaa_sec.c
index 122c80a..3071258 100644
--- a/drivers/crypto/dpaa_sec/dpaa_sec.c
+++ b/drivers/crypto/dpaa_sec/dpaa_sec.c
@@ -2765,9 +2765,5 @@ RTE_PMD_REGISTER_DPAA(CRYPTODEV_NAME_DPAA_SEC_PMD, rte_dpaa_sec_driver);
RTE_PMD_REGISTER_CRYPTO_DRIVER(dpaa_sec_crypto_drv, rte_dpaa_sec_driver.driver,
cryptodev_driver_id);
-RTE_INIT(dpaa_sec_init_log)
-{
- dpaa_logtype_sec = rte_log_register("pmd.crypto.dpaa");
- if (dpaa_logtype_sec >= 0)
- rte_log_set_level(dpaa_logtype_sec, RTE_LOG_NOTICE);
-}
+RTE_LOG_REGISTER(dpaa_logtype_sec, "pmd.crypto.dpaa",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/kasumi/rte_kasumi_pmd.c b/drivers/crypto/kasumi/rte_kasumi_pmd.c
index 3abdb01..1f30561 100644
--- a/drivers/crypto/kasumi/rte_kasumi_pmd.c
+++ b/drivers/crypto/kasumi/rte_kasumi_pmd.c
@@ -625,7 +625,5 @@ RTE_PMD_REGISTER_PARAM_STRING(CRYPTODEV_NAME_KASUMI_PMD,
RTE_PMD_REGISTER_CRYPTO_DRIVER(kasumi_crypto_drv,
cryptodev_kasumi_pmd_drv.driver, cryptodev_driver_id);
-RTE_INIT(kasumi_init_log)
-{
- kasumi_logtype_driver = rte_log_register("pmd.crypto.kasumi");
-}
+RTE_LOG_REGISTER(kasumi_logtype_driver, "pmd.crypto.kasumi",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/mvsam/rte_mrvl_pmd.c b/drivers/crypto/mvsam/rte_mrvl_pmd.c
index ef2e5ed..4349efd 100644
--- a/drivers/crypto/mvsam/rte_mrvl_pmd.c
+++ b/drivers/crypto/mvsam/rte_mrvl_pmd.c
@@ -1021,7 +1021,5 @@ RTE_PMD_REGISTER_PARAM_STRING(CRYPTODEV_NAME_MRVL_PMD,
RTE_PMD_REGISTER_CRYPTO_DRIVER(mrvl_crypto_drv, cryptodev_mrvl_pmd_drv.driver,
cryptodev_driver_id);
-RTE_INIT(crypto_mrvl_init_log)
-{
- mrvl_logtype_driver = rte_log_register("pmd.crypto.mvsam");
-}
+RTE_LOG_REGISTER(mrvl_logtype_driver, "pmd.crypto.mvsam",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/null/null_crypto_pmd.c b/drivers/crypto/null/null_crypto_pmd.c
index d5e3064..d70cd02 100644
--- a/drivers/crypto/null/null_crypto_pmd.c
+++ b/drivers/crypto/null/null_crypto_pmd.c
@@ -248,7 +248,5 @@ RTE_PMD_REGISTER_PARAM_STRING(CRYPTODEV_NAME_NULL_PMD,
RTE_PMD_REGISTER_CRYPTO_DRIVER(null_crypto_drv, cryptodev_null_pmd_drv.driver,
cryptodev_driver_id);
-RTE_INIT(null_init_log)
-{
- null_logtype_driver = rte_log_register("pmd.crypto.null");
-}
+RTE_LOG_REGISTER(null_logtype_driver, "pmd.crypto.null",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/octeontx/otx_cryptodev.c b/drivers/crypto/octeontx/otx_cryptodev.c
index fc64a5f..fd44763 100644
--- a/drivers/crypto/octeontx/otx_cryptodev.c
+++ b/drivers/crypto/octeontx/otx_cryptodev.c
@@ -121,10 +121,5 @@ RTE_PMD_REGISTER_PCI_TABLE(CRYPTODEV_NAME_OCTEONTX_PMD, pci_id_cpt_table);
RTE_PMD_REGISTER_CRYPTO_DRIVER(otx_cryptodev_drv, otx_cryptodev_pmd.driver,
otx_cryptodev_driver_id);
-RTE_INIT(otx_cpt_init_log)
-{
- /* Bus level logs */
- otx_cryptodev_logtype = rte_log_register("pmd.crypto.octeontx");
- if (otx_cryptodev_logtype >= 0)
- rte_log_set_level(otx_cryptodev_logtype, RTE_LOG_NOTICE);
-}
+RTE_LOG_REGISTER(otx_cryptodev_logtype, "pmd.crypto.octeontx",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/openssl/rte_openssl_pmd.c b/drivers/crypto/openssl/rte_openssl_pmd.c
index 2f55528..372dfb5 100644
--- a/drivers/crypto/openssl/rte_openssl_pmd.c
+++ b/drivers/crypto/openssl/rte_openssl_pmd.c
@@ -2198,7 +2198,5 @@ RTE_PMD_REGISTER_PARAM_STRING(CRYPTODEV_NAME_OPENSSL_PMD,
RTE_PMD_REGISTER_CRYPTO_DRIVER(openssl_crypto_drv,
cryptodev_openssl_pmd_drv.driver, cryptodev_driver_id);
-RTE_INIT(openssl_init_log)
-{
- openssl_logtype_driver = rte_log_register("pmd.crypto.openssl");
-}
+RTE_LOG_REGISTER(openssl_logtype_driver, "pmd.crypto.openssl",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/scheduler/rte_cryptodev_scheduler.c b/drivers/crypto/scheduler/rte_cryptodev_scheduler.c
index 1fef88f..57e7401 100644
--- a/drivers/crypto/scheduler/rte_cryptodev_scheduler.c
+++ b/drivers/crypto/scheduler/rte_cryptodev_scheduler.c
@@ -578,7 +578,5 @@ rte_cryptodev_scheduler_option_get(uint8_t scheduler_id,
return (*sched_ctx->ops.option_get)(dev, option_type, option);
}
-RTE_INIT(scheduler_init_log)
-{
- scheduler_logtype_driver = rte_log_register("pmd.crypto.scheduler");
-}
+RTE_LOG_REGISTER(scheduler_logtype_driver, "pmd.crypto.scheduler",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_CRYPTODEV);
diff --git a/drivers/crypto/snow3g/rte_snow3g_pmd.c b/drivers/crypto/snow3g/rte_snow3g_pmd.c
index 68d7176..fea2dfe 100644
--- a/drivers/crypto/snow3g/rte_snow3g_pmd.c
+++ b/drivers/crypto/snow3g/rte_snow3g_pmd.c
@@ -636,7 +636,5 @@ RTE_PMD_REGISTER_PARAM_STRING(CRYPTODEV_NAME_SNOW3G_PMD,
RTE_PMD_REGISTER_CRYPTO_DRIVER(snow3g_crypto_drv,
cryptodev_snow3g_pmd_drv.driver, cryptodev_driver_id);
-RTE_INIT(snow3g_init_log)
-{
- snow3g_logtype_driver = rte_log_register("pmd.crypto.snow3g");
-}
+RTE_LOG_REGISTER(snow3g_logtype_drivern "pmd.crypto.snow3g",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/virtio/virtio_cryptodev.c b/drivers/crypto/virtio/virtio_cryptodev.c
index f16bdfe..6e2a5ac 100644
--- a/drivers/crypto/virtio/virtio_cryptodev.c
+++ b/drivers/crypto/virtio/virtio_cryptodev.c
@@ -1490,28 +1490,13 @@ RTE_PMD_REGISTER_CRYPTO_DRIVER(virtio_crypto_drv,
rte_virtio_crypto_driver.driver,
cryptodev_virtio_driver_id);
-RTE_INIT(virtio_crypto_init_log)
-{
- virtio_crypto_logtype_init = rte_log_register("pmd.crypto.virtio.init");
- if (virtio_crypto_logtype_init >= 0)
- rte_log_set_level(virtio_crypto_logtype_init, RTE_LOG_NOTICE);
-
- virtio_crypto_logtype_session =
- rte_log_register("pmd.crypto.virtio.session");
- if (virtio_crypto_logtype_session >= 0)
- rte_log_set_level(virtio_crypto_logtype_session,
- RTE_LOG_NOTICE);
-
- virtio_crypto_logtype_rx = rte_log_register("pmd.crypto.virtio.rx");
- if (virtio_crypto_logtype_rx >= 0)
- rte_log_set_level(virtio_crypto_logtype_rx, RTE_LOG_NOTICE);
-
- virtio_crypto_logtype_tx = rte_log_register("pmd.crypto.virtio.tx");
- if (virtio_crypto_logtype_tx >= 0)
- rte_log_set_level(virtio_crypto_logtype_tx, RTE_LOG_NOTICE);
-
- virtio_crypto_logtype_driver =
- rte_log_register("pmd.crypto.virtio.driver");
- if (virtio_crypto_logtype_driver >= 0)
- rte_log_set_level(virtio_crypto_logtype_driver, RTE_LOG_NOTICE);
-}
+RTE_LOG_REGISTER(virtio_crypto_logtype_init, "pmd.crypto.virtio.init",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
+RTE_LOG_REGISTER(virtio_crypto_logtype_session, "pmd.crypto.virtio.session",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
+RTE_LOG_REGISTER(virtio_crypto_logtype_rx, "pmd.crypto.virtio.rx",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
+RTE_LOG_REGISTER(virtio_crypto_logtype_tx, "pmd.crypto.virtio.tx",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
+RTE_LOG_REGISTER(virtio_crypto_logtype_driver, "pmd.crypto.virtio.driver",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
diff --git a/drivers/crypto/zuc/rte_zuc_pmd.c b/drivers/crypto/zuc/rte_zuc_pmd.c
index 637994d..e6a9cb7 100644
--- a/drivers/crypto/zuc/rte_zuc_pmd.c
+++ b/drivers/crypto/zuc/rte_zuc_pmd.c
@@ -544,7 +544,5 @@ RTE_PMD_REGISTER_PARAM_STRING(CRYPTODEV_NAME_ZUC_PMD,
RTE_PMD_REGISTER_CRYPTO_DRIVER(zuc_crypto_drv, cryptodev_zuc_pmd_drv.driver,
cryptodev_driver_id);
-RTE_INIT(zuc_init_log)
-{
- zuc_logtype_driver = rte_log_register("pmd.crypto.zuc");
-}
+RTE_LOG_REGISTER(zuc_logtype_driver, "pmd.crypto.zuc",
+ RTE_LOG_NOTICE, RTE_LOGTYPE_PMD);
--
1.8.3.1
next prev parent reply other threads:[~2019-08-19 11:43 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-19 11:41 [dpdk-dev] [PATCH 00/11] Fixing log levels for dynamically loaded drivers David Marchand
2019-08-19 11:41 ` [dpdk-dev] [PATCH 01/11] log: fix plugin level restore with patterns David Marchand
2019-08-19 12:30 ` Andrew Rybchenko
2019-08-19 11:41 ` [dpdk-dev] [PATCH 02/11] log: define logtype register wrapper for drivers David Marchand
2019-08-19 12:27 ` Andrew Rybchenko
2019-09-02 14:29 ` Ferruh Yigit
2019-09-03 8:06 ` David Marchand
2019-09-03 8:47 ` Ferruh Yigit
2019-09-04 17:45 ` Thomas Monjalon
2019-09-04 19:21 ` Andrew Rybchenko
2019-09-04 19:41 ` Thomas Monjalon
2019-09-04 19:58 ` Andrew Rybchenko
2019-09-04 20:44 ` Thomas Monjalon
2019-09-05 6:29 ` Andrew Rybchenko
2019-09-05 7:13 ` David Marchand
2019-09-05 7:45 ` Thomas Monjalon
2019-08-19 11:41 ` [dpdk-dev] [PATCH 03/11] drivers/baseband: use new logtype wrapper David Marchand
2019-08-19 15:39 ` Chautru, Nicolas
2019-08-19 11:41 ` [dpdk-dev] [PATCH 04/11] drivers/bus: " David Marchand
2019-08-19 11:41 ` [dpdk-dev] [PATCH 05/11] drivers/common: " David Marchand
2019-08-19 11:41 ` [dpdk-dev] [PATCH 06/11] drivers/compress: " David Marchand
2019-08-19 11:41 ` David Marchand [this message]
2019-08-19 11:41 ` [dpdk-dev] [PATCH 08/11] drivers/event: " David Marchand
2019-08-19 11:41 ` [dpdk-dev] [PATCH 09/11] drivers/mempool: " David Marchand
2019-08-19 11:41 ` [dpdk-dev] [PATCH 10/11] drivers/net: " David Marchand
2019-08-19 14:55 ` Legacy, Allain
2019-09-02 16:11 ` Ferruh Yigit
2019-09-03 8:06 ` David Marchand
2019-09-03 15:03 ` Stephen Hemminger
2019-08-19 11:41 ` [dpdk-dev] [PATCH 11/11] drivers/raw: " David Marchand
2019-09-02 14:17 ` [dpdk-dev] [PATCH 00/11] Fixing log levels for dynamically loaded drivers Ferruh Yigit
2019-09-03 8:06 ` David Marchand
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=1566214919-32250-8-git-send-email-david.marchand@redhat.com \
--to=david.marchand@redhat.com \
--cc=akhil.goyal@nxp.com \
--cc=anoobj@marvell.com \
--cc=declan.doherty@intel.com \
--cc=dev@dpdk.org \
--cc=g.singh@nxp.com \
--cc=hemant.agrawal@nxp.com \
--cc=jianjay.zhou@huawei.com \
--cc=lironh@marvell.com \
--cc=michaelsh@marvell.com \
--cc=pablo.de.lara.guarch@intel.com \
--cc=roy.fan.zhang@intel.com \
--cc=tdu@semihalf.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 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).