Skip to contentSkip to conversation

Use RTE_LOG_LINE in drivers

PATCH Superseded David Marchand 7 participants 47 messages Sep 7, 2024 – Oct 4, 2024 Page 1 of 2

Subsystems (10)
lore
Share & tools
lore
#0 lore raw

cover Use RTE_LOG_LINE in drivers

This is a continuation of the cleanup effort in logging macros.

As a reminder of what this series is about, RTE_LOG_LINE() has been introduced to check that the format string does not contain a trailing \n. The goal was to prevent from:
- introducing multilines log messages (ugly and unhelpful for lambda users),
- introducing double \n in logs,
- introducing missing \n in logs,

I have built/maintained this series for fixing drivers/ since the beginning of the year and I hope we can merge this series early in 24.11.

Some drivers are not converted because of multiple inconsistencies (like event/dlb2 where the _INFO/_ERR macros add an internal \n but the _DBG macros does not).
Those may be fixed later.

As for the changes on lib/, new macros have been introduced so that backports trigger a build error and force the backport to adjust the patches containing logs accordingly.

Most of the changes have been done with some scripting, but it is likely there are some errors and I hope driver maintainers will review in depth.

A check is added for drivers/ in the hope that new drivers don't introduce more mess.

Yet, sometimes it is not possible to fix macros (a good example is base/ drivers code...), so the check skips *osdep.h headers where calls to RTE_LOG() may be accepted.

Signature · 369 lines
David Marchand

David Marchand (11):
  devtools: fix forbidden token check with multiple files
  devtools: report all warnings in forbidden token check
  net/dpaa: remove broken debug macros
  net/sfc: fix driver logtype token
  drivers: reuse default logtype for SFC drivers
  drivers: move log wrappers to Intel base drivers
  net/txgbe: move wrapper to base driver
  drivers: replace logging helpers
  drivers: remove redundant newline from logs
  drivers: split multilines log messages
  drivers: use per line logging in helpers

 devtools/check-forbidden-tokens.awk           |  15 +-
 devtools/checkpatches.sh                      |  11 +-
 drivers/baseband/acc/acc100_pmd.h             |  12 +-
 drivers/baseband/acc/acc_common.h             |   6 +-
 drivers/baseband/acc/rte_acc100_pmd.c         |  21 +-
 drivers/baseband/acc/rte_vrb_pmd.c            |  27 +-
 drivers/baseband/acc/vrb_pmd.h                |  12 +-
 .../baseband/fpga_5gnr_fec/fpga_5gnr_fec.h    |  15 +-
 .../fpga_5gnr_fec/rte_fpga_5gnr_fec.c         | 267 ++++----
 drivers/baseband/fpga_lte_fec/fpga_lte_fec.c  |  37 +-
 drivers/baseband/la12xx/bbdev_la12xx.c        |   4 +-
 .../baseband/la12xx/bbdev_la12xx_pmd_logs.h   |  16 +-
 drivers/baseband/null/bbdev_null.c            |   5 +-
 .../baseband/turbo_sw/bbdev_turbo_software.c  |  10 +-
 drivers/bus/auxiliary/private.h               |   5 +-
 drivers/bus/cdx/cdx_logs.h                    |   7 +-
 drivers/bus/cdx/cdx_vfio.c                    |   8 +-
 drivers/bus/dpaa/include/fman.h               |   2 +-
 drivers/bus/dpaa/rte_dpaa_logs.h              |   6 +-
 drivers/bus/fslmc/fslmc_bus.c                 |   8 +-
 drivers/bus/fslmc/fslmc_logs.h                |   7 +-
 drivers/bus/fslmc/fslmc_vfio.c                |  10 +-
 drivers/bus/fslmc/portal/dpaa2_hw_dpci.c      |   4 +-
 drivers/bus/ifpga/ifpga_bus.c                 |   8 +-
 drivers/bus/ifpga/ifpga_logs.h                |   3 +-
 drivers/bus/platform/platform.c               |  28 +-
 drivers/bus/platform/platform_params.c        |   2 +-
 drivers/bus/platform/private.h                |   9 +-
 drivers/bus/uacce/uacce.c                     |   4 +-
 drivers/bus/vdev/vdev_logs.h                  |   3 +-
 drivers/bus/vdev/vdev_params.c                |   2 +-
 drivers/bus/vmbus/private.h                   |   3 +-
 drivers/bus/vmbus/vmbus_common.c              |   2 +-
 drivers/common/cnxk/roc_dev.c                 |   2 +-
 drivers/common/cnxk/roc_model.c               |   2 +-
 drivers/common/cnxk/roc_nix_ops.c             |  20 +-
 drivers/common/cnxk/roc_nix_tm.c              |   2 +-
 drivers/common/cnxk/roc_nix_tm_mark.c         |   2 +-
 drivers/common/cnxk/roc_nix_tm_ops.c          |   2 +-
 drivers/common/cnxk/roc_nix_tm_utils.c        |   2 +-
 drivers/common/cnxk/roc_platform.h            |  31 +-
 drivers/common/cnxk/roc_sso.c                 |   2 +-
 drivers/common/cnxk/roc_tim.c                 |   2 +-
 drivers/common/cpt/cpt_pmd_logs.h             |  15 +-
 drivers/common/cpt/cpt_ucode.h                |   4 +-
 drivers/common/dpaax/dpaax_logs.h             |   6 +-
 drivers/common/iavf/iavf_osdep.h              |   8 +-
 drivers/common/idpf/base/idpf_osdep.h         |  10 +-
 drivers/common/idpf/idpf_common_logs.h        |  31 +-
 drivers/common/nfp/nfp_common_log.h           |   5 +-
 drivers/common/nitrox/nitrox_hal.c            |   4 +-
 drivers/common/nitrox/nitrox_logs.h           |   8 +-
 drivers/common/nitrox/nitrox_qp.c             |  10 +-
 drivers/common/octeontx/octeontx_mbox.c       |   4 +-
 drivers/common/octeontx/octeontx_mbox.h       |   5 +-
 drivers/common/qat/qat_logs.h                 |   8 +-
 drivers/common/qat/qat_pf2vf.c                |   4 +-
 drivers/common/qat/qat_qp.c                   |   2 +-
 drivers/common/sfc_efx/sfc_efx_log.h          |   5 +-
 drivers/compress/isal/isal_compress_pmd.c     |  78 +--
 .../compress/isal/isal_compress_pmd_private.h |   3 +-
 drivers/compress/nitrox/nitrox_comp.c         |  44 +-
 drivers/compress/nitrox/nitrox_comp_reqmgr.c  | 170 +++---
 drivers/compress/octeontx/otx_zip.h           |  17 +-
 drivers/compress/octeontx/otx_zip_pmd.c       |  14 +-
 .../compress/uadk/uadk_compress_pmd_private.h |   5 +-
 drivers/compress/zlib/zlib_pmd.c              |  26 +-
 drivers/compress/zlib/zlib_pmd_ops.c          |   4 +-
 drivers/compress/zlib/zlib_pmd_private.h      |   3 +-
 drivers/crypto/armv8/armv8_pmd_private.h      |  16 +-
 drivers/crypto/bcmfs/bcmfs_logs.h             |  10 +-
 drivers/crypto/bcmfs/bcmfs_qp.c               |   2 +-
 drivers/crypto/bcmfs/bcmfs_sym_pmd.c          |   2 +-
 drivers/crypto/bcmfs/bcmfs_sym_session.c      |   2 +-
 drivers/crypto/caam_jr/caam_jr.c              |  39 +-
 drivers/crypto/caam_jr/caam_jr_log.h          |   8 +-
 drivers/crypto/caam_jr/caam_jr_uio.c          |   6 +-
 drivers/crypto/ccp/ccp_dev.c                  |   2 +-
 drivers/crypto/ccp/rte_ccp_pmd.c              |   2 +-
 drivers/crypto/cnxk/cnxk_se.h                 |   6 +-
 drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c   |  98 +--
 drivers/crypto/dpaa2_sec/dpaa2_sec_logs.h     |   8 +-
 drivers/crypto/dpaa2_sec/dpaa2_sec_raw_dp.c   |  16 +-
 drivers/crypto/dpaa_sec/dpaa_sec.c            |  27 +-
 drivers/crypto/dpaa_sec/dpaa_sec_log.h        |   8 +-
 drivers/crypto/dpaa_sec/dpaa_sec_raw_dp.c     |   6 +-
 drivers/crypto/ipsec_mb/ipsec_mb_private.c    |   4 +-
 drivers/crypto/ipsec_mb/ipsec_mb_private.h    |   7 +-
 drivers/crypto/ipsec_mb/pmd_aesni_mb.c        |  28 +-
 drivers/crypto/ipsec_mb/pmd_snow3g.c          |   4 +-
 drivers/crypto/mvsam/mrvl_pmd_private.h       |   5 +-
 drivers/crypto/nitrox/nitrox_sym.c            |  54 +-
 drivers/crypto/nitrox/nitrox_sym_reqmgr.c     |  12 +-
 drivers/crypto/null/null_crypto_pmd_private.h |   5 +-
 .../crypto/octeontx/otx_cryptodev_hw_access.h |   6 +-
 drivers/crypto/openssl/openssl_pmd_private.h  |   5 +-
 drivers/crypto/openssl/rte_openssl_pmd.c      |  42 +-
 drivers/crypto/openssl/rte_openssl_pmd_ops.c  |  44 +-
 drivers/crypto/qat/qat_asym.c                 |   2 +-
 drivers/crypto/qat/qat_sym_session.c          |  12 +-
 .../crypto/scheduler/scheduler_pmd_private.h  |   5 +-
 drivers/crypto/uadk/uadk_crypto_pmd.c         |   8 +-
 drivers/crypto/uadk/uadk_crypto_pmd_private.h |   5 +-
 drivers/crypto/virtio/virtio_cryptodev.c      |  12 +-
 drivers/crypto/virtio/virtio_logs.h           |  30 +-
 drivers/dma/dpaa/dpaa_qdma.c                  |  40 +-
 drivers/dma/dpaa/dpaa_qdma_logs.h             |   8 +-
 drivers/dma/dpaa2/dpaa2_qdma.c                |  10 +-
 drivers/dma/dpaa2/dpaa2_qdma_logs.h           |  10 +-
 drivers/dma/hisilicon/hisi_dmadev.c           |  23 +-
 drivers/dma/idxd/idxd_common.c                |   2 +-
 drivers/dma/idxd/idxd_internal.h              |   5 +-
 drivers/dma/idxd/idxd_pci.c                   |   6 +-
 drivers/dma/ioat/ioat_dmadev.c                |  14 +-
 drivers/dma/ioat/ioat_internal.h              |   5 +-
 drivers/dma/odm/odm.h                         |  21 +-
 drivers/dma/odm/odm_dmadev.c                  |  12 +-
 drivers/dma/skeleton/skeleton_dmadev.c        |   3 +-
 drivers/event/cnxk/cnxk_tim_evdev.c           |   2 +-
 drivers/event/dpaa/dpaa_eventdev.c            |   1 +
 drivers/event/dpaa/dpaa_eventdev.h            |   2 +-
 drivers/event/dpaa2/dpaa2_eventdev.c          |  14 +-
 drivers/event/dpaa2/dpaa2_eventdev_logs.h     |   7 +-
 drivers/event/dsw/dsw_evdev.h                 |   8 +-
 drivers/event/dsw/dsw_event.c                 |  78 +--
 drivers/event/octeontx/ssovf_evdev.h          |   5 +-
 drivers/event/octeontx/timvf_evdev.c          |   2 +-
 drivers/event/octeontx/timvf_evdev.h          |   5 +-
 drivers/event/opdl/opdl_evdev.c               |  30 +-
 drivers/event/opdl/opdl_log.h                 |   9 +-
 drivers/event/opdl/opdl_test.c                | 116 ++--
 drivers/event/skeleton/skeleton_eventdev.h    |   7 +-
 drivers/event/sw/sw_evdev.c                   |  22 +-
 drivers/event/sw/sw_evdev_log.h               |   3 +-
 drivers/event/sw/sw_evdev_xstats.c            |   4 +-
 drivers/gpu/cuda/common.h                     |   3 +-
 drivers/mempool/dpaa/dpaa_mempool.h           |   3 +-
 drivers/mempool/dpaa2/dpaa2_hw_mempool.c      |   8 +-
 drivers/mempool/dpaa2/dpaa2_hw_mempool_logs.h |   6 +-
 drivers/mempool/octeontx/octeontx_fpavf.c     |  22 +-
 drivers/mempool/octeontx/octeontx_pool_logs.h |   5 +-
 .../mempool/octeontx/rte_mempool_octeontx.c   |   6 +-
 drivers/ml/cnxk/cn10k_ml_dev.c                |  32 +-
 drivers/ml/cnxk/cnxk_ml_ops.c                 |  20 +-
 drivers/net/af_packet/rte_eth_af_packet.c     |   9 +-
 drivers/net/af_xdp/rte_eth_af_xdp.c           | 212 +++----
 drivers/net/atlantic/atl_logs.h               |  16 +-
 drivers/net/atlantic/atl_rxtx.c               |   4 +-
 drivers/net/atlantic/hw_atl/hw_atl_utils.c    |  12 +-
 drivers/net/avp/avp_ethdev.c                  | 155 +++--
 drivers/net/avp/avp_logs.h                    |  17 +-
 drivers/net/axgbe/axgbe_dev.c                 |  34 +-
 drivers/net/axgbe/axgbe_ethdev.c              | 130 ++--
 drivers/net/axgbe/axgbe_i2c.c                 |  18 +-
 drivers/net/axgbe/axgbe_logs.h                |  10 +-
 drivers/net/axgbe/axgbe_mdio.c                |  36 +-
 drivers/net/axgbe/axgbe_phy_impl.c            |  50 +-
 drivers/net/axgbe/axgbe_rxtx.c                |  24 +-
 drivers/net/bnx2x/bnx2x.c                     |   8 +-
 drivers/net/bnx2x/bnx2x_logs.h                |  25 +-
 drivers/net/bnxt/bnxt.h                       |   8 +-
 drivers/net/bnxt/bnxt_cpr.c                   |  66 +-
 drivers/net/bnxt/bnxt_ethdev.c                | 570 +++++++++---------
 drivers/net/bnxt/bnxt_filter.c                |  18 +-
 drivers/net/bnxt/bnxt_flow.c                  | 126 ++--
 drivers/net/bnxt/bnxt_hwrm.c                  | 328 +++++-----
 drivers/net/bnxt/bnxt_irq.c                   |   4 +-
 drivers/net/bnxt/bnxt_reps.c                  |  86 +--
 drivers/net/bnxt/bnxt_ring.c                  |  18 +-
 drivers/net/bnxt/bnxt_rxq.c                   |  66 +-
 drivers/net/bnxt/bnxt_rxr.c                   |  32 +-
 drivers/net/bnxt/bnxt_rxtx_vec_avx2.c         |   2 +-
 drivers/net/bnxt/bnxt_rxtx_vec_neon.c         |   6 +-
 drivers/net/bnxt/bnxt_rxtx_vec_sse.c          |   6 +-
 drivers/net/bnxt/bnxt_stats.c                 |   6 +-
 drivers/net/bnxt/bnxt_txq.c                   |  16 +-
 drivers/net/bnxt/bnxt_txr.c                   |  20 +-
 drivers/net/bnxt/bnxt_vnic.c                  | 124 ++--
 drivers/net/bnxt/rte_pmd_bnxt.c               | 132 ++--
 .../net/bnxt/tf_core/tf_em_hash_internal.c    |   4 +-
 drivers/net/bnxt/tf_core/tf_em_internal.c     |   4 +-
 drivers/net/bnxt/tf_ulp/bnxt_tf_common.h      |   3 +-
 drivers/net/bnxt/tf_ulp/bnxt_tf_pmd_shim.c    |   6 +-
 drivers/net/bnxt/tf_ulp/bnxt_ulp.c            |   2 +-
 drivers/net/bnxt/tf_ulp/ulp_fc_mgr.c          |  22 +-
 drivers/net/bnxt/tf_ulp/ulp_ha_mgr.c          |   2 +-
 drivers/net/cnxk/cn10k_ethdev.c               |   2 +-
 drivers/net/cnxk/cn9k_ethdev.c                |   2 +-
 drivers/net/cnxk/cnxk_eswitch_devargs.c       |   2 +-
 drivers/net/cnxk/cnxk_ethdev.c                |   4 +-
 drivers/net/cnxk/cnxk_ethdev_mcs.c            |  14 +-
 drivers/net/cnxk/cnxk_ethdev_ops.c            |   2 +-
 drivers/net/cnxk/cnxk_rep.c                   |   8 +-
 drivers/net/cnxk/cnxk_rep.h                   |   2 +-
 drivers/net/cpfl/cpfl_ethdev.c                |   2 +-
 drivers/net/cpfl/cpfl_flow_parser.c           |   2 +-
 drivers/net/cpfl/cpfl_fxp_rule.c              |   8 +-
 drivers/net/cpfl/cpfl_logs.h                  |  12 +-
 drivers/net/dpaa/dpaa_ethdev.c                |   9 +-
 drivers/net/dpaa/dpaa_ethdev.h                |   4 +-
 drivers/net/dpaa/fmlib/fm_ext.h               |  21 +-
 drivers/net/dpaa2/dpaa2_ethdev.c              |  16 +-
 drivers/net/dpaa2/dpaa2_flow.c                |  36 +-
 drivers/net/dpaa2/dpaa2_mux.c                 |   4 +-
 drivers/net/dpaa2/dpaa2_pmd_logs.h            |  10 +-
 drivers/net/dpaa2/dpaa2_recycle.c             |   6 +-
 drivers/net/dpaa2/dpaa2_rxtx.c                |  44 +-
 drivers/net/dpaa2/dpaa2_sparser.c             |   8 +-
 drivers/net/dpaa2/dpaa2_tm.c                  |  24 +-
 drivers/net/e1000/base/e1000_osdep.h          |   2 +-
 drivers/net/e1000/e1000_logs.h                |  20 +-
 drivers/net/e1000/igb_ethdev.c                |   2 +-
 drivers/net/ena/ena_ethdev.c                  | 348 +++++------
 drivers/net/ena/ena_logs.h                    |  28 +-
 drivers/net/ena/ena_platform.h                |   2 +-
 drivers/net/ena/ena_rss.c                     |  76 +--
 drivers/net/enetc/enetc_ethdev.c              |   4 +-
 drivers/net/enetc/enetc_logs.h                |  10 +-
 drivers/net/enetfec/enet_ethdev.c             |   4 +-
 drivers/net/enetfec/enet_pmd_logs.h           |   7 +-
 drivers/net/enetfec/enet_uio.c                |  10 +-
 drivers/net/enic/enic_compat.h                |   5 +-
 drivers/net/enic/enic_ethdev.c                |  20 +-
 drivers/net/enic/enic_flow.c                  |  20 +-
 drivers/net/enic/enic_vf_representor.c        |  16 +-
 drivers/net/failsafe/failsafe_args.c          |   2 +-
 drivers/net/failsafe/failsafe_eal.c           |   2 +-
 drivers/net/failsafe/failsafe_ether.c         |   4 +-
 drivers/net/failsafe/failsafe_intr.c          |   6 +-
 drivers/net/failsafe/failsafe_private.h       |   7 +-
 drivers/net/fm10k/base/fm10k_osdep.h          |   2 +-
 drivers/net/fm10k/fm10k_logs.h                |  23 +-
 drivers/net/gve/base/gve_adminq.c             |   4 +-
 drivers/net/gve/gve_logs.h                    |   4 +-
 drivers/net/gve/gve_rx.c                      |   2 +-
 drivers/net/gve/gve_tx.c                      |   2 +-
 drivers/net/hinic/base/hinic_compat.h         |   5 +-
 drivers/net/hinic/base/hinic_pmd_eqs.c        |   2 +-
 drivers/net/hinic/base/hinic_pmd_mbox.c       |   6 +-
 drivers/net/hinic/base/hinic_pmd_niccfg.c     |   8 +-
 drivers/net/hinic/hinic_pmd_ethdev.c          |   4 +-
 drivers/net/hns3/hns3_dump.c                  |  12 +-
 drivers/net/hns3/hns3_intr.c                  |  12 +-
 drivers/net/hns3/hns3_logs.h                  |  25 +-
 drivers/net/hns3/hns3_ptp.c                   |   2 +-
 drivers/net/hns3/hns3_regs.c                  |   4 +-
 drivers/net/i40e/base/i40e_osdep.h            |   6 +-
 drivers/net/i40e/i40e_ethdev.c                |  51 +-
 drivers/net/i40e/i40e_logs.h                  |  23 +-
 drivers/net/i40e/i40e_pf.c                    |   8 +-
 drivers/net/i40e/i40e_rxtx.c                  |  42 +-
 drivers/net/iavf/iavf_ethdev.c                |  12 +-
 drivers/net/iavf/iavf_log.h                   |  21 +-
 drivers/net/iavf/iavf_rxtx.c                  |  16 +-
 drivers/net/ice/base/ice_osdep.h              |   2 +-
 drivers/net/ice/ice_dcf_ethdev.c              |   4 +-
 drivers/net/ice/ice_dcf_vf_representor.c      |  14 +-
 drivers/net/ice/ice_ethdev.c                  |  50 +-
 drivers/net/ice/ice_fdir_filter.c             |   2 +-
 drivers/net/ice/ice_hash.c                    |   8 +-
 drivers/net/ice/ice_logs.h                    |  23 +-
 drivers/net/ice/ice_rxtx.c                    |  18 +-
 drivers/net/idpf/idpf_logs.h                  |  17 +-
 drivers/net/igc/base/igc_osdep.h              |   2 +-
 drivers/net/igc/igc_logs.h                    |  16 +-
 drivers/net/ipn3ke/ipn3ke_ethdev.c            |   4 +-
 drivers/net/ipn3ke/ipn3ke_flow.c              |  23 +-
 drivers/net/ipn3ke/ipn3ke_logs.h              |   4 +-
 drivers/net/ipn3ke/ipn3ke_representor.c       |  20 +-
 drivers/net/ipn3ke/ipn3ke_tm.c                |  10 +-
 drivers/net/ixgbe/base/ixgbe_osdep.h          |   2 +-
 drivers/net/ixgbe/ixgbe_ethdev.c              |   7 +-
 drivers/net/ixgbe/ixgbe_ipsec.c               |  24 +-
 drivers/net/ixgbe/ixgbe_logs.h                |  23 +-
 drivers/net/ixgbe/ixgbe_pf.c                  |  18 +-
 drivers/net/ixgbe/rte_pmd_ixgbe.c             |   8 +-
 drivers/net/mana/mana.h                       |   7 +-
 drivers/net/memif/rte_eth_memif.c             |   2 +-
 drivers/net/memif/rte_eth_memif.h             |   5 +-
 drivers/net/mlx4/mlx4.c                       |   4 +-
 drivers/net/mlx4/mlx4_mr.c                    |  18 +-
 drivers/net/mlx4/mlx4_utils.h                 |   9 +-
 drivers/net/mvneta/mvneta_ethdev.h            |   4 +-
 drivers/net/mvpp2/mrvl_ethdev.h               |   3 +-
 drivers/net/netvsc/hn_logs.h                  |  14 +-
 drivers/net/netvsc/hn_rndis.c                 |  60 +-
 drivers/net/netvsc/hn_rxtx.c                  |   4 +-
 drivers/net/nfb/nfb.h                         |   4 +-
 drivers/net/nfp/nfp_logs.h                    |  20 +-
 drivers/net/ngbe/base/ngbe_hw.c               |   2 +-
 drivers/net/ngbe/ngbe_ethdev.c                |   2 +-
 drivers/net/ngbe/ngbe_logs.h                  |  20 +-
 drivers/net/ngbe/ngbe_pf.c                    |  10 +-
 drivers/net/null/rte_eth_null.c               |   5 +-
 drivers/net/octeon_ep/cnxk_ep_tx.c            |   2 +-
 drivers/net/octeon_ep/cnxk_ep_vf.c            |  12 +-
 drivers/net/octeon_ep/otx2_ep_vf.c            |  18 +-
 drivers/net/octeon_ep/otx_ep_common.h         |  14 +-
 drivers/net/octeon_ep/otx_ep_ethdev.c         |  82 +--
 drivers/net/octeon_ep/otx_ep_mbox.c           |  30 +-
 drivers/net/octeon_ep/otx_ep_rxtx.c           |  78 +--
 drivers/net/octeon_ep/otx_ep_vf.c             |  20 +-
 drivers/net/octeontx/base/octeontx_pkovf.c    |   2 +-
 drivers/net/octeontx/octeontx_ethdev.c        |  26 +-
 drivers/net/octeontx/octeontx_logs.h          |  16 +-
 drivers/net/pcap/pcap_ethdev.c                |   4 +-
 drivers/net/pcap/pcap_osdep.h                 |   5 +-
 drivers/net/pfe/pfe_ethdev.c                  |  22 +-
 drivers/net/pfe/pfe_hif.c                     |  12 +-
 drivers/net/pfe/pfe_hif_lib.c                 |   2 +-
 drivers/net/pfe/pfe_logs.h                    |   7 +-
 drivers/net/qede/qede_rxtx.c                  |  66 +-
 drivers/net/ring/rte_eth_ring.c               |   5 +-
 drivers/net/sfc/sfc_ethdev.c                  |   2 +-
 drivers/net/sfc/sfc_log.h                     |   7 +-
 drivers/net/softnic/rte_eth_softnic.c         |   5 +-
 drivers/net/tap/tap_log.h                     |   3 +-
 drivers/net/thunderx/nicvf_ethdev.c           |   2 +-
 drivers/net/thunderx/nicvf_logs.h             |  12 +-
 drivers/net/txgbe/base/txgbe_osdep.h          |   8 +
 drivers/net/txgbe/txgbe_ethdev.c              |   4 +-
 drivers/net/txgbe/txgbe_ipsec.c               |  24 +-
 drivers/net/txgbe/txgbe_logs.h                |  33 +-
 drivers/net/txgbe/txgbe_pf.c                  |  20 +-
 drivers/net/vdev_netvsc/vdev_netvsc.c         |   6 +-
 drivers/net/vhost/rte_eth_vhost.c             |  75 +--
 drivers/net/virtio/virtio_cvq.c               |  19 +-
 drivers/net/virtio/virtio_logs.h              |  13 +-
 drivers/net/virtio/virtio_user/vhost_vdpa.c   |   2 +-
 .../net/virtio/virtio_user/virtio_user_dev.c  |  32 +-
 drivers/net/vmxnet3/vmxnet3_ethdev.c          |   4 +-
 drivers/net/vmxnet3/vmxnet3_logs.h            |  14 +-
 drivers/net/vmxnet3/vmxnet3_rxtx.c            |   2 +-
 drivers/raw/cnxk_bphy/cnxk_bphy.c             |   2 +-
 drivers/raw/cnxk_bphy/rte_pmd_bphy.h          |   4 +-
 drivers/raw/cnxk_gpio/cnxk_gpio.h             |   3 +-
 drivers/raw/dpaa2_cmdif/dpaa2_cmdif.c         |  14 +-
 drivers/raw/dpaa2_cmdif/dpaa2_cmdif_logs.h    |  10 +-
 drivers/raw/ifpga/afu_pmd_n3000.c             |   2 +-
 drivers/raw/ifpga/ifpga_rawdev.c              |  94 +--
 drivers/raw/ifpga/ifpga_rawdev.h              |   3 +-
 drivers/raw/ntb/ntb.h                         |   3 +-
 drivers/raw/skeleton/skeleton_rawdev.h        |   3 +-
 drivers/raw/skeleton/skeleton_rawdev_test.c   |   2 +-
 drivers/regex/cn9k/cn9k_regexdev.c            |   2 +-
 drivers/vdpa/ifc/base/ifcvf.c                 |  10 +-
 drivers/vdpa/ifc/ifcvf_vdpa.c                 |  15 +-
 drivers/vdpa/nfp/nfp_vdpa.c                   |   2 +-
 drivers/vdpa/nfp/nfp_vdpa_log.h               |  10 +-
 drivers/vdpa/sfc/sfc_vdpa_log.h               |   7 +-
 350 files changed, 3587 insertions(+), 3637 deletions(-)

-- 
2.46.0
#1 lore raw

PATCH 1/11 devtools: fix forbidden token check with multiple files

If a patch contains multiple files, it is possible to pass through the check because the count of token mentions is not reset between file evaluation.

Example with a fake patch:

  $ cat toto.patch
  --- a/drivers/plop1
  +++ b/drivers/plop1
  - RTE_LOG(
  - RTE_LOG(
  + RTE_LOG(
  --- a/drivers/plop2
  +++ b/drivers/plop2
  + RTE_LOG(
  $ awk -v FOLDERS='drivers' -v EXPRESSIONS='RTE_LOG\\('
    -v MESSAGE='Prefer RTE_LOG_LINE'
    -f devtools/check-forbidden-tokens.awk toto.patch

Besides, the expressions[] array is not used since commit b467d38284b1 ("devtools: add explicit warnings for forbidden tokens").

Fixes 42f4d724ec27 ("devtools: move awk script ckecking forbidden tokens")
---
 devtools/check-forbidden-tokens.awk | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)
devtools/check-forbidden-tokens.awk +3 -5
index 90d3a64f8e..807dad7f48 100755
@@ -32,14 +32,11 @@ BEGIN {
 		for (i in deny_expr) {
 			forbidden_added = "^\\+.*" deny_expr[i];
 			forbidden_removed="^-.*" deny_expr[i];
-			current = expressions[deny_expr[i]]
 			if ($0 ~ forbidden_added) {
-				count = count + 1;
-				expressions[deny_expr[i]] = current + 1
+				count = count + 1
 			}
 			if ($0 ~ forbidden_removed) {
-				count = count - 1;
-				expressions[deny_expr[i]] = current - 1
+				count = count - 1
 			}
 		}
 	}
@@ -55,6 +52,7 @@ BEGIN {
 	if (count > 0) {
 		exit;
 	}
+	count = 0
 	for (i in deny_folders) {
 		re = "^\\+\\+\\+ b/" deny_folders[i];
 		if ($0 ~ re) {
Signature · 1 line
2.46.0
#2 lore raw

PATCH 2/11 devtools: report all warnings in forbidden token check

In reply to David Marchand

Do not stop at the first file that got warnings.

---
 devtools/check-forbidden-tokens.awk | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
devtools/check-forbidden-tokens.awk +6 -1
index 807dad7f48..d72d244d3a 100755
@@ -13,6 +13,7 @@ BEGIN {
 	in_file=0;
 	in_comment=0;
 	count=0;
+	warned=0;
 	comment_start="/*"
 	comment_end="*/"
 }
@@ -50,7 +51,8 @@ BEGIN {
 ($0 ~ "^\\+\\+\\+ b/") {
 	in_file = 0;
 	if (count > 0) {
-		exit;
+		warned = warned + 1
+		print "Warning in " substr(last_file,7) ":"
 	}
 	count = 0
 	for (i in deny_folders) {
@@ -66,7 +68,10 @@ BEGIN {
 }
 END {
 	if (count > 0) {
+		warned = warned + 1
 		print "Warning in " substr(last_file,7) ":"
+	}
+	if (warned > 0) {
 		print MESSAGE
 		exit RET_ON_FAIL
 	}
Signature · 1 line
2.46.0
#3 lore raw

PATCH 3/11 net/dpaa: remove broken debug macros

In reply to David Marchand

Those debug macros never worked as existing callers never passed a 'level' argument.
Remove them.

---
 drivers/net/dpaa/fmlib/fm_ext.h | 21 ++-------------------
 1 file changed, 2 insertions(+), 19 deletions(-)
drivers/net/dpaa/fmlib/fm_ext.h +2 -19
index 8e7153bdaf..4666fa3b0b 100644
@@ -15,25 +15,8 @@
 #define MODULE_FM		0x00010000
 #define __ERR_MODULE__		MODULE_FM
 
-/* #define FM_LIB_DBG */
-
-#if defined(FM_LIB_DBG)
-	#define _fml_dbg(fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_pmd, "fmlib:%s(): " fmt "\n", \
-			__func__, ##args)
-#else
-	#define _fml_dbg(arg...)
-#endif
-
-/*#define FM_IOCTL_DBG*/
-
-#if defined(FM_IOCTL_DBG)
-	#define _fm_ioctl_dbg(fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_pmd, "fmioc:%s(): " fmt "\n", \
-				__func__, ##args)
-#else
-	#define _fm_ioctl_dbg(arg...)
-#endif
+#define _fml_dbg(...)
+#define _fm_ioctl_dbg(...)
 
 /*
  * @Group	lnx_ioctl_ncsw_grp	NetCommSw Linux User-Space (IOCTL) API
Signature · 1 line
2.46.0
#4 lore raw

PATCH 4/11 net/sfc: fix driver logtype token

In reply to David Marchand

The net/sfc driver logtype was registered under pmd.net.sfc."driver".

Fixes 0f39f32482a1 ("net/sfc: remove use of EAL logtype")
---
 drivers/net/sfc/sfc_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/sfc/sfc_ethdev.c +1 -1
index 24686a1eaf..3480a51642 100644
@@ -3616,4 +3616,4 @@ RTE_PMD_REGISTER_PARAM_STRING(net_sfc_efx,
 	SFC_KVARG_FW_VARIANT "=" SFC_KVARG_VALUES_FW_VARIANT " "
 	SFC_KVARG_RXD_WAIT_TIMEOUT_NS "=<long> "
 	SFC_KVARG_STATS_UPDATE_PERIOD_MS "=<long>");
-RTE_LOG_REGISTER_SUFFIX(sfc_logtype_driver, "driver", NOTICE);
+RTE_LOG_REGISTER_SUFFIX(sfc_logtype_driver, driver, NOTICE);
Signature · 1 line
2.46.0
Reviewed-by on v1 4/11
#5 lore raw

Re: [PATCH 04/11] net/sfc: fix driver logtype token

Quoted 14 lines · David Marchand

The net/sfc driver logtype was registered under pmd.net.sfc."driver".

Fixes 0f39f32482a1 ("net/sfc: remove use of EAL logtype")
---
  drivers/net/sfc/sfc_ethdev.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/sfc/sfc_ethdev.c +0 -0
index 24686a1eaf..3480a51642 100644

drivers/net/sfc/sfc_ethdev.c RTE_PMD_REGISTER_PARAM_STRING(net_sfc_efx, · line 3619

Quoted 5 lines
drivers/net/sfc/sfc_ethdev.c +1 -1
@@ -3616,4 +3616,4 @@ RTE_PMD_REGISTER_PARAM_STRING(net_sfc_efx,
  	SFC_KVARG_FW_VARIANT "=" SFC_KVARG_VALUES_FW_VARIANT " "
  	SFC_KVARG_RXD_WAIT_TIMEOUT_NS "=<long> "
  	SFC_KVARG_STATS_UPDATE_PERIOD_MS "=<long>");
-RTE_LOG_REGISTER_SUFFIX(sfc_logtype_driver, "driver", NOTICE);
+RTE_LOG_REGISTER_SUFFIX(sfc_logtype_driver, driver, NOTICE);
#6 lore raw

PATCH 5/11 drivers: reuse default logtype for SFC drivers

In reply to David Marchand

Nothing is fixed here, just reuse the value coming from the build framework rather than use a fixed string that may get wrong in the future.

---
 drivers/net/sfc/sfc_log.h       | 7 ++-----
 drivers/vdpa/sfc/sfc_vdpa_log.h | 7 ++-----
 2 files changed, 4 insertions(+), 10 deletions(-)
drivers/net/sfc/sfc_log.h +2 -5
index 10a9ce6ced..b92b358927 100644
@@ -13,9 +13,6 @@
 /** Generic driver log type */
 extern int sfc_logtype_driver;
 
-/** Common log type name prefix */
-#define SFC_LOGTYPE_PREFIX	"pmd.net.sfc."
-
 /** Log PMD generic message, add a prefix and a line break */
 #define SFC_GENERIC_LOG(level, ...) \
 	rte_log(RTE_LOG_ ## level, sfc_logtype_driver,			\
@@ -23,10 +20,10 @@ extern int sfc_logtype_driver;
 			RTE_FMT_TAIL(__VA_ARGS__ ,)))
 
 /** Name prefix for the per-device log type used to report basic information */
-#define SFC_LOGTYPE_MAIN_STR	SFC_LOGTYPE_PREFIX "main"
+#define SFC_LOGTYPE_MAIN_STR	RTE_STR(RTE_LOG_DEFAULT_LOGTYPE) ".main"
 
 /** Device MCDI log type name prefix */
-#define SFC_LOGTYPE_MCDI_STR	SFC_LOGTYPE_PREFIX "mcdi"
+#define SFC_LOGTYPE_MCDI_STR	RTE_STR(RTE_LOG_DEFAULT_LOGTYPE) ".mcdi"
 
 #define SFC_LOG_PREFIX_MAX	32
 
drivers/vdpa/sfc/sfc_vdpa_log.h +2 -5
index 6c0101dbb4..1104e7de43 100644
@@ -8,9 +8,6 @@
 /** Generic driver log type */
 extern int sfc_vdpa_logtype_driver;
 
-/** Common log type name prefix */
-#define SFC_VDPA_LOGTYPE_PREFIX	"pmd.vdpa.sfc."
-
 /** Log PMD generic message, add a prefix and a line break */
 #define SFC_VDPA_GENERIC_LOG(level, ...) \
 	rte_log(RTE_LOG_ ## level, sfc_vdpa_logtype_driver,		\
@@ -18,10 +15,10 @@ extern int sfc_vdpa_logtype_driver;
 			RTE_FMT_TAIL(__VA_ARGS__ ,)))
 
 /** Name prefix for the per-device log type used to report basic information */
-#define SFC_VDPA_LOGTYPE_MAIN_STR	SFC_VDPA_LOGTYPE_PREFIX "main"
+#define SFC_VDPA_LOGTYPE_MAIN_STR	RTE_STR(RTE_LOG_DEFAULT_LOGTYPE) ".main"
 
 /** Device MCDI log type name prefix */
-#define SFC_VDPA_LOGTYPE_MCDI_STR	SFC_VDPA_LOGTYPE_PREFIX "mcdi"
+#define SFC_VDPA_LOGTYPE_MCDI_STR	RTE_STR(RTE_LOG_DEFAULT_LOGTYPE) ".mcdi"
 
 #define SFC_VDPA_LOG_PREFIX_MAX	32
 
Signature · 1 line
2.46.0
#8 lore raw

PATCH 6/11 drivers: move log wrappers to Intel base drivers

In reply to David Marchand

Remove _RAW macros and directly call RTE_LOG() where needed in headers providing wrappers for base drivers code.
This will help later when adding a check on RTE_LOG() use in drivers/.

---
 drivers/common/iavf/iavf_osdep.h      |  8 ++++----
 drivers/common/idpf/base/idpf_osdep.h | 10 +++++-----
 drivers/net/e1000/base/e1000_osdep.h  |  2 +-
 drivers/net/e1000/e1000_logs.h        |  8 ++------
 drivers/net/fm10k/base/fm10k_osdep.h  |  2 +-
 drivers/net/fm10k/fm10k_logs.h        |  7 ++-----
 drivers/net/i40e/base/i40e_osdep.h    |  6 +++---
 drivers/net/i40e/i40e_logs.h          |  7 ++-----
 drivers/net/ice/base/ice_osdep.h      |  2 +-
 drivers/net/ice/ice_logs.h            |  7 ++-----
 drivers/net/igc/base/igc_osdep.h      |  2 +-
 drivers/net/igc/igc_logs.h            |  6 +-----
 drivers/net/ixgbe/base/ixgbe_osdep.h  |  2 +-
 drivers/net/ixgbe/ixgbe_logs.h        |  7 ++-----
 14 files changed, 28 insertions(+), 48 deletions(-)
drivers/common/iavf/iavf_osdep.h +4 -4
index 263d92400c..1f2b7889cb 100644
@@ -143,16 +143,16 @@ writeq(uint64_t value, volatile void *addr)
 #define IAVF_WRITE_FLUSH(a) IAVF_READ_REG(a, IAVF_VFGEN_RSTAT)
 
 extern int iavf_common_logger;
+#define RTE_LOGTYPE_IAVF_COMMON iavf_common_logger
 
-#define DEBUGOUT(S)          rte_log(RTE_LOG_DEBUG, iavf_common_logger, S)
-#define DEBUGOUT2(S, A...)   rte_log(RTE_LOG_DEBUG, iavf_common_logger, S, ##A)
+#define DEBUGOUT(S, ...)     RTE_LOG(DEBUG, IAVF_COMMON, S, ## __VA_ARGS__)
+#define DEBUGOUT2(S, ...)    DEBUGOUT(S, ## __VA_ARGS__)
 #define DEBUGFUNC(F)         DEBUGOUT(F "\n")
 
 #define iavf_debug(h, m, s, ...)                                \
 do {                                                            \
 	if (((m) & (h)->debug_mask))                            \
-		rte_log(RTE_LOG_DEBUG, iavf_common_logger,      \
-			"iavf %02x.%x " s,                      \
+		DEBUGOUT("iavf %02x.%x " s,                      \
 			(h)->bus.device, (h)->bus.func,         \
 					##__VA_ARGS__);         \
 } while (0)
drivers/common/idpf/base/idpf_osdep.h +5 -5
index b2af8f443d..e042ef871c 100644
@@ -25,6 +25,8 @@
 #include <rte_io.h>
 #include <rte_compat.h>
 
+#include "../idpf_common_logs.h"
+
 #define INLINE inline
 #define STATIC static
 
@@ -108,16 +110,14 @@ typedef struct idpf_lock idpf_lock;
 #define FIELD_SIZEOF(t, f) (sizeof(((t *)0)->(f)))
 #define MAKEMASK(m, s) ((m) << (s))
 
-extern int idpf_common_logger;
-
-#define DEBUGOUT(S)		rte_log(RTE_LOG_DEBUG, idpf_common_logger, S)
-#define DEBUGOUT2(S, A...)	rte_log(RTE_LOG_DEBUG, idpf_common_logger, S, ##A)
+#define DEBUGOUT(S, ...)	RTE_LOG(DEBUG, IDPF_COMMON, S, ## __VA_ARGS__)
+#define DEBUGOUT2(S, ...)	DEBUGOUT(S, ## __VA_ARGS__)
 #define DEBUGFUNC(F)		DEBUGOUT(F "\n")
 
 #define idpf_debug(h, m, s, ...)					\
 	do {								\
 		if (((m) & (h)->debug_mask))				\
-			PMD_DRV_LOG_RAW(DEBUG, "idpf %02x.%x " s,       \
+			DEBUGOUT("idpf %02x.%x " s "\n",		\
 					(h)->bus.device, (h)->bus.func,	\
 					##__VA_ARGS__);			\
 	} while (0)
drivers/net/e1000/base/e1000_osdep.h +1 -1
index cd90228cef..6b5d58950f 100644
@@ -27,7 +27,7 @@
 #define msec_delay_irq(x) DELAY(1000*(x))
 
 #define DEBUGFUNC(F)            DEBUGOUT(F "\n");
-#define DEBUGOUT(S, args...)    PMD_DRV_LOG_RAW(DEBUG, S, ##args)
+#define DEBUGOUT(S, ...)        RTE_LOG(DEBUG, E1000_DRIVER, "%s(): " S, __func__, ## __VA_ARGS__)
 #define DEBUGOUT1(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT2(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT3(S, args...)   DEBUGOUT(S, ##args)
drivers/net/e1000/e1000_logs.h +2 -6
index 86f546b0f9..30b5531069 100644
@@ -34,13 +34,9 @@ extern int e1000_logtype_tx;
 #endif
 
 extern int e1000_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, e1000_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
+#define RTE_LOGTYPE_E1000_DRIVER e1000_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
-
+	RTE_LOG(level, E1000_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 /* log init function shared by e1000 and igb drivers */
 void e1000_igb_init_log(void);
drivers/net/fm10k/base/fm10k_osdep.h +1 -1
index 25f46c3908..d3e5528575 100644
@@ -24,7 +24,7 @@
 
 #define STATIC                  static
 #define DEBUGFUNC(F)            DEBUGOUT(F "\n");
-#define DEBUGOUT(S, args...)    PMD_DRV_LOG_RAW(DEBUG, S, ##args)
+#define DEBUGOUT(S, ...)        RTE_LOG(DEBUG, FM10K_DRIVER, "%s(): " S, __func__, ## __VA_ARGS__)
 #define DEBUGOUT1(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT2(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT3(S, args...)   DEBUGOUT(S, ##args)
drivers/net/fm10k/fm10k_logs.h +2 -5
index 4f039f8beb..c4c7c977d9 100644
@@ -33,11 +33,8 @@ extern int fm10k_logtype_tx;
 #endif
 
 extern int fm10k_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, fm10k_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
+#define RTE_LOGTYPE_FM10K_DRIVER fm10k_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG(level, FM10K_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 #endif /* _FM10K_LOGS_H_ */
drivers/net/i40e/base/i40e_osdep.h +3 -3
index aa5dc61841..8960206d8b 100644
@@ -82,8 +82,8 @@ typedef enum i40e_status_code i40e_status;
 
 #define FIELD_SIZEOF(t, f) (sizeof(((t*)0)->f))
 
-#define DEBUGOUT(S)        PMD_DRV_LOG_RAW(DEBUG, S)
-#define DEBUGOUT1(S, A...) PMD_DRV_LOG_RAW(DEBUG, S, ##A)
+#define DEBUGOUT(S, ...) RTE_LOG(DEBUG, I40E_DRIVER, "%s(): " S, __func__, ## __VA_ARGS__)
+#define DEBUGOUT1 DEBUGOUT
 
 #define DEBUGFUNC(F) DEBUGOUT(F "\n")
 #define DEBUGOUT2 DEBUGOUT1
@@ -94,7 +94,7 @@ typedef enum i40e_status_code i40e_status;
 #define i40e_debug(h, m, s, ...)                                \
 do {                                                            \
 	if (((m) & (h)->debug_mask))                            \
-		PMD_DRV_LOG_RAW(DEBUG, "i40e %02x.%x " s,       \
+		DEBUGOUT("i40e %02x.%x " s,			\
 			(h)->bus.device, (h)->bus.func,         \
 					##__VA_ARGS__);         \
 } while (0)
drivers/net/i40e/i40e_logs.h +2 -5
index eebe6c5559..fb1f3a4096 100644
@@ -30,11 +30,8 @@ extern int i40e_logtype_tx;
 #endif
 
 extern int i40e_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, i40e_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
+#define RTE_LOGTYPE_I40E_DRIVER i40e_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG(level, I40E_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 #endif /* _I40E_LOGS_H_ */
drivers/net/ice/base/ice_osdep.h +1 -1
index c17f1bf09f..5f7347023f 100644
@@ -149,7 +149,7 @@ writeq(uint64_t value, volatile void *addr)
 #define ice_debug(h, m, s, ...)					\
 do {								\
 	if (((m) & (h)->debug_mask))				\
-		PMD_DRV_LOG_RAW(DEBUG, "ice %02x.%x " s,	\
+		RTE_LOG(DEBUG, ICE_DRIVER, "ice %02x.%x " s,	\
 			(h)->bus.device, (h)->bus.func,		\
 					##__VA_ARGS__);		\
 } while (0)
drivers/net/ice/ice_logs.h +2 -5
index e79980fb63..a54e9d8b59 100644
@@ -7,6 +7,7 @@
 
 extern int ice_logtype_init;
 extern int ice_logtype_driver;
+#define RTE_LOGTYPE_ICE_DRIVER ice_logtype_driver
 
 #define PMD_INIT_LOG(level, fmt, args...) \
 	rte_log(RTE_LOG_ ## level, ice_logtype_init, "%s(): " fmt "\n", \
@@ -32,11 +33,7 @@ extern int ice_logtype_tx;
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ice_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG(level, ICE_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 #endif /* _ICE_LOGS_H_ */
drivers/net/igc/base/igc_osdep.h +1 -1
index 25090d65ea..4e479eb500 100644
@@ -27,7 +27,7 @@
 #define msec_delay_irq(x) DELAY(1000 * (x))
 
 #define DEBUGFUNC(F)            DEBUGOUT(F "\n")
-#define DEBUGOUT(S, args...)    PMD_DRV_LOG_RAW(DEBUG, S, ##args)
+#define DEBUGOUT(S, ...)        RTE_LOG(DEBUG, IGC_DRIVER, "%s(): " S, __func__, ## __VA_ARGS__)
 #define DEBUGOUT1(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT2(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT3(S, args...)   DEBUGOUT(S, ##args)
drivers/net/igc/igc_logs.h +1 -5
index cca5389eff..4a574f10cb 100644
@@ -35,12 +35,8 @@ extern int igc_logtype_driver;
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, igc_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG(level, IGC_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 #ifdef __cplusplus
 }
drivers/net/ixgbe/base/ixgbe_osdep.h +1 -1
index e832a7bec8..502f386b56 100644
@@ -33,7 +33,7 @@
 #define msec_delay(x) DELAY(1000*(x))
 
 #define DEBUGFUNC(F)            DEBUGOUT(F "\n");
-#define DEBUGOUT(S, args...)    PMD_DRV_LOG_RAW(DEBUG, S, ##args)
+#define DEBUGOUT(S, ...)        RTE_LOG(DEBUG, IXGBE_DRIVER, "%s(): " S, __func__, ## __VA_ARGS__)
 #define DEBUGOUT1(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT2(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT3(S, args...)   DEBUGOUT(S, ##args)
drivers/net/ixgbe/ixgbe_logs.h +2 -5
index 00ef797ca1..5a2c5ccde0 100644
@@ -31,11 +31,8 @@ extern int ixgbe_logtype_tx;
 #endif
 
 extern int ixgbe_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ixgbe_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
+#define RTE_LOGTYPE_IXGBE_DRIVER ixgbe_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG(level, IXGBE_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 #endif /* _IXGBE_LOGS_H_ */
Signature · 1 line
2.46.0
#9 lore raw

PATCH 7/11 net/txgbe: move wrapper to base driver

In reply to David Marchand

BP_LOG() is only used in the base driver.

---
 drivers/net/txgbe/base/txgbe_osdep.h | 8 ++++++++
 drivers/net/txgbe/txgbe_logs.h       | 7 -------
 2 files changed, 8 insertions(+), 7 deletions(-)
drivers/net/txgbe/base/txgbe_osdep.h +8 -0
index 62d16a6abb..91c8abf12e 100644
@@ -28,6 +28,14 @@
 #define TMZ_VADDR(mz)  ((mz)->addr)
 #define TDEV_NAME(eth_dev)  ((eth_dev)->device->name)
 
+extern int txgbe_logtype_bp;
+#define RTE_LOGTYPE_TXGBE_BP txgbe_logtype_bp
+#define BP_LOG(fmt, ...) \
+	RTE_LOG(DEBUG, TXGBE_BP, \
+		"[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
+		usec_stamp() / 1000000, usec_stamp() % 1000000, \
+		__func__, __LINE__, ## __VA_ARGS__)
+
 #define ASSERT(x) do {			\
 	if (!(x))			\
 		PMD_DRV_LOG(ERR, "TXGBE: %d", x);	\
drivers/net/txgbe/txgbe_logs.h +0 -7
index 74f49ab9ef..b5a5a9233f 100644
@@ -51,11 +51,4 @@ extern int txgbe_logtype_tx_free;
 #define DEBUGOUT(fmt, args...)    PMD_DRV_LOG(DEBUG, fmt, ##args)
 #define PMD_INIT_FUNC_TRACE()     PMD_DRV_LOG(DEBUG, ">>")
 
-extern int txgbe_logtype_bp;
-#define BP_LOG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, txgbe_logtype_bp, \
-		"[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
-		usec_stamp() / 1000000, usec_stamp() % 1000000, \
-		__func__, __LINE__, ##args)
-
 #endif /* _TXGBE_LOGS_H_ */
Signature · 1 line
2.46.0
#10 lore raw

RE: [PATCH 07/11] net/txgbe: move wrapper to base driver

Quoted 44 lines · David Marchand

BP_LOG() is only used in the base driver.

---
 drivers/net/txgbe/base/txgbe_osdep.h | 8 ++++++++
 drivers/net/txgbe/txgbe_logs.h       | 7 -------
 2 files changed, 8 insertions(+), 7 deletions(-)
drivers/net/txgbe/base/txgbe_osdep.h +8 -0
index 62d16a6abb..91c8abf12e 100644
@@ -28,6 +28,14 @@
 #define TMZ_VADDR(mz)  ((mz)->addr)
 #define TDEV_NAME(eth_dev)  ((eth_dev)->device->name)
 
+extern int txgbe_logtype_bp;
+#define RTE_LOGTYPE_TXGBE_BP txgbe_logtype_bp
+#define BP_LOG(fmt, ...) \
+	RTE_LOG(DEBUG, TXGBE_BP, \
+		"[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
+		usec_stamp() / 1000000, usec_stamp() % 1000000, \
+		__func__, __LINE__, ## __VA_ARGS__)
+
 #define ASSERT(x) do {			\
 	if (!(x))			\
 		PMD_DRV_LOG(ERR, "TXGBE: %d", x);	\
drivers/net/txgbe/txgbe_logs.h +0 -8
index 74f49ab9ef..b5a5a9233f 100644
@@ -51,11 +51,4 @@ extern int txgbe_logtype_tx_free;
 #define DEBUGOUT(fmt, args...)    PMD_DRV_LOG(DEBUG, fmt, ##args)
 #define PMD_INIT_FUNC_TRACE()     PMD_DRV_LOG(DEBUG, ">>")
 
-extern int txgbe_logtype_bp;
-#define BP_LOG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, txgbe_logtype_bp, \
-		"[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
-		usec_stamp() / 1000000, usec_stamp() % 1000000, \
-		__func__, __LINE__, ##args)
-
 #endif /* _TXGBE_LOGS_H_ */
--
Quoted 2 lines

2.46.0

Hi,

Does this have to change? It looks a little weird.

#11 lore raw

Re: [PATCH 07/11] net/txgbe: move wrapper to base driver

Quoted 51 lines · Jiawen Wu
Quoted 44 lines · David Marchand

BP_LOG() is only used in the base driver.

---
 drivers/net/txgbe/base/txgbe_osdep.h | 8 ++++++++
 drivers/net/txgbe/txgbe_logs.h       | 7 -------
 2 files changed, 8 insertions(+), 7 deletions(-)
drivers/net/txgbe/base/txgbe_osdep.h +8 -0
index 62d16a6abb..91c8abf12e 100644
@@ -28,6 +28,14 @@
 #define TMZ_VADDR(mz)  ((mz)->addr)
 #define TDEV_NAME(eth_dev)  ((eth_dev)->device->name)
 
+extern int txgbe_logtype_bp;
+#define RTE_LOGTYPE_TXGBE_BP txgbe_logtype_bp
+#define BP_LOG(fmt, ...) \
+     RTE_LOG(DEBUG, TXGBE_BP, \
+             "[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
+             usec_stamp() / 1000000, usec_stamp() % 1000000, \
+             __func__, __LINE__, ## __VA_ARGS__)
+
 #define ASSERT(x) do {                       \
      if (!(x))                       \
              PMD_DRV_LOG(ERR, "TXGBE: %d", x);       \
drivers/net/txgbe/txgbe_logs.h +0 -8
index 74f49ab9ef..b5a5a9233f 100644
@@ -51,11 +51,4 @@ extern int txgbe_logtype_tx_free;
 #define DEBUGOUT(fmt, args...)    PMD_DRV_LOG(DEBUG, fmt, ##args)
 #define PMD_INIT_FUNC_TRACE()     PMD_DRV_LOG(DEBUG, ">>")
 
-extern int txgbe_logtype_bp;
-#define BP_LOG(fmt, args...) \
-     rte_log(RTE_LOG_DEBUG, txgbe_logtype_bp, \
-             "[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
-             usec_stamp() / 1000000, usec_stamp() % 1000000, \
-             __func__, __LINE__, ##args)
-
 #endif /* _TXGBE_LOGS_H_ */
--
Quoted 2 lines

2.46.0

Hi,

Quoted 1 line

Does this have to change? It looks a little weird.

Can you be more specific about the part that you don't like?

There is a change in behavior, I agree: messages would now be prefixed with the logtype, here TXGBE_BP.
I can revert this part if you prefer.

As for moving the macro, in all other drivers in DPDK, the osdep.h header provides helpers for the base driver code, so it is the right location.

Signature · 1 line
David Marchand
Acked-by
#12 lore raw

RE: [PATCH 07/11] net/txgbe: move wrapper to base driver

Quoted 52 lines · David Marchand
Quoted 51 lines · Jiawen Wu
Quoted 44 lines · David Marchand

BP_LOG() is only used in the base driver.

---
 drivers/net/txgbe/base/txgbe_osdep.h | 8 ++++++++
 drivers/net/txgbe/txgbe_logs.h       | 7 -------
 2 files changed, 8 insertions(+), 7 deletions(-)
drivers/net/txgbe/base/txgbe_osdep.h +8 -0
index 62d16a6abb..91c8abf12e 100644
@@ -28,6 +28,14 @@
 #define TMZ_VADDR(mz)  ((mz)->addr)
 #define TDEV_NAME(eth_dev)  ((eth_dev)->device->name)
 
+extern int txgbe_logtype_bp;
+#define RTE_LOGTYPE_TXGBE_BP txgbe_logtype_bp
+#define BP_LOG(fmt, ...) \
+     RTE_LOG(DEBUG, TXGBE_BP, \
+             "[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
+             usec_stamp() / 1000000, usec_stamp() % 1000000, \
+             __func__, __LINE__, ## __VA_ARGS__)
+
 #define ASSERT(x) do {                       \
      if (!(x))                       \
              PMD_DRV_LOG(ERR, "TXGBE: %d", x);       \
drivers/net/txgbe/txgbe_logs.h +0 -8
index 74f49ab9ef..b5a5a9233f 100644
@@ -51,11 +51,4 @@ extern int txgbe_logtype_tx_free;
 #define DEBUGOUT(fmt, args...)    PMD_DRV_LOG(DEBUG, fmt, ##args)
 #define PMD_INIT_FUNC_TRACE()     PMD_DRV_LOG(DEBUG, ">>")
 
-extern int txgbe_logtype_bp;
-#define BP_LOG(fmt, args...) \
-     rte_log(RTE_LOG_DEBUG, txgbe_logtype_bp, \
-             "[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
-             usec_stamp() / 1000000, usec_stamp() % 1000000, \
-             __func__, __LINE__, ##args)
-
 #endif /* _TXGBE_LOGS_H_ */
--
Quoted 2 lines

2.46.0

Hi,

Quoted 3 lines
Quoted 1 line

Does this have to change? It looks a little weird.

Can you be more specific about the part that you don't like?

Just for defining log macro in other .h file.

Quoted 7 lines

There is a change in behavior, I agree: messages would now be prefixed with the logtype, here TXGBE_BP.
I can revert this part if you prefer.

As for moving the macro, in all other drivers in DPDK, the osdep.h header provides helpers for the base driver code, so it is the right location.

#13 lore raw

PATCH 8/11 drivers: replace logging helpers

In reply to David Marchand

Prepare for the conversion to RTE_LOG_LINE.
Some drivers currently add no \n in the logging macro and have the callers do it.

Let's invert this logic but again, thinking about backports, introduce the change in new macros.

---
 drivers/bus/platform/platform.c               |  28 +-
 drivers/bus/platform/platform_params.c        |   2 +-
 drivers/bus/platform/private.h                |  10 +-
 drivers/common/nitrox/nitrox_hal.c            |   4 +-
 drivers/common/nitrox/nitrox_logs.h           |   8 +-
 drivers/common/nitrox/nitrox_qp.c             |  10 +-
 drivers/compress/nitrox/nitrox_comp.c         |  44 +-
 drivers/compress/nitrox/nitrox_comp_reqmgr.c  | 170 +++---
 drivers/crypto/nitrox/nitrox_sym.c            |  54 +-
 drivers/crypto/nitrox/nitrox_sym_reqmgr.c     |  12 +-
 drivers/dma/odm/odm.h                         |  14 +-
 drivers/dma/odm/odm_dmadev.c                  |  12 +-
 drivers/event/dsw/dsw_evdev.h                 |   8 +-
 drivers/event/dsw/dsw_event.c                 |  78 +--
 drivers/net/af_xdp/rte_eth_af_xdp.c           | 212 +++----
 drivers/net/avp/avp_ethdev.c                  | 155 +++--
 drivers/net/avp/avp_logs.h                    |  17 +-
 drivers/net/axgbe/axgbe_dev.c                 |  34 +-
 drivers/net/axgbe/axgbe_ethdev.c              | 128 ++--
 drivers/net/axgbe/axgbe_i2c.c                 |  18 +-
 drivers/net/axgbe/axgbe_logs.h                |   6 +-
 drivers/net/axgbe/axgbe_mdio.c                |  36 +-
 drivers/net/axgbe/axgbe_phy_impl.c            |  50 +-
 drivers/net/axgbe/axgbe_rxtx.c                |  24 +-
 drivers/net/bnxt/bnxt.h                       |   8 +-
 drivers/net/bnxt/bnxt_cpr.c                   |  66 +-
 drivers/net/bnxt/bnxt_ethdev.c                | 570 +++++++++---------
 drivers/net/bnxt/bnxt_filter.c                |  18 +-
 drivers/net/bnxt/bnxt_flow.c                  | 126 ++--
 drivers/net/bnxt/bnxt_hwrm.c                  | 320 +++++-----
 drivers/net/bnxt/bnxt_irq.c                   |   4 +-
 drivers/net/bnxt/bnxt_reps.c                  |  86 +--
 drivers/net/bnxt/bnxt_ring.c                  |  18 +-
 drivers/net/bnxt/bnxt_rxq.c                   |  66 +-
 drivers/net/bnxt/bnxt_rxr.c                   |  32 +-
 drivers/net/bnxt/bnxt_rxtx_vec_avx2.c         |   2 +-
 drivers/net/bnxt/bnxt_rxtx_vec_neon.c         |   2 +-
 drivers/net/bnxt/bnxt_rxtx_vec_sse.c          |   2 +-
 drivers/net/bnxt/bnxt_stats.c                 |   6 +-
 drivers/net/bnxt/bnxt_txq.c                   |  16 +-
 drivers/net/bnxt/bnxt_txr.c                   |  16 +-
 drivers/net/bnxt/bnxt_vnic.c                  | 124 ++--
 drivers/net/bnxt/rte_pmd_bnxt.c               | 132 ++--
 .../net/bnxt/tf_core/tf_em_hash_internal.c    |   4 +-
 drivers/net/bnxt/tf_core/tf_em_internal.c     |   4 +-
 drivers/net/bnxt/tf_ulp/bnxt_tf_common.h      |   3 +-
 drivers/net/bnxt/tf_ulp/bnxt_tf_pmd_shim.c    |   6 +-
 drivers/net/bnxt/tf_ulp/bnxt_ulp.c            |   2 +-
 drivers/net/bnxt/tf_ulp/ulp_fc_mgr.c          |  22 +-
 drivers/net/bnxt/tf_ulp/ulp_ha_mgr.c          |   2 +-
 drivers/net/ena/ena_ethdev.c                  | 348 +++++------
 drivers/net/ena/ena_logs.h                    |  28 +-
 drivers/net/ena/ena_rss.c                     |  76 +--
 drivers/net/vhost/rte_eth_vhost.c             |  76 +--
 54 files changed, 1654 insertions(+), 1665 deletions(-)
drivers/bus/platform/platform.c +14 -14
index 7e24bb96a1..11892caa24 100644
@@ -97,7 +97,7 @@ dev_add(const char *dev_name)
 
 	FOREACH_DEVICE_ON_PLATFORM_BUS(tmp) {
 		if (!strcmp(tmp->name, pdev->name)) {
-			PLATFORM_LOG(INFO, "device %s already added\n", pdev->name);
+			PLATFORM_LOG_LINE(INFO, "device %s already added", pdev->name);
 
 			if (tmp->device.devargs != pdev->device.devargs)
 				rte_devargs_remove(pdev->device.devargs);
@@ -109,7 +109,7 @@ dev_add(const char *dev_name)
 
 	TAILQ_INSERT_HEAD(&platform_bus.device_list, pdev, next);
 
-	PLATFORM_LOG(INFO, "adding device %s to the list\n", dev_name);
+	PLATFORM_LOG_LINE(INFO, "adding device %s to the list", dev_name);
 
 	return 0;
 }
@@ -161,7 +161,7 @@ platform_bus_scan(void)
 
 	dp = opendir(PLATFORM_BUS_DEVICES_PATH);
 	if (dp == NULL) {
-		PLATFORM_LOG(INFO, "failed to open %s\n", PLATFORM_BUS_DEVICES_PATH);
+		PLATFORM_LOG_LINE(INFO, "failed to open %s", PLATFORM_BUS_DEVICES_PATH);
 		return -errno;
 	}
 
@@ -195,7 +195,7 @@ device_map_resource_offset(struct rte_platform_device *pdev, struct rte_platform
 	if (res->mem.addr == MAP_FAILED)
 		return -errno;
 
-	PLATFORM_LOG(DEBUG, "adding resource va = %p len = %"PRIu64" name = %s\n", res->mem.addr,
+	PLATFORM_LOG_LINE(DEBUG, "adding resource va = %p len = %"PRIu64" name = %s", res->mem.addr,
 		     res->mem.len, res->name);
 
 	return 0;
@@ -271,7 +271,7 @@ device_map_resources(struct rte_platform_device *pdev, unsigned int num)
 	int ret;
 
 	if (num == 0) {
-		PLATFORM_LOG(WARNING, "device %s has no resources\n", pdev->name);
+		PLATFORM_LOG_LINE(WARNING, "device %s has no resources", pdev->name);
 		return 0;
 	}
 
@@ -287,7 +287,7 @@ device_map_resources(struct rte_platform_device *pdev, unsigned int num)
 
 		ret = ioctl(pdev->dev_fd, VFIO_DEVICE_GET_REGION_INFO, &reg_info);
 		if (ret) {
-			PLATFORM_LOG(ERR, "failed to get region info at %d\n", i);
+			PLATFORM_LOG_LINE(ERR, "failed to get region info at %d", i);
 			ret = -errno;
 			goto out;
 		}
@@ -297,7 +297,7 @@ device_map_resources(struct rte_platform_device *pdev, unsigned int num)
 		res->mem.len = reg_info.size;
 		ret = device_map_resource_offset(pdev, res, reg_info.offset);
 		if (ret) {
-			PLATFORM_LOG(ERR, "failed to ioremap resource at %d\n", i);
+			PLATFORM_LOG_LINE(ERR, "failed to ioremap resource at %d", i);
 			goto out;
 		}
 
@@ -327,7 +327,7 @@ device_setup(struct rte_platform_device *pdev)
 
 	ret = rte_vfio_setup_device(PLATFORM_BUS_DEVICES_PATH, name, &pdev->dev_fd, &dev_info);
 	if (ret) {
-		PLATFORM_LOG(ERR, "failed to setup %s\n", name);
+		PLATFORM_LOG_LINE(ERR, "failed to setup %s", name);
 		return -ENODEV;
 	}
 
@@ -342,7 +342,7 @@ device_setup(struct rte_platform_device *pdev)
 	 */
 #ifdef VFIO_DEVICE_FLAGS_PLATFORM
 	if (!(dev_info.flags & VFIO_DEVICE_FLAGS_PLATFORM)) {
-		PLATFORM_LOG(ERR, "device not backed by vfio-platform\n");
+		PLATFORM_LOG_LINE(ERR, "device not backed by vfio-platform");
 		ret = -ENOTSUP;
 		goto out;
 	}
@@ -350,7 +350,7 @@ device_setup(struct rte_platform_device *pdev)
 
 	ret = device_map_resources(pdev, dev_info.num_regions);
 	if (ret) {
-		PLATFORM_LOG(ERR, "failed to setup platform resources\n");
+		PLATFORM_LOG_LINE(ERR, "failed to setup platform resources");
 		goto out;
 	}
 
@@ -389,7 +389,7 @@ driver_probe_device(struct rte_platform_driver *pdrv, struct rte_platform_device
 
 	iova_mode = rte_eal_iova_mode();
 	if (pdrv->drv_flags & RTE_PLATFORM_DRV_NEED_IOVA_AS_VA && iova_mode != RTE_IOVA_VA) {
-		PLATFORM_LOG(ERR, "driver %s expects VA IOVA mode but current mode is PA\n",
+		PLATFORM_LOG_LINE(ERR, "driver %s expects VA IOVA mode but current mode is PA",
 			     pdrv->driver.name);
 		return -EINVAL;
 	}
@@ -462,11 +462,11 @@ platform_bus_probe(void)
 	FOREACH_DEVICE_ON_PLATFORM_BUS(pdev) {
 		ret = device_attach(pdev);
 		if (ret == -EBUSY) {
-			PLATFORM_LOG(DEBUG, "device %s already probed\n", pdev->name);
+			PLATFORM_LOG_LINE(DEBUG, "device %s already probed", pdev->name);
 			continue;
 		}
 		if (ret)
-			PLATFORM_LOG(ERR, "failed to probe %s\n", pdev->name);
+			PLATFORM_LOG_LINE(ERR, "failed to probe %s", pdev->name);
 	}
 
 	return 0;
@@ -517,7 +517,7 @@ device_release_driver(struct rte_platform_device *pdev)
 	if (pdrv != NULL && pdrv->remove != NULL) {
 		ret = pdrv->remove(pdev);
 		if (ret)
-			PLATFORM_LOG(WARNING, "failed to remove %s\n", pdev->name);
+			PLATFORM_LOG_LINE(WARNING, "failed to remove %s", pdev->name);
 	}
 
 	pdev->device.driver = NULL;
drivers/bus/platform/platform_params.c +1 -1
index 0eb8eb56e7..8a6214b97c 100644
@@ -56,7 +56,7 @@ platform_bus_dev_iterate(const void *start, const char *str,
 	if (str != NULL) {
 		kvargs = rte_kvargs_parse(str, platform_params_keys);
 		if (!kvargs) {
-			PLATFORM_LOG(ERR, "cannot parse argument list %s", str);
+			PLATFORM_LOG_LINE(ERR, "cannot parse argument list %s", str);
 			rte_errno = EINVAL;
 			return NULL;
 		}
drivers/bus/platform/private.h +5 -5
index a7a4b0da56..72185aa457 100644
@@ -15,7 +15,6 @@
 #include "bus_platform_driver.h"
 
 extern struct rte_platform_bus platform_bus;
-extern int platform_bus_logtype;
 
 /* Platform bus iterators. */
 #define FOREACH_DEVICE_ON_PLATFORM_BUS(p) \
@@ -33,10 +32,11 @@ struct rte_platform_bus {
 	RTE_TAILQ_HEAD(, rte_platform_driver) driver_list; /* List of bus drivers */
 };
 
-#define PLATFORM_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, platform_bus_logtype, \
-		RTE_FMT("platform bus: " RTE_FMT_HEAD(__VA_ARGS__,), \
-			RTE_FMT_TAIL(__VA_ARGS__,)))
+extern int platform_bus_logtype;
+#define RTE_LOGTYPE_PLATFORM_BUS platform_bus_logtype
+#define PLATFORM_LOG_LINE(level, ...) \
+	RTE_LOG(level, PLATFORM_BUS, RTE_FMT(RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
+		RTE_FMT_TAIL(__VA_ARGS__,)))
 
 /*
  * Iterate registered platform devices and find one that matches provided string.
drivers/common/nitrox/nitrox_hal.c +2 -2
index 451549a664..9ef974409c 100644
@@ -190,7 +190,7 @@ zqmq_input_ring_disable(uint8_t *bar_addr, uint16_t ring)
 	}
 
 	if (zqmq_activity_stat.s.queue_active) {
-		NITROX_LOG(ERR, "Failed to disable zqmq ring %d\n", ring);
+		NITROX_LOG_LINE(ERR, "Failed to disable zqmq ring %d", ring);
 		return -EBUSY;
 	}
 
@@ -271,7 +271,7 @@ setup_zqmq_input_ring(uint8_t *bar_addr, uint16_t ring, uint32_t rsize,
 	}
 
 	if (!zqmq_en.s.queue_enable) {
-		NITROX_LOG(ERR, "Failed to enable zqmq ring %d\n", ring);
+		NITROX_LOG_LINE(ERR, "Failed to enable zqmq ring %d", ring);
 		err = -EFAULT;
 	} else {
 		err = 0;
drivers/common/nitrox/nitrox_logs.h +3 -5
index 50e52f396b..67964447eb 100644
@@ -5,11 +5,9 @@
 #ifndef _NITROX_LOGS_H_
 #define _NITROX_LOGS_H_
 
-#define LOG_PREFIX "NITROX: "
-#define NITROX_LOG(level, fmt, args...)					\
-	rte_log(RTE_LOG_ ## level, nitrox_logtype,			\
-		LOG_PREFIX "%s:%d " fmt, __func__, __LINE__, ## args)
-
 extern int nitrox_logtype;
+#define RTE_LOGTYPE_NITROX nitrox_logtype
+#define NITROX_LOG_LINE(level, fmt, args...) \
+	RTE_LOG(level, NITROX, "%s:%d " fmt "\n", __func__, __LINE__, ## args)
 
 #endif /* _NITROX_LOGS_H_ */
drivers/common/nitrox/nitrox_qp.c +5 -5
index 1665c3c40d..d6a5ddd641 100644
@@ -28,7 +28,7 @@ nitrox_setup_cmdq(struct nitrox_qp *qp, uint8_t *bar_addr,
 					 RTE_MEMZONE_256MB,
 					 CMDQ_PKT_IN_ALIGN);
 	if (!mz) {
-		NITROX_LOG(ERR, "cmdq memzone reserve failed for %s queue\n",
+		NITROX_LOG_LINE(ERR, "cmdq memzone reserve failed for %s queue",
 			   mz_name);
 		return -ENOMEM;
 	}
@@ -48,7 +48,7 @@ nitrox_setup_cmdq(struct nitrox_qp *qp, uint8_t *bar_addr,
 					    mz->iova);
 		break;
 	default:
-		NITROX_LOG(ERR, "Invalid queue type %d\n", qp->type);
+		NITROX_LOG_LINE(ERR, "Invalid queue type %d", qp->type);
 		err = -EINVAL;
 		break;
 	}
@@ -73,7 +73,7 @@ nitrox_setup_ridq(struct nitrox_qp *qp, int socket_id)
 				   RTE_CACHE_LINE_SIZE,
 				   socket_id);
 	if (!qp->ridq) {
-		NITROX_LOG(ERR, "Failed to create rid queue\n");
+		NITROX_LOG_LINE(ERR, "Failed to create rid queue");
 		return -ENOMEM;
 	}
 
@@ -112,8 +112,8 @@ nitrox_qp_setup(struct nitrox_qp *qp, uint8_t *bar_addr, const char *dev_name,
 
 	count = rte_align32pow2(nb_descriptors);
 	if (count > MAX_CMD_QLEN) {
-		NITROX_LOG(ERR, "%s: Number of descriptors too big %d,"
-			   " greater than max queue length %d\n",
+		NITROX_LOG_LINE(ERR, "%s: Number of descriptors too big %d,"
+			   " greater than max queue length %d",
 			   dev_name, count,
 			   MAX_CMD_QLEN);
 		return -EINVAL;
drivers/compress/nitrox/nitrox_comp.c +22 -22

162 lines not on this page · raw message

drivers/compress/nitrox/nitrox_comp_reqmgr.c +85 -85

329 lines not on this page · raw message

drivers/crypto/nitrox/nitrox_sym.c +27 -27

197 lines not on this page · raw message

drivers/crypto/nitrox/nitrox_sym_reqmgr.c +6 -6
index 973bb5f424..7751c1a9fc 100644
@@ -466,7 +466,7 @@ create_cipher_auth_sglist(struct nitrox_softreq *sr,
 	if (unlikely(
 		op->sym->cipher.data.offset + op->sym->cipher.data.length !=
 		op->sym->auth.data.offset + op->sym->auth.data.length)) {
-		NITROX_LOG(ERR, "Auth only data after cipher data not supported\n");
+		NITROX_LOG_LINE(ERR, "Auth only data after cipher data not supported");
 		return -ENOTSUP;
 	}
 
@@ -679,7 +679,7 @@ softreq_copy_salt(struct nitrox_softreq *sr)
 	uint8_t *addr;
 
 	if (unlikely(ctx->iv.length < AES_GCM_SALT_SIZE)) {
-		NITROX_LOG(ERR, "Invalid IV length %d\n", ctx->iv.length);
+		NITROX_LOG_LINE(ERR, "Invalid IV length %d", ctx->iv.length);
 		return -EINVAL;
 	}
 
@@ -829,8 +829,8 @@ nitrox_process_se_req(uint16_t qno, struct rte_crypto_op *op,
 	if (unlikely(op->sym->m_src->nb_segs > MAX_SUPPORTED_MBUF_SEGS ||
 		     (op->sym->m_dst &&
 		      op->sym->m_dst->nb_segs > MAX_SUPPORTED_MBUF_SEGS))) {
-		NITROX_LOG(ERR, "Mbuf segments not supported. "
-			   "Max supported %d\n", MAX_SUPPORTED_MBUF_SEGS);
+		NITROX_LOG_LINE(ERR, "Mbuf segments not supported. "
+			   "Max supported %d", MAX_SUPPORTED_MBUF_SEGS);
 		return -ENOTSUP;
 	}
 
@@ -865,7 +865,7 @@ nitrox_check_se_req(struct nitrox_softreq *sr, struct rte_crypto_op **op)
 		return -EAGAIN;
 
 	if (unlikely(err))
-		NITROX_LOG(ERR, "Request err 0x%x, orh 0x%"PRIx64"\n", err,
+		NITROX_LOG_LINE(ERR, "Request err 0x%x, orh 0x%"PRIx64, err,
 			   sr->resp.orh);
 
 	*op = sr->op;
@@ -901,7 +901,7 @@ nitrox_sym_req_pool_create(struct rte_cryptodev *cdev, uint32_t nobjs,
 				64, 0, NULL, NULL, req_pool_obj_init, NULL,
 				socket_id, 0);
 	if (unlikely(!mp))
-		NITROX_LOG(ERR, "Failed to create req pool, qid %d, err %d\n",
+		NITROX_LOG_LINE(ERR, "Failed to create req pool, qid %d, err %d",
 			   qp_id, rte_errno);
 
 	return mp;
drivers/dma/odm/odm.h +3 -11
index 7303aa2955..274c21ef8d 100644
@@ -66,17 +66,9 @@ extern int odm_logtype;
 #define odm_read64(addr)       rte_read64_relaxed((volatile void *)(addr))
 #define odm_write64(val, addr) rte_write64_relaxed((val), (volatile void *)(addr))
 
-#define odm_err(...)                                                                               \
-	rte_log(RTE_LOG_ERR, odm_logtype,                                                          \
-		RTE_FMT("%s(): %u" RTE_FMT_HEAD(__VA_ARGS__, ), __func__, __LINE__,                \
-			RTE_FMT_TAIL(__VA_ARGS__, )))
-#define odm_info(...)                                                                              \
-	rte_log(RTE_LOG_INFO, odm_logtype,                                                         \
-		RTE_FMT("%s(): %u" RTE_FMT_HEAD(__VA_ARGS__, ), __func__, __LINE__,                \
-			RTE_FMT_TAIL(__VA_ARGS__, )))
-#define odm_debug(...)                                                                             \
-	rte_log(RTE_LOG_DEBUG, odm_logtype,                                                        \
-		RTE_FMT("%s(): %u" RTE_FMT_HEAD(__VA_ARGS__, ), __func__, __LINE__,                \
+#define ODM_LOG(level, ...) \
+	rte_log(RTE_LOG_ ## level, odm_logtype, \
+		RTE_FMT("%s(): %u" RTE_FMT_HEAD(__VA_ARGS__,) "\n", __func__, __LINE__, \
 			RTE_FMT_TAIL(__VA_ARGS__, )))
 
 /*
drivers/dma/odm/odm_dmadev.c +6 -6
index 57bd6923f1..a2f4ed9a8e 100644
@@ -494,10 +494,10 @@ odm_dmadev_completed_status(void *dev_private, uint16_t vchan, const uint16_t nb
 	}
 
 #ifdef ODM_DEBUG
-	odm_debug("cring_head: 0x%" PRIx16, cring_head);
-	odm_debug("Submitted: 0x%" PRIx64, vq->stats.submitted);
-	odm_debug("Completed: 0x%" PRIx64, vq->stats.completed);
-	odm_debug("Hardware count: 0x%" PRIx64, odm_read64(odm->rbase + ODM_VDMA_CNT(vchan)));
+	ODM_LOG(DEBUG, "cring_head: 0x%" PRIx16, cring_head);
+	ODM_LOG(DEBUG, "Submitted: 0x%" PRIx64, vq->stats.submitted);
+	ODM_LOG(DEBUG, "Completed: 0x%" PRIx64, vq->stats.completed);
+	ODM_LOG(DEBUG, "Hardware count: 0x%" PRIx64, odm_read64(odm->rbase + ODM_VDMA_CNT(vchan)));
 #endif
 
 	for (cnt = 0; cnt < nb_cpls; cnt++) {
@@ -651,11 +651,11 @@ odm_dmadev_probe(struct rte_pci_driver *pci_drv __rte_unused, struct rte_pci_dev
 
 	dmadev = rte_dma_pmd_allocate(name, pci_dev->device.numa_node, sizeof(*odm));
 	if (dmadev == NULL) {
-		odm_err("DMA device allocation failed for %s", name);
+		ODM_LOG(ERR, "DMA device allocation failed for %s", name);
 		return -ENOMEM;
 	}
 
-	odm_info("DMA device %s probed", name);
+	ODM_LOG(INFO, "DMA device %s probed", name);
 	odm = dmadev->data->dev_private;
 
 	dmadev->device = &pci_dev->device;
drivers/event/dsw/dsw_evdev.h +4 -4
index c9bf4f8b6b..ca7aec575c 100644
@@ -302,12 +302,12 @@ dsw_pmd_priv(const struct rte_eventdev *eventdev)
 	return eventdev->data->dev_private;
 }
 
-#define DSW_LOG_DP(level, fmt, args...)					\
-	RTE_LOG_DP(level, EVENTDEV, "[%s] %s() line %u: " fmt,		\
+#define DSW_LOG_DP_LINE(level, fmt, args...)				\
+	RTE_LOG_DP(level, EVENTDEV, "[%s] %s() line %u: " fmt "\n",	\
 		   DSW_PMD_NAME,					\
 		   __func__, __LINE__, ## args)
 
-#define DSW_LOG_DP_PORT(level, port_id, fmt, args...)		\
-	DSW_LOG_DP(level, "<Port %d> " fmt, port_id, ## args)
+#define DSW_LOG_DP_PORT_LINE(level, port_id, fmt, args...)		\
+	DSW_LOG_DP_LINE(level, "<Port %d> " fmt, port_id, ## args)
 
 #endif
drivers/event/dsw/dsw_event.c +39 -39

203 lines not on this page · raw message

drivers/net/af_xdp/rte_eth_af_xdp.c +106 -106

770 lines not on this page · raw message

drivers/net/avp/avp_ethdev.c +77 -78

566 lines not on this page · raw message

drivers/net/avp/avp_logs.h +8 -9
index 574b720b30..3f2721df1a 100644
@@ -8,24 +8,23 @@
 #include <rte_log.h>
 
 #ifdef RTE_LIBRTE_AVP_DEBUG_RX
-#define PMD_RX_LOG(level, fmt, args...) \
-	RTE_LOG(level, AVP_DRIVER, "%s() rx: " fmt, __func__, ## args)
+#define PMD_RX_LOG_LINE(level, fmt, ...) \
+	RTE_LOG(level, AVP_DRIVER, "%s() rx: " fmt "\n", __func__, ## __VA_ARGS__)
 #else
-#define PMD_RX_LOG(level, fmt, args...) do { } while (0)
+#define PMD_RX_LOG_LINE(...) do { } while (0)
 #endif
 
 #ifdef RTE_LIBRTE_AVP_DEBUG_TX
-#define PMD_TX_LOG(level, fmt, args...) \
-	RTE_LOG(level, AVP_DRIVER, "%s() tx: " fmt, __func__, ## args)
+#define PMD_TX_LOG_LINE(level, fmt, ...) \
+	RTE_LOG(level, AVP_DRIVER, "%s() tx: " fmt "\n", __func__, ## __VA_ARGS__)
 #else
-#define PMD_TX_LOG(level, fmt, args...) do { } while (0)
+#define PMD_TX_LOG_LINE(...) do { } while (0)
 #endif
 
 extern int avp_logtype_driver;
 #define RTE_LOGTYPE_AVP_DRIVER avp_logtype_driver
 
-#define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, avp_logtype_driver, \
-		"%s(): " fmt, __func__, ## args)
+#define PMD_DRV_LOG_LINE(level, fmt, ...) \
+	RTE_LOG(level, AVP_DRIVER, "%s(): " fmt "\n", __func__, ## __VA_ARGS__)
 
 #endif /* _AVP_LOGS_H_ */
drivers/net/axgbe/axgbe_dev.c +17 -17
index ebe64295aa..9173a6fea6 100644
@@ -107,7 +107,7 @@ static int axgbe_write_ext_mii_regs(struct axgbe_port *pdata,
 			return 0;
 	}
 
-	PMD_DRV_LOG(ERR, "Mdio write operation timed out\n");
+	PMD_DRV_LOG_LINE(ERR, "Mdio write operation timed out");
 	return -ETIMEDOUT;
 }
 
@@ -154,7 +154,7 @@ static int axgbe_read_ext_mii_regs(struct axgbe_port *pdata,
 			goto success;
 	}
 
-	PMD_DRV_LOG(ERR, "Mdio read operation timed out\n");
+	PMD_DRV_LOG_LINE(ERR, "Mdio read operation timed out");
 	return -ETIMEDOUT;
 
 success:
@@ -272,7 +272,7 @@ static int axgbe_read_mmd_regs(struct axgbe_port *pdata, int prtad,
 {
 	switch (pdata->vdata->xpcs_access) {
 	case AXGBE_XPCS_ACCESS_V1:
-		PMD_DRV_LOG(ERR, "PHY_Version 1 is not supported\n");
+		PMD_DRV_LOG_LINE(ERR, "PHY_Version 1 is not supported");
 		return -1;
 	case AXGBE_XPCS_ACCESS_V2:
 	default:
@@ -285,7 +285,7 @@ static void axgbe_write_mmd_regs(struct axgbe_port *pdata, int prtad,
 {
 	switch (pdata->vdata->xpcs_access) {
 	case AXGBE_XPCS_ACCESS_V1:
-		PMD_DRV_LOG(ERR, "PHY_Version 1 is not supported\n");
+		PMD_DRV_LOG_LINE(ERR, "PHY_Version 1 is not supported");
 		return;
 	case AXGBE_XPCS_ACCESS_V2:
 	default:
@@ -369,7 +369,7 @@ static int axgbe_enable_tx_flow_control(struct axgbe_port *pdata)
 
 		AXGMAC_MTL_IOWRITE_BITS(pdata, i, MTL_Q_RQOMR, EHFC, ehfc);
 
-		PMD_DRV_LOG(DEBUG, "flow control %s for RXq%u\n",
+		PMD_DRV_LOG_LINE(DEBUG, "flow control %s for RXq%u",
 			    ehfc ? "enabled" : "disabled", i);
 	}
 
@@ -608,8 +608,8 @@ static int axgbe_update_vlan_hash_table(struct axgbe_port *pdata)
 		vid_valid = pdata->active_vlans[vid_idx];
 		vid_valid = (unsigned long)vid_valid >> (vid - (64 * vid_idx));
 		if (vid_valid & 1)
-			PMD_DRV_LOG(DEBUG,
-				    "vid:%d pdata->active_vlans[%ld]=0x%lx\n",
+			PMD_DRV_LOG_LINE(DEBUG,
+				    "vid:%d pdata->active_vlans[%ld]=0x%lx",
 				    vid, vid_idx, pdata->active_vlans[vid_idx]);
 		else
 			continue;
@@ -617,13 +617,13 @@ static int axgbe_update_vlan_hash_table(struct axgbe_port *pdata)
 		vid_le = rte_cpu_to_le_16(vid);
 		crc = bitrev32(~axgbe_vid_crc32_le(vid_le)) >> 28;
 		vlan_hash_table |= (1 << crc);
-		PMD_DRV_LOG(DEBUG, "crc = %d vlan_hash_table = 0x%x\n",
+		PMD_DRV_LOG_LINE(DEBUG, "crc = %d vlan_hash_table = 0x%x",
 			    crc, vlan_hash_table);
 	}
 	/* Set the VLAN Hash Table filtering register */
 	AXGMAC_IOWRITE_BITS(pdata, MAC_VLANHTR, VLHT, vlan_hash_table);
 	reg = AXGMAC_IOREAD(pdata, MAC_VLANHTR);
-	PMD_DRV_LOG(DEBUG, "vlan_hash_table reg val = 0x%x\n", reg);
+	PMD_DRV_LOG_LINE(DEBUG, "vlan_hash_table reg val = 0x%x", reg);
 	return 0;
 }
 
@@ -927,7 +927,7 @@ static int axgbe_config_rss(struct axgbe_port *pdata)
 					i % pdata->eth_dev->data->nb_rx_queues);
 		axgbe_rss_options(pdata);
 		if (axgbe_enable_rss(pdata)) {
-			PMD_DRV_LOG(ERR, "Error in enabling RSS support\n");
+			PMD_DRV_LOG_LINE(ERR, "Error in enabling RSS support");
 			return -1;
 		}
 	} else {
@@ -1012,7 +1012,7 @@ static int wrapper_rx_desc_init(struct axgbe_port *pdata)
 		for (j = 0; j < rxq->nb_desc; j++) {
 			mbuf = rte_mbuf_raw_alloc(rxq->mb_pool);
 			if (mbuf == NULL) {
-				PMD_DRV_LOG(ERR, "RX mbuf alloc failed queue_id = %u, idx = %d\n",
+				PMD_DRV_LOG_LINE(ERR, "RX mbuf alloc failed queue_id = %u, idx = %d",
 					    (unsigned int)rxq->queue_id, j);
 				axgbe_dev_rx_queue_release(pdata->eth_dev, i);
 				return -ENOMEM;
@@ -1138,7 +1138,7 @@ static void axgbe_config_rx_fifo_size(struct axgbe_port *pdata)
 	axgbe_calculate_flow_control_threshold(pdata);
 	axgbe_config_flow_control_threshold(pdata);
 
-	PMD_DRV_LOG(DEBUG, "%d Rx hardware queues, %d byte fifo per queue\n",
+	PMD_DRV_LOG_LINE(DEBUG, "%d Rx hardware queues, %d byte fifo per queue",
 		    pdata->rx_q_count, q_fifo_size);
 }
 
@@ -1164,7 +1164,7 @@ static void axgbe_config_tx_fifo_size(struct axgbe_port *pdata)
 	for (i = 0; i < pdata->tx_q_count; i++)
 		AXGMAC_MTL_IOWRITE_BITS(pdata, i, MTL_Q_TQOMR, TQS, p_fifo);
 
-	PMD_DRV_LOG(DEBUG, "%d Tx hardware queues, %d byte fifo per queue\n",
+	PMD_DRV_LOG_LINE(DEBUG, "%d Tx hardware queues, %d byte fifo per queue",
 		    pdata->tx_q_count, q_fifo_size);
 }
 
@@ -1181,12 +1181,12 @@ static void axgbe_config_queue_mapping(struct axgbe_port *pdata)
 
 	for (i = 0, queue = 0; i < pdata->hw_feat.tc_cnt; i++) {
 		for (j = 0; j < qptc; j++) {
-			PMD_DRV_LOG(DEBUG, "TXq%u mapped to TC%u\n", queue, i);
+			PMD_DRV_LOG_LINE(DEBUG, "TXq%u mapped to TC%u", queue, i);
 			AXGMAC_MTL_IOWRITE_BITS(pdata, queue, MTL_Q_TQOMR,
 						Q2TCMAP, i);
 		}
 		if (i < qptc_extra) {
-			PMD_DRV_LOG(DEBUG, "TXq%u mapped to TC%u\n", queue, i);
+			PMD_DRV_LOG_LINE(DEBUG, "TXq%u mapped to TC%u", queue, i);
 			AXGMAC_MTL_IOWRITE_BITS(pdata, queue, MTL_Q_TQOMR,
 						Q2TCMAP, i);
 		}
@@ -1254,7 +1254,7 @@ void axgbe_set_mac_hash_table(struct axgbe_port *pdata, u8 *addr, bool add)
 		pdata->uc_hash_table[htable_index] &= ~htable_bitmask;
 		pdata->uc_hash_mac_addr--;
 	}
-	PMD_DRV_LOG(DEBUG, "%s MAC hash table Bit %d at Index %#x\n",
+	PMD_DRV_LOG_LINE(DEBUG, "%s MAC hash table Bit %d at Index %#x",
 		    add ? "set" : "clear", (crc & 0x1f), htable_index);
 
 	AXGMAC_IOWRITE(pdata, MAC_HTR(htable_index),
@@ -1283,7 +1283,7 @@ void axgbe_set_mac_addn_addr(struct axgbe_port *pdata, u8 *addr, uint32_t index)
 		AXGMAC_SET_BITS(mac_addr_hi, MAC_MACA1HR, AE, 1);
 	}
 
-	PMD_DRV_LOG(DEBUG, "%s mac address at %#x\n",
+	PMD_DRV_LOG_LINE(DEBUG, "%s mac address at %#x",
 		    addr ? "set" : "clear", index);
 
 	AXGMAC_IOWRITE(pdata, MAC_MACAHR(index), mac_addr_hi);
drivers/net/axgbe/axgbe_ethdev.c +64 -64

306 lines not on this page · raw message

drivers/net/axgbe/axgbe_i2c.c +9 -9
index a2798f484e..484ee1b4e4 100644

Lines of this file are not shown. View the raw message.

drivers/net/axgbe/axgbe_logs.h +3 -3
index d148701716..3962895c5a 100644

Lines of this file are not shown. View the raw message.

drivers/net/axgbe/axgbe_mdio.c +18 -18
index 130a67479e..952a0add62 100644

Lines of this file are not shown. View the raw message.

drivers/net/axgbe/axgbe_phy_impl.c +25 -25

50 lines not on this page · raw message

drivers/net/axgbe/axgbe_rxtx.c +12 -12
index a9ff291cef..974ade9ab7 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt.h +2 -6
index aaa7ea00cc..8ac20961d9 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_cpr.c +33 -33

66 lines not on this page · raw message

drivers/net/bnxt/bnxt_ethdev.c +286 -284

570 lines not on this page · raw message

drivers/net/bnxt/bnxt_filter.c +9 -9
index ff563f08bb..7b90ba651f 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_flow.c +63 -63

126 lines not on this page · raw message

drivers/net/bnxt/bnxt_hwrm.c +160 -160

320 lines not on this page · raw message

drivers/net/bnxt/bnxt_irq.c +2 -2
index edf16bd33e..ac00ee1cbb 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_reps.c +43 -43

86 lines not on this page · raw message

drivers/net/bnxt/bnxt_ring.c +9 -9
index 9e512321d9..3d63956bd8 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_rxq.c +33 -33

66 lines not on this page · raw message

drivers/net/bnxt/bnxt_rxr.c +16 -16
index b59989b5a1..d51a66ae77 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_rxtx_vec_avx2.c +1 -1
index 976f258044..43d9528134 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_rxtx_vec_neon.c +1 -1
index 04864e0b95..0ff1641c19 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_rxtx_vec_sse.c +1 -1
index e367fbfbd1..9f1a02f0ab 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_stats.c +3 -3
index b9cce227d9..5e59afe79f 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_txq.c +8 -8
index 05032f7807..c864935992 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_txr.c +8 -8
index 83c003d258..6a38c7c6e4 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_vnic.c +62 -62

124 lines not on this page · raw message

drivers/net/bnxt/rte_pmd_bnxt.c +66 -66

132 lines not on this page · raw message

drivers/net/bnxt/tf_core/tf_em_hash_internal.c +2 -2
index d72ac83295..9c527e152d 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_core/tf_em_internal.c +2 -2
index 46de63a9da..7f7a663789 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_ulp/bnxt_tf_common.h +2 -1
index cd4cd8ac74..747f1da557 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_ulp/bnxt_tf_pmd_shim.c +3 -3
index 96d61c3ed2..75a0b77ac2 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_ulp/bnxt_ulp.c +1 -1
index 33028c470f..361bed7b3e 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_ulp/ulp_fc_mgr.c +11 -11
index c39cde39aa..2360788f8f 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_ulp/ulp_ha_mgr.c +1 -1
index 852deef3b4..074cb4ff45 100644

Lines of this file are not shown. View the raw message.

drivers/net/ena/ena_ethdev.c +174 -174

348 lines not on this page · raw message

drivers/net/ena/ena_logs.h +14 -14
index 43f16458ea..5c9ec1772b 100644

Lines of this file are not shown. View the raw message.

drivers/net/ena/ena_rss.c +38 -38

76 lines not on this page · raw message

drivers/net/vhost/rte_eth_vhost.c +39 -37

76 lines not on this page · raw message

The rest of this diff is not shown. View the raw message.

Signature · 1 line
2.46.0

Part of the diff is not shown here. View the raw message.

#14 lore raw

PATCH 9/11 drivers: remove redundant newline from logs

In reply to David Marchand

Fix places where two newline characters may be logged.

---
 drivers/baseband/acc/rte_acc100_pmd.c         |  20 +--
 drivers/baseband/acc/rte_vrb_pmd.c            |  26 ++--
 .../fpga_5gnr_fec/rte_fpga_5gnr_fec.c         |  16 +--
 drivers/baseband/la12xx/bbdev_la12xx.c        |   4 +-
 .../baseband/turbo_sw/bbdev_turbo_software.c  |   4 +-
 drivers/bus/cdx/cdx_vfio.c                    |   8 +-
 drivers/bus/dpaa/include/fman.h               |   3 +-
 drivers/bus/fslmc/fslmc_bus.c                 |   8 +-
 drivers/bus/fslmc/fslmc_vfio.c                |  10 +-
 drivers/bus/fslmc/portal/dpaa2_hw_dpci.c      |   4 +-
 drivers/bus/ifpga/ifpga_bus.c                 |   8 +-
 drivers/bus/vdev/vdev_params.c                |   2 +-
 drivers/bus/vmbus/vmbus_common.c              |   2 +-
 drivers/common/cnxk/roc_dev.c                 |   2 +-
 drivers/common/cnxk/roc_model.c               |   2 +-
 drivers/common/cnxk/roc_nix_ops.c             |  20 +--
 drivers/common/cnxk/roc_nix_tm.c              |   2 +-
 drivers/common/cnxk/roc_nix_tm_mark.c         |   2 +-
 drivers/common/cnxk/roc_nix_tm_ops.c          |   2 +-
 drivers/common/cnxk/roc_nix_tm_utils.c        |   2 +-
 drivers/common/cnxk/roc_sso.c                 |   2 +-
 drivers/common/cnxk/roc_tim.c                 |   2 +-
 drivers/common/cpt/cpt_ucode.h                |   4 +-
 drivers/common/idpf/idpf_common_logs.h        |   5 +-
 drivers/common/octeontx/octeontx_mbox.c       |   4 +-
 drivers/common/qat/qat_pf2vf.c                |   4 +-
 drivers/common/qat/qat_qp.c                   |   2 +-
 drivers/compress/isal/isal_compress_pmd.c     |  78 ++++++------
 drivers/compress/octeontx/otx_zip.h           |  12 +-
 drivers/compress/octeontx/otx_zip_pmd.c       |  14 +--
 drivers/compress/zlib/zlib_pmd.c              |  26 ++--
 drivers/compress/zlib/zlib_pmd_ops.c          |   4 +-
 drivers/crypto/bcmfs/bcmfs_qp.c               |   2 +-
 drivers/crypto/bcmfs/bcmfs_sym_pmd.c          |   2 +-
 drivers/crypto/bcmfs/bcmfs_sym_session.c      |   2 +-
 drivers/crypto/caam_jr/caam_jr.c              |  32 ++---
 drivers/crypto/caam_jr/caam_jr_uio.c          |   6 +-
 drivers/crypto/ccp/ccp_dev.c                  |   2 +-
 drivers/crypto/ccp/rte_ccp_pmd.c              |   2 +-
 drivers/crypto/cnxk/cnxk_se.h                 |   6 +-
 drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c   |  44 +++----
 drivers/crypto/dpaa2_sec/dpaa2_sec_raw_dp.c   |  16 +--
 drivers/crypto/dpaa_sec/dpaa_sec.c            |  27 ++--
 drivers/crypto/dpaa_sec/dpaa_sec_log.h        |   2 +-
 drivers/crypto/dpaa_sec/dpaa_sec_raw_dp.c     |   6 +-
 drivers/crypto/ipsec_mb/ipsec_mb_private.c    |   4 +-
 drivers/crypto/ipsec_mb/ipsec_mb_private.h    |   2 +-
 drivers/crypto/ipsec_mb/pmd_aesni_mb.c        |  28 ++---
 drivers/crypto/ipsec_mb/pmd_snow3g.c          |   4 +-
 .../crypto/octeontx/otx_cryptodev_hw_access.h |   6 +-
 drivers/crypto/openssl/rte_openssl_pmd.c      |  42 +++----
 drivers/crypto/openssl/rte_openssl_pmd_ops.c  |  44 +++----
 drivers/crypto/qat/qat_asym.c                 |   2 +-
 drivers/crypto/qat/qat_sym_session.c          |  12 +-
 drivers/crypto/uadk/uadk_crypto_pmd.c         |   8 +-
 drivers/crypto/virtio/virtio_cryptodev.c      |   2 +-
 drivers/dma/dpaa/dpaa_qdma.c                  |  40 +++---
 drivers/dma/dpaa2/dpaa2_qdma.c                |  10 +-
 drivers/dma/hisilicon/hisi_dmadev.c           |   6 +-
 drivers/dma/idxd/idxd_common.c                |   2 +-
 drivers/dma/idxd/idxd_pci.c                   |   6 +-
 drivers/dma/ioat/ioat_dmadev.c                |  14 +--
 drivers/event/cnxk/cnxk_tim_evdev.c           |   2 +-
 drivers/event/dpaa2/dpaa2_eventdev.c          |  14 +--
 drivers/event/octeontx/timvf_evdev.c          |   2 +-
 drivers/event/opdl/opdl_evdev.c               |  30 ++---
 drivers/event/opdl/opdl_test.c                | 116 +++++++++---------
 drivers/event/sw/sw_evdev.c                   |  22 ++--
 drivers/event/sw/sw_evdev_xstats.c            |   4 +-
 drivers/mempool/dpaa2/dpaa2_hw_mempool.c      |   8 +-
 drivers/mempool/octeontx/octeontx_fpavf.c     |  22 ++--
 .../mempool/octeontx/rte_mempool_octeontx.c   |   6 +-
 drivers/ml/cnxk/cn10k_ml_dev.c                |  32 ++---
 drivers/ml/cnxk/cnxk_ml_ops.c                 |  20 +--
 drivers/net/atlantic/atl_rxtx.c               |   4 +-
 drivers/net/atlantic/hw_atl/hw_atl_utils.c    |  12 +-
 drivers/net/axgbe/axgbe_ethdev.c              |   2 +-
 drivers/net/bnx2x/bnx2x.c                     |   8 +-
 drivers/net/cnxk/cn10k_ethdev.c               |   2 +-
 drivers/net/cnxk/cn9k_ethdev.c                |   2 +-
 drivers/net/cnxk/cnxk_eswitch_devargs.c       |   2 +-
 drivers/net/cnxk/cnxk_ethdev.c                |   4 +-
 drivers/net/cnxk/cnxk_ethdev_mcs.c            |  14 +--
 drivers/net/cnxk/cnxk_ethdev_ops.c            |   2 +-
 drivers/net/cnxk/cnxk_rep.c                   |   8 +-
 drivers/net/cnxk/cnxk_rep.h                   |   2 +-
 drivers/net/cpfl/cpfl_ethdev.c                |   2 +-
 drivers/net/cpfl/cpfl_flow_parser.c           |   2 +-
 drivers/net/cpfl/cpfl_fxp_rule.c              |   8 +-
 drivers/net/dpaa2/dpaa2_ethdev.c              |  16 +--
 drivers/net/dpaa2/dpaa2_flow.c                |  36 +++---
 drivers/net/dpaa2/dpaa2_mux.c                 |   4 +-
 drivers/net/dpaa2/dpaa2_recycle.c             |   6 +-
 drivers/net/dpaa2/dpaa2_rxtx.c                |  14 +--
 drivers/net/dpaa2/dpaa2_sparser.c             |   8 +-
 drivers/net/dpaa2/dpaa2_tm.c                  |  24 ++--
 drivers/net/e1000/igb_ethdev.c                |   2 +-
 drivers/net/enetc/enetc_ethdev.c              |   4 +-
 drivers/net/enetfec/enet_ethdev.c             |   4 +-
 drivers/net/enetfec/enet_uio.c                |  10 +-
 drivers/net/enic/enic_ethdev.c                |  20 +--
 drivers/net/enic/enic_flow.c                  |  20 +--
 drivers/net/enic/enic_vf_representor.c        |  16 +--
 drivers/net/failsafe/failsafe_args.c          |   2 +-
 drivers/net/failsafe/failsafe_eal.c           |   2 +-
 drivers/net/failsafe/failsafe_ether.c         |   4 +-
 drivers/net/failsafe/failsafe_intr.c          |   6 +-
 drivers/net/gve/base/gve_adminq.c             |   4 +-
 drivers/net/gve/gve_rx.c                      |   2 +-
 drivers/net/gve/gve_tx.c                      |   2 +-
 drivers/net/hinic/base/hinic_pmd_eqs.c        |   2 +-
 drivers/net/hinic/base/hinic_pmd_mbox.c       |   6 +-
 drivers/net/hinic/base/hinic_pmd_niccfg.c     |   8 +-
 drivers/net/hinic/hinic_pmd_ethdev.c          |   4 +-
 drivers/net/hns3/hns3_dump.c                  |  12 +-
 drivers/net/hns3/hns3_intr.c                  |  12 +-
 drivers/net/hns3/hns3_ptp.c                   |   2 +-
 drivers/net/hns3/hns3_regs.c                  |   4 +-
 drivers/net/i40e/i40e_ethdev.c                |  51 ++++----
 drivers/net/i40e/i40e_pf.c                    |   8 +-
 drivers/net/i40e/i40e_rxtx.c                  |  42 +++----
 drivers/net/iavf/iavf_ethdev.c                |  12 +-
 drivers/net/iavf/iavf_rxtx.c                  |  16 +--
 drivers/net/ice/ice_dcf_ethdev.c              |   4 +-
 drivers/net/ice/ice_dcf_vf_representor.c      |  14 +--
 drivers/net/ice/ice_ethdev.c                  |  50 ++++----
 drivers/net/ice/ice_fdir_filter.c             |   2 +-
 drivers/net/ice/ice_hash.c                    |   8 +-
 drivers/net/ice/ice_rxtx.c                    |  18 +--
 drivers/net/ipn3ke/ipn3ke_ethdev.c            |   4 +-
 drivers/net/ipn3ke/ipn3ke_flow.c              |  23 ++--
 drivers/net/ipn3ke/ipn3ke_representor.c       |  20 +--
 drivers/net/ipn3ke/ipn3ke_tm.c                |  10 +-
 drivers/net/ixgbe/ixgbe_ethdev.c              |   7 +-
 drivers/net/ixgbe/ixgbe_ipsec.c               |  24 ++--
 drivers/net/ixgbe/ixgbe_pf.c                  |  18 +--
 drivers/net/ixgbe/rte_pmd_ixgbe.c             |   8 +-
 drivers/net/memif/rte_eth_memif.c             |   2 +-
 drivers/net/mlx4/mlx4.c                       |   4 +-
 drivers/net/netvsc/hn_rxtx.c                  |   4 +-
 drivers/net/ngbe/base/ngbe_hw.c               |   2 +-
 drivers/net/ngbe/ngbe_ethdev.c                |   2 +-
 drivers/net/ngbe/ngbe_pf.c                    |  10 +-
 drivers/net/octeon_ep/cnxk_ep_tx.c            |   2 +-
 drivers/net/octeon_ep/cnxk_ep_vf.c            |  12 +-
 drivers/net/octeon_ep/otx2_ep_vf.c            |  18 +--
 drivers/net/octeon_ep/otx_ep_common.h         |   2 +-
 drivers/net/octeon_ep/otx_ep_ethdev.c         |  82 ++++++-------
 drivers/net/octeon_ep/otx_ep_mbox.c           |  30 ++---
 drivers/net/octeon_ep/otx_ep_rxtx.c           |  74 +++++------
 drivers/net/octeon_ep/otx_ep_vf.c             |  20 +--
 drivers/net/octeontx/base/octeontx_pkovf.c    |   2 +-
 drivers/net/octeontx/octeontx_ethdev.c        |   4 +-
 drivers/net/pcap/pcap_ethdev.c                |   4 +-
 drivers/net/pfe/pfe_ethdev.c                  |  22 ++--
 drivers/net/pfe/pfe_hif.c                     |  12 +-
 drivers/net/pfe/pfe_hif_lib.c                 |   2 +-
 drivers/net/qede/qede_rxtx.c                  |  66 +++++-----
 drivers/net/thunderx/nicvf_ethdev.c           |   2 +-
 drivers/net/txgbe/txgbe_ethdev.c              |   4 +-
 drivers/net/txgbe/txgbe_ipsec.c               |  24 ++--
 drivers/net/txgbe/txgbe_pf.c                  |  20 +--
 drivers/net/virtio/virtio_user/vhost_vdpa.c   |   2 +-
 .../net/virtio/virtio_user/virtio_user_dev.c  |   2 +-
 drivers/net/vmxnet3/vmxnet3_ethdev.c          |   4 +-
 drivers/net/vmxnet3/vmxnet3_rxtx.c            |   2 +-
 drivers/raw/dpaa2_cmdif/dpaa2_cmdif.c         |  14 +--
 drivers/raw/ifpga/afu_pmd_n3000.c             |   2 +-
 drivers/raw/ifpga/ifpga_rawdev.c              |  94 +++++++-------
 drivers/regex/cn9k/cn9k_regexdev.c            |   2 +-
 drivers/vdpa/ifc/ifcvf_vdpa.c                 |  10 +-
 drivers/vdpa/nfp/nfp_vdpa.c                   |   2 +-
 172 files changed, 1087 insertions(+), 1105 deletions(-)
drivers/baseband/acc/rte_acc100_pmd.c +10 -10
index ab69350080..5c91acab7e 100644
@@ -229,7 +229,7 @@ fetch_acc100_config(struct rte_bbdev *dev)
 	}
 
 	rte_bbdev_log_debug(
-			"%s Config LLR SIGN IN/OUT %s %s QG %u %u %u %u AQ %u %u %u %u Len %u %u %u %u\n",
+			"%s Config LLR SIGN IN/OUT %s %s QG %u %u %u %u AQ %u %u %u %u Len %u %u %u %u",
 			(d->pf_device) ? "PF" : "VF",
 			(acc_conf->input_pos_llr_1_bit) ? "POS" : "NEG",
 			(acc_conf->output_pos_llr_1_bit) ? "POS" : "NEG",
@@ -2672,7 +2672,7 @@ harq_loopback(struct acc_queue *q, struct rte_bbdev_dec_op *op,
 	uint32_t harq_index;
 
 	if (harq_in_length == 0) {
-		rte_bbdev_log(ERR, "Loopback of invalid null size\n");
+		rte_bbdev_log(ERR, "Loopback of invalid null size");
 		return -EINVAL;
 	}
 
@@ -2710,7 +2710,7 @@ harq_loopback(struct acc_queue *q, struct rte_bbdev_dec_op *op,
 	fcw->hcin_en = 1;
 	fcw->hcout_en = 1;
 
-	rte_bbdev_log(DEBUG, "Loopback IN %d Index %d offset %d length %d %d\n",
+	rte_bbdev_log(DEBUG, "Loopback IN %d Index %d offset %d length %d %d",
 			ddr_mem_in, harq_index,
 			harq_layout[harq_index].offset, harq_in_length,
 			harq_dma_length_in);
@@ -2726,7 +2726,7 @@ harq_loopback(struct acc_queue *q, struct rte_bbdev_dec_op *op,
 		fcw->hcin_size0 = harq_in_length;
 	}
 	harq_layout[harq_index].val = 0;
-	rte_bbdev_log(DEBUG, "Loopback FCW Config %d %d %d\n",
+	rte_bbdev_log(DEBUG, "Loopback FCW Config %d %d %d",
 			fcw->hcin_size0, fcw->hcin_offset, fcw->hcin_size1);
 	fcw->hcout_size0 = harq_in_length;
 	fcw->hcin_decomp_mode = h_comp;
@@ -3450,7 +3450,7 @@ acc100_enqueue_ldpc_dec_cb(struct rte_bbdev_queue_data *q_data,
 		}
 		avail -= 1;
 
-		rte_bbdev_log(INFO, "Op %d %d %d %d %d %d %d %d %d %d %d\n",
+		rte_bbdev_log(INFO, "Op %d %d %d %d %d %d %d %d %d %d %d",
 			i, ops[i]->ldpc_dec.op_flags, ops[i]->ldpc_dec.rv_index,
 			ops[i]->ldpc_dec.iter_max, ops[i]->ldpc_dec.iter_count,
 			ops[i]->ldpc_dec.basegraph, ops[i]->ldpc_dec.z_c,
@@ -3566,7 +3566,7 @@ dequeue_enc_one_op_cb(struct acc_queue *q, struct rte_bbdev_enc_op **ref_op,
 		return -1;
 
 	rsp.val = atom_desc.rsp.val;
-	rte_bbdev_log_debug("Resp. desc %p: %x num %d\n", desc, rsp.val, desc->req.numCBs);
+	rte_bbdev_log_debug("Resp. desc %p: %x num %d", desc, rsp.val, desc->req.numCBs);
 
 	/* Dequeue */
 	op = desc->req.op_addr;
@@ -3643,7 +3643,7 @@ dequeue_enc_one_op_tb(struct acc_queue *q, struct rte_bbdev_enc_op **ref_op,
 		atom_desc.atom_hdr = rte_atomic_load_explicit((uint64_t __rte_atomic *)desc,
 				rte_memory_order_relaxed);
 		rsp.val = atom_desc.rsp.val;
-		rte_bbdev_log_debug("Resp. desc %p: %x descs %d cbs %d\n",
+		rte_bbdev_log_debug("Resp. desc %p: %x descs %d cbs %d",
 				desc, rsp.val, descs_in_tb, desc->req.numCBs);
 
 		op->status |= ((rsp.dma_err) ? (1 << RTE_BBDEV_DRV_ERROR) : 0);
@@ -3739,7 +3739,7 @@ dequeue_ldpc_dec_one_op_cb(struct rte_bbdev_queue_data *q_data,
 		return -1;
 
 	rsp.val = atom_desc.rsp.val;
-	rte_bbdev_log_debug("Resp. desc %p: %x\n", desc, rsp.val);
+	rte_bbdev_log_debug("Resp. desc %p: %x", desc, rsp.val);
 
 	/* Dequeue */
 	op = desc->req.op_addr;
@@ -3818,7 +3818,7 @@ dequeue_dec_one_op_tb(struct acc_queue *q, struct rte_bbdev_dec_op **ref_op,
 		atom_desc.atom_hdr = rte_atomic_load_explicit((uint64_t __rte_atomic *)desc,
 				rte_memory_order_relaxed);
 		rsp.val = atom_desc.rsp.val;
-		rte_bbdev_log_debug("Resp. desc %p: %x r %d c %d\n",
+		rte_bbdev_log_debug("Resp. desc %p: %x r %d c %d",
 						desc, rsp.val, cb_idx, cbs_in_tb);
 
 		op->status |= ((rsp.input_err) ? (1 << RTE_BBDEV_DATA_ERROR) : 0);
@@ -4552,7 +4552,7 @@ acc100_configure(const char *dev_name, struct rte_acc_conf *conf)
 	}
 
 	if (aram_address > ACC100_WORDS_IN_ARAM_SIZE) {
-		rte_bbdev_log(ERR, "ARAM Configuration not fitting %d %d\n",
+		rte_bbdev_log(ERR, "ARAM Configuration not fitting %d %d",
 				aram_address, ACC100_WORDS_IN_ARAM_SIZE);
 		return -EINVAL;
 	}
drivers/baseband/acc/rte_vrb_pmd.c +13 -13
index 585dc49bd6..fad984ccc1 100644
@@ -348,7 +348,7 @@ fetch_acc_config(struct rte_bbdev *dev)
 	}
 
 	rte_bbdev_log_debug(
-			"%s Config LLR SIGN IN/OUT %s %s QG %u %u %u %u %u %u AQ %u %u %u %u %u %u Len %u %u %u %u %u %u\n",
+			"%s Config LLR SIGN IN/OUT %s %s QG %u %u %u %u %u %u AQ %u %u %u %u %u %u Len %u %u %u %u %u %u",
 			(d->pf_device) ? "PF" : "VF",
 			(acc_conf->input_pos_llr_1_bit) ? "POS" : "NEG",
 			(acc_conf->output_pos_llr_1_bit) ? "POS" : "NEG",
@@ -464,7 +464,7 @@ vrb_dev_interrupt_handler(void *cb_arg)
 			}
 		} else {
 			rte_bbdev_log_debug(
-					"VRB VF Interrupt received, Info Ring data: 0x%x\n",
+					"VRB VF Interrupt received, Info Ring data: 0x%x",
 					ring_data->val);
 			switch (int_nb) {
 			case ACC_VF_INT_DMA_DL_DESC_IRQ:
@@ -698,7 +698,7 @@ vrb_intr_enable(struct rte_bbdev *dev)
 
 	if (d->device_variant == VRB1_VARIANT) {
 		/* On VRB1: cannot enable MSI/IR to avoid potential back-pressure corner case. */
-		rte_bbdev_log(ERR, "VRB1 (%s) doesn't support any MSI/MSI-X interrupt\n",
+		rte_bbdev_log(ERR, "VRB1 (%s) doesn't support any MSI/MSI-X interrupt",
 				dev->data->name);
 		return -ENOTSUP;
 	}
@@ -800,7 +800,7 @@ vrb_intr_enable(struct rte_bbdev *dev)
 		return 0;
 	}
 
-	rte_bbdev_log(ERR, "Device (%s) supports only VFIO MSI/MSI-X interrupts\n",
+	rte_bbdev_log(ERR, "Device (%s) supports only VFIO MSI/MSI-X interrupts",
 			dev->data->name);
 	return -ENOTSUP;
 }
@@ -1023,7 +1023,7 @@ vrb_queue_setup(struct rte_bbdev *dev, uint16_t queue_id,
 			d->queue_offset(d->pf_device, q->vf_id, q->qgrp_id, q->aq_id));
 
 	rte_bbdev_log_debug(
-			"Setup dev%u q%u: qgrp_id=%u, vf_id=%u, aq_id=%u, aq_depth=%u, mmio_reg_enqueue=%p base %p\n",
+			"Setup dev%u q%u: qgrp_id=%u, vf_id=%u, aq_id=%u, aq_depth=%u, mmio_reg_enqueue=%p base %p",
 			dev->data->dev_id, queue_id, q->qgrp_id, q->vf_id,
 			q->aq_id, q->aq_depth, q->mmio_reg_enqueue,
 			d->mmio_base);
@@ -1076,7 +1076,7 @@ vrb_print_op(struct rte_bbdev_dec_op *op, enum rte_bbdev_op_type op_type,
 			);
 	} else if (op_type == RTE_BBDEV_OP_MLDTS) {
 		struct rte_bbdev_mldts_op *op_mldts = (struct rte_bbdev_mldts_op *) op;
-		rte_bbdev_log(INFO, "  Op MLD %d RBs %d NL %d Rp %d %d %x\n",
+		rte_bbdev_log(INFO, "  Op MLD %d RBs %d NL %d Rp %d %d %x",
 				index,
 				op_mldts->mldts.num_rbs, op_mldts->mldts.num_layers,
 				op_mldts->mldts.r_rep,
@@ -2492,7 +2492,7 @@ vrb_enqueue_ldpc_dec_one_op_cb(struct acc_queue *q, struct rte_bbdev_dec_op *op,
 		hq_output = op->ldpc_dec.harq_combined_output.data;
 		hq_len = op->ldpc_dec.harq_combined_output.length;
 		if (unlikely(!mbuf_append(hq_output_head, hq_output, hq_len))) {
-			rte_bbdev_log(ERR, "HARQ output mbuf issue %d %d\n",
+			rte_bbdev_log(ERR, "HARQ output mbuf issue %d %d",
 					hq_output->buf_len,
 					hq_len);
 			return -1;
@@ -2985,7 +2985,7 @@ vrb_enqueue_ldpc_dec_cb(struct rte_bbdev_queue_data *q_data,
 			break;
 		}
 		avail -= 1;
-		rte_bbdev_log(INFO, "Op %d %d %d %d %d %d %d %d %d %d %d %d\n",
+		rte_bbdev_log(INFO, "Op %d %d %d %d %d %d %d %d %d %d %d %d",
 			i, ops[i]->ldpc_dec.op_flags, ops[i]->ldpc_dec.rv_index,
 			ops[i]->ldpc_dec.iter_max, ops[i]->ldpc_dec.iter_count,
 			ops[i]->ldpc_dec.basegraph, ops[i]->ldpc_dec.z_c,
@@ -3304,7 +3304,7 @@ vrb_dequeue_ldpc_dec_one_op_cb(struct rte_bbdev_queue_data *q_data,
 		return -1;
 
 	rsp.val = atom_desc.rsp.val;
-	rte_bbdev_log_debug("Resp. desc %p: %x %x %x\n", desc, rsp.val, desc->rsp.add_info_0,
+	rte_bbdev_log_debug("Resp. desc %p: %x %x %x", desc, rsp.val, desc->rsp.add_info_0,
 			desc->rsp.add_info_1);
 
 	/* Dequeue. */
@@ -3411,7 +3411,7 @@ vrb_dequeue_dec_one_op_tb(struct acc_queue *q, struct rte_bbdev_dec_op **ref_op,
 	}
 
 	if (check_bit(op->ldpc_dec.op_flags, RTE_BBDEV_LDPC_CRC_TYPE_24A_CHECK)) {
-		rte_bbdev_log_debug("TB-CRC Check %x\n", tb_crc_check);
+		rte_bbdev_log_debug("TB-CRC Check %x", tb_crc_check);
 		if (tb_crc_check > 0)
 			op->status |= 1 << RTE_BBDEV_CRC_ERROR;
 	}
@@ -3946,7 +3946,7 @@ vrb2_check_mld_r_constraint(struct rte_bbdev_mldts_op *op) {
 	layer_idx = RTE_MIN(op->mldts.num_layers - VRB2_MLD_MIN_LAYER,
 			VRB2_MLD_MAX_LAYER - VRB2_MLD_MIN_LAYER);
 	rrep_idx = RTE_MIN(op->mldts.r_rep, VRB2_MLD_MAX_RREP);
-	rte_bbdev_log_debug("RB %d index %d %d max %d\n", op->mldts.num_rbs, layer_idx, rrep_idx,
+	rte_bbdev_log_debug("RB %d index %d %d max %d", op->mldts.num_rbs, layer_idx, rrep_idx,
 			max_rb[layer_idx][rrep_idx]);
 
 	return (op->mldts.num_rbs <= max_rb[layer_idx][rrep_idx]);
@@ -4606,7 +4606,7 @@ vrb1_configure(const char *dev_name, struct rte_acc_conf *conf)
 	}
 
 	if (aram_address > VRB1_WORDS_IN_ARAM_SIZE) {
-		rte_bbdev_log(ERR, "ARAM Configuration not fitting %d %d\n",
+		rte_bbdev_log(ERR, "ARAM Configuration not fitting %d %d",
 				aram_address, VRB1_WORDS_IN_ARAM_SIZE);
 		return -EINVAL;
 	}
@@ -4976,7 +4976,7 @@ vrb2_configure(const char *dev_name, struct rte_acc_conf *conf)
 			}
 		}
 		if (aram_address > VRB2_WORDS_IN_ARAM_SIZE) {
-			rte_bbdev_log(ERR, "ARAM Configuration not fitting %d %d\n",
+			rte_bbdev_log(ERR, "ARAM Configuration not fitting %d %d",
 					aram_address, VRB2_WORDS_IN_ARAM_SIZE);
 			return -EINVAL;
 		}
drivers/baseband/fpga_5gnr_fec/rte_fpga_5gnr_fec.c +8 -8
index 9b253cde28..3e04e44ba2 100644
@@ -1997,10 +1997,10 @@ fpga_5gnr_mutex_acquisition(struct fpga_5gnr_queue *q)
 	do {
 		if (cnt > 0)
 			usleep(FPGA_5GNR_TIMEOUT_CHECK_INTERVAL);
-		rte_bbdev_log_debug("Acquiring Mutex for %x\n", q->ddr_mutex_uuid);
+		rte_bbdev_log_debug("Acquiring Mutex for %x", q->ddr_mutex_uuid);
 		fpga_5gnr_reg_write_32(q->d->mmio_base, FPGA_5GNR_FEC_MUTEX, mutex_ctrl);
 		mutex_read = fpga_5gnr_reg_read_32(q->d->mmio_base, FPGA_5GNR_FEC_MUTEX);
-		rte_bbdev_log_debug("Mutex %x cnt %d owner %x\n",
+		rte_bbdev_log_debug("Mutex %x cnt %d owner %x",
 				mutex_read, cnt, q->ddr_mutex_uuid);
 		cnt++;
 	} while ((mutex_read >> 16) != q->ddr_mutex_uuid);
@@ -2038,7 +2038,7 @@ fpga_5gnr_harq_write_loopback(struct fpga_5gnr_queue *q,
 		reg_32 = fpga_5gnr_reg_read_32(q->d->mmio_base, FPGA_5GNR_FEC_HARQ_BUF_SIZE_REGS);
 		if (reg_32 < harq_in_length) {
 			left_length = reg_32;
-			rte_bbdev_log(ERR, "HARQ in length > HARQ buffer size\n");
+			rte_bbdev_log(ERR, "HARQ in length > HARQ buffer size");
 		}
 	}
 
@@ -2108,17 +2108,17 @@ fpga_5gnr_harq_read_loopback(struct fpga_5gnr_queue *q,
 		reg = fpga_5gnr_reg_read_32(q->d->mmio_base, FPGA_5GNR_FEC_HARQ_BUF_SIZE_REGS);
 		if (reg < harq_in_length) {
 			harq_in_length = reg;
-			rte_bbdev_log(ERR, "HARQ in length > HARQ buffer size\n");
+			rte_bbdev_log(ERR, "HARQ in length > HARQ buffer size");
 		}
 	}
 
 	if (!mbuf_append(harq_output, harq_output, harq_in_length)) {
-		rte_bbdev_log(ERR, "HARQ output buffer warning %d %d\n",
+		rte_bbdev_log(ERR, "HARQ output buffer warning %d %d",
 				harq_output->buf_len - rte_pktmbuf_headroom(harq_output),
 				harq_in_length);
 		harq_in_length = harq_output->buf_len - rte_pktmbuf_headroom(harq_output);
 		if (!mbuf_append(harq_output, harq_output, harq_in_length)) {
-			rte_bbdev_log(ERR, "HARQ output buffer issue %d %d\n",
+			rte_bbdev_log(ERR, "HARQ output buffer issue %d %d",
 					harq_output->buf_len, harq_in_length);
 			return -1;
 		}
@@ -2142,7 +2142,7 @@ fpga_5gnr_harq_read_loopback(struct fpga_5gnr_queue *q,
 		while (reg != 1) {
 			reg = fpga_5gnr_reg_read_8(q->d->mmio_base, FPGA_5GNR_FEC_DDR4_RD_RDY_REGS);
 			if (reg == FPGA_5GNR_DDR_OVERFLOW) {
-				rte_bbdev_log(ERR, "Read address is overflow!\n");
+				rte_bbdev_log(ERR, "Read address is overflow!");
 				return -1;
 			}
 		}
@@ -3376,7 +3376,7 @@ int rte_fpga_5gnr_fec_configure(const char *dev_name, const struct rte_fpga_5gnr
 		return -ENODEV;
 	}
 	struct rte_pci_device *pci_dev = RTE_DEV_TO_PCI(bbdev->device);
-	rte_bbdev_log(INFO, "Configure dev id %x\n", pci_dev->id.device_id);
+	rte_bbdev_log(INFO, "Configure dev id %x", pci_dev->id.device_id);
 	if (pci_dev->id.device_id == VC_5GNR_PF_DEVICE_ID)
 		return vc_5gnr_configure(dev_name, conf);
 	else if (pci_dev->id.device_id == AGX100_PF_DEVICE_ID)
drivers/baseband/la12xx/bbdev_la12xx.c +2 -2
index 1a56e73abd..af4b4f1e9a 100644
@@ -201,7 +201,7 @@ la12xx_e200_queue_setup(struct rte_bbdev *dev,
 		q_priv->la12xx_core_id = LA12XX_LDPC_DEC_CORE;
 		break;
 	default:
-		rte_bbdev_log(ERR, "Unsupported op type\n");
+		rte_bbdev_log(ERR, "Unsupported op type");
 		return -1;
 	}
 
@@ -269,7 +269,7 @@ la12xx_e200_queue_setup(struct rte_bbdev *dev,
 		ch->feca_blk_id = rte_cpu_to_be_32(priv->num_ldpc_dec_queues++);
 		break;
 	default:
-		rte_bbdev_log(ERR, "Not supported op type\n");
+		rte_bbdev_log(ERR, "Not supported op type");
 		return -1;
 	}
 	ch->op_type = rte_cpu_to_be_32(q_priv->op_type);
drivers/baseband/turbo_sw/bbdev_turbo_software.c +2 -2
index 574743a9da..1f661dd801 100644
@@ -269,7 +269,7 @@ info_get(struct rte_bbdev *dev, struct rte_bbdev_driver_info *dev_info)
 			dev_info->num_queues[op_cap->type] = num_queue_per_type;
 	}
 
-	rte_bbdev_log_debug("got device info from %u\n", dev->data->dev_id);
+	rte_bbdev_log_debug("got device info from %u", dev->data->dev_id);
 }
 
 /* Release queue */
@@ -1951,7 +1951,7 @@ turbo_sw_bbdev_probe(struct rte_vdev_device *vdev)
 	parse_turbo_sw_params(&init_params, input_args);
 
 	rte_bbdev_log_debug(
-			"Initialising %s on NUMA node %d with max queues: %d\n",
+			"Initialising %s on NUMA node %d with max queues: %d",
 			name, init_params.socket_id, init_params.queues_num);
 
 	return turbo_sw_bbdev_create(vdev, &init_params);
drivers/bus/cdx/cdx_vfio.c +4 -4
index 79abc3f120..664f267471 100644
@@ -638,7 +638,7 @@ rte_cdx_vfio_bm_enable(struct rte_cdx_device *dev)
 	feature->flags |= VFIO_DEVICE_FEATURE_SET;
 	ret = ioctl(vfio_dev_fd, RTE_VFIO_DEVICE_FEATURE, feature);
 	if (ret) {
-		CDX_BUS_ERR("Bus Master configuring not supported for device: %s, error: %d (%s)\n",
+		CDX_BUS_ERR("Bus Master configuring not supported for device: %s, error: %d (%s)",
 			dev->name, errno, strerror(errno));
 		free(feature);
 		return ret;
@@ -648,7 +648,7 @@ rte_cdx_vfio_bm_enable(struct rte_cdx_device *dev)
 	vfio_bm_feature->op = VFIO_DEVICE_FEATURE_SET_MASTER;
 	ret = ioctl(vfio_dev_fd, RTE_VFIO_DEVICE_FEATURE, feature);
 	if (ret < 0)
-		CDX_BUS_ERR("BM Enable Error for device: %s, Error: %d (%s)\n",
+		CDX_BUS_ERR("BM Enable Error for device: %s, Error: %d (%s)",
 			dev->name, errno, strerror(errno));
 
 	free(feature);
@@ -682,7 +682,7 @@ rte_cdx_vfio_bm_disable(struct rte_cdx_device *dev)
 	feature->flags |= VFIO_DEVICE_FEATURE_SET;
 	ret = ioctl(vfio_dev_fd, RTE_VFIO_DEVICE_FEATURE, feature);
 	if (ret) {
-		CDX_BUS_ERR("Bus Master configuring not supported for device: %s, Error: %d (%s)\n",
+		CDX_BUS_ERR("Bus Master configuring not supported for device: %s, Error: %d (%s)",
 			dev->name, errno, strerror(errno));
 		free(feature);
 		return ret;
@@ -692,7 +692,7 @@ rte_cdx_vfio_bm_disable(struct rte_cdx_device *dev)
 	vfio_bm_feature->op = VFIO_DEVICE_FEATURE_CLEAR_MASTER;
 	ret = ioctl(vfio_dev_fd, RTE_VFIO_DEVICE_FEATURE, feature);
 	if (ret < 0)
-		CDX_BUS_ERR("BM Disable Error for device: %s, Error: %d (%s)\n",
+		CDX_BUS_ERR("BM Disable Error for device: %s, Error: %d (%s)",
 			dev->name, errno, strerror(errno));
 
 	free(feature);
drivers/bus/dpaa/include/fman.h +2 -1
index 3a6dd555a7..19f6132bba 100644
@@ -403,7 +403,8 @@ extern int fman_ccsr_map_fd;
 #define FMAN_ERR(rc, fmt, args...) \
 	do { \
 		_errno = (rc); \
-		DPAA_BUS_LOG(ERR, fmt "(%d)", ##args, errno); \
+		rte_log(RTE_LOG_ERR, dpaa_logtype_bus, "dpaa: " fmt "(%d)\n", \
+			##args, errno); \
 	} while (0)
 
 #define FMAN_IP_REV_1	0xC30C4
drivers/bus/fslmc/fslmc_bus.c +4 -4
index c155f4a2fd..097d6dca08 100644
@@ -500,7 +500,7 @@ rte_fslmc_find_device(const struct rte_device *start, rte_dev_cmp_t cmp,
 	const struct rte_dpaa2_device *dstart;
 	struct rte_dpaa2_device *dev;
 
-	DPAA2_BUS_DEBUG("Finding a device named %s\n", (const char *)data);
+	DPAA2_BUS_DEBUG("Finding a device named %s", (const char *)data);
 
 	/* find_device is always called with an opaque object which should be
 	 * passed along to the 'cmp' function iterating over all device obj
@@ -515,7 +515,7 @@ rte_fslmc_find_device(const struct rte_device *start, rte_dev_cmp_t cmp,
 	}
 	while (dev != NULL) {
 		if (cmp(&dev->device, data) == 0) {
-			DPAA2_BUS_DEBUG("Found device (%s)\n",
+			DPAA2_BUS_DEBUG("Found device (%s)",
 					dev->device.name);
 			return &dev->device;
 		}
@@ -629,14 +629,14 @@ fslmc_bus_dev_iterate(const void *start, const char *str,
 
 	/* Expectation is that device would be name=device_name */
 	if (strncmp(str, "name=", 5) != 0) {
-		DPAA2_BUS_DEBUG("Invalid device string (%s)\n", str);
+		DPAA2_BUS_DEBUG("Invalid device string (%s)", str);
 		return NULL;
 	}
 
 	/* Now that name=device_name format is available, split */
 	dup = strdup(str);
 	if (dup == NULL) {
-		DPAA2_BUS_DEBUG("Dup string (%s) failed!\n", str);
+		DPAA2_BUS_DEBUG("Dup string (%s) failed!", str);
 		return NULL;
 	}
 	dev_name = dup + strlen("name=");
drivers/bus/fslmc/fslmc_vfio.c +5 -5
index e12fd62f34..6981679a2d 100644
@@ -232,7 +232,7 @@ fslmc_memevent_cb(enum rte_mem_event type, const void *addr, size_t len,
 
 		/* iova_addr may be set to RTE_BAD_IOVA */
 		if (iova_addr == RTE_BAD_IOVA) {
-			DPAA2_BUS_DEBUG("Segment has invalid iova, skipping\n");
+			DPAA2_BUS_DEBUG("Segment has invalid iova, skipping");
 			cur_len += map_len;
 			continue;
 		}
@@ -389,7 +389,7 @@ rte_fslmc_vfio_mem_dmamap(uint64_t vaddr, uint64_t iova, uint64_t size)
 	dma_map.vaddr = vaddr;
 	dma_map.iova = iova;
 
-	DPAA2_BUS_DEBUG("VFIOdmamap 0x%"PRIx64":0x%"PRIx64",size 0x%"PRIx64"\n",
+	DPAA2_BUS_DEBUG("VFIOdmamap 0x%"PRIx64":0x%"PRIx64",size 0x%"PRIx64,
 			(uint64_t)dma_map.vaddr, (uint64_t)dma_map.iova,
 			(uint64_t)dma_map.size);
 	ret = ioctl(group->container->fd, VFIO_IOMMU_MAP_DMA,
@@ -480,13 +480,13 @@ fslmc_vfio_setup_device(const char *sysfs_base, const char *dev_addr,
 	ret = ioctl(vfio_group_fd, VFIO_GROUP_GET_STATUS, &group_status);
 	if (ret) {
 		DPAA2_BUS_ERR("  %s cannot get group status, "
-				"error %i (%s)\n", dev_addr,
+				"error %i (%s)", dev_addr,
 				errno, strerror(errno));
 		close(vfio_group_fd);
 		rte_vfio_clear_group(vfio_group_fd);
 		return -1;
 	} else if (!(group_status.flags & VFIO_GROUP_FLAGS_VIABLE)) {
-		DPAA2_BUS_ERR("  %s VFIO group is not viable!\n", dev_addr);
+		DPAA2_BUS_ERR("  %s VFIO group is not viable!", dev_addr);
 		close(vfio_group_fd);
 		rte_vfio_clear_group(vfio_group_fd);
 		return -1;
@@ -503,7 +503,7 @@ fslmc_vfio_setup_device(const char *sysfs_base, const char *dev_addr,
 				&vfio_container_fd);
 		if (ret) {
 			DPAA2_BUS_ERR("  %s cannot add VFIO group to container, "
-					"error %i (%s)\n", dev_addr,
+					"error %i (%s)", dev_addr,
 					errno, strerror(errno));
 			close(vfio_group_fd);
 			close(vfio_container_fd);
drivers/bus/fslmc/portal/dpaa2_hw_dpci.c +2 -2
index 07256ed7ec..7e858a113f 100644
@@ -86,7 +86,7 @@ rte_dpaa2_create_dpci_device(int vdev_fd __rte_unused,
 					sizeof(struct queue_storage_info_t),
 					RTE_CACHE_LINE_SIZE);
 		if (!rxq->q_storage) {
-			DPAA2_BUS_ERR("q_storage allocation failed\n");
+			DPAA2_BUS_ERR("q_storage allocation failed");
 			ret = -ENOMEM;
 			goto err;
 		}
@@ -94,7 +94,7 @@ rte_dpaa2_create_dpci_device(int vdev_fd __rte_unused,
 		memset(rxq->q_storage, 0, sizeof(struct queue_storage_info_t));
 		ret = dpaa2_alloc_dq_storage(rxq->q_storage);
 		if (ret) {
-			DPAA2_BUS_ERR("dpaa2_alloc_dq_storage failed\n");
+			DPAA2_BUS_ERR("dpaa2_alloc_dq_storage failed");
 			goto err;
 		}
 	}
drivers/bus/ifpga/ifpga_bus.c +4 -4
index ffb0c61214..11b31eee4f 100644
@@ -180,7 +180,7 @@ ifpga_scan_one(struct rte_rawdev *rawdev,
 		rawdev->dev_ops->firmware_load &&
 		rawdev->dev_ops->firmware_load(rawdev,
 				&afu_pr_conf)){
-		IFPGA_BUS_ERR("firmware load error %d\n", ret);
+		IFPGA_BUS_ERR("firmware load error %d", ret);
 		goto end;
 	}
 	afu_dev->id.uuid.uuid_low  = afu_pr_conf.afu_id.uuid.uuid_low;
@@ -316,7 +316,7 @@ ifpga_probe_all_drivers(struct rte_afu_device *afu_dev)
 
 	/* Check if a driver is already loaded */
 	if (rte_dev_is_probed(&afu_dev->device)) {
-		IFPGA_BUS_DEBUG("Device %s is already probed\n",
+		IFPGA_BUS_DEBUG("Device %s is already probed",
 				rte_ifpga_device_name(afu_dev));
 		return -EEXIST;
 	}
@@ -353,7 +353,7 @@ ifpga_probe(void)
 		if (ret == -EEXIST)
 			continue;
 		if (ret < 0)
-			IFPGA_BUS_ERR("failed to initialize %s device\n",
+			IFPGA_BUS_ERR("failed to initialize %s device",
 				rte_ifpga_device_name(afu_dev));
 	}
 
@@ -408,7 +408,7 @@ ifpga_remove_driver(struct rte_afu_device *afu_dev)
 
 	name = rte_ifpga_device_name(afu_dev);
 	if (afu_dev->driver == NULL) {
-		IFPGA_BUS_DEBUG("no driver attach to device %s\n", name);
+		IFPGA_BUS_DEBUG("no driver attach to device %s", name);
 		return 1;
 	}
 
drivers/bus/vdev/vdev_params.c +1 -1
index 51583fe949..68ae09e2e9 100644
@@ -53,7 +53,7 @@ rte_vdev_dev_iterate(const void *start,
 	if (str != NULL) {
 		kvargs = rte_kvargs_parse(str, vdev_params_keys);
 		if (kvargs == NULL) {
-			VDEV_LOG(ERR, "cannot parse argument list\n");
+			VDEV_LOG(ERR, "cannot parse argument list");
 			rte_errno = EINVAL;
 			return NULL;
 		}
drivers/bus/vmbus/vmbus_common.c +1 -1
index b9139c6e6c..8a965d10d9 100644
@@ -108,7 +108,7 @@ vmbus_probe_one_driver(struct rte_vmbus_driver *dr,
 	/* no initialization when marked as blocked, return without error */
 	if (dev->device.devargs != NULL &&
 		dev->device.devargs->policy == RTE_DEV_BLOCKED) {
-		VMBUS_LOG(INFO, "  Device is blocked, not initializing\n");
+		VMBUS_LOG(INFO, "  Device is blocked, not initializing");
 		return 1;
 	}
 
drivers/common/cnxk/roc_dev.c +1 -1
index daf7684d8e..438ac72563 100644
@@ -1564,7 +1564,7 @@ dev_init(struct dev *dev, struct plt_pci_device *pci_dev)
 		rc = plt_thread_create_control(&dev->sync.pfvf_msg_thread, name,
 				pf_vf_mbox_thread_main, dev);
 		if (rc != 0) {
-			plt_err("Failed to create thread for VF mbox handling\n");
+			plt_err("Failed to create thread for VF mbox handling");
 			goto thread_fail;
 		}
 	}
drivers/common/cnxk/roc_model.c +1 -1
index 6dc2afe7f0..446ab3d2bd 100644
@@ -153,7 +153,7 @@ cn10k_part_pass_get(uint32_t *part, uint32_t *pass)
 
 	dir = opendir(SYSFS_PCI_DEVICES);
 	if (dir == NULL) {
-		plt_err("%s(): opendir failed: %s\n", __func__,
+		plt_err("%s(): opendir failed: %s", __func__,
 			strerror(errno));
 		return -errno;
 	}
drivers/common/cnxk/roc_nix_ops.c +10 -10
index 9e66ad1a49..efb0a41d07 100644
@@ -220,7 +220,7 @@ roc_nix_lso_fmt_setup(struct roc_nix *roc_nix)
 		goto exit;
 	}
 
-	plt_nix_dbg("tcpv4 lso fmt=%u\n", rsp->lso_format_idx);
+	plt_nix_dbg("tcpv4 lso fmt=%u", rsp->lso_format_idx);
 
 	/*
 	 * IPv6/TCP LSO
@@ -240,7 +240,7 @@ roc_nix_lso_fmt_setup(struct roc_nix *roc_nix)
 		goto exit;
 	}
 
-	plt_nix_dbg("tcpv6 lso fmt=%u\n", rsp->lso_format_idx);
+	plt_nix_dbg("tcpv6 lso fmt=%u", rsp->lso_format_idx);
 
 	/*
 	 * IPv4/UDP/TUN HDR/IPv4/TCP LSO
@@ -256,7 +256,7 @@ roc_nix_lso_fmt_setup(struct roc_nix *roc_nix)
 		goto exit;
 
 	nix->lso_udp_tun_idx[ROC_NIX_LSO_TUN_V4V4] = rsp->lso_format_idx;
-	plt_nix_dbg("udp tun v4v4 fmt=%u\n", rsp->lso_format_idx);
+	plt_nix_dbg("udp tun v4v4 fmt=%u", rsp->lso_format_idx);
 
 	/*
 	 * IPv4/UDP/TUN HDR/IPv6/TCP LSO
@@ -272,7 +272,7 @@ roc_nix_lso_fmt_setup(struct roc_nix *roc_nix)
 		goto exit;
 
 	nix->lso_udp_tun_idx[ROC_NIX_LSO_TUN_V4V6] = rsp->lso_format_idx;
-	plt_nix_dbg("udp tun v4v6 fmt=%u\n", rsp->lso_format_idx);
+	plt_nix_dbg("udp tun v4v6 fmt=%u", rsp->lso_format_idx);
 
 	/*
 	 * IPv6/UDP/TUN HDR/IPv4/TCP LSO
@@ -288,7 +288,7 @@ roc_nix_lso_fmt_setup(struct roc_nix *roc_nix)
 		goto exit;
 
 	nix->lso_udp_tun_idx[ROC_NIX_LSO_TUN_V6V4] = rsp->lso_format_idx;
-	plt_nix_dbg("udp tun v6v4 fmt=%u\n", rsp->lso_format_idx);
+	plt_nix_dbg("udp tun v6v4 fmt=%u", rsp->lso_format_idx);
 
 	/*
 	 * IPv6/UDP/TUN HDR/IPv6/TCP LSO
@@ -304,7 +304,7 @@ roc_nix_lso_fmt_setup(struct roc_nix *roc_nix)
 		goto exit;
 
 	nix->lso_udp_tun_idx[ROC_NIX_LSO_TUN_V6V6] = rsp->lso_format_idx;
-	plt_nix_dbg("udp tun v6v6 fmt=%u\n", rsp->lso_format_idx);
+	plt_nix_dbg("udp tun v6v6 fmt=%u", rsp->lso_format_idx);
 
 	/*
 	 * IPv4/TUN HDR/IPv4/TCP LSO
@@ -320,7 +320,7 @@ roc_nix_lso_fmt_setup(struct roc_nix *roc_nix)
 		goto exit;
 
 	nix->lso_tun_idx[ROC_NIX_LSO_TUN_V4V4] = rsp->lso_format_idx;
-	plt_nix_dbg("tun v4v4 fmt=%u\n", rsp->lso_format_idx);
+	plt_nix_dbg("tun v4v4 fmt=%u", rsp->lso_format_idx);
 
 	/*
 	 * IPv4/TUN HDR/IPv6/TCP LSO
@@ -336,7 +336,7 @@ roc_nix_lso_fmt_setup(struct roc_nix *roc_nix)
 		goto exit;
 
 	nix->lso_tun_idx[ROC_NIX_LSO_TUN_V4V6] = rsp->lso_format_idx;
-	plt_nix_dbg("tun v4v6 fmt=%u\n", rsp->lso_format_idx);
+	plt_nix_dbg("tun v4v6 fmt=%u", rsp->lso_format_idx);
 
 	/*
 	 * IPv6/TUN HDR/IPv4/TCP LSO
@@ -352,7 +352,7 @@ roc_nix_lso_fmt_setup(struct roc_nix *roc_nix)
 		goto exit;
 
 	nix->lso_tun_idx[ROC_NIX_LSO_TUN_V6V4] = rsp->lso_format_idx;
-	plt_nix_dbg("tun v6v4 fmt=%u\n", rsp->lso_format_idx);
+	plt_nix_dbg("tun v6v4 fmt=%u", rsp->lso_format_idx);
 
 	/*
 	 * IPv6/TUN HDR/IPv6/TCP LSO
@@ -369,7 +369,7 @@ roc_nix_lso_fmt_setup(struct roc_nix *roc_nix)
 		goto exit;
 
 	nix->lso_tun_idx[ROC_NIX_LSO_TUN_V6V6] = rsp->lso_format_idx;
-	plt_nix_dbg("tun v6v6 fmt=%u\n", rsp->lso_format_idx);
+	plt_nix_dbg("tun v6v6 fmt=%u", rsp->lso_format_idx);
 	rc = 0;
 exit:
 	mbox_put(mbox);
drivers/common/cnxk/roc_nix_tm.c +1 -1
index ac522f8235..d890fad681 100644
@@ -908,7 +908,7 @@ nix_tm_sq_flush_pre(struct roc_nix_sq *sq)
 			if (rc) {
 				roc_nix_tm_dump(sq->roc_nix, NULL);
 				roc_nix_queues_ctx_dump(sq->roc_nix, NULL);
-				plt_err("Failed to drain sq %u, rc=%d\n", sq->qid, rc);
+				plt_err("Failed to drain sq %u, rc=%d", sq->qid, rc);
 				return rc;
 			}
 			/* Freed all pending SQEs for this SQ, so disable this node */
drivers/common/cnxk/roc_nix_tm_mark.c +1 -1
index e9a7604e79..092d0851b9 100644
@@ -266,7 +266,7 @@ nix_tm_mark_init(struct nix *nix)
 			}
 
 			nix->tm_markfmt[i][j] = rsp->mark_format_idx;
-			plt_tm_dbg("Mark type: %u, Mark Color:%u, id:%u\n", i,
+			plt_tm_dbg("Mark type: %u, Mark Color:%u, id:%u", i,
 				   j, nix->tm_markfmt[i][j]);
 		}
 	}
drivers/common/cnxk/roc_nix_tm_ops.c +1 -1
index 9f3870a311..e24826bb5d 100644
@@ -504,7 +504,7 @@ roc_nix_tm_hierarchy_disable(struct roc_nix *roc_nix)
 		/* Wait for sq entries to be flushed */
 		rc = roc_nix_tm_sq_flush_spin(sq);
 		if (rc) {
-			plt_err("Failed to drain sq, rc=%d\n", rc);
+			plt_err("Failed to drain sq, rc=%d", rc);
 			goto cleanup;
 		}
 	}
drivers/common/cnxk/roc_nix_tm_utils.c +1 -1
index 8e3da95a45..4a09cc2aae 100644
@@ -583,7 +583,7 @@ nix_tm_topology_reg_prep(struct nix *nix, struct nix_tm_node *node,
 		/* Configure TL4 to send to SDP channel instead of CGX/LBK */
 		if (nix->sdp_link) {
 			relchan = nix->tx_chan_base & 0xff;
-			plt_tm_dbg("relchan=%u schq=%u tx_chan_cnt=%u\n", relchan, schq,
+			plt_tm_dbg("relchan=%u schq=%u tx_chan_cnt=%u", relchan, schq,
 				   nix->tx_chan_cnt);
 			reg[k] = NIX_AF_TL4X_SDP_LINK_CFG(schq);
 			regval[k] = BIT_ULL(12);
drivers/common/cnxk/roc_sso.c +1 -1
index 293b0c81a1..499f93e373 100644
@@ -186,7 +186,7 @@ sso_rsrc_get(struct roc_sso *roc_sso)
 	mbox_alloc_msg_free_rsrc_cnt(mbox);
 	rc = mbox_process_msg(mbox, (void **)&rsrc_cnt);
 	if (rc) {
-		plt_err("Failed to get free resource count\n");
+		plt_err("Failed to get free resource count");
 		rc = -EIO;
 		goto exit;
 	}
drivers/common/cnxk/roc_tim.c +1 -1
index 095afbb9e6..83228fb2b6 100644
@@ -342,7 +342,7 @@ tim_free_lf_count_get(struct dev *dev, uint16_t *nb_lfs)
 	mbox_alloc_msg_free_rsrc_cnt(mbox);
 	rc = mbox_process_msg(mbox, (void **)&rsrc_cnt);
 	if (rc) {
-		plt_err("Failed to get free resource count\n");
+		plt_err("Failed to get free resource count");
 		mbox_put(mbox);
 		return -EIO;
 	}
drivers/common/cpt/cpt_ucode.h +2 -2
index 87a3ac80b9..636f93604e 100644
@@ -2589,7 +2589,7 @@ fill_sess_aead(struct rte_crypto_sym_xform *xform,
 		sess->cpt_op |= CPT_OP_CIPHER_DECRYPT;
 		sess->cpt_op |= CPT_OP_AUTH_VERIFY;
 	} else {
-		CPT_LOG_DP_ERR("Unknown aead operation\n");
+		CPT_LOG_DP_ERR("Unknown aead operation");
 		return -1;
 	}
 	switch (aead_form->algo) {
@@ -2658,7 +2658,7 @@ fill_sess_cipher(struct rte_crypto_sym_xform *xform,
 			ctx->dec_auth = 1;
 		}
 	} else {
-		CPT_LOG_DP_ERR("Unknown cipher operation\n");
+		CPT_LOG_DP_ERR("Unknown cipher operation");
 		return -1;
 	}
 
drivers/common/idpf/idpf_common_logs.h +1 -4
index e638c616d8..561836760c 100644
@@ -10,7 +10,7 @@
 extern int idpf_common_logtype;
 #define RTE_LOGTYPE_IDPF_COMMON idpf_common_logtype
 
-#define DRV_LOG_RAW(level, ...)					\
+#define DRV_LOG(level, ...)					\
 	rte_log(RTE_LOG_ ## level,				\
 		idpf_common_logtype,				\
 		RTE_FMT("%s(): "				\
@@ -18,9 +18,6 @@ extern int idpf_common_logtype;
 			__func__,				\
 			RTE_FMT_TAIL(__VA_ARGS__,)))
 
-#define DRV_LOG(level, fmt, args...)		\
-	DRV_LOG_RAW(level, fmt "\n", ## args)
-
 #ifdef RTE_LIBRTE_IDPF_DEBUG_RX
 #define RX_LOG(level, ...) \
 	RTE_LOG(level, \
drivers/common/octeontx/octeontx_mbox.c +2 -2
index 4fd3fda721..f98942c79c 100644
@@ -264,7 +264,7 @@ octeontx_start_domain(void)
 
 	result = octeontx_mbox_send(&hdr, NULL, 0, NULL, 0);
 	if (result != 0) {
-		mbox_log_err("Could not start domain. Err=%d. FuncErr=%d\n",
+		mbox_log_err("Could not start domain. Err=%d. FuncErr=%d",
 			     result, hdr.res_code);
 		result = -EINVAL;
 	}
@@ -288,7 +288,7 @@ octeontx_check_mbox_version(struct mbox_intf_ver *app_intf_ver,
 				    sizeof(struct mbox_intf_ver),
 				    &kernel_intf_ver, sizeof(kernel_intf_ver));
 	if (result != sizeof(kernel_intf_ver)) {
-		mbox_log_err("Could not send interface version. Err=%d. FuncErr=%d\n",
+		mbox_log_err("Could not send interface version. Err=%d. FuncErr=%d",
 			     result, hdr.res_code);
 		result = -EINVAL;
 	}
drivers/common/qat/qat_pf2vf.c +2 -2
index 621f12fce2..9b25fdc6a0 100644
@@ -36,7 +36,7 @@ int qat_pf2vf_exch_msg(struct qat_pci_device *qat_dev,
 	}
 
 	if ((pf2vf_msg.msg_type & type_mask) != pf2vf_msg.msg_type) {
-		QAT_LOG(ERR, "PF2VF message type 0x%X out of range\n",
+		QAT_LOG(ERR, "PF2VF message type 0x%X out of range",
 			pf2vf_msg.msg_type);
 		return -EINVAL;
 	}
@@ -65,7 +65,7 @@ int qat_pf2vf_exch_msg(struct qat_pci_device *qat_dev,
 			(++count < ADF_IOV_MSG_ACK_MAX_RETRY));
 
 		if (val & ADF_PFVF_INT) {
-			QAT_LOG(ERR, "ACK not received from remote\n");
+			QAT_LOG(ERR, "ACK not received from remote");
 			return -EIO;
 		}
 
drivers/common/qat/qat_qp.c +1 -1
index ad44b0e01f..4bf9bac23e 100644
@@ -267,7 +267,7 @@ qat_queue_create(struct qat_pci_device *qat_dev, struct qat_queue *queue,
 	if (qat_qp_check_queue_alignment(queue->base_phys_addr,
 			queue_size_bytes)) {
 		QAT_LOG(ERR, "Invalid alignment on queue create "
-					" 0x%"PRIx64"\n",
+					" 0x%"PRIx64,
 					queue->base_phys_addr);
 		ret = -EFAULT;
 		goto queue_create_err;
drivers/compress/isal/isal_compress_pmd.c +39 -39

287 lines not on this page · raw message

drivers/compress/octeontx/otx_zip.h +6 -6
index bb19854b50..7353fd4957 100644
@@ -206,7 +206,7 @@ zipvf_prepare_sgl(struct rte_mbuf *buf, int64_t offset, struct zipvf_sginfo *sg_
 			break;
 		}
 
-		ZIP_PMD_LOG(DEBUG, "ZIP SGL buf[%d], len = %d, iova = 0x%"PRIx64"\n",
+		ZIP_PMD_LOG(DEBUG, "ZIP SGL buf[%d], len = %d, iova = 0x%"PRIx64,
 			    sgidx, sginfo[sgidx].sg_ctl.s.length, sginfo[sgidx].sg_addr.s.addr);
 		++sgidx;
 	}
@@ -219,7 +219,7 @@ zipvf_prepare_sgl(struct rte_mbuf *buf, int64_t offset, struct zipvf_sginfo *sg_
 	}
 	qp->num_sgbuf = ++sgidx;
 
-	ZIP_PMD_LOG(DEBUG, "Tot_buf_len:%d max_segs:%"PRIx64"\n", tot_buf_len,
+	ZIP_PMD_LOG(DEBUG, "Tot_buf_len:%d max_segs:%"PRIx64, tot_buf_len,
 		    qp->num_sgbuf);
 	return ret;
 }
@@ -246,7 +246,7 @@ zipvf_prepare_in_buf(union zip_inst_s *inst, struct zipvf_qp *qp, struct rte_com
 		inst->s.inp_ptr_ctl.s.length = qp->num_sgbuf;
 		inst->s.inp_ptr_ctl.s.fw = 0;
 
-		ZIP_PMD_LOG(DEBUG, "Gather(input): len(nb_segs):%d, iova: 0x%"PRIx64"\n",
+		ZIP_PMD_LOG(DEBUG, "Gather(input): len(nb_segs):%d, iova: 0x%"PRIx64,
 			    inst->s.inp_ptr_ctl.s.length, inst->s.inp_ptr_addr.s.addr);
 		return ret;
 	}
@@ -256,7 +256,7 @@ zipvf_prepare_in_buf(union zip_inst_s *inst, struct zipvf_qp *qp, struct rte_com
 	inst->s.inp_ptr_addr.s.addr = rte_pktmbuf_iova_offset(m_src, offset);
 	inst->s.inp_ptr_ctl.s.length = inlen;
 
-	ZIP_PMD_LOG(DEBUG, "Direct input - inlen:%d\n", inlen);
+	ZIP_PMD_LOG(DEBUG, "Direct input - inlen:%d", inlen);
 	return ret;
 }
 
@@ -282,7 +282,7 @@ zipvf_prepare_out_buf(union zip_inst_s *inst, struct zipvf_qp *qp, struct rte_co
 		inst->s.out_ptr_addr.s.addr = rte_mem_virt2iova(qp->s_info);
 		inst->s.out_ptr_ctl.s.length = qp->num_sgbuf;
 
-		ZIP_PMD_LOG(DEBUG, "Scatter(output): nb_segs:%d, iova:0x%"PRIx64"\n",
+		ZIP_PMD_LOG(DEBUG, "Scatter(output): nb_segs:%d, iova:0x%"PRIx64,
 			    inst->s.out_ptr_ctl.s.length, inst->s.out_ptr_addr.s.addr);
 		return ret;
 	}
@@ -296,7 +296,7 @@ zipvf_prepare_out_buf(union zip_inst_s *inst, struct zipvf_qp *qp, struct rte_co
 
 	inst->s.out_ptr_ctl.s.length = inst->s.totaloutputlength;
 
-	ZIP_PMD_LOG(DEBUG, "Direct output - outlen:%d\n", inst->s.totaloutputlength);
+	ZIP_PMD_LOG(DEBUG, "Direct output - outlen:%d", inst->s.totaloutputlength);
 	return ret;
 }
 
drivers/compress/octeontx/otx_zip_pmd.c +7 -7
index fd20139da6..c8f456b319 100644
@@ -161,7 +161,7 @@ zip_set_stream_parameters(struct rte_compressdev *dev,
 			 */
 
 		} else {
-			ZIP_PMD_ERR("\nxform type not supported");
+			ZIP_PMD_ERR("xform type not supported");
 			ret = -1;
 			goto err;
 		}
@@ -527,7 +527,7 @@ zip_pmd_enqueue_burst(void *queue_pair,
 	}
 
 	qp->enqed = enqd;
-	ZIP_PMD_LOG(DEBUG, "ops_enqd[nb_ops:%d]:%d\n", nb_ops, enqd);
+	ZIP_PMD_LOG(DEBUG, "ops_enqd[nb_ops:%d]:%d", nb_ops, enqd);
 
 	return enqd;
 }
@@ -563,7 +563,7 @@ zip_pmd_dequeue_burst(void *queue_pair,
 			op->status = RTE_COMP_OP_STATUS_SUCCESS;
 		} else {
 			/* FATAL error cannot do anything */
-			ZIP_PMD_ERR("operation failed with error code:%d\n",
+			ZIP_PMD_ERR("operation failed with error code:%d",
 				zresult->s.compcode);
 			if (zresult->s.compcode == ZIP_COMP_E_DSTOP)
 				op->status = RTE_COMP_OP_STATUS_OUT_OF_SPACE_TERMINATED;
@@ -571,7 +571,7 @@ zip_pmd_dequeue_burst(void *queue_pair,
 				op->status = RTE_COMP_OP_STATUS_ERROR;
 		}
 
-		ZIP_PMD_LOG(DEBUG, "written %d\n", zresult->s.totalbyteswritten);
+		ZIP_PMD_LOG(DEBUG, "written %d", zresult->s.totalbyteswritten);
 
 		/* Update op stats */
 		switch (op->status) {
@@ -582,7 +582,7 @@ zip_pmd_dequeue_burst(void *queue_pair,
 			op->produced = zresult->s.totalbyteswritten;
 			break;
 		default:
-			ZIP_PMD_ERR("stats not updated for status:%d\n",
+			ZIP_PMD_ERR("stats not updated for status:%d",
 				    op->status);
 			break;
 		}
@@ -598,7 +598,7 @@ zip_pmd_dequeue_burst(void *queue_pair,
 			rte_mempool_put(qp->vf->sg_mp, qp->s_info);
 	}
 
-	ZIP_PMD_LOG(DEBUG, "ops_deqd[nb_ops:%d]: %d\n", nb_ops, nb_dequeued);
+	ZIP_PMD_LOG(DEBUG, "ops_deqd[nb_ops:%d]: %d", nb_ops, nb_dequeued);
 	return nb_dequeued;
 }
 
@@ -676,7 +676,7 @@ zip_pci_remove(struct rte_pci_device *pci_dev)
 	char compressdev_name[RTE_COMPRESSDEV_NAME_MAX_LEN];
 
 	if (pci_dev == NULL) {
-		ZIP_PMD_ERR(" Invalid PCI Device\n");
+		ZIP_PMD_ERR(" Invalid PCI Device");
 		return -EINVAL;
 	}
 	rte_pci_device_name(&pci_dev->addr, compressdev_name,
drivers/compress/zlib/zlib_pmd.c +13 -13
index 98abd41013..92e808e78c 100644
@@ -29,13 +29,13 @@ process_zlib_deflate(struct rte_comp_op *op, z_stream *strm)
 		break;
 	default:
 		op->status = RTE_COMP_OP_STATUS_INVALID_ARGS;
-		ZLIB_PMD_ERR("Invalid flush value\n");
+		ZLIB_PMD_ERR("Invalid flush value");
 		return;
 	}
 
 	if (unlikely(!strm)) {
 		op->status = RTE_COMP_OP_STATUS_INVALID_ARGS;
-		ZLIB_PMD_ERR("Invalid z_stream\n");
+		ZLIB_PMD_ERR("Invalid z_stream");
 		return;
 	}
 	/* Update z_stream with the inputs provided by application */
@@ -98,7 +98,7 @@ process_zlib_deflate(struct rte_comp_op *op, z_stream *strm)
 		op->produced += strm->total_out;
 		break;
 	default:
-		ZLIB_PMD_ERR("stats not updated for status:%d\n",
+		ZLIB_PMD_ERR("stats not updated for status:%d",
 				op->status);
 	}
 
@@ -114,7 +114,7 @@ process_zlib_inflate(struct rte_comp_op *op, z_stream *strm)
 
 	if (unlikely(!strm)) {
 		op->status = RTE_COMP_OP_STATUS_INVALID_ARGS;
-		ZLIB_PMD_ERR("Invalid z_stream\n");
+		ZLIB_PMD_ERR("Invalid z_stream");
 		return;
 	}
 	strm->next_in = rte_pktmbuf_mtod_offset(mbuf_src, uint8_t *,
@@ -184,7 +184,7 @@ process_zlib_inflate(struct rte_comp_op *op, z_stream *strm)
 		op->produced += strm->total_out;
 		break;
 	default:
-		ZLIB_PMD_ERR("stats not produced for status:%d\n",
+		ZLIB_PMD_ERR("stats not produced for status:%d",
 				op->status);
 	}
 
@@ -203,7 +203,7 @@ process_zlib_op(struct zlib_qp *qp, struct rte_comp_op *op)
 			(op->dst.offset > rte_pktmbuf_data_len(op->m_dst))) {
 		op->status = RTE_COMP_OP_STATUS_INVALID_ARGS;
 		ZLIB_PMD_ERR("Invalid source or destination buffers or "
-			     "invalid Operation requested\n");
+			     "invalid Operation requested");
 	} else {
 		private_xform = (struct zlib_priv_xform *)op->private_xform;
 		stream = &private_xform->stream;
@@ -238,7 +238,7 @@ zlib_set_stream_parameters(const struct rte_comp_xform *xform,
 			wbits = -(xform->compress.window_size);
 			break;
 		default:
-			ZLIB_PMD_ERR("Compression algorithm not supported\n");
+			ZLIB_PMD_ERR("Compression algorithm not supported");
 			return -1;
 		}
 		/** Compression Level */
@@ -260,7 +260,7 @@ zlib_set_stream_parameters(const struct rte_comp_xform *xform,
 			if (level < RTE_COMP_LEVEL_MIN ||
 					level > RTE_COMP_LEVEL_MAX) {
 				ZLIB_PMD_ERR("Compression level %d "
-						"not supported\n",
+						"not supported",
 						level);
 				return -1;
 			}
@@ -278,13 +278,13 @@ zlib_set_stream_parameters(const struct rte_comp_xform *xform,
 			strategy = Z_DEFAULT_STRATEGY;
 			break;
 		default:
-			ZLIB_PMD_ERR("Compression strategy not supported\n");
+			ZLIB_PMD_ERR("Compression strategy not supported");
 			return -1;
 		}
 		if (deflateInit2(strm, level,
 					Z_DEFLATED, wbits,
 					DEF_MEM_LEVEL, strategy) != Z_OK) {
-			ZLIB_PMD_ERR("Deflate init failed\n");
+			ZLIB_PMD_ERR("Deflate init failed");
 			return -1;
 		}
 		break;
@@ -298,12 +298,12 @@ zlib_set_stream_parameters(const struct rte_comp_xform *xform,
 			wbits = -(xform->decompress.window_size);
 			break;
 		default:
-			ZLIB_PMD_ERR("Compression algorithm not supported\n");
+			ZLIB_PMD_ERR("Compression algorithm not supported");
 			return -1;
 		}
 
 		if (inflateInit2(strm, wbits) != Z_OK) {
-			ZLIB_PMD_ERR("Inflate init failed\n");
+			ZLIB_PMD_ERR("Inflate init failed");
 			return -1;
 		}
 		break;
@@ -395,7 +395,7 @@ zlib_probe(struct rte_vdev_device *vdev)
 	retval = rte_compressdev_pmd_parse_input_args(&init_params, input_args);
 	if (retval < 0) {
 		ZLIB_PMD_LOG(ERR,
-			"Failed to parse initialisation arguments[%s]\n",
+			"Failed to parse initialisation arguments[%s]",
 			input_args);
 		return -EINVAL;
 	}
drivers/compress/zlib/zlib_pmd_ops.c +2 -2
index 445a3baa67..a530d15119 100644
@@ -48,8 +48,8 @@ zlib_pmd_config(struct rte_compressdev *dev,
 				NULL, config->socket_id,
 				0);
 		if (mp == NULL) {
-			ZLIB_PMD_ERR("Cannot create private xform pool on "
-			"socket %d\n", config->socket_id);
+			ZLIB_PMD_ERR("Cannot create private xform pool on socket %d",
+				config->socket_id);
 			return -ENOMEM;
 		}
 		internals->mp = mp;
drivers/crypto/bcmfs/bcmfs_qp.c +1 -1
index d1ede5e990..59e39a6c14 100644
@@ -142,7 +142,7 @@ bcmfs_queue_create(struct bcmfs_queue *queue,
 
 	if (bcmfs_qp_check_queue_alignment(qp_mz->iova, align)) {
 		BCMFS_LOG(ERR, "Invalid alignment on queue create "
-					" 0x%" PRIx64 "\n",
+					" 0x%" PRIx64,
 					queue->base_phys_addr);
 		ret = -EFAULT;
 		goto queue_create_err;
drivers/crypto/bcmfs/bcmfs_sym_pmd.c +1 -1
index 78272d616c..d3b1e25d57 100644
@@ -217,7 +217,7 @@ bcmfs_sym_qp_setup(struct rte_cryptodev *cdev, uint16_t qp_id,
 	bcmfs_private->fsdev->qps_in_use[qp_id] = *qp_addr;
 
 	cdev->data->queue_pairs[qp_id] = qp;
-	BCMFS_LOG(NOTICE, "queue %d setup done\n", qp_id);
+	BCMFS_LOG(NOTICE, "queue %d setup done", qp_id);
 
 	return 0;
 }
drivers/crypto/bcmfs/bcmfs_sym_session.c +1 -1
index 40813d1fe5..64bd4a317a 100644
@@ -192,7 +192,7 @@ crypto_set_session_parameters(struct bcmfs_sym_session *sess,
 			rc = -EINVAL;
 		break;
 	default:
-		BCMFS_DP_LOG(ERR, "Invalid chain order\n");
+		BCMFS_DP_LOG(ERR, "Invalid chain order");
 		rc = -EINVAL;
 		break;
 	}
drivers/crypto/caam_jr/caam_jr.c +16 -16
index 6ed7a8f41c..27cdbf5ed4 100644
@@ -309,7 +309,7 @@ caam_jr_prep_cdb(struct caam_jr_session *ses)
 
 	cdb = caam_jr_dma_mem_alloc(L1_CACHE_BYTES, sizeof(struct sec_cdb));
 	if (!cdb) {
-		CAAM_JR_ERR("failed to allocate memory for cdb\n");
+		CAAM_JR_ERR("failed to allocate memory for cdb");
 		return -1;
 	}
 
@@ -606,7 +606,7 @@ hw_poll_job_ring(struct sec_job_ring_t *job_ring,
 		/*TODO for multiple ops, packets*/
 		ctx = container_of(current_desc, struct caam_jr_op_ctx, jobdes);
 		if (unlikely(sec_error_code)) {
-			CAAM_JR_ERR("desc at cidx %d generated error 0x%x\n",
+			CAAM_JR_ERR("desc at cidx %d generated error 0x%x",
 				job_ring->cidx, sec_error_code);
 			hw_handle_job_ring_error(job_ring, sec_error_code);
 			//todo improve with exact errors
@@ -1368,7 +1368,7 @@ caam_jr_enqueue_op(struct rte_crypto_op *op, struct caam_jr_qp *qp)
 	}
 
 	if (unlikely(!ses->qp || ses->qp != qp)) {
-		CAAM_JR_DP_DEBUG("Old:sess->qp=%p New qp = %p\n", ses->qp, qp);
+		CAAM_JR_DP_DEBUG("Old:sess->qp=%p New qp = %p", ses->qp, qp);
 		ses->qp = qp;
 		caam_jr_prep_cdb(ses);
 	}
@@ -1554,7 +1554,7 @@ caam_jr_cipher_init(struct rte_cryptodev *dev __rte_unused,
 	session->cipher_key.data = rte_zmalloc(NULL, xform->cipher.key.length,
 					       RTE_CACHE_LINE_SIZE);
 	if (session->cipher_key.data == NULL && xform->cipher.key.length > 0) {
-		CAAM_JR_ERR("No Memory for cipher key\n");
+		CAAM_JR_ERR("No Memory for cipher key");
 		return -ENOMEM;
 	}
 	session->cipher_key.length = xform->cipher.key.length;
@@ -1576,7 +1576,7 @@ caam_jr_auth_init(struct rte_cryptodev *dev __rte_unused,
 	session->auth_key.data = rte_zmalloc(NULL, xform->auth.key.length,
 					     RTE_CACHE_LINE_SIZE);
 	if (session->auth_key.data == NULL && xform->auth.key.length > 0) {
-		CAAM_JR_ERR("No Memory for auth key\n");
+		CAAM_JR_ERR("No Memory for auth key");
 		return -ENOMEM;
 	}
 	session->auth_key.length = xform->auth.key.length;
@@ -1602,7 +1602,7 @@ caam_jr_aead_init(struct rte_cryptodev *dev __rte_unused,
 	session->aead_key.data = rte_zmalloc(NULL, xform->aead.key.length,
 					     RTE_CACHE_LINE_SIZE);
 	if (session->aead_key.data == NULL && xform->aead.key.length > 0) {
-		CAAM_JR_ERR("No Memory for aead key\n");
+		CAAM_JR_ERR("No Memory for aead key");
 		return -ENOMEM;
 	}
 	session->aead_key.length = xform->aead.key.length;
@@ -1755,7 +1755,7 @@ caam_jr_set_ipsec_session(__rte_unused struct rte_cryptodev *dev,
 					       RTE_CACHE_LINE_SIZE);
 	if (session->cipher_key.data == NULL &&
 			cipher_xform->key.length > 0) {
-		CAAM_JR_ERR("No Memory for cipher key\n");
+		CAAM_JR_ERR("No Memory for cipher key");
 		return -ENOMEM;
 	}
 
@@ -1765,7 +1765,7 @@ caam_jr_set_ipsec_session(__rte_unused struct rte_cryptodev *dev,
 					RTE_CACHE_LINE_SIZE);
 	if (session->auth_key.data == NULL &&
 			auth_xform->key.length > 0) {
-		CAAM_JR_ERR("No Memory for auth key\n");
+		CAAM_JR_ERR("No Memory for auth key");
 		rte_free(session->cipher_key.data);
 		return -ENOMEM;
 	}
@@ -1810,11 +1810,11 @@ caam_jr_set_ipsec_session(__rte_unused struct rte_cryptodev *dev,
 	case RTE_CRYPTO_AUTH_KASUMI_F9:
 	case RTE_CRYPTO_AUTH_AES_CBC_MAC:
 	case RTE_CRYPTO_AUTH_ZUC_EIA3:
-		CAAM_JR_ERR("Crypto: Unsupported auth alg %u\n",
+		CAAM_JR_ERR("Crypto: Unsupported auth alg %u",
 			auth_xform->algo);
 		goto out;
 	default:
-		CAAM_JR_ERR("Crypto: Undefined Auth specified %u\n",
+		CAAM_JR_ERR("Crypto: Undefined Auth specified %u",
 			auth_xform->algo);
 		goto out;
 	}
@@ -1834,11 +1834,11 @@ caam_jr_set_ipsec_session(__rte_unused struct rte_cryptodev *dev,
 	case RTE_CRYPTO_CIPHER_3DES_ECB:
 	case RTE_CRYPTO_CIPHER_AES_ECB:
 	case RTE_CRYPTO_CIPHER_KASUMI_F8:
-		CAAM_JR_ERR("Crypto: Unsupported Cipher alg %u\n",
+		CAAM_JR_ERR("Crypto: Unsupported Cipher alg %u",
 			cipher_xform->algo);
 		goto out;
 	default:
-		CAAM_JR_ERR("Crypto: Undefined Cipher specified %u\n",
+		CAAM_JR_ERR("Crypto: Undefined Cipher specified %u",
 			cipher_xform->algo);
 		goto out;
 	}
@@ -1962,7 +1962,7 @@ caam_jr_dev_configure(struct rte_cryptodev *dev,
 						NULL, NULL, NULL, NULL,
 						SOCKET_ID_ANY, 0);
 		if (!internals->ctx_pool) {
-			CAAM_JR_ERR("%s create failed\n", str);
+			CAAM_JR_ERR("%s create failed", str);
 			return -ENOMEM;
 		}
 	} else
@@ -2180,7 +2180,7 @@ init_job_ring(void *reg_base_addr, int irq_id)
 		}
 	}
 	if (job_ring == NULL) {
-		CAAM_JR_ERR("No free job ring\n");
+		CAAM_JR_ERR("No free job ring");
 		return NULL;
 	}
 
@@ -2301,7 +2301,7 @@ caam_jr_dev_init(const char *name,
 						job_ring->uio_fd);
 
 	if (!dev->data->dev_private) {
-		CAAM_JR_ERR("Ring memory allocation failed\n");
+		CAAM_JR_ERR("Ring memory allocation failed");
 		goto cleanup2;
 	}
 
@@ -2334,7 +2334,7 @@ caam_jr_dev_init(const char *name,
 	security_instance = rte_malloc("caam_jr",
 				sizeof(struct rte_security_ctx), 0);
 	if (security_instance == NULL) {
-		CAAM_JR_ERR("memory allocation failed\n");
+		CAAM_JR_ERR("memory allocation failed");
 		//todo error handling.
 		goto cleanup2;
 	}
drivers/crypto/caam_jr/caam_jr_uio.c +3 -3
index 0dcf971a15..8956f7750d 100644
@@ -338,7 +338,7 @@ free_job_ring(int uio_fd)
 	}
 
 	if (job_ring == NULL) {
-		CAAM_JR_ERR("JR not available for fd = %x\n", uio_fd);
+		CAAM_JR_ERR("JR not available for fd = %x", uio_fd);
 		return;
 	}
 
@@ -378,7 +378,7 @@ uio_job_ring *config_job_ring(void)
 	}
 
 	if (job_ring == NULL) {
-		CAAM_JR_ERR("No free job ring\n");
+		CAAM_JR_ERR("No free job ring");
 		return NULL;
 	}
 
@@ -441,7 +441,7 @@ sec_configure(void)
 					dir->d_name, "name", uio_name);
 			CAAM_JR_INFO("sec device uio name: %s", uio_name);
 			if (ret != 0) {
-				CAAM_JR_ERR("file_read_first_line failed\n");
+				CAAM_JR_ERR("file_read_first_line failed");
 				closedir(d);
 				return -1;
 			}
drivers/crypto/ccp/ccp_dev.c +1 -1
index 0c800fc350..5088d8ded6 100644
@@ -362,7 +362,7 @@ ccp_find_lsb_regions(struct ccp_queue *cmd_q, uint64_t status)
 		if (ccp_get_bit(&cmd_q->lsbmask, j))
 			weight++;
 
-	CCP_LOG_DBG("Queue %d can access %d LSB regions  of mask  %lu\n",
+	CCP_LOG_DBG("Queue %d can access %d LSB regions  of mask  %lu",
 	       (int)cmd_q->id, weight, cmd_q->lsbmask);
 
 	return weight ? 0 : -EINVAL;
drivers/crypto/ccp/rte_ccp_pmd.c +1 -1
index ca99bc6f42..700e141667 100644
@@ -227,7 +227,7 @@ cryptodev_ccp_create(const char *name,
 	}
 	cryptodev_cnt++;
 
-	CCP_LOG_DBG("CCP : Crypto device count = %d\n", cryptodev_cnt);
+	CCP_LOG_DBG("CCP : Crypto device count = %d", cryptodev_cnt);
 	dev->device = &pci_dev->device;
 	dev->device->driver = &pci_drv->driver;
 	dev->driver_id = ccp_cryptodev_driver_id;
drivers/crypto/cnxk/cnxk_se.h +3 -3
index dbd36a8a54..32415e815e 100644
@@ -1953,7 +1953,7 @@ fill_sess_aead(struct rte_crypto_sym_xform *xform, struct cnxk_se_sess *sess)
 		sess->cpt_op |= ROC_SE_OP_CIPHER_DECRYPT;
 		sess->cpt_op |= ROC_SE_OP_AUTH_VERIFY;
 	} else {
-		plt_dp_err("Unknown aead operation\n");
+		plt_dp_err("Unknown aead operation");
 		return -1;
 	}
 	switch (aead_form->algo) {
@@ -2037,7 +2037,7 @@ fill_sm_sess_cipher(struct rte_crypto_sym_xform *xform, struct cnxk_se_sess *ses
 		sess->cpt_op |= ROC_SE_OP_CIPHER_DECRYPT;
 		sess->roc_se_ctx.template_w4.s.opcode_minor = ROC_SE_FC_MINOR_OP_DECRYPT;
 	} else {
-		plt_dp_err("Unknown cipher operation\n");
+		plt_dp_err("Unknown cipher operation");
 		return -1;
 	}
 
@@ -2114,7 +2114,7 @@ fill_sess_cipher(struct rte_crypto_sym_xform *xform, struct cnxk_se_sess *sess)
 				ROC_SE_FC_MINOR_OP_HMAC_FIRST;
 		}
 	} else {
-		plt_dp_err("Unknown cipher operation\n");
+		plt_dp_err("Unknown cipher operation");
 		return -1;
 	}
 
drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c +22 -22

174 lines not on this page · raw message

drivers/crypto/dpaa2_sec/dpaa2_sec_raw_dp.c +8 -8
index 4754b9d6f8..883584a6e2 100644
@@ -605,7 +605,7 @@ build_raw_dp_cipher_fd(uint8_t *drv_ctx,
 	flc = &priv->flc_desc[0].flc;
 
 	DPAA2_SEC_DP_DEBUG(
-		"RAW CIPHER SG: cipher_off: 0x%x/length %d, ivlen=%d\n",
+		"RAW CIPHER SG: cipher_off: 0x%x/length %d, ivlen=%d",
 		data_offset,
 		data_len,
 		sess->iv.length);
@@ -642,7 +642,7 @@ build_raw_dp_cipher_fd(uint8_t *drv_ctx,
 	DPAA2_SET_FLE_FIN(sge);
 
 	DPAA2_SEC_DP_DEBUG(
-		"RAW CIPHER SG: 1 - flc = %p, fle = %p FLEaddr = %x-%x, len %d\n",
+		"RAW CIPHER SG: 1 - flc = %p, fle = %p FLEaddr = %x-%x, len %d",
 		flc, fle, fle->addr_hi, fle->addr_lo,
 		fle->length);
 
@@ -678,7 +678,7 @@ build_raw_dp_cipher_fd(uint8_t *drv_ctx,
 	DPAA2_SET_FD_FLC(fd, DPAA2_VADDR_TO_IOVA(flc));
 
 	DPAA2_SEC_DP_DEBUG(
-		"RAW CIPHER SG: fdaddr =%" PRIx64 " off =%d, len =%d\n",
+		"RAW CIPHER SG: fdaddr =%" PRIx64 " off =%d, len =%d",
 		DPAA2_GET_FD_ADDR(fd),
 		DPAA2_GET_FD_OFFSET(fd),
 		DPAA2_GET_FD_LEN(fd));
@@ -721,7 +721,7 @@ dpaa2_sec_raw_enqueue_burst(void *qp_data, uint8_t *drv_ctx,
 		ret = dpaa2_affine_qbman_swp();
 		if (ret) {
 			DPAA2_SEC_ERR(
-				"Failed to allocate IO portal, tid: %d\n",
+				"Failed to allocate IO portal, tid: %d",
 				rte_gettid());
 			return 0;
 		}
@@ -811,7 +811,7 @@ sec_fd_to_userdata(const struct qbman_fd *fd)
 	void *userdata;
 	fle = (struct qbman_fle *)DPAA2_IOVA_TO_VADDR(DPAA2_GET_FD_ADDR(fd));
 
-	DPAA2_SEC_DP_DEBUG("FLE addr = %x - %x, offset = %x\n",
+	DPAA2_SEC_DP_DEBUG("FLE addr = %x - %x, offset = %x",
 			   fle->addr_hi, fle->addr_lo, fle->fin_bpid_offset);
 	userdata = (struct rte_crypto_op *)DPAA2_GET_FLE_ADDR((fle - 1));
 	/* free the fle memory */
@@ -847,7 +847,7 @@ dpaa2_sec_raw_dequeue_burst(void *qp_data, uint8_t *drv_ctx,
 		ret = dpaa2_affine_qbman_swp();
 		if (ret) {
 			DPAA2_SEC_ERR(
-				"Failed to allocate IO portal, tid: %d\n",
+				"Failed to allocate IO portal, tid: %d",
 				rte_gettid());
 			return 0;
 		}
@@ -900,7 +900,7 @@ dpaa2_sec_raw_dequeue_burst(void *qp_data, uint8_t *drv_ctx,
 			status = (uint8_t)qbman_result_DQ_flags(dq_storage);
 			if (unlikely(
 				(status & QBMAN_DQ_STAT_VALIDFRAME) == 0)) {
-				DPAA2_SEC_DP_DEBUG("No frame is delivered\n");
+				DPAA2_SEC_DP_DEBUG("No frame is delivered");
 				continue;
 			}
 		}
@@ -929,7 +929,7 @@ dpaa2_sec_raw_dequeue_burst(void *qp_data, uint8_t *drv_ctx,
 	*dequeue_status = 1;
 	*n_success = num_rx;
 
-	DPAA2_SEC_DP_DEBUG("SEC Received %d Packets\n", num_rx);
+	DPAA2_SEC_DP_DEBUG("SEC Received %d Packets", num_rx);
 	/*Return the total number of packets received to DPAA2 app*/
 	return num_rx;
 }
drivers/crypto/dpaa_sec/dpaa_sec.c +13 -14
index 1ddad6944e..225bf950e9 100644
@@ -102,7 +102,7 @@ ern_sec_fq_handler(struct qman_portal *qm __rte_unused,
 		   struct qman_fq *fq,
 		   const struct qm_mr_entry *msg)
 {
-	DPAA_SEC_DP_ERR("sec fq %d error, RC = %x, seqnum = %x\n",
+	DPAA_SEC_DP_ERR("sec fq %d error, RC = %x, seqnum = %x",
 			fq->fqid, msg->ern.rc, msg->ern.seqnum);
 }
 
@@ -851,7 +851,7 @@ dpaa_sec_deq(struct dpaa_sec_qp *qp, struct rte_crypto_op **ops, int nb_ops)
 			op->status = RTE_CRYPTO_OP_STATUS_SUCCESS;
 		} else {
 			if (dpaa_sec_dp_dump > DPAA_SEC_DP_NO_DUMP) {
-				DPAA_SEC_DP_WARN("SEC return err:0x%x\n",
+				DPAA_SEC_DP_WARN("SEC return err:0x%x",
 						  ctx->fd_status);
 				if (dpaa_sec_dp_dump > DPAA_SEC_DP_ERR_DUMP)
 					dpaa_sec_dump(ctx, qp, stdout);
@@ -1946,7 +1946,7 @@ dpaa_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
 			} else if (unlikely(ses->qp[rte_lcore_id() %
 						MAX_DPAA_CORES] != qp)) {
 				DPAA_SEC_DP_ERR("Old:sess->qp = %p"
-					" New qp = %p\n",
+					" New qp = %p",
 					ses->qp[rte_lcore_id() %
 					MAX_DPAA_CORES], qp);
 				frames_to_send = loop;
@@ -2056,7 +2056,7 @@ dpaa_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
 				fd->cmd = 0x80000000 |
 					*((uint32_t *)((uint8_t *)op +
 					ses->pdcp.hfn_ovd_offset));
-				DPAA_SEC_DP_DEBUG("Per packet HFN: %x, ovd:%u\n",
+				DPAA_SEC_DP_DEBUG("Per packet HFN: %x, ovd:%u",
 					*((uint32_t *)((uint8_t *)op +
 					ses->pdcp.hfn_ovd_offset)),
 					ses->pdcp.hfn_ovd);
@@ -2097,7 +2097,7 @@ dpaa_sec_dequeue_burst(void *qp, struct rte_crypto_op **ops,
 	dpaa_qp->rx_pkts += num_rx;
 	dpaa_qp->rx_errs += nb_ops - num_rx;
 
-	DPAA_SEC_DP_DEBUG("SEC Received %d Packets\n", num_rx);
+	DPAA_SEC_DP_DEBUG("SEC Received %d Packets", num_rx);
 
 	return num_rx;
 }
@@ -2160,7 +2160,7 @@ dpaa_sec_queue_pair_setup(struct rte_cryptodev *dev, uint16_t qp_id,
 							NULL, NULL, NULL, NULL,
 							SOCKET_ID_ANY, 0);
 		if (!qp->ctx_pool) {
-			DPAA_SEC_ERR("%s create failed\n", str);
+			DPAA_SEC_ERR("%s create failed", str);
 			return -ENOMEM;
 		}
 	} else
@@ -2466,7 +2466,7 @@ dpaa_sec_aead_init(struct rte_cryptodev *dev __rte_unused,
 	session->aead_key.data = rte_zmalloc(NULL, xform->aead.key.length,
 					     RTE_CACHE_LINE_SIZE);
 	if (session->aead_key.data == NULL && xform->aead.key.length > 0) {
-		DPAA_SEC_ERR("No Memory for aead key\n");
+		DPAA_SEC_ERR("No Memory for aead key");
 		return -ENOMEM;
 	}
 	session->aead_key.length = xform->aead.key.length;
@@ -2517,9 +2517,8 @@ dpaa_sec_detach_rxq(struct dpaa_sec_dev_private *qi, struct qman_fq *fq)
 		if (&qi->inq[i] == fq) {
 			ret = qman_retire_fq(fq, NULL);
 			if (ret != 0)
-				DPAA_SEC_ERR("Queue %d is not retired"
-					     " err: %d\n", fq->fqid,
-					     ret);
+				DPAA_SEC_ERR("Queue %d is not retired err: %d",
+					     fq->fqid, ret);
 			qman_oos_fq(fq);
 			qi->inq_attach[i] = 0;
 			return 0;
@@ -3475,7 +3474,7 @@ dpaa_sec_eventq_attach(const struct rte_cryptodev *dev,
 		qp->outq.cb.dqrr_dpdk_cb = dpaa_sec_process_atomic_event;
 		break;
 	case RTE_SCHED_TYPE_ORDERED:
-		DPAA_SEC_ERR("Ordered queue schedule type is not supported\n");
+		DPAA_SEC_ERR("Ordered queue schedule type is not supported");
 		return -ENOTSUP;
 	default:
 		opts.fqd.fq_ctrl |= QM_FQCTRL_AVOIDBLOCK;
@@ -3574,7 +3573,7 @@ check_devargs_handler(__rte_unused const char *key, const char *value,
 	dpaa_sec_dp_dump = atoi(value);
 	if (dpaa_sec_dp_dump > DPAA_SEC_DP_FULL_DUMP) {
 		DPAA_SEC_WARN("WARN: DPAA_SEC_DP_DUMP_LEVEL is not "
-			      "supported, changing to FULL error prints\n");
+			      "supported, changing to FULL error prints");
 		dpaa_sec_dp_dump = DPAA_SEC_DP_FULL_DUMP;
 	}
 
@@ -3637,7 +3636,7 @@ dpaa_sec_dev_init(struct rte_cryptodev *cryptodev)
 
 	ret = munmap(internals->sec_hw, MAP_SIZE);
 	if (ret)
-		DPAA_SEC_WARN("munmap failed\n");
+		DPAA_SEC_WARN("munmap failed");
 
 	close(map_fd);
 	cryptodev->driver_id = dpaa_cryptodev_driver_id;
@@ -3705,7 +3704,7 @@ dpaa_sec_dev_init(struct rte_cryptodev *cryptodev)
 	return 0;
 
 init_error:
-	DPAA_SEC_ERR("driver %s: create failed\n", cryptodev->data->name);
+	DPAA_SEC_ERR("driver %s: create failed", cryptodev->data->name);
 
 	rte_free(cryptodev->security_ctx);
 	return -EFAULT;
drivers/crypto/dpaa_sec/dpaa_sec_log.h +1 -1
index f8c85b6528..60dbaee4ec 100644
@@ -30,7 +30,7 @@ extern int dpaa_logtype_sec;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define DPAA_SEC_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, DPAA_SEC, fmt, ## args)
+	RTE_LOG_DP_LINE(level, DPAA_SEC, fmt, ## args)
 
 #define DPAA_SEC_DP_DEBUG(fmt, args...) \
 	DPAA_SEC_DP_LOG(DEBUG, fmt, ## args)
drivers/crypto/dpaa_sec/dpaa_sec_raw_dp.c +3 -3
index ce49c4996f..f62c803894 100644
@@ -761,7 +761,7 @@ build_dpaa_raw_proto_sg(uint8_t *drv_ctx,
 		fd->cmd = 0x80000000 |
 			*((uint32_t *)((uint8_t *)userdata +
 			ses->pdcp.hfn_ovd_offset));
-		DPAA_SEC_DP_DEBUG("Per packet HFN: %x, ovd:%u\n",
+		DPAA_SEC_DP_DEBUG("Per packet HFN: %x, ovd:%u",
 			*((uint32_t *)((uint8_t *)userdata +
 			ses->pdcp.hfn_ovd_offset)),
 			ses->pdcp.hfn_ovd);
@@ -806,7 +806,7 @@ dpaa_sec_raw_enqueue_burst(void *qp_data, uint8_t *drv_ctx,
 			} else if (unlikely(ses->qp[rte_lcore_id() %
 						MAX_DPAA_CORES] != dpaa_qp)) {
 				DPAA_SEC_DP_ERR("Old:sess->qp = %p"
-					" New qp = %p\n",
+					" New qp = %p",
 					ses->qp[rte_lcore_id() %
 					MAX_DPAA_CORES], dpaa_qp);
 				frames_to_send = loop;
@@ -955,7 +955,7 @@ dpaa_sec_raw_dequeue_burst(void *qp_data, uint8_t *drv_ctx,
 	*dequeue_status = 1;
 	*n_success = num_rx;
 
-	DPAA_SEC_DP_DEBUG("SEC Received %d Packets\n", num_rx);
+	DPAA_SEC_DP_DEBUG("SEC Received %d Packets", num_rx);
 
 	return num_rx;
 }
drivers/crypto/ipsec_mb/ipsec_mb_private.c +2 -2
index f485d130b6..0d2538832d 100644
@@ -165,7 +165,7 @@ ipsec_mb_create(struct rte_vdev_device *vdev,
 
 	rte_cryptodev_pmd_probing_finish(dev);
 
-	IPSEC_MB_LOG(INFO, "IPSec Multi-buffer library version used: %s\n",
+	IPSEC_MB_LOG(INFO, "IPSec Multi-buffer library version used: %s",
 		     imb_get_version_str());
 
 	if (rte_eal_process_type() == RTE_PROC_PRIMARY) {
@@ -176,7 +176,7 @@ ipsec_mb_create(struct rte_vdev_device *vdev,
 
 		if (retval)
 			IPSEC_MB_LOG(ERR,
-				"IPSec Multi-buffer register MP request failed.\n");
+				"IPSec Multi-buffer register MP request failed.");
 	}
 	return retval;
 }
drivers/crypto/ipsec_mb/ipsec_mb_private.h +1 -1
index be6dbe9b1b..d42acd913c 100644
@@ -198,7 +198,7 @@ alloc_init_mb_mgr(void)
 	IMB_MGR *mb_mgr = alloc_mb_mgr(0);
 
 	if (unlikely(mb_mgr == NULL)) {
-		IPSEC_MB_LOG(ERR, "Failed to allocate IMB_MGR data\n");
+		IPSEC_MB_LOG(ERR, "Failed to allocate IMB_MGR data");
 		return NULL;
 	}
 
drivers/crypto/ipsec_mb/pmd_aesni_mb.c +14 -14
index ef4228bd38..f3633091a9 100644
@@ -113,7 +113,7 @@ aesni_mb_set_session_auth_parameters(IMB_MGR *mb_mgr,
 		uint16_t xcbc_mac_digest_len =
 			get_truncated_digest_byte_length(IMB_AUTH_AES_XCBC);
 		if (sess->auth.req_digest_len != xcbc_mac_digest_len) {
-			IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+			IPSEC_MB_LOG(ERR, "Invalid digest size");
 			return -EINVAL;
 		}
 		sess->template_job.auth_tag_output_len_in_bytes = sess->auth.req_digest_len;
@@ -136,7 +136,7 @@ aesni_mb_set_session_auth_parameters(IMB_MGR *mb_mgr,
 				get_digest_byte_length(IMB_AUTH_AES_CMAC);
 
 		if (sess->auth.req_digest_len > cmac_digest_len) {
-			IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+			IPSEC_MB_LOG(ERR, "Invalid digest size");
 			return -EINVAL;
 		}
 		/*
@@ -171,7 +171,7 @@ aesni_mb_set_session_auth_parameters(IMB_MGR *mb_mgr,
 
 		if (sess->auth.req_digest_len >
 			get_digest_byte_length(IMB_AUTH_AES_GMAC)) {
-			IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+			IPSEC_MB_LOG(ERR, "Invalid digest size");
 			return -EINVAL;
 		}
 		sess->template_job.auth_tag_output_len_in_bytes = sess->auth.req_digest_len;
@@ -198,7 +198,7 @@ aesni_mb_set_session_auth_parameters(IMB_MGR *mb_mgr,
 			sess->template_job.key_len_in_bytes = IMB_KEY_256_BYTES;
 			break;
 		default:
-			IPSEC_MB_LOG(ERR, "Invalid authentication key length\n");
+			IPSEC_MB_LOG(ERR, "Invalid authentication key length");
 			return -EINVAL;
 		}
 		sess->template_job.u.GMAC._key = &sess->cipher.gcm_key;
@@ -211,7 +211,7 @@ aesni_mb_set_session_auth_parameters(IMB_MGR *mb_mgr,
 			sess->template_job.hash_alg = IMB_AUTH_ZUC_EIA3_BITLEN;
 
 			if (sess->auth.req_digest_len != 4) {
-				IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+				IPSEC_MB_LOG(ERR, "Invalid digest size");
 				return -EINVAL;
 			}
 		} else if (xform->auth.key.length == 32) {
@@ -223,11 +223,11 @@ aesni_mb_set_session_auth_parameters(IMB_MGR *mb_mgr,
 #else
 			if (sess->auth.req_digest_len != 4) {
 #endif
-				IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+				IPSEC_MB_LOG(ERR, "Invalid digest size");
 				return -EINVAL;
 			}
 		} else {
-			IPSEC_MB_LOG(ERR, "Invalid authentication key length\n");
+			IPSEC_MB_LOG(ERR, "Invalid authentication key length");
 			return -EINVAL;
 		}
 
@@ -243,7 +243,7 @@ aesni_mb_set_session_auth_parameters(IMB_MGR *mb_mgr,
 			get_truncated_digest_byte_length(
 						IMB_AUTH_SNOW3G_UIA2_BITLEN);
 		if (sess->auth.req_digest_len != snow3g_uia2_digest_len) {
-			IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+			IPSEC_MB_LOG(ERR, "Invalid digest size");
 			return -EINVAL;
 		}
 		sess->template_job.auth_tag_output_len_in_bytes = sess->auth.req_digest_len;
@@ -258,7 +258,7 @@ aesni_mb_set_session_auth_parameters(IMB_MGR *mb_mgr,
 		uint16_t kasumi_f9_digest_len =
 			get_truncated_digest_byte_length(IMB_AUTH_KASUMI_UIA1);
 		if (sess->auth.req_digest_len != kasumi_f9_digest_len) {
-			IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+			IPSEC_MB_LOG(ERR, "Invalid digest size");
 			return -EINVAL;
 		}
 		sess->template_job.auth_tag_output_len_in_bytes = sess->auth.req_digest_len;
@@ -389,7 +389,7 @@ aesni_mb_set_session_auth_parameters(IMB_MGR *mb_mgr,
 
 	if (sess->auth.req_digest_len > full_digest_size ||
 			sess->auth.req_digest_len == 0) {
-		IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+		IPSEC_MB_LOG(ERR, "Invalid digest size");
 		return -EINVAL;
 	}
 
@@ -725,7 +725,7 @@ aesni_mb_set_session_aead_parameters(const IMB_MGR *mb_mgr,
 		if (sess->auth.req_digest_len < AES_CCM_DIGEST_MIN_LEN ||
 			sess->auth.req_digest_len > AES_CCM_DIGEST_MAX_LEN ||
 			(sess->auth.req_digest_len & 1) == 1) {
-			IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+			IPSEC_MB_LOG(ERR, "Invalid digest size");
 			return -EINVAL;
 		}
 		break;
@@ -761,7 +761,7 @@ aesni_mb_set_session_aead_parameters(const IMB_MGR *mb_mgr,
 		/* GCM digest size must be between 1 and 16 */
 		if (sess->auth.req_digest_len == 0 ||
 				sess->auth.req_digest_len > 16) {
-			IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+			IPSEC_MB_LOG(ERR, "Invalid digest size");
 			return -EINVAL;
 		}
 		break;
@@ -782,7 +782,7 @@ aesni_mb_set_session_aead_parameters(const IMB_MGR *mb_mgr,
 		sess->template_job.enc_keys = sess->cipher.expanded_aes_keys.encode;
 		sess->template_job.dec_keys = sess->cipher.expanded_aes_keys.decode;
 		if (sess->auth.req_digest_len != 16) {
-			IPSEC_MB_LOG(ERR, "Invalid digest size\n");
+			IPSEC_MB_LOG(ERR, "Invalid digest size");
 			return -EINVAL;
 		}
 		break;
@@ -1234,7 +1234,7 @@ handle_sgl_linear(IMB_JOB *job, struct rte_crypto_op *op, uint32_t dst_offset,
 	total_len = sgl_linear_cipher_auth_len(job, &auth_len);
 	linear_buf = rte_zmalloc(NULL, total_len + job->auth_tag_output_len_in_bytes, 0);
 	if (linear_buf == NULL) {
-		IPSEC_MB_LOG(ERR, "Error allocating memory for SGL Linear Buffer\n");
+		IPSEC_MB_LOG(ERR, "Error allocating memory for SGL Linear Buffer");
 		return -1;
 	}
 
drivers/crypto/ipsec_mb/pmd_snow3g.c +2 -2
index a96779f059..65f0e5c568 100644
@@ -186,7 +186,7 @@ process_snow3g_cipher_op_bit(struct ipsec_mb_qp *qp,
 	src = rte_pktmbuf_mtod(op->sym->m_src, uint8_t *);
 	if (op->sym->m_dst == NULL) {
 		op->status = RTE_CRYPTO_OP_STATUS_INVALID_ARGS;
-		IPSEC_MB_LOG(ERR, "bit-level in-place not supported\n");
+		IPSEC_MB_LOG(ERR, "bit-level in-place not supported");
 		return 0;
 	}
 	length_in_bits = op->sym->cipher.data.length;
@@ -317,7 +317,7 @@ process_ops(struct rte_crypto_op **ops, struct snow3g_session *session,
 			IPSEC_MB_LOG(ERR,
 				"PMD supports only contiguous mbufs, "
 				"op (%p) provides noncontiguous mbuf as "
-				"source/destination buffer.\n", ops[i]);
+				"source/destination buffer.", ops[i]);
 			ops[i]->status = RTE_CRYPTO_OP_STATUS_INVALID_ARGS;
 			return 0;
 		}
drivers/crypto/octeontx/otx_cryptodev_hw_access.h +3 -3
index 6e2afde34f..3104e6d31e 100644
@@ -211,7 +211,7 @@ otx_cpt_ring_dbell(struct cpt_instance *instance, uint16_t count)
 static __rte_always_inline void *
 get_cpt_inst(struct command_queue *cqueue)
 {
-	CPT_LOG_DP_DEBUG("CPT queue idx %u\n", cqueue->idx);
+	CPT_LOG_DP_DEBUG("CPT queue idx %u", cqueue->idx);
 	return &cqueue->qhead[cqueue->idx * CPT_INST_SIZE];
 }
 
@@ -305,9 +305,9 @@ check_nb_command_id(struct cpt_request_info *user_req,
 				" error, MC completion code : 0x%x", user_req,
 				ret);
 		}
-		CPT_LOG_DP_DEBUG("MC status %.8x\n",
+		CPT_LOG_DP_DEBUG("MC status %.8x",
 			   *((volatile uint32_t *)user_req->alternate_caddr));
-		CPT_LOG_DP_DEBUG("HW status %.8x\n",
+		CPT_LOG_DP_DEBUG("HW status %.8x",
 			   *((volatile uint32_t *)user_req->completion_addr));
 	} else if ((cptres->s8x.compcode == CPT_8X_COMP_E_SWERR) ||
 		   (cptres->s8x.compcode == CPT_8X_COMP_E_FAULT)) {
drivers/crypto/openssl/rte_openssl_pmd.c +21 -21

167 lines not on this page · raw message

drivers/crypto/openssl/rte_openssl_pmd_ops.c +22 -22

175 lines not on this page · raw message

drivers/crypto/qat/qat_asym.c +1 -1
index 491f5ecd5b..e43884e69b 100644
@@ -1531,7 +1531,7 @@ qat_asym_dev_create(struct qat_pci_device *qat_pci_dev)
 
 	snprintf(name, RTE_CRYPTODEV_NAME_MAX_LEN, "%s_%s",
 			qat_pci_dev->name, "asym");
-	QAT_LOG(DEBUG, "Creating QAT ASYM device %s\n", name);
+	QAT_LOG(DEBUG, "Creating QAT ASYM device %s", name);
 
 	if (qat_pci_dev->qat_dev_gen == QAT_VQAT &&
 		sub_id != ADF_VQAT_ASYM_PCI_SUBSYSTEM_ID) {
drivers/crypto/qat/qat_sym_session.c +5 -7
index eb267db424..50d687fd37 100644
@@ -581,7 +581,7 @@ qat_sym_session_configure_cipher(struct rte_cryptodev *dev,
 		ret = -ENOTSUP;
 		goto error_out;
 	default:
-		QAT_LOG(ERR, "Crypto: Undefined Cipher specified %u\n",
+		QAT_LOG(ERR, "Crypto: Undefined Cipher specified %u",
 				cipher_xform->algo);
 		ret = -EINVAL;
 		goto error_out;
@@ -1180,7 +1180,7 @@ qat_sym_session_configure_aead(struct rte_cryptodev *dev,
 						aead_xform);
 		break;
 	default:
-		QAT_LOG(ERR, "Crypto: Undefined AEAD specified %u\n",
+		QAT_LOG(ERR, "Crypto: Undefined AEAD specified %u",
 				aead_xform->algo);
 		return -EINVAL;
 	}
@@ -1805,7 +1805,7 @@ static int aes_ipsecmb_job(uint8_t *in, uint8_t *out, IMB_MGR *m,
 
 	err = imb_get_errno(m);
 	if (err)
-		QAT_LOG(ERR, "Error: %s!\n", imb_get_strerror(err));
+		QAT_LOG(ERR, "Error: %s!", imb_get_strerror(err));
 
 	return -EFAULT;
 }
@@ -2657,10 +2657,8 @@ int qat_sym_cd_auth_set(struct qat_sym_session *cdesc,
 			&state2_size, cdesc->aes_cmac);
 #endif
 		if (ret) {
-			cdesc->aes_cmac ? QAT_LOG(ERR,
-						  "(CMAC)precompute failed")
-					: QAT_LOG(ERR,
-						  "(XCBC)precompute failed");
+			QAT_LOG(ERR, "(%s)precompute failed",
+				cdesc->aes_cmac ? "CMAC" : "XCBC");
 			return -EFAULT;
 		}
 		break;
drivers/crypto/uadk/uadk_crypto_pmd.c +4 -4
index 824383512e..e4b1a32398 100644
@@ -634,7 +634,7 @@ uadk_set_session_cipher_parameters(struct rte_cryptodev *dev,
 	setup.sched_param = &params;
 	sess->handle_cipher = wd_cipher_alloc_sess(&setup);
 	if (!sess->handle_cipher) {
-		UADK_LOG(ERR, "uadk failed to alloc session!\n");
+		UADK_LOG(ERR, "uadk failed to alloc session!");
 		ret = -EINVAL;
 		goto env_uninit;
 	}
@@ -642,7 +642,7 @@ uadk_set_session_cipher_parameters(struct rte_cryptodev *dev,
 	ret = wd_cipher_set_key(sess->handle_cipher, cipher->key.data, cipher->key.length);
 	if (ret) {
 		wd_cipher_free_sess(sess->handle_cipher);
-		UADK_LOG(ERR, "uadk failed to set key!\n");
+		UADK_LOG(ERR, "uadk failed to set key!");
 		ret = -EINVAL;
 		goto env_uninit;
 	}
@@ -734,7 +734,7 @@ uadk_set_session_auth_parameters(struct rte_cryptodev *dev,
 	setup.sched_param = &params;
 	sess->handle_digest = wd_digest_alloc_sess(&setup);
 	if (!sess->handle_digest) {
-		UADK_LOG(ERR, "uadk failed to alloc session!\n");
+		UADK_LOG(ERR, "uadk failed to alloc session!");
 		ret = -EINVAL;
 		goto env_uninit;
 	}
@@ -745,7 +745,7 @@ uadk_set_session_auth_parameters(struct rte_cryptodev *dev,
 					xform->auth.key.data,
 					xform->auth.key.length);
 		if (ret) {
-			UADK_LOG(ERR, "uadk failed to alloc session!\n");
+			UADK_LOG(ERR, "uadk failed to alloc session!");
 			wd_digest_free_sess(sess->handle_digest);
 			sess->handle_digest = 0;
 			ret = -EINVAL;
drivers/crypto/virtio/virtio_cryptodev.c +1 -1
index 4854820ba6..c0d3178b71 100644
@@ -591,7 +591,7 @@ virtio_crypto_qp_setup(struct rte_cryptodev *dev, uint16_t queue_pair_id,
 			qp_conf->nb_descriptors, socket_id, &vq);
 	if (ret < 0) {
 		VIRTIO_CRYPTO_INIT_LOG_ERR(
-			"virtio crypto data queue initialization failed\n");
+			"virtio crypto data queue initialization failed");
 		return ret;
 	}
 
drivers/dma/dpaa/dpaa_qdma.c +20 -20
index 10e65ef1d7..3d4fd818f8 100644
@@ -295,7 +295,7 @@ static struct fsl_qdma_queue
 		for (i = 0; i < queue_num; i++) {
 			if (queue_size[i] > FSL_QDMA_CIRCULAR_DESC_SIZE_MAX ||
 			    queue_size[i] < FSL_QDMA_CIRCULAR_DESC_SIZE_MIN) {
-				DPAA_QDMA_ERR("Get wrong queue-sizes.\n");
+				DPAA_QDMA_ERR("Get wrong queue-sizes.");
 				goto fail;
 			}
 			queue_temp = queue_head + i + (j * queue_num);
@@ -345,7 +345,7 @@ fsl_qdma_queue *fsl_qdma_prep_status_queue(void)
 	status_size = QDMA_STATUS_SIZE;
 	if (status_size > FSL_QDMA_CIRCULAR_DESC_SIZE_MAX ||
 	    status_size < FSL_QDMA_CIRCULAR_DESC_SIZE_MIN) {
-		DPAA_QDMA_ERR("Get wrong status_size.\n");
+		DPAA_QDMA_ERR("Get wrong status_size.");
 		return NULL;
 	}
 
@@ -643,7 +643,7 @@ fsl_qdma_alloc_chan_resources(struct fsl_qdma_chan *fsl_chan)
 				FSL_QDMA_COMMAND_BUFFER_SIZE, 64);
 	if (ret) {
 		DPAA_QDMA_ERR(
-			"failed to alloc dma buffer for comp descriptor\n");
+			"failed to alloc dma buffer for comp descriptor");
 		goto exit;
 	}
 
@@ -779,7 +779,7 @@ dpaa_qdma_enqueue(void *dev_private, uint16_t vchan,
 			(dma_addr_t)dst, (dma_addr_t)src,
 			length, NULL, NULL);
 	if (!fsl_comp) {
-		DPAA_QDMA_DP_DEBUG("fsl_comp is NULL\n");
+		DPAA_QDMA_DP_DEBUG("fsl_comp is NULL");
 		return -1;
 	}
 	ret = fsl_qdma_enqueue_desc(fsl_chan, fsl_comp, flags);
@@ -803,19 +803,19 @@ dpaa_qdma_dequeue_status(void *dev_private, uint16_t vchan,
 
 	intr = qdma_readl_be(status + FSL_QDMA_DEDR);
 	if (intr) {
-		DPAA_QDMA_ERR("DMA transaction error! %x\n", intr);
+		DPAA_QDMA_ERR("DMA transaction error! %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECFDW0R);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW0R %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW0R %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECFDW1R);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW1R %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW1R %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECFDW2R);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW2R %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW2R %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECFDW3R);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW3R %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW3R %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECFQIDR);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECFQIDR %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECFQIDR %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECBR);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECBR %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECBR %x", intr);
 		qdma_writel(0xffffffff,
 			    status + FSL_QDMA_DEDR);
 		intr = qdma_readl(status + FSL_QDMA_DEDR);
@@ -849,19 +849,19 @@ dpaa_qdma_dequeue(void *dev_private,
 
 	intr = qdma_readl_be(status + FSL_QDMA_DEDR);
 	if (intr) {
-		DPAA_QDMA_ERR("DMA transaction error! %x\n", intr);
+		DPAA_QDMA_ERR("DMA transaction error! %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECFDW0R);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW0R %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW0R %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECFDW1R);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW1R %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW1R %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECFDW2R);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW2R %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW2R %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECFDW3R);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW3R %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECFDW3R %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECFQIDR);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECFQIDR %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECFQIDR %x", intr);
 		intr = qdma_readl(status + FSL_QDMA_DECBR);
-		DPAA_QDMA_INFO("reg FSL_QDMA_DECBR %x\n", intr);
+		DPAA_QDMA_INFO("reg FSL_QDMA_DECBR %x", intr);
 		qdma_writel(0xffffffff,
 			    status + FSL_QDMA_DEDR);
 		intr = qdma_readl(status + FSL_QDMA_DEDR);
@@ -974,7 +974,7 @@ dpaa_qdma_init(struct rte_dma_dev *dmadev)
 	close(ccsr_qdma_fd);
 	if (fsl_qdma->ctrl_base == MAP_FAILED) {
 		DPAA_QDMA_ERR("Can not map CCSR base qdma: Phys: %08" PRIx64
-		       "size %d\n", phys_addr, regs_size);
+		       "size %d", phys_addr, regs_size);
 		goto err;
 	}
 
@@ -998,7 +998,7 @@ dpaa_qdma_init(struct rte_dma_dev *dmadev)
 
 	ret = fsl_qdma_reg_init(fsl_qdma);
 	if (ret) {
-		DPAA_QDMA_ERR("Can't Initialize the qDMA engine.\n");
+		DPAA_QDMA_ERR("Can't Initialize the qDMA engine.");
 		munmap(fsl_qdma->ctrl_base, regs_size);
 		goto err;
 	}
drivers/dma/dpaa2/dpaa2_qdma.c +5 -5
index 2c91ceec13..5780e49297 100644
@@ -578,7 +578,7 @@ dpdmai_dev_dequeue_multijob_prefetch(struct qdma_virt_queue *qdma_vq,
 		ret = dpaa2_affine_qbman_swp();
 		if (ret) {
 			DPAA2_QDMA_ERR(
-				"Failed to allocate IO portal, tid: %d\n",
+				"Failed to allocate IO portal, tid: %d",
 				rte_gettid());
 			return 0;
 		}
@@ -608,7 +608,7 @@ dpdmai_dev_dequeue_multijob_prefetch(struct qdma_virt_queue *qdma_vq,
 		while (1) {
 			if (qbman_swp_pull(swp, &pulldesc)) {
 				DPAA2_QDMA_DP_WARN(
-					"VDQ command not issued.QBMAN busy\n");
+					"VDQ command not issued.QBMAN busy");
 					/* Portal was busy, try again */
 				continue;
 			}
@@ -684,7 +684,7 @@ dpdmai_dev_dequeue_multijob_prefetch(struct qdma_virt_queue *qdma_vq,
 	while (1) {
 		if (qbman_swp_pull(swp, &pulldesc)) {
 			DPAA2_QDMA_DP_WARN(
-				"VDQ command is not issued. QBMAN is busy (2)\n");
+				"VDQ command is not issued. QBMAN is busy (2)");
 			continue;
 		}
 		break;
@@ -728,7 +728,7 @@ dpdmai_dev_dequeue_multijob_no_prefetch(struct qdma_virt_queue *qdma_vq,
 		ret = dpaa2_affine_qbman_swp();
 		if (ret) {
 			DPAA2_QDMA_ERR(
-				"Failed to allocate IO portal, tid: %d\n",
+				"Failed to allocate IO portal, tid: %d",
 				rte_gettid());
 			return 0;
 		}
@@ -825,7 +825,7 @@ dpdmai_dev_submit_multi(struct qdma_virt_queue *qdma_vq,
 		ret = dpaa2_affine_qbman_swp();
 		if (ret) {
 			DPAA2_QDMA_ERR(
-				"Failed to allocate IO portal, tid: %d\n",
+				"Failed to allocate IO portal, tid: %d",
 				rte_gettid());
 			return 0;
 		}
drivers/dma/hisilicon/hisi_dmadev.c +3 -3
index 7cd6ebc1e0..bce4b4b277 100644
@@ -357,7 +357,7 @@ hisi_dma_start(struct rte_dma_dev *dev)
 	struct hisi_dma_dev *hw = dev->data->dev_private;
 
 	if (hw->iomz == NULL) {
-		HISI_DMA_ERR(hw, "Vchan was not setup, start fail!\n");
+		HISI_DMA_ERR(hw, "Vchan was not setup, start fail!");
 		return -EINVAL;
 	}
 
@@ -630,7 +630,7 @@ hisi_dma_scan_cq(struct hisi_dma_dev *hw)
 			 * status array indexed by csq_head. Only error logs
 			 * are used for prompting.
 			 */
-			HISI_DMA_ERR(hw, "invalid csq_head:%u!\n", csq_head);
+			HISI_DMA_ERR(hw, "invalid csq_head:%u!", csq_head);
 			count = 0;
 			break;
 		}
@@ -912,7 +912,7 @@ hisi_dma_probe(struct rte_pci_driver *pci_drv __rte_unused,
 	rte_pci_device_name(&pci_dev->addr, name, sizeof(name));
 
 	if (pci_dev->mem_resource[2].addr == NULL) {
-		HISI_DMA_LOG(ERR, "%s BAR2 is NULL!\n", name);
+		HISI_DMA_LOG(ERR, "%s BAR2 is NULL!", name);
 		return -ENODEV;
 	}
 
drivers/dma/idxd/idxd_common.c +1 -1
index 83d53942eb..dc2e8cd432 100644
@@ -616,7 +616,7 @@ idxd_dmadev_create(const char *name, struct rte_device *dev,
 			sizeof(idxd->batch_comp_ring[0]))	* (idxd->max_batches + 1),
 			sizeof(idxd->batch_comp_ring[0]), dev->numa_node);
 	if (idxd->batch_comp_ring == NULL) {
-		IDXD_PMD_ERR("Unable to reserve memory for batch data\n");
+		IDXD_PMD_ERR("Unable to reserve memory for batch data");
 		ret = -ENOMEM;
 		goto cleanup;
 	}
drivers/dma/idxd/idxd_pci.c +3 -3
index 81637d9420..60ac219559 100644
@@ -324,7 +324,7 @@ idxd_dmadev_probe_pci(struct rte_pci_driver *drv, struct rte_pci_device *dev)
 
 		/* look up queue 0 to get the PCI structure */
 		snprintf(qname, sizeof(qname), "%s-q0", name);
-		IDXD_PMD_INFO("Looking up %s\n", qname);
+		IDXD_PMD_INFO("Looking up %s", qname);
 		ret = idxd_dmadev_create(qname, &dev->device, NULL, &idxd_pci_ops);
 		if (ret != 0) {
 			IDXD_PMD_ERR("Failed to create dmadev %s", name);
@@ -339,7 +339,7 @@ idxd_dmadev_probe_pci(struct rte_pci_driver *drv, struct rte_pci_device *dev)
 		for (qid = 1; qid < max_qid; qid++) {
 			/* add the queue number to each device name */
 			snprintf(qname, sizeof(qname), "%s-q%d", name, qid);
-			IDXD_PMD_INFO("Looking up %s\n", qname);
+			IDXD_PMD_INFO("Looking up %s", qname);
 			ret = idxd_dmadev_create(qname, &dev->device, NULL, &idxd_pci_ops);
 			if (ret != 0) {
 				IDXD_PMD_ERR("Failed to create dmadev %s", name);
@@ -365,7 +365,7 @@ idxd_dmadev_probe_pci(struct rte_pci_driver *drv, struct rte_pci_device *dev)
 		return ret;
 	}
 	if (idxd.u.pci->portals == NULL) {
-		IDXD_PMD_ERR("Error, invalid portal assigned during initialization\n");
+		IDXD_PMD_ERR("Error, invalid portal assigned during initialization");
 		free(idxd.u.pci);
 		return -EINVAL;
 	}
drivers/dma/ioat/ioat_dmadev.c +7 -7
index 5fc14bcf22..8b7ff5652f 100644
@@ -156,12 +156,12 @@ ioat_dev_start(struct rte_dma_dev *dev)
 	ioat->offset = 0;
 	ioat->failure = 0;
 
-	IOAT_PMD_DEBUG("channel status - %s [0x%"PRIx64"]\n",
+	IOAT_PMD_DEBUG("channel status - %s [0x%"PRIx64"]",
 			chansts_readable[ioat->status & IOAT_CHANSTS_STATUS],
 			ioat->status);
 
 	if ((ioat->regs->chansts & IOAT_CHANSTS_STATUS) == IOAT_CHANSTS_HALTED) {
-		IOAT_PMD_WARN("Device HALTED on start, attempting to recover\n");
+		IOAT_PMD_WARN("Device HALTED on start, attempting to recover");
 		if (__ioat_recover(ioat) != 0) {
 			IOAT_PMD_ERR("Device couldn't be recovered");
 			return -1;
@@ -469,7 +469,7 @@ ioat_completed(void *dev_private, uint16_t qid __rte_unused, const uint16_t max_
 		ioat->failure = ioat->regs->chanerr;
 		ioat->next_read = read + count + 1;
 		if (__ioat_recover(ioat) != 0) {
-			IOAT_PMD_ERR("Device HALTED and could not be recovered\n");
+			IOAT_PMD_ERR("Device HALTED and could not be recovered");
 			__dev_dump(dev_private, stdout);
 			return 0;
 		}
@@ -515,7 +515,7 @@ ioat_completed_status(void *dev_private, uint16_t qid __rte_unused,
 		count++;
 		ioat->next_read = read + count;
 		if (__ioat_recover(ioat) != 0) {
-			IOAT_PMD_ERR("Device HALTED and could not be recovered\n");
+			IOAT_PMD_ERR("Device HALTED and could not be recovered");
 			__dev_dump(dev_private, stdout);
 			return 0;
 		}
@@ -652,12 +652,12 @@ ioat_dmadev_create(const char *name, struct rte_pci_device *dev)
 
 	/* Do device initialization - reset and set error behaviour. */
 	if (ioat->regs->chancnt != 1)
-		IOAT_PMD_WARN("%s: Channel count == %d\n", __func__,
+		IOAT_PMD_WARN("%s: Channel count == %d", __func__,
 				ioat->regs->chancnt);
 
 	/* Locked by someone else. */
 	if (ioat->regs->chanctrl & IOAT_CHANCTRL_CHANNEL_IN_USE) {
-		IOAT_PMD_WARN("%s: Channel appears locked\n", __func__);
+		IOAT_PMD_WARN("%s: Channel appears locked", __func__);
 		ioat->regs->chanctrl = 0;
 	}
 
@@ -676,7 +676,7 @@ ioat_dmadev_create(const char *name, struct rte_pci_device *dev)
 		rte_delay_ms(1);
 		if (++retry >= 200) {
 			IOAT_PMD_ERR("%s: cannot reset device. CHANCMD=%#"PRIx8
-					", CHANSTS=%#"PRIx64", CHANERR=%#"PRIx32"\n",
+					", CHANSTS=%#"PRIx64", CHANERR=%#"PRIx32,
 					__func__,
 					ioat->regs->chancmd,
 					ioat->regs->chansts,
drivers/event/cnxk/cnxk_tim_evdev.c +1 -1
index 6d59fdf909..bba70646fa 100644
@@ -268,7 +268,7 @@ cnxk_tim_ring_create(struct rte_event_timer_adapter *adptr)
 	sso_set_priv_mem_fn(dev->event_dev, NULL);
 
 	plt_tim_dbg(
-		"Total memory used %" PRIu64 "MB\n",
+		"Total memory used %" PRIu64 "MB",
 		(uint64_t)(((tim_ring->nb_chunks * tim_ring->chunk_sz) +
 			    (tim_ring->nb_bkts * sizeof(struct cnxk_tim_bkt))) /
 			   BIT_ULL(20)));
drivers/event/dpaa2/dpaa2_eventdev.c +7 -7
index 1273455673..f0b2c7de99 100644
@@ -74,7 +74,7 @@ dpaa2_eventdev_enqueue_burst(void *port, const struct rte_event ev[],
 		ret = dpaa2_affine_qbman_swp();
 		if (ret < 0) {
 			DPAA2_EVENTDEV_ERR(
-				"Failed to allocate IO portal, tid: %d\n",
+				"Failed to allocate IO portal, tid: %d",
 				rte_gettid());
 			return 0;
 		}
@@ -276,7 +276,7 @@ dpaa2_eventdev_dequeue_burst(void *port, struct rte_event ev[],
 		ret = dpaa2_affine_qbman_swp();
 		if (ret < 0) {
 			DPAA2_EVENTDEV_ERR(
-				"Failed to allocate IO portal, tid: %d\n",
+				"Failed to allocate IO portal, tid: %d",
 				rte_gettid());
 			return 0;
 		}
@@ -851,7 +851,7 @@ dpaa2_eventdev_crypto_queue_add_all(const struct rte_eventdev *dev,
 	for (i = 0; i < cryptodev->data->nb_queue_pairs; i++) {
 		ret = dpaa2_sec_eventq_attach(cryptodev, i, dpcon, ev);
 		if (ret) {
-			DPAA2_EVENTDEV_ERR("dpaa2_sec_eventq_attach failed: ret %d\n",
+			DPAA2_EVENTDEV_ERR("dpaa2_sec_eventq_attach failed: ret %d",
 				    ret);
 			goto fail;
 		}
@@ -885,7 +885,7 @@ dpaa2_eventdev_crypto_queue_add(const struct rte_eventdev *dev,
 				      dpcon, &conf->ev);
 	if (ret) {
 		DPAA2_EVENTDEV_ERR(
-			"dpaa2_sec_eventq_attach failed: ret: %d\n", ret);
+			"dpaa2_sec_eventq_attach failed: ret: %d", ret);
 		return ret;
 	}
 	return 0;
@@ -905,7 +905,7 @@ dpaa2_eventdev_crypto_queue_del_all(const struct rte_eventdev *dev,
 		ret = dpaa2_sec_eventq_detach(cdev, i);
 		if (ret) {
 			DPAA2_EVENTDEV_ERR(
-				"dpaa2_sec_eventq_detach failed:ret %d\n", ret);
+				"dpaa2_sec_eventq_detach failed:ret %d", ret);
 			return ret;
 		}
 	}
@@ -928,7 +928,7 @@ dpaa2_eventdev_crypto_queue_del(const struct rte_eventdev *dev,
 	ret = dpaa2_sec_eventq_detach(cryptodev, rx_queue_id);
 	if (ret) {
 		DPAA2_EVENTDEV_ERR(
-			"dpaa2_sec_eventq_detach failed: ret: %d\n", ret);
+			"dpaa2_sec_eventq_detach failed: ret: %d", ret);
 		return ret;
 	}
 
@@ -1161,7 +1161,7 @@ dpaa2_eventdev_destroy(const char *name)
 
 	eventdev = rte_event_pmd_get_named_dev(name);
 	if (eventdev == NULL) {
-		RTE_EDEV_LOG_ERR("eventdev with name %s not allocated", name);
+		DPAA2_EVENTDEV_ERR("eventdev with name %s not allocated", name);
 		return -1;
 	}
 
drivers/event/octeontx/timvf_evdev.c +1 -1
index 090b3ed183..82f17144a6 100644
@@ -196,7 +196,7 @@ timvf_ring_start(const struct rte_event_timer_adapter *adptr)
 	timr->tck_int = NSEC2CLK(timr->tck_nsec, rte_get_timer_hz());
 	timr->fast_div = rte_reciprocal_value_u64(timr->tck_int);
 	timvf_log_info("nb_bkts %d min_ns %"PRIu64" min_cyc %"PRIu64""
-			" maxtmo %"PRIu64"\n",
+			" maxtmo %"PRIu64,
 			timr->nb_bkts, timr->tck_nsec, interval,
 			timr->max_tout);
 
drivers/event/opdl/opdl_evdev.c +15 -15
index b34a5fcacd..25853166bf 100644
@@ -99,7 +99,7 @@ opdl_port_link(struct rte_eventdev *dev,
 
 	if (unlikely(dev->data->dev_started)) {
 		PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-			     "Attempt to link queue (%u) to port %d while device started\n",
+			     "Attempt to link queue (%u) to port %d while device started",
 			     dev->data->dev_id,
 				queues[0],
 				p->id);
@@ -110,7 +110,7 @@ opdl_port_link(struct rte_eventdev *dev,
 	/* Max of 1 queue per port */
 	if (num > 1) {
 		PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-			     "Attempt to link more than one queue (%u) to port %d requested\n",
+			     "Attempt to link more than one queue (%u) to port %d requested",
 			     dev->data->dev_id,
 				num,
 				p->id);
@@ -120,7 +120,7 @@ opdl_port_link(struct rte_eventdev *dev,
 
 	if (!p->configured) {
 		PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-			     "port %d not configured, cannot link to %u\n",
+			     "port %d not configured, cannot link to %u",
 			     dev->data->dev_id,
 				p->id,
 				queues[0]);
@@ -130,7 +130,7 @@ opdl_port_link(struct rte_eventdev *dev,
 
 	if (p->external_qid != OPDL_INVALID_QID) {
 		PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-			     "port %d already linked to queue %u, cannot link to %u\n",
+			     "port %d already linked to queue %u, cannot link to %u",
 			     dev->data->dev_id,
 				p->id,
 				p->external_qid,
@@ -157,7 +157,7 @@ opdl_port_unlink(struct rte_eventdev *dev,
 
 	if (unlikely(dev->data->dev_started)) {
 		PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-			     "Attempt to unlink queue (%u) to port %d while device started\n",
+			     "Attempt to unlink queue (%u) to port %d while device started",
 			     dev->data->dev_id,
 			     queues[0],
 			     p->id);
@@ -188,7 +188,7 @@ opdl_port_setup(struct rte_eventdev *dev,
 	/* Check if port already configured */
 	if (p->configured) {
 		PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-			     "Attempt to setup port %d which is already setup\n",
+			     "Attempt to setup port %d which is already setup",
 			     dev->data->dev_id,
 			     p->id);
 		return -EDQUOT;
@@ -244,7 +244,7 @@ opdl_queue_setup(struct rte_eventdev *dev,
 	/* Extra sanity check, probably not needed */
 	if (queue_id == OPDL_INVALID_QID) {
 		PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-			     "Invalid queue id %u requested\n",
+			     "Invalid queue id %u requested",
 			     dev->data->dev_id,
 			     queue_id);
 		return -EINVAL;
@@ -252,7 +252,7 @@ opdl_queue_setup(struct rte_eventdev *dev,
 
 	if (device->nb_q_md > device->max_queue_nb) {
 		PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-			     "Max number of queues %u exceeded by request %u\n",
+			     "Max number of queues %u exceeded by request %u",
 			     dev->data->dev_id,
 			     device->max_queue_nb,
 			     device->nb_q_md);
@@ -262,7 +262,7 @@ opdl_queue_setup(struct rte_eventdev *dev,
 	if (RTE_EVENT_QUEUE_CFG_ALL_TYPES
 	    & conf->event_queue_cfg) {
 		PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-			     "QUEUE_CFG_ALL_TYPES not supported\n",
+			     "QUEUE_CFG_ALL_TYPES not supported",
 			     dev->data->dev_id);
 		return -ENOTSUP;
 	} else if (RTE_EVENT_QUEUE_CFG_SINGLE_LINK
@@ -281,7 +281,7 @@ opdl_queue_setup(struct rte_eventdev *dev,
 			break;
 		default:
 			PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-				     "Unknown queue type %d requested\n",
+				     "Unknown queue type %d requested",
 				     dev->data->dev_id,
 				     conf->event_queue_cfg);
 			return -EINVAL;
@@ -292,7 +292,7 @@ opdl_queue_setup(struct rte_eventdev *dev,
 	for (i = 0; i < device->nb_q_md; i++) {
 		if (device->q_md[i].ext_id == queue_id) {
 			PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-				     "queue id %u already setup\n",
+				     "queue id %u already setup",
 				     dev->data->dev_id,
 				     queue_id);
 			return -EINVAL;
@@ -352,7 +352,7 @@ opdl_dev_configure(const struct rte_eventdev *dev)
 
 	if (conf->event_dev_cfg & RTE_EVENT_DEV_CFG_PER_DEQUEUE_TIMEOUT) {
 		PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : "
-			     "DEQUEUE_TIMEOUT not supported\n",
+			     "DEQUEUE_TIMEOUT not supported",
 			     dev->data->dev_id);
 		return -ENOTSUP;
 	}
@@ -662,7 +662,7 @@ opdl_probe(struct rte_vdev_device *vdev)
 
 		if (!kvlist) {
 			PMD_DRV_LOG(INFO,
-					"Ignoring unsupported parameters when creating device '%s'\n",
+					"Ignoring unsupported parameters when creating device '%s'",
 					name);
 		} else {
 			int ret = rte_kvargs_process(kvlist, NUMA_NODE_ARG,
@@ -709,7 +709,7 @@ opdl_probe(struct rte_vdev_device *vdev)
 
 	PMD_DRV_LOG(INFO, "DEV_ID:[%02d] : "
 		      "Success - creating eventdev device %s, numa_node:[%d], do_validation:[%s]"
-			  " , self_test:[%s]\n",
+			  " , self_test:[%s]",
 		      dev->data->dev_id,
 		      name,
 		      socket_id,
@@ -753,7 +753,7 @@ opdl_remove(struct rte_vdev_device *vdev)
 	if (name == NULL)
 		return -EINVAL;
 
-	PMD_DRV_LOG(INFO, "Closing eventdev opdl device %s\n", name);
+	PMD_DRV_LOG(INFO, "Closing eventdev opdl device %s", name);
 
 	return rte_event_pmd_vdev_uninit(name);
 }
drivers/event/opdl/opdl_test.c +58 -58

221 lines not on this page · raw message

drivers/event/sw/sw_evdev.c +11 -11
index 19a52afc7d..7913bc547e 100644

Lines of this file are not shown. View the raw message.

drivers/event/sw/sw_evdev_xstats.c +2 -2
index fbac8f3ab5..076b982ab8 100644

Lines of this file are not shown. View the raw message.

drivers/mempool/dpaa2/dpaa2_hw_mempool.c +4 -4
index 42e17d984c..886fb7fbb0 100644

Lines of this file are not shown. View the raw message.

drivers/mempool/octeontx/octeontx_fpavf.c +10 -12
index 1513c632c6..966fee8bfe 100644

Lines of this file are not shown. View the raw message.

drivers/mempool/octeontx/rte_mempool_octeontx.c +3 -3
index f4de1c8412..631e521b58 100644

Lines of this file are not shown. View the raw message.

drivers/ml/cnxk/cn10k_ml_dev.c +16 -16
index 41f3b7a95d..3c328d9d0e 100644

Lines of this file are not shown. View the raw message.

drivers/ml/cnxk/cnxk_ml_ops.c +10 -10
index 971362b242..7bd73727e1 100644

Lines of this file are not shown. View the raw message.

drivers/net/atlantic/atl_rxtx.c +2 -2
index cb6f8141a8..0f367faad5 100644

Lines of this file are not shown. View the raw message.

drivers/net/atlantic/hw_atl/hw_atl_utils.c +6 -6
index 84d11ab3a5..06d79115b9 100644

Lines of this file are not shown. View the raw message.

drivers/net/axgbe/axgbe_ethdev.c +1 -1
index 17b7b5c543..5448a5f3d7 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnx2x/bnx2x.c +4 -4
index 597ee43359..3153cc4d80 100644

Lines of this file are not shown. View the raw message.

drivers/net/cnxk/cn10k_ethdev.c +1 -1
index 55ed54bb0f..ad6bc1ec21 100644

Lines of this file are not shown. View the raw message.

drivers/net/cnxk/cn9k_ethdev.c +1 -1
index ea92b1dcb6..84c88655f8 100644

Lines of this file are not shown. View the raw message.

drivers/net/cnxk/cnxk_eswitch_devargs.c +1 -1
index 8167ce673a..655813c71a 100644

Lines of this file are not shown. View the raw message.

drivers/net/cnxk/cnxk_ethdev.c +2 -2
index 38746c81c5..33bac55704 100644

Lines of this file are not shown. View the raw message.

drivers/net/cnxk/cnxk_ethdev_mcs.c +7 -7
index 06ef7c98f3..119060bcf3 100644

Lines of this file are not shown. View the raw message.

drivers/net/cnxk/cnxk_ethdev_ops.c +1 -1
index b1093dd584..5b0948e07a 100644

Lines of this file are not shown. View the raw message.

drivers/net/cnxk/cnxk_rep.c +4 -4
index ca0637bde5..652d419ad8 100644

Lines of this file are not shown. View the raw message.

drivers/net/cnxk/cnxk_rep.h +1 -1
index ad89649702..aaae2d4e8f 100644

Lines of this file are not shown. View the raw message.

drivers/net/cpfl/cpfl_ethdev.c +1 -1
index 222e178949..6f6707a0bd 100644

Lines of this file are not shown. View the raw message.

drivers/net/cpfl/cpfl_flow_parser.c +1 -1
index 40569ddc6f..011229a470 100644

Lines of this file are not shown. View the raw message.

drivers/net/cpfl/cpfl_fxp_rule.c +4 -4
index be34da9fa2..42553c9641 100644

Lines of this file are not shown. View the raw message.

drivers/net/dpaa2/dpaa2_ethdev.c +8 -8
index 449bbda7ca..88374ea905 100644

Lines of this file are not shown. View the raw message.

drivers/net/dpaa2/dpaa2_flow.c +18 -18
index 6c7bac4d48..62e350d736 100644

Lines of this file are not shown. View the raw message.

drivers/net/dpaa2/dpaa2_mux.c +2 -2
index 2ff1a98fda..7dd5a60966 100644

Lines of this file are not shown. View the raw message.

drivers/net/dpaa2/dpaa2_recycle.c +3 -3
index fbfdf360d1..4fde9b95a0 100644

Lines of this file are not shown. View the raw message.

drivers/net/dpaa2/dpaa2_rxtx.c +7 -7
index 23f7c4132d..b64232b88f 100644

Lines of this file are not shown. View the raw message.

drivers/net/dpaa2/dpaa2_sparser.c +4 -4
index 36a14526a5..59f7a172c6 100644

Lines of this file are not shown. View the raw message.

drivers/net/dpaa2/dpaa2_tm.c +12 -12
index cb854964b4..97d65e7181 100644

Lines of this file are not shown. View the raw message.

drivers/net/e1000/igb_ethdev.c +1 -1
index 095be27b08..1e0a483d4a 100644

Lines of this file are not shown. View the raw message.

drivers/net/enetc/enetc_ethdev.c +2 -2
index d02ee206f1..ffbecc407c 100644

Lines of this file are not shown. View the raw message.

drivers/net/enetfec/enet_ethdev.c +2 -2
index 898aad1c37..8c7067fbb5 100644

Lines of this file are not shown. View the raw message.

drivers/net/enetfec/enet_uio.c +5 -5
index 6539cbb354..9f4e896985 100644

Lines of this file are not shown. View the raw message.

drivers/net/enic/enic_ethdev.c +10 -10
index cad8db2f6f..c1dba0c0fd 100644

Lines of this file are not shown. View the raw message.

drivers/net/enic/enic_flow.c +10 -10
index e6c9ad442a..758000ea21 100644

Lines of this file are not shown. View the raw message.

drivers/net/enic/enic_vf_representor.c +8 -8
index 5d8d29135c..8469e06de9 100644

Lines of this file are not shown. View the raw message.

drivers/net/failsafe/failsafe_args.c +1 -1
index 3b867437d7..1b8f1d3050 100644

Lines of this file are not shown. View the raw message.

drivers/net/failsafe/failsafe_eal.c +1 -1
index d71b512f81..e79d3b4120 100644

Lines of this file are not shown. View the raw message.

drivers/net/failsafe/failsafe_ether.c +2 -2
index 031f3eb13f..dc4aba6e30 100644

Lines of this file are not shown. View the raw message.

drivers/net/failsafe/failsafe_intr.c +3 -3
index 969ded6ced..68b7310b85 100644

Lines of this file are not shown. View the raw message.

drivers/net/gve/base/gve_adminq.c +2 -2
index 09c6bff026..bcb983e4a0 100644

Lines of this file are not shown. View the raw message.

drivers/net/gve/gve_rx.c +1 -1
index 89b6ef384a..1f5fa3f1da 100644

Lines of this file are not shown. View the raw message.

drivers/net/gve/gve_tx.c +1 -1
index 658bfb972b..015ea9646b 100644

Lines of this file are not shown. View the raw message.

drivers/net/hinic/base/hinic_pmd_eqs.c +1 -1
index fecb653401..f0e1139a98 100644

Lines of this file are not shown. View the raw message.

drivers/net/hinic/base/hinic_pmd_mbox.c +3 -3
index 92a7cc1a11..a75a6953ad 100644

Lines of this file are not shown. View the raw message.

drivers/net/hinic/base/hinic_pmd_niccfg.c +4 -4
index 8c08d63286..a08020313f 100644

Lines of this file are not shown. View the raw message.

drivers/net/hinic/hinic_pmd_ethdev.c +2 -2
index d4978e0649..cb5c013b21 100644

Lines of this file are not shown. View the raw message.

drivers/net/hns3/hns3_dump.c +6 -6
index cb369be5be..a3b58e0a8f 100644

Lines of this file are not shown. View the raw message.

drivers/net/hns3/hns3_intr.c +6 -6
index 26fa2eb951..f7162ee7bc 100644

Lines of this file are not shown. View the raw message.

drivers/net/hns3/hns3_ptp.c +1 -1
index 894ac6dd71..c6e77d21cb 100644

Lines of this file are not shown. View the raw message.

drivers/net/hns3/hns3_regs.c +2 -2
index be1be6a89c..955bc7e3af 100644

Lines of this file are not shown. View the raw message.

drivers/net/i40e/i40e_ethdev.c +24 -27

51 lines not on this page · raw message

drivers/net/i40e/i40e_pf.c +4 -4
index 15d9ff868f..4a47a8f7ee 100644

Lines of this file are not shown. View the raw message.

drivers/net/i40e/i40e_rxtx.c +21 -21

42 lines not on this page · raw message

drivers/net/iavf/iavf_ethdev.c +6 -6
index 44276dcf38..c56fcfadf0 100644

Lines of this file are not shown. View the raw message.

drivers/net/iavf/iavf_rxtx.c +8 -8
index ecc31430d1..4850b9e381 100644

Lines of this file are not shown. View the raw message.

drivers/net/ice/ice_dcf_ethdev.c +2 -2
index 8f3a385ca5..91f4943a11 100644

Lines of this file are not shown. View the raw message.

drivers/net/ice/ice_dcf_vf_representor.c +7 -7
index af281f069a..564ff02fd8 100644

Lines of this file are not shown. View the raw message.

drivers/net/ice/ice_ethdev.c +25 -25

50 lines not on this page · raw message

drivers/net/ice/ice_fdir_filter.c +1 -1
index edd8cc8f1a..741107f939 100644

Lines of this file are not shown. View the raw message.

drivers/net/ice/ice_hash.c +4 -4
index b720e0f755..00d65bc637 100644

Lines of this file are not shown. View the raw message.

drivers/net/ice/ice_rxtx.c +9 -9
index f270498ed1..acd7539b5e 100644

Lines of this file are not shown. View the raw message.

drivers/net/ipn3ke/ipn3ke_ethdev.c +2 -2
index 2c15611a23..baae80d661 100644

Lines of this file are not shown. View the raw message.

drivers/net/ipn3ke/ipn3ke_flow.c +11 -12
index d20a29b9a2..a2f76268b5 100644

Lines of this file are not shown. View the raw message.

drivers/net/ipn3ke/ipn3ke_representor.c +10 -10
index 8145f1bb2a..feb57420c3 100644

Lines of this file are not shown. View the raw message.

drivers/net/ipn3ke/ipn3ke_tm.c +3 -7
index 0260227900..44a8b88699 100644

Lines of this file are not shown. View the raw message.

drivers/net/ixgbe/ixgbe_ethdev.c +2 -5
index d88d4065f1..357307b2e0 100644

Lines of this file are not shown. View the raw message.

drivers/net/ixgbe/ixgbe_ipsec.c +12 -12
index d331308556..3a666ba15f 100644

Lines of this file are not shown. View the raw message.

drivers/net/ixgbe/ixgbe_pf.c +9 -9
index 91ba395ac3..e967fe5e48 100644

Lines of this file are not shown. View the raw message.

drivers/net/ixgbe/rte_pmd_ixgbe.c +4 -4
index f76ef63921..15c28e7a3f 100644

Lines of this file are not shown. View the raw message.

drivers/net/memif/rte_eth_memif.c +1 -1
index 16da22b5c6..e220ffaf92 100644

Lines of this file are not shown. View the raw message.

drivers/net/mlx4/mlx4.c +2 -2
index c19db5c0eb..9c2872429f 100644

Lines of this file are not shown. View the raw message.

drivers/net/netvsc/hn_rxtx.c +2 -2
index 9bf1ec5509..297ff3fb31 100644

Lines of this file are not shown. View the raw message.

drivers/net/ngbe/base/ngbe_hw.c +1 -1
index e8dda8d460..29944f5070 100644

Lines of this file are not shown. View the raw message.

drivers/net/ngbe/ngbe_ethdev.c +1 -1
index 23a452cacd..6c45ffaad3 100644

Lines of this file are not shown. View the raw message.

drivers/net/ngbe/ngbe_pf.c +5 -5
index 947ae7fe94..bb62e2fbb7 100644

Lines of this file are not shown. View the raw message.

drivers/net/octeon_ep/cnxk_ep_tx.c +1 -1
index 45ea0b9c34..e84de5c1c7 100644

Lines of this file are not shown. View the raw message.

drivers/net/octeon_ep/cnxk_ep_vf.c +6 -6
index 39b28de2d0..d44ac211f1 100644

Lines of this file are not shown. View the raw message.

drivers/net/octeon_ep/otx2_ep_vf.c +9 -9
index 2aeebb4675..76f72c64c9 100644

Lines of this file are not shown. View the raw message.

drivers/net/octeon_ep/otx_ep_common.h +1 -1
index 73eb0c9d31..7d5dd91a77 100644

Lines of this file are not shown. View the raw message.

drivers/net/octeon_ep/otx_ep_ethdev.c +41 -41

82 lines not on this page · raw message

drivers/net/octeon_ep/otx_ep_mbox.c +15 -15
index 4118645dc7..c92adeaf9a 100644

Lines of this file are not shown. View the raw message.

drivers/net/octeon_ep/otx_ep_rxtx.c +37 -37

74 lines not on this page · raw message

drivers/net/octeon_ep/otx_ep_vf.c +10 -10
index 236b7a874c..7defb0f13d 100644

Lines of this file are not shown. View the raw message.

drivers/net/octeontx/base/octeontx_pkovf.c +1 -1
index 5d445dfb49..7aec84a813 100644

Lines of this file are not shown. View the raw message.

drivers/net/octeontx/octeontx_ethdev.c +2 -2
index 3c2154043c..c802b2c389 100644

Lines of this file are not shown. View the raw message.

drivers/net/pcap/pcap_ethdev.c +2 -2
index bfec085045..9626c343dc 100644

Lines of this file are not shown. View the raw message.

drivers/net/pfe/pfe_ethdev.c +11 -11
index eccaaa2448..725ffcb2bc 100644

Lines of this file are not shown. View the raw message.

drivers/net/pfe/pfe_hif.c +6 -6
index e2b23bbeb7..abb9cde996 100644

Lines of this file are not shown. View the raw message.

drivers/net/pfe/pfe_hif_lib.c +1 -1
index 6fe6d33d23..541ba365c6 100644

Lines of this file are not shown. View the raw message.

drivers/net/qede/qede_rxtx.c +33 -33

66 lines not on this page · raw message

drivers/net/thunderx/nicvf_ethdev.c +1 -1
index 609d95dcfa..4441a90bdf 100644

Lines of this file are not shown. View the raw message.

drivers/net/txgbe/txgbe_ethdev.c +2 -2
index 2fabb9fc4e..2834468764 100644

Lines of this file are not shown. View the raw message.

drivers/net/txgbe/txgbe_ipsec.c +12 -12
index f9f8108fb8..4af49dd802 100644

Lines of this file are not shown. View the raw message.

drivers/net/txgbe/txgbe_pf.c +10 -10
index 176f79005c..700632bd88 100644

Lines of this file are not shown. View the raw message.

drivers/net/virtio/virtio_user/vhost_vdpa.c +1 -1
index 3246b74e13..bc3e2a9af5 100644

Lines of this file are not shown. View the raw message.

drivers/net/virtio/virtio_user/virtio_user_dev.c +1 -1
index 48b872524a..e8642be86b 100644

Lines of this file are not shown. View the raw message.

drivers/net/vmxnet3/vmxnet3_ethdev.c +2 -2
index 467fb61137..78fac63ab6 100644

Lines of this file are not shown. View the raw message.

drivers/net/vmxnet3/vmxnet3_rxtx.c +1 -1
index 380f41f98b..e226641fdf 100644

Lines of this file are not shown. View the raw message.

drivers/raw/dpaa2_cmdif/dpaa2_cmdif.c +7 -7
index aeee4ac289..de8c024abb 100644

Lines of this file are not shown. View the raw message.

drivers/raw/ifpga/afu_pmd_n3000.c +1 -1
index 67b3941265..6aae1b224e 100644

Lines of this file are not shown. View the raw message.

drivers/raw/ifpga/ifpga_rawdev.c +47 -47

94 lines not on this page · raw message

drivers/regex/cn9k/cn9k_regexdev.c +1 -1
index e96cbf4141..aa809ab5bf 100644

Lines of this file are not shown. View the raw message.

drivers/vdpa/ifc/ifcvf_vdpa.c +5 -5
index f034bd59ba..2958368813 100644

Lines of this file are not shown. View the raw message.

drivers/vdpa/nfp/nfp_vdpa.c +1 -1
index cef80b5476..3e4247dbcb 100644

Lines of this file are not shown. View the raw message.

The rest of this diff is not shown. View the raw message.

Signature · 1 line
2.46.0

Part of the diff is not shown here. View the raw message.

#16 lore raw

PATCH 10/11 drivers: split multilines log messages

In reply to David Marchand

Prepare for RTE_LOG_LINE conversion.

---
 .../fpga_5gnr_fec/rte_fpga_5gnr_fec.c         | 251 +++++++++---------
 drivers/baseband/fpga_lte_fec/fpga_lte_fec.c  |  24 +-
 drivers/crypto/caam_jr/caam_jr.c              |   7 +-
 drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c   |  54 ++--
 drivers/crypto/virtio/virtio_cryptodev.c      |  10 +-
 drivers/net/bnxt/bnxt_hwrm.c                  |  16 +-
 drivers/net/dpaa/dpaa_ethdev.c                |   9 +-
 drivers/net/mlx4/mlx4_mr.c                    |  18 +-
 drivers/net/octeontx/octeontx_ethdev.c        |  22 +-
 drivers/net/virtio/virtio_cvq.c               |  19 +-
 .../net/virtio/virtio_user/virtio_user_dev.c  |  30 +--
 drivers/raw/cnxk_bphy/cnxk_bphy.c             |   2 +-
 12 files changed, 228 insertions(+), 234 deletions(-)
drivers/baseband/fpga_5gnr_fec/rte_fpga_5gnr_fec.c +124 -127
index 3e04e44ba2..b4a97de967 100644
@@ -100,49 +100,49 @@ print_static_reg_debug_info(void *mmio_base, uint8_t fpga_variant)
 static void
 vc_5gnr_print_dma_dec_desc_debug_info(union vc_5gnr_dma_desc *desc)
 {
-	rte_bbdev_log_debug("DMA response desc %p\n"
-			"\t-- done(%"PRIu32") | iter(%"PRIu32") | et_pass(%"PRIu32")"
-			" | crcb_pass (%"PRIu32") | error(%"PRIu32")\n"
-			"\t-- qm_idx(%"PRIu32") | max_iter(%"PRIu32") | "
-			"bg_idx (%"PRIu32") | harqin_en(%"PRIu32") | zc(%"PRIu32")\n"
-			"\t-- hbstroe_offset(%"PRIu32") | num_null (%"PRIu32") "
-			"| irq_en(%"PRIu32")\n"
-			"\t-- ncb(%"PRIu32") | desc_idx (%"PRIu32") | "
-			"drop_crc24b(%"PRIu32") | RV (%"PRIu32")\n"
-			"\t-- crc24b_ind(%"PRIu32") | et_dis (%"PRIu32")\n"
-			"\t-- harq_input_length(%"PRIu32") | rm_e(%"PRIu32")\n"
-			"\t-- cbs_in_op(%"PRIu32") | in_add (0x%08"PRIx32"%08"PRIx32")"
-			"| out_add (0x%08"PRIx32"%08"PRIx32")",
-			desc,
+	rte_bbdev_log_debug("DMA response desc %p",
+			desc);
+	rte_bbdev_log_debug("\t-- done(%"PRIu32") | iter(%"PRIu32") | et_pass(%"PRIu32")"
+			" | crcb_pass (%"PRIu32") | error(%"PRIu32")",
 			(uint32_t)desc->dec_req.done,
 			(uint32_t)desc->dec_req.iter,
 			(uint32_t)desc->dec_req.et_pass,
 			(uint32_t)desc->dec_req.crcb_pass,
-			(uint32_t)desc->dec_req.error,
+			(uint32_t)desc->dec_req.error);
+	rte_bbdev_log_debug("\t-- qm_idx(%"PRIu32") | max_iter(%"PRIu32") | "
+			"bg_idx (%"PRIu32") | harqin_en(%"PRIu32") | zc(%"PRIu32")",
 			(uint32_t)desc->dec_req.qm_idx,
 			(uint32_t)desc->dec_req.max_iter,
 			(uint32_t)desc->dec_req.bg_idx,
 			(uint32_t)desc->dec_req.harqin_en,
-			(uint32_t)desc->dec_req.zc,
+			(uint32_t)desc->dec_req.zc);
+	rte_bbdev_log_debug("\t-- hbstroe_offset(%"PRIu32") | num_null (%"PRIu32") "
+			"| irq_en(%"PRIu32")",
 			(uint32_t)desc->dec_req.hbstroe_offset,
 			(uint32_t)desc->dec_req.num_null,
-			(uint32_t)desc->dec_req.irq_en,
+			(uint32_t)desc->dec_req.irq_en);
+	rte_bbdev_log_debug("\t-- ncb(%"PRIu32") | desc_idx (%"PRIu32") | "
+			"drop_crc24b(%"PRIu32") | RV (%"PRIu32")",
 			(uint32_t)desc->dec_req.ncb,
 			(uint32_t)desc->dec_req.desc_idx,
 			(uint32_t)desc->dec_req.drop_crc24b,
-			(uint32_t)desc->dec_req.rv,
+			(uint32_t)desc->dec_req.rv);
+	rte_bbdev_log_debug("\t-- crc24b_ind(%"PRIu32") | et_dis (%"PRIu32")",
 			(uint32_t)desc->dec_req.crc24b_ind,
-			(uint32_t)desc->dec_req.et_dis,
+			(uint32_t)desc->dec_req.et_dis);
+	rte_bbdev_log_debug("\t-- harq_input_length(%"PRIu32") | rm_e(%"PRIu32")",
 			(uint32_t)desc->dec_req.harq_input_length,
-			(uint32_t)desc->dec_req.rm_e,
+			(uint32_t)desc->dec_req.rm_e);
+	rte_bbdev_log_debug("\t-- cbs_in_op(%"PRIu32") | in_add (0x%08"PRIx32"%08"PRIx32")"
+			"| out_add (0x%08"PRIx32"%08"PRIx32")",
 			(uint32_t)desc->dec_req.cbs_in_op,
 			(uint32_t)desc->dec_req.in_addr_hi,
 			(uint32_t)desc->dec_req.in_addr_lw,
 			(uint32_t)desc->dec_req.out_addr_hi,
 			(uint32_t)desc->dec_req.out_addr_lw);
 	uint32_t *word = (uint32_t *) desc;
-	rte_bbdev_log_debug("%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n"
-			"%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n",
+	rte_bbdev_log_debug("%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32", "
+			"%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32,
 			word[0], word[1], word[2], word[3],
 			word[4], word[5], word[6], word[7]);
 }
@@ -151,37 +151,12 @@ vc_5gnr_print_dma_dec_desc_debug_info(union vc_5gnr_dma_desc *desc)
 static void
 agx100_print_dma_dec_desc_debug_info(union agx100_dma_desc *desc)
 {
-	rte_bbdev_log_debug("DMA response desc %p\n"
-			"\t-- done(%"PRIu32") | tb_crc_pass(%"PRIu32") | cb_crc_all_pass(%"PRIu32")"
+	rte_bbdev_log_debug("DMA response desc %p",
+			desc);
+	rte_bbdev_log_debug("\t-- done(%"PRIu32") | tb_crc_pass(%"PRIu32") | cb_crc_all_pass(%"PRIu32")"
 			" | cb_all_et_pass(%"PRIu32") | max_iter_ret(%"PRIu32") |"
 			"cgb_crc_bitmap(%"PRIu32") | error_msg(%"PRIu32") | error_code(%"PRIu32") |"
-			"et_dis (%"PRIu32") | harq_in_en(%"PRIu32") | max_iter(%"PRIu32")\n"
-			"\t-- ncb(%"PRIu32") | bg_idx (%"PRIu32") | qm_idx (%"PRIu32")"
-			"| zc(%"PRIu32") | rv(%"PRIu32") | int_en(%"PRIu32")\n"
-			"\t-- max_cbg(%"PRIu32") | cbgti(%"PRIu32") | cbgfi(%"PRIu32") |"
-			"cbgs(%"PRIu32") | desc_idx(%"PRIu32")\n"
-			"\t-- ca(%"PRIu32") | c(%"PRIu32") | llr_pckg(%"PRIu32") |"
-			"syndrome_check_mode(%"PRIu32") | num_null(%"PRIu32")\n"
-			"\t-- ea(%"PRIu32") | eba(%"PRIu32")\n"
-			"\t-- hbstore_offset_out(%"PRIu32")\n"
-			"\t-- hbstore_offset_in(%"PRIu32") | en_slice_ts(%"PRIu32") |"
-			"en_host_ts(%"PRIu32") | en_cb_wr_status(%"PRIu32")"
-			" | en_output_sg(%"PRIu32") | en_input_sg(%"PRIu32") | tb_cb(%"PRIu32")"
-			" | crc24b_ind(%"PRIu32")| drop_crc24b(%"PRIu32")\n"
-			"\t-- harq_input_length_a(%"PRIu32") | harq_input_length_b(%"PRIu32")\n"
-			"\t-- input_slice_table_addr_lo(%"PRIu32")"
-			" | input_start_addr_lo(%"PRIu32")\n"
-			"\t-- input_slice_table_addr_hi(%"PRIu32")"
-			" | input_start_addr_hi(%"PRIu32")\n"
-			"\t-- input_slice_num(%"PRIu32") | input_length(%"PRIu32")\n"
-			"\t-- output_slice_table_addr_lo(%"PRIu32")"
-			" | output_start_addr_lo(%"PRIu32")\n"
-			"\t-- output_slice_table_addr_hi(%"PRIu32")"
-			" | output_start_addr_hi(%"PRIu32")\n"
-			"\t-- output_slice_num(%"PRIu32") | output_length(%"PRIu32")\n"
-			"\t-- enqueue_timestamp(%"PRIu32")\n"
-			"\t-- completion_timestamp(%"PRIu32")\n",
-			desc,
+			"et_dis (%"PRIu32") | harq_in_en(%"PRIu32") | max_iter(%"PRIu32")",
 			(uint32_t)desc->dec_req.done,
 			(uint32_t)desc->dec_req.tb_crc_pass,
 			(uint32_t)desc->dec_req.cb_crc_all_pass,
@@ -192,26 +167,38 @@ agx100_print_dma_dec_desc_debug_info(union agx100_dma_desc *desc)
 			(uint32_t)desc->dec_req.error_code,
 			(uint32_t)desc->dec_req.et_dis,
 			(uint32_t)desc->dec_req.harq_in_en,
-			(uint32_t)desc->dec_req.max_iter,
+			(uint32_t)desc->dec_req.max_iter);
+	rte_bbdev_log_debug("\t-- ncb(%"PRIu32") | bg_idx (%"PRIu32") | qm_idx (%"PRIu32")"
+			"| zc(%"PRIu32") | rv(%"PRIu32") | int_en(%"PRIu32")",
 			(uint32_t)desc->dec_req.ncb,
 			(uint32_t)desc->dec_req.bg_idx,
 			(uint32_t)desc->dec_req.qm_idx,
 			(uint32_t)desc->dec_req.zc,
 			(uint32_t)desc->dec_req.rv,
-			(uint32_t)desc->dec_req.int_en,
+			(uint32_t)desc->dec_req.int_en);
+	rte_bbdev_log_debug("\t-- max_cbg(%"PRIu32") | cbgti(%"PRIu32") | cbgfi(%"PRIu32") |"
+			"cbgs(%"PRIu32") | desc_idx(%"PRIu32")",
 			(uint32_t)desc->dec_req.max_cbg,
 			(uint32_t)desc->dec_req.cbgti,
 			(uint32_t)desc->dec_req.cbgfi,
 			(uint32_t)desc->dec_req.cbgs,
-			(uint32_t)desc->dec_req.desc_idx,
+			(uint32_t)desc->dec_req.desc_idx);
+	rte_bbdev_log_debug("\t-- ca(%"PRIu32") | c(%"PRIu32") | llr_pckg(%"PRIu32") |"
+			"syndrome_check_mode(%"PRIu32") | num_null(%"PRIu32")",
 			(uint32_t)desc->dec_req.ca,
 			(uint32_t)desc->dec_req.c,
 			(uint32_t)desc->dec_req.llr_pckg,
 			(uint32_t)desc->dec_req.syndrome_check_mode,
-			(uint32_t)desc->dec_req.num_null,
+			(uint32_t)desc->dec_req.num_null);
+	rte_bbdev_log_debug("\t-- ea(%"PRIu32") | eba(%"PRIu32")",
 			(uint32_t)desc->dec_req.ea,
-			(uint32_t)desc->dec_req.eba,
-			(uint32_t)desc->dec_req.hbstore_offset_out,
+			(uint32_t)desc->dec_req.eba);
+	rte_bbdev_log_debug("\t-- hbstore_offset_out(%"PRIu32")",
+			(uint32_t)desc->dec_req.hbstore_offset_out);
+	rte_bbdev_log_debug("\t-- hbstore_offset_in(%"PRIu32") | en_slice_ts(%"PRIu32") |"
+			"en_host_ts(%"PRIu32") | en_cb_wr_status(%"PRIu32")"
+			" | en_output_sg(%"PRIu32") | en_input_sg(%"PRIu32") | tb_cb(%"PRIu32")"
+			" | crc24b_ind(%"PRIu32")| drop_crc24b(%"PRIu32")",
 			(uint32_t)desc->dec_req.hbstore_offset_in,
 			(uint32_t)desc->dec_req.en_slice_ts,
 			(uint32_t)desc->dec_req.en_host_ts,
@@ -220,29 +207,42 @@ agx100_print_dma_dec_desc_debug_info(union agx100_dma_desc *desc)
 			(uint32_t)desc->dec_req.en_input_sg,
 			(uint32_t)desc->dec_req.tb_cb,
 			(uint32_t)desc->dec_req.crc24b_ind,
-			(uint32_t)desc->dec_req.drop_crc24b,
+			(uint32_t)desc->dec_req.drop_crc24b);
+	rte_bbdev_log_debug("\t-- harq_input_length_a(%"PRIu32") | harq_input_length_b(%"PRIu32")",
 			(uint32_t)desc->dec_req.harq_input_length_a,
-			(uint32_t)desc->dec_req.harq_input_length_b,
+			(uint32_t)desc->dec_req.harq_input_length_b);
+	rte_bbdev_log_debug("\t-- input_slice_table_addr_lo(%"PRIu32")"
+			" | input_start_addr_lo(%"PRIu32")",
 			(uint32_t)desc->dec_req.input_slice_table_addr_lo,
-			(uint32_t)desc->dec_req.input_start_addr_lo,
+			(uint32_t)desc->dec_req.input_start_addr_lo);
+	rte_bbdev_log_debug("\t-- input_slice_table_addr_hi(%"PRIu32")"
+			" | input_start_addr_hi(%"PRIu32")",
 			(uint32_t)desc->dec_req.input_slice_table_addr_hi,
-			(uint32_t)desc->dec_req.input_start_addr_hi,
+			(uint32_t)desc->dec_req.input_start_addr_hi);
+	rte_bbdev_log_debug("\t-- input_slice_num(%"PRIu32") | input_length(%"PRIu32")",
 			(uint32_t)desc->dec_req.input_slice_num,
-			(uint32_t)desc->dec_req.input_length,
+			(uint32_t)desc->dec_req.input_length);
+	rte_bbdev_log_debug("\t-- output_slice_table_addr_lo(%"PRIu32")"
+			" | output_start_addr_lo(%"PRIu32")",
 			(uint32_t)desc->dec_req.output_slice_table_addr_lo,
-			(uint32_t)desc->dec_req.output_start_addr_lo,
+			(uint32_t)desc->dec_req.output_start_addr_lo);
+	rte_bbdev_log_debug("\t-- output_slice_table_addr_hi(%"PRIu32")"
+			" | output_start_addr_hi(%"PRIu32")",
 			(uint32_t)desc->dec_req.output_slice_table_addr_hi,
-			(uint32_t)desc->dec_req.output_start_addr_hi,
+			(uint32_t)desc->dec_req.output_start_addr_hi);
+	rte_bbdev_log_debug("\t-- output_slice_num(%"PRIu32") | output_length(%"PRIu32")",
 			(uint32_t)desc->dec_req.output_slice_num,
-			(uint32_t)desc->dec_req.output_length,
-			(uint32_t)desc->dec_req.enqueue_timestamp,
+			(uint32_t)desc->dec_req.output_length);
+	rte_bbdev_log_debug("\t-- enqueue_timestamp(%"PRIu32")",
+			(uint32_t)desc->dec_req.enqueue_timestamp);
+	rte_bbdev_log_debug("\t-- completion_timestamp(%"PRIu32")",
 			(uint32_t)desc->dec_req.completion_timestamp);
 
 	uint32_t *word = (uint32_t *) desc;
-	rte_bbdev_log_debug("%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n"
-			"%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n"
-			"%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n"
-			"%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n",
+	rte_bbdev_log_debug("%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32", "
+			"%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32", "
+			"%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32", "
+			"%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32,
 			word[0], word[1], word[2], word[3],
 			word[4], word[5], word[6], word[7],
 			word[8], word[9], word[10], word[11],
@@ -253,31 +253,28 @@ agx100_print_dma_dec_desc_debug_info(union agx100_dma_desc *desc)
 static void
 vc_5gnr_print_dma_enc_desc_debug_info(union vc_5gnr_dma_desc *desc)
 {
-	rte_bbdev_log_debug("DMA response desc %p\n"
-			"%"PRIu32" %"PRIu32"\n"
-			"K' %"PRIu32" E %"PRIu32" desc %"PRIu32" Z %"PRIu32"\n"
-			"BG %"PRIu32" Qm %"PRIu32" CRC %"PRIu32" IRQ %"PRIu32"\n"
-			"k0 %"PRIu32" Ncb %"PRIu32" F %"PRIu32"\n",
-			desc,
+	rte_bbdev_log_debug("DMA response desc %p",
+			desc);
+	rte_bbdev_log_debug("%"PRIu32" %"PRIu32,
 			(uint32_t)desc->enc_req.done,
-			(uint32_t)desc->enc_req.error,
-
+			(uint32_t)desc->enc_req.error);
+	rte_bbdev_log_debug("K' %"PRIu32" E %"PRIu32" desc %"PRIu32" Z %"PRIu32,
 			(uint32_t)desc->enc_req.k_,
 			(uint32_t)desc->enc_req.rm_e,
 			(uint32_t)desc->enc_req.desc_idx,
-			(uint32_t)desc->enc_req.zc,
-
+			(uint32_t)desc->enc_req.zc);
+	rte_bbdev_log_debug("BG %"PRIu32" Qm %"PRIu32" CRC %"PRIu32" IRQ %"PRIu32,
 			(uint32_t)desc->enc_req.bg_idx,
 			(uint32_t)desc->enc_req.qm_idx,
 			(uint32_t)desc->enc_req.crc_en,
-			(uint32_t)desc->enc_req.irq_en,
-
+			(uint32_t)desc->enc_req.irq_en);
+	rte_bbdev_log_debug("k0 %"PRIu32" Ncb %"PRIu32" F %"PRIu32,
 			(uint32_t)desc->enc_req.k0,
 			(uint32_t)desc->enc_req.ncb,
 			(uint32_t)desc->enc_req.num_null);
 	uint32_t *word = (uint32_t *) desc;
-	rte_bbdev_log_debug("%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n"
-			"%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n",
+	rte_bbdev_log_debug("%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32", "
+			"%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32,
 			word[0], word[1], word[2], word[3],
 			word[4], word[5], word[6], word[7]);
 }
@@ -286,49 +283,37 @@ vc_5gnr_print_dma_enc_desc_debug_info(union vc_5gnr_dma_desc *desc)
 static void
 agx100_print_dma_enc_desc_debug_info(union agx100_dma_desc *desc)
 {
-	rte_bbdev_log_debug("DMA response desc %p\n"
-			"\t-- done(%"PRIu32") | error_msg(%"PRIu32") | error_code(%"PRIu32")\n"
-			"\t-- ncb(%"PRIu32") | bg_idx (%"PRIu32") | qm_idx (%"PRIu32")"
-			"| zc(%"PRIu32") | rv(%"PRIu32") | int_en(%"PRIu32")\n"
-			"\t-- max_cbg(%"PRIu32") | cbgti(%"PRIu32") | cbgs(%"PRIu32") | "
-			"desc_idx(%"PRIu32")\n"
-			"\t-- ca(%"PRIu32") | c(%"PRIu32") | num_null(%"PRIu32")\n"
-			"\t-- ea(%"PRIu32")\n"
-			"\t-- eb(%"PRIu32")\n"
-			"\t-- k_(%"PRIu32") | en_slice_ts(%"PRIu32") | en_host_ts(%"PRIu32") | "
-			"en_cb_wr_status(%"PRIu32") | en_output_sg(%"PRIu32") | "
-			"en_input_sg(%"PRIu32") | tb_cb(%"PRIu32") | crc_en(%"PRIu32")\n"
-			"\t-- input_slice_table_addr_lo(%"PRIu32")"
-			" | input_start_addr_lo(%"PRIu32")\n"
-			"\t-- input_slice_table_addr_hi(%"PRIu32")"
-			" | input_start_addr_hi(%"PRIu32")\n"
-			"\t-- input_slice_num(%"PRIu32") | input_length(%"PRIu32")\n"
-			"\t-- output_slice_table_addr_lo(%"PRIu32")"
-			" | output_start_addr_lo(%"PRIu32")\n"
-			"\t-- output_slice_table_addr_hi(%"PRIu32")"
-			" | output_start_addr_hi(%"PRIu32")\n"
-			"\t-- output_slice_num(%"PRIu32") | output_length(%"PRIu32")\n"
-			"\t-- enqueue_timestamp(%"PRIu32")\n"
-			"\t-- completion_timestamp(%"PRIu32")\n",
-			desc,
+	rte_bbdev_log_debug("DMA response desc %p",
+			desc);
+	rte_bbdev_log_debug("\t-- done(%"PRIu32") | error_msg(%"PRIu32") | error_code(%"PRIu32")",
 			(uint32_t)desc->enc_req.done,
 			(uint32_t)desc->enc_req.error_msg,
-			(uint32_t)desc->enc_req.error_code,
+			(uint32_t)desc->enc_req.error_code);
+	rte_bbdev_log_debug("\t-- ncb(%"PRIu32") | bg_idx (%"PRIu32") | qm_idx (%"PRIu32")"
+			"| zc(%"PRIu32") | rv(%"PRIu32") | int_en(%"PRIu32")",
 			(uint32_t)desc->enc_req.ncb,
 			(uint32_t)desc->enc_req.bg_idx,
 			(uint32_t)desc->enc_req.qm_idx,
 			(uint32_t)desc->enc_req.zc,
 			(uint32_t)desc->enc_req.rv,
-			(uint32_t)desc->enc_req.int_en,
+			(uint32_t)desc->enc_req.int_en);
+	rte_bbdev_log_debug("\t-- max_cbg(%"PRIu32") | cbgti(%"PRIu32") | cbgs(%"PRIu32") | "
+			"desc_idx(%"PRIu32")",
 			(uint32_t)desc->enc_req.max_cbg,
 			(uint32_t)desc->enc_req.cbgti,
 			(uint32_t)desc->enc_req.cbgs,
-			(uint32_t)desc->enc_req.desc_idx,
+			(uint32_t)desc->enc_req.desc_idx);
+	rte_bbdev_log_debug("\t-- ca(%"PRIu32") | c(%"PRIu32") | num_null(%"PRIu32")",
 			(uint32_t)desc->enc_req.ca,
 			(uint32_t)desc->enc_req.c,
-			(uint32_t)desc->enc_req.num_null,
-			(uint32_t)desc->enc_req.ea,
-			(uint32_t)desc->enc_req.eb,
+			(uint32_t)desc->enc_req.num_null);
+	rte_bbdev_log_debug("\t-- ea(%"PRIu32")",
+			(uint32_t)desc->enc_req.ea);
+	rte_bbdev_log_debug("\t-- eb(%"PRIu32")",
+			(uint32_t)desc->enc_req.eb);
+	rte_bbdev_log_debug("\t-- k_(%"PRIu32") | en_slice_ts(%"PRIu32") | en_host_ts(%"PRIu32") | "
+			"en_cb_wr_status(%"PRIu32") | en_output_sg(%"PRIu32") | "
+			"en_input_sg(%"PRIu32") | tb_cb(%"PRIu32") | crc_en(%"PRIu32")",
 			(uint32_t)desc->enc_req.k_,
 			(uint32_t)desc->enc_req.en_slice_ts,
 			(uint32_t)desc->enc_req.en_host_ts,
@@ -336,27 +321,39 @@ agx100_print_dma_enc_desc_debug_info(union agx100_dma_desc *desc)
 			(uint32_t)desc->enc_req.en_output_sg,
 			(uint32_t)desc->enc_req.en_input_sg,
 			(uint32_t)desc->enc_req.tb_cb,
-			(uint32_t)desc->enc_req.crc_en,
+			(uint32_t)desc->enc_req.crc_en);
+	rte_bbdev_log_debug("\t-- input_slice_table_addr_lo(%"PRIu32")"
+			" | input_start_addr_lo(%"PRIu32")",
 			(uint32_t)desc->enc_req.input_slice_table_addr_lo,
-			(uint32_t)desc->enc_req.input_start_addr_lo,
+			(uint32_t)desc->enc_req.input_start_addr_lo);
+	rte_bbdev_log_debug("\t-- input_slice_table_addr_hi(%"PRIu32")"
+			" | input_start_addr_hi(%"PRIu32")",
 			(uint32_t)desc->enc_req.input_slice_table_addr_hi,
-			(uint32_t)desc->enc_req.input_start_addr_hi,
+			(uint32_t)desc->enc_req.input_start_addr_hi);
+	rte_bbdev_log_debug("\t-- input_slice_num(%"PRIu32") | input_length(%"PRIu32")",
 			(uint32_t)desc->enc_req.input_slice_num,
-			(uint32_t)desc->enc_req.input_length,
+			(uint32_t)desc->enc_req.input_length);
+	rte_bbdev_log_debug("\t-- output_slice_table_addr_lo(%"PRIu32")"
+			" | output_start_addr_lo(%"PRIu32")",
 			(uint32_t)desc->enc_req.output_slice_table_addr_lo,
-			(uint32_t)desc->enc_req.output_start_addr_lo,
+			(uint32_t)desc->enc_req.output_start_addr_lo);
+	rte_bbdev_log_debug("\t-- output_slice_table_addr_hi(%"PRIu32")"
+			" | output_start_addr_hi(%"PRIu32")",
 			(uint32_t)desc->enc_req.output_slice_table_addr_hi,
-			(uint32_t)desc->enc_req.output_start_addr_hi,
+			(uint32_t)desc->enc_req.output_start_addr_hi);
+	rte_bbdev_log_debug("\t-- output_slice_num(%"PRIu32") | output_length(%"PRIu32")",
 			(uint32_t)desc->enc_req.output_slice_num,
-			(uint32_t)desc->enc_req.output_length,
-			(uint32_t)desc->enc_req.enqueue_timestamp,
+			(uint32_t)desc->enc_req.output_length);
+	rte_bbdev_log_debug("\t-- enqueue_timestamp(%"PRIu32")",
+			(uint32_t)desc->enc_req.enqueue_timestamp);
+	rte_bbdev_log_debug("\t-- completion_timestamp(%"PRIu32")",
 			(uint32_t)desc->enc_req.completion_timestamp);
 
 	uint32_t *word = (uint32_t *) desc;
-	rte_bbdev_log_debug("%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n"
-			"%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n"
-			"%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n"
-			"%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n%08"PRIx32"\n",
+	rte_bbdev_log_debug("%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32", "
+			"%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32", "
+			"%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32", "
+			"%08"PRIx32", %08"PRIx32", %08"PRIx32", %08"PRIx32,
 			word[0], word[1], word[2], word[3],
 			word[4], word[5], word[6], word[7],
 			word[8], word[9], word[10], word[11],
drivers/baseband/fpga_lte_fec/fpga_lte_fec.c +12 -12
index a4a963f74d..d9373a072d 100644
@@ -444,28 +444,28 @@ print_static_reg_debug_info(void *mmio_base)
 static void
 print_dma_dec_desc_debug_info(union fpga_dma_desc *desc)
 {
-	rte_bbdev_log_debug("DMA response desc %p\n"
-		"\t-- done(%"PRIu32") | iter(%"PRIu32") | crc_pass(%"PRIu32")"
-		" | error (%"PRIu32") | crc_type(%"PRIu32")\n"
-		"\t-- max_iter(%"PRIu32") | bypass_rm(%"PRIu32") | "
-		"irq_en (%"PRIu32") | drop_crc(%"PRIu32") | offset(%"PRIu32")\n"
-		"\t-- k(%"PRIu32") | in_len (%"PRIu16") | op_add(%p)\n"
-		"\t-- cbs_in_op(%"PRIu32") | in_add (0x%08"PRIx32"%08"PRIx32") | "
-		"out_add (0x%08"PRIx32"%08"PRIx32")",
-		desc,
+	rte_bbdev_log_debug("DMA response desc %p",
+		desc);
+	rte_bbdev_log_debug("\t-- done(%"PRIu32") | iter(%"PRIu32") | crc_pass(%"PRIu32")"
+		" | error (%"PRIu32") | crc_type(%"PRIu32")",
 		(uint32_t)desc->dec_req.done,
 		(uint32_t)desc->dec_req.iter,
 		(uint32_t)desc->dec_req.crc_pass,
 		(uint32_t)desc->dec_req.error,
-		(uint32_t)desc->dec_req.crc_type,
+		(uint32_t)desc->dec_req.crc_type);
+	rte_bbdev_log_debug("\t-- max_iter(%"PRIu32") | bypass_rm(%"PRIu32") | "
+		"irq_en (%"PRIu32") | drop_crc(%"PRIu32") | offset(%"PRIu32")",
 		(uint32_t)desc->dec_req.max_iter,
 		(uint32_t)desc->dec_req.bypass_rm,
 		(uint32_t)desc->dec_req.irq_en,
 		(uint32_t)desc->dec_req.drop_crc,
-		(uint32_t)desc->dec_req.offset,
+		(uint32_t)desc->dec_req.offset);
+	rte_bbdev_log_debug("\t-- k(%"PRIu32") | in_len (%"PRIu16") | op_add(%p)",
 		(uint32_t)desc->dec_req.k,
 		(uint16_t)desc->dec_req.in_len,
-		desc->dec_req.op_addr,
+		desc->dec_req.op_addr);
+	rte_bbdev_log_debug("\t-- cbs_in_op(%"PRIu32") | in_add (0x%08"PRIx32"%08"PRIx32") | "
+		"out_add (0x%08"PRIx32"%08"PRIx32")",
 		(uint32_t)desc->dec_req.cbs_in_op,
 		(uint32_t)desc->dec_req.in_addr_hi,
 		(uint32_t)desc->dec_req.in_addr_lw,
drivers/crypto/caam_jr/caam_jr.c +4 -3
index 27cdbf5ed4..4082b3f422 100644
@@ -123,9 +123,10 @@ void caam_jr_stats_get(struct rte_cryptodev *dev,
 		stats->dequeued_count += qp[i]->rx_pkts;
 		stats->enqueue_err_count += qp[i]->tx_errs;
 		stats->dequeue_err_count += qp[i]->rx_errs;
-		CAAM_JR_INFO("extra stats:\n\tRX Poll ERR = %" PRIu64
-			     "\n\tTX Ring Full = %" PRIu64,
-			     qp[i]->rx_poll_err,
+		CAAM_JR_INFO("extra stats:");
+		CAAM_JR_INFO("\tRX Poll ERR = %" PRIu64,
+			     qp[i]->rx_poll_err);
+		CAAM_JR_INFO("\tTX Ring Full = %" PRIu64,
 			     qp[i]->tx_ring_full);
 	}
 }
drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c +28 -26

92 lines not on this page · raw message

drivers/crypto/virtio/virtio_cryptodev.c +4 -6
index c0d3178b71..643921dc02 100644
@@ -239,9 +239,8 @@ virtio_crypto_send_command(struct virtqueue *vq,
 		vq->vq_free_cnt++;
 	}
 
-	VIRTIO_CRYPTO_INIT_LOG_DBG("vq->vq_free_cnt=%d\n"
-			"vq->vq_desc_head_idx=%d",
-			vq->vq_free_cnt, vq->vq_desc_head_idx);
+	VIRTIO_CRYPTO_INIT_LOG_DBG("vq->vq_free_cnt=%d", vq->vq_free_cnt);
+	VIRTIO_CRYPTO_INIT_LOG_DBG("vq->vq_desc_head_idx=%d", vq->vq_desc_head_idx);
 
 	/* get the result */
 	if (input->status != VIRTIO_CRYPTO_OK) {
@@ -1057,9 +1056,8 @@ virtio_crypto_sym_clear_session(
 		return;
 	}
 
-	VIRTIO_CRYPTO_INIT_LOG_DBG("vq->vq_free_cnt=%d\n"
-			"vq->vq_desc_head_idx=%d",
-			vq->vq_free_cnt, vq->vq_desc_head_idx);
+	VIRTIO_CRYPTO_INIT_LOG_DBG("vq->vq_free_cnt=%d", vq->vq_free_cnt);
+	VIRTIO_CRYPTO_INIT_LOG_DBG("vq->vq_desc_head_idx=%d", vq->vq_desc_head_idx);
 
 	VIRTIO_CRYPTO_SESSION_LOG_INFO("Close session %"PRIu64" successfully ",
 			session->session_id);
drivers/net/bnxt/bnxt_hwrm.c +8 -8
index bcbcb56546..d14536e242 100644
@@ -1828,16 +1828,16 @@ static int bnxt_hwrm_port_phy_qcfg(struct bnxt *bp,
 
 	/* Display the captured P7 phy details */
 	if (BNXT_LINK_SPEEDS_V2(bp)) {
-		PMD_DRV_LOG_LINE(DEBUG, "Phytype:%d, Media_type:%d, Status: %d, Link Signal:%d\n"
-			    "Active Fec: %d Support_speeds2:%x, Force_link_speedsv2:%x\n"
-			    "Auto_link_speedsv2:%x, Active_lanes:%d",
+		PMD_DRV_LOG_LINE(DEBUG, "Phytype:%d, Media_type:%d, Status: %d, Link Signal:%d",
 			    link_info->phy_type,
 			    link_info->media_type,
 			    link_info->phy_link_status,
-			    link_info->link_signal_mode,
+			    link_info->link_signal_mode);
+		PMD_DRV_LOG_LINE(DEBUG, "Active Fec: %d Support_speeds2:%x, Force_link_speedsv2:%x",
 			    (resp->active_fec_signal_mode &
 				HWRM_PORT_PHY_QCFG_OUTPUT_ACTIVE_FEC_MASK) >> 4,
-			    link_info->support_speeds2, link_info->force_link_speeds2,
+			    link_info->support_speeds2, link_info->force_link_speeds2);
+		PMD_DRV_LOG_LINE(DEBUG, "Auto_link_speedsv2:%x, Active_lanes:%d",
 			    link_info->auto_link_speeds2,
 			    link_info->active_lanes);
 
@@ -1850,12 +1850,12 @@ static int bnxt_hwrm_port_phy_qcfg(struct bnxt *bp,
 			desc = ((struct link_speeds2_tbl *)
 				bnxt_get_hwrm_to_rte_speeds2_entry(link_info->link_speed))->desc;
 
-		PMD_DRV_LOG_LINE(INFO, "Link Speed: %s %s, Status: %s Signal-mode: %s\n"
-			    "Media type: %s, Xcvr type: %s, Active FEC: %s Lanes: %d",
+		PMD_DRV_LOG_LINE(INFO, "Link Speed: %s %s, Status: %s Signal-mode: %s",
 			    desc,
 			    !(link_info->auto_mode) ? "Forced" : "AutoNegotiated",
 			    link_status_str[link_info->phy_link_status % MAX_LINK_STR],
-			    signal_mode[link_info->link_signal_mode % MAX_SIG_MODE],
+			    signal_mode[link_info->link_signal_mode % MAX_SIG_MODE]);
+		PMD_DRV_LOG_LINE(INFO, "Media type: %s, Xcvr type: %s, Active FEC: %s Lanes: %d",
 			    media_type[link_info->media_type % MAX_MEDIA_TYPE],
 			    bnxt_get_xcvr_type(rte_le_to_cpu_32
 					       (resp->xcvr_identifier_type_tx_lpi_timer)),
drivers/net/dpaa/dpaa_ethdev.c +5 -4
index 060b8c678f..51f5422e0c 100644
@@ -1200,11 +1200,12 @@ dpaa_eth_eventq_attach(const struct rte_eth_dev *dev,
 	struct qman_fq *rxq = &dpaa_intf->rx_queues[eth_rx_queue_id];
 	struct qm_mcc_initfq opts = {0};
 
-	if (dpaa_push_mode_max_queue)
-		DPAA_PMD_WARN("PUSH mode q and EVENTDEV are not compatible\n"
-			      "PUSH mode already enabled for first %d queues.\n"
-			      "To disable set DPAA_PUSH_QUEUES_NUMBER to 0",
+	if (dpaa_push_mode_max_queue) {
+		DPAA_PMD_WARN("PUSH mode q and EVENTDEV are not compatible");
+		DPAA_PMD_WARN("PUSH mode already enabled for first %d queues.",
 			      dpaa_push_mode_max_queue);
+		DPAA_PMD_WARN("To disable set DPAA_PUSH_QUEUES_NUMBER to 0");
+	}
 
 	dpaa_poll_queue_default_config(&opts);
 
drivers/net/mlx4/mlx4_mr.c +9 -9
index e95f45aa3e..2251c624ff 100644
@@ -564,9 +564,9 @@ mlx4_mr_create_secondary(struct rte_eth_dev *dev, struct mlx4_mr_cache *entry,
 	/* Lookup can't fail. */
 	MLX4_ASSERT(entry->lkey != UINT32_MAX);
 	rte_rwlock_read_unlock(&priv->mr.rwlock);
-	DEBUG("port %u MR CREATED by primary process for %p:\n"
-	      "  [0x%" PRIxPTR ", 0x%" PRIxPTR "), lkey=0x%x",
-	      dev->data->port_id, (void *)addr,
+	DEBUG("port %u MR CREATED by primary process for %p:",
+	      dev->data->port_id, (void *)addr);
+	DEBUG("  [0x%" PRIxPTR ", 0x%" PRIxPTR "), lkey=0x%x",
 	      entry->start, entry->end, entry->lkey);
 	return entry->lkey;
 }
@@ -787,10 +787,10 @@ mlx4_mr_create_primary(struct rte_eth_dev *dev, struct mlx4_mr_cache *entry,
 	MLX4_ASSERT((uintptr_t)mr->ibv_mr->addr == data.start);
 	MLX4_ASSERT(mr->ibv_mr->length == len);
 	LIST_INSERT_HEAD(&priv->mr.mr_list, mr, mr);
-	DEBUG("port %u MR CREATED (%p) for %p:\n"
-	      "  [0x%" PRIxPTR ", 0x%" PRIxPTR "),"
+	DEBUG("port %u MR CREATED (%p) for %p:",
+	      dev->data->port_id, (void *)mr, (void *)addr);
+	DEBUG("  [0x%" PRIxPTR ", 0x%" PRIxPTR "),"
 	      " lkey=0x%x base_idx=%u ms_n=%u, ms_bmp_n=%u",
-	      dev->data->port_id, (void *)mr, (void *)addr,
 	      data.start, data.end, rte_cpu_to_be_32(mr->ibv_mr->lkey),
 	      mr->ms_base_idx, mr->ms_n, mr->ms_bmp_n);
 	/* Insert to the global cache table. */
@@ -1251,10 +1251,10 @@ mlx4_mr_update_ext_mp_cb(struct rte_mempool *mp, void *opaque,
 	mr->ms_bmp_n = 1;
 	rte_rwlock_write_lock(&priv->mr.rwlock);
 	LIST_INSERT_HEAD(&priv->mr.mr_list, mr, mr);
-	DEBUG("port %u MR CREATED (%p) for external memory %p:\n"
-	      "  [0x%" PRIxPTR ", 0x%" PRIxPTR "),"
+	DEBUG("port %u MR CREATED (%p) for external memory %p:",
+	      dev->data->port_id, (void *)mr, (void *)addr);
+	DEBUG("  [0x%" PRIxPTR ", 0x%" PRIxPTR "),"
 	      " lkey=0x%x base_idx=%u ms_n=%u, ms_bmp_n=%u",
-	      dev->data->port_id, (void *)mr, (void *)addr,
 	      addr, addr + len, rte_cpu_to_be_32(mr->ibv_mr->lkey),
 	      mr->ms_base_idx, mr->ms_n, mr->ms_bmp_n);
 	/* Insert to the global cache table. */
drivers/net/octeontx/octeontx_ethdev.c +11 -11
index c802b2c389..3b8d717797 100644
@@ -1389,17 +1389,17 @@ octeontx_dev_rx_queue_setup(struct rte_eth_dev *dev, uint16_t qidx,
 			rte_free(rxq);
 			return ret;
 		}
-		PMD_RX_LOG(DEBUG, "Port %d Rx pktbuf configured:\n"
-				"\tmbuf_size:\t0x%0x\n"
-				"\twqe_skip:\t0x%0x\n"
-				"\tfirst_skip:\t0x%0x\n"
-				"\tlater_skip:\t0x%0x\n"
-				"\tcache_mode:\t%s\n",
-				port,
-				pktbuf_conf.mbuff_size,
-				pktbuf_conf.wqe_skip,
-				pktbuf_conf.first_skip,
-				pktbuf_conf.later_skip,
+		PMD_RX_LOG(DEBUG, "Port %d Rx pktbuf configured:",
+				port);
+		PMD_RX_LOG(DEBUG, "\tmbuf_size:\t0x%0x",
+				pktbuf_conf.mbuff_size);
+		PMD_RX_LOG(DEBUG, "\twqe_skip:\t0x%0x",
+				pktbuf_conf.wqe_skip);
+		PMD_RX_LOG(DEBUG, "\tfirst_skip:\t0x%0x",
+				pktbuf_conf.first_skip);
+		PMD_RX_LOG(DEBUG, "\tlater_skip:\t0x%0x",
+				pktbuf_conf.later_skip);
+		PMD_RX_LOG(DEBUG, "\tcache_mode:\t%s",
 				(pktbuf_conf.cache_mode ==
 						PKI_OPC_MODE_STT) ?
 				"STT" :
drivers/net/virtio/virtio_cvq.c +7 -12
index 5e457f5fd0..657b0692b2 100644
@@ -92,16 +92,11 @@ virtio_send_command_packed(struct virtnet_ctl *cvq,
 		vq->vq_packed.used_wrap_counter ^= 1;
 	}
 
-	PMD_INIT_LOG(DEBUG, "vq->vq_free_cnt=%d\n"
-			"vq->vq_avail_idx=%d\n"
-			"vq->vq_used_cons_idx=%d\n"
-			"vq->vq_packed.cached_flags=0x%x\n"
-			"vq->vq_packed.used_wrap_counter=%d",
-			vq->vq_free_cnt,
-			vq->vq_avail_idx,
-			vq->vq_used_cons_idx,
-			vq->vq_packed.cached_flags,
-			vq->vq_packed.used_wrap_counter);
+	PMD_INIT_LOG(DEBUG, "vq->vq_free_cnt=%d", vq->vq_free_cnt);
+	PMD_INIT_LOG(DEBUG, "vq->vq_avail_idx=%d", vq->vq_avail_idx);
+	PMD_INIT_LOG(DEBUG, "vq->vq_used_cons_idx=%d", vq->vq_used_cons_idx);
+	PMD_INIT_LOG(DEBUG, "vq->vq_packed.cached_flags=0x%x", vq->vq_packed.cached_flags);
+	PMD_INIT_LOG(DEBUG, "vq->vq_packed.used_wrap_counter=%d", vq->vq_packed.used_wrap_counter);
 
 	result = cvq->hdr_mz->addr;
 	return result;
@@ -183,8 +178,8 @@ virtio_send_command_split(struct virtnet_ctl *cvq,
 		vq->vq_free_cnt++;
 	}
 
-	PMD_INIT_LOG(DEBUG, "vq->vq_free_cnt=%d\nvq->vq_desc_head_idx=%d",
-			vq->vq_free_cnt, vq->vq_desc_head_idx);
+	PMD_INIT_LOG(DEBUG, "vq->vq_free_cnt=%d", vq->vq_free_cnt);
+	PMD_INIT_LOG(DEBUG, "vq->vq_desc_head_idx=%d", vq->vq_desc_head_idx);
 
 	result = cvq->hdr_mz->addr;
 	return result;
drivers/net/virtio/virtio_user/virtio_user_dev.c +15 -15
index e8642be86b..2997d2bd26 100644
@@ -1197,21 +1197,21 @@ virtio_user_dev_update_status(struct virtio_user_dev *dev)
 	ret = dev->ops->get_status(dev, &status);
 	if (!ret) {
 		dev->status = status;
-		PMD_INIT_LOG(DEBUG, "Updated Device Status(0x%08x):\n"
-			"\t-RESET: %u\n"
-			"\t-ACKNOWLEDGE: %u\n"
-			"\t-DRIVER: %u\n"
-			"\t-DRIVER_OK: %u\n"
-			"\t-FEATURES_OK: %u\n"
-			"\t-DEVICE_NEED_RESET: %u\n"
-			"\t-FAILED: %u",
-			dev->status,
-			(dev->status == VIRTIO_CONFIG_STATUS_RESET),
-			!!(dev->status & VIRTIO_CONFIG_STATUS_ACK),
-			!!(dev->status & VIRTIO_CONFIG_STATUS_DRIVER),
-			!!(dev->status & VIRTIO_CONFIG_STATUS_DRIVER_OK),
-			!!(dev->status & VIRTIO_CONFIG_STATUS_FEATURES_OK),
-			!!(dev->status & VIRTIO_CONFIG_STATUS_DEV_NEED_RESET),
+		PMD_INIT_LOG(DEBUG, "Updated Device Status(0x%08x):",
+			dev->status);
+		PMD_INIT_LOG(DEBUG, "\t-RESET: %u",
+			(dev->status == VIRTIO_CONFIG_STATUS_RESET));
+		PMD_INIT_LOG(DEBUG, "\t-ACKNOWLEDGE: %u",
+			!!(dev->status & VIRTIO_CONFIG_STATUS_ACK));
+		PMD_INIT_LOG(DEBUG, "\t-DRIVER: %u",
+			!!(dev->status & VIRTIO_CONFIG_STATUS_DRIVER));
+		PMD_INIT_LOG(DEBUG, "\t-DRIVER_OK: %u",
+			!!(dev->status & VIRTIO_CONFIG_STATUS_DRIVER_OK));
+		PMD_INIT_LOG(DEBUG, "\t-FEATURES_OK: %u",
+			!!(dev->status & VIRTIO_CONFIG_STATUS_FEATURES_OK));
+		PMD_INIT_LOG(DEBUG, "\t-DEVICE_NEED_RESET: %u",
+			!!(dev->status & VIRTIO_CONFIG_STATUS_DEV_NEED_RESET));
+		PMD_INIT_LOG(DEBUG, "\t-FAILED: %u",
 			!!(dev->status & VIRTIO_CONFIG_STATUS_FAILED));
 	} else if (ret != -ENOTSUP) {
 		PMD_INIT_LOG(ERR, "(%s) Failed to get backend status", dev->path);
drivers/raw/cnxk_bphy/cnxk_bphy.c +1 -1
index 57f77297a8..0c26cfbbe6 100644
@@ -332,7 +332,7 @@ bphy_rawdev_probe(struct rte_pci_driver *pci_drv,
 		return 0;
 
 	if (!pci_dev->mem_resource[0].addr) {
-		CNXK_BPHY_LOG(ERR, "BARs have invalid values: BAR0 %p\n BAR2 %p",
+		CNXK_BPHY_LOG(ERR, "BARs have invalid values: BAR0 %p BAR2 %p",
 			      pci_dev->mem_resource[0].addr, pci_dev->mem_resource[2].addr);
 		return -ENODEV;
 	}
Signature · 1 line
2.46.0
#17 lore raw

PATCH 11/11 drivers: use per line logging in helpers

In reply to David Marchand

Use RTE_LOG_LINE in existing macros that append a \n.

---
 devtools/checkpatches.sh                      | 11 +++-
 drivers/baseband/acc/acc100_pmd.h             | 12 ++--
 drivers/baseband/acc/acc_common.h             |  6 +-
 drivers/baseband/acc/rte_acc100_pmd.c         |  1 +
 drivers/baseband/acc/rte_vrb_pmd.c            |  1 +
 drivers/baseband/acc/vrb_pmd.h                | 12 ++--
 .../baseband/fpga_5gnr_fec/fpga_5gnr_fec.h    | 15 ++---
 drivers/baseband/fpga_lte_fec/fpga_lte_fec.c  | 13 ++--
 .../baseband/la12xx/bbdev_la12xx_pmd_logs.h   | 16 +++--
 drivers/baseband/null/bbdev_null.c            |  5 +-
 .../baseband/turbo_sw/bbdev_turbo_software.c  |  6 +-
 drivers/bus/auxiliary/private.h               |  5 +-
 drivers/bus/cdx/cdx_logs.h                    |  7 +--
 drivers/bus/dpaa/include/fman.h               |  3 +-
 drivers/bus/dpaa/rte_dpaa_logs.h              |  6 +-
 drivers/bus/fslmc/fslmc_logs.h                |  7 +--
 drivers/bus/ifpga/ifpga_logs.h                |  3 +-
 drivers/bus/platform/private.h                |  3 +-
 drivers/bus/uacce/uacce.c                     |  4 +-
 drivers/bus/vdev/vdev_logs.h                  |  3 +-
 drivers/bus/vmbus/private.h                   |  3 +-
 drivers/common/cnxk/roc_platform.h            | 31 +++++++---
 drivers/common/cpt/cpt_pmd_logs.h             | 15 +++--
 drivers/common/dpaax/dpaax_logs.h             |  6 +-
 drivers/common/idpf/idpf_common_logs.h        | 26 +++-----
 drivers/common/nfp/nfp_common_log.h           |  5 +-
 drivers/common/nitrox/nitrox_logs.h           |  2 +-
 drivers/common/octeontx/octeontx_mbox.h       |  5 +-
 drivers/common/qat/qat_logs.h                 |  8 +--
 drivers/common/sfc_efx/sfc_efx_log.h          |  5 +-
 .../compress/isal/isal_compress_pmd_private.h |  3 +-
 drivers/compress/octeontx/otx_zip.h           |  5 +-
 .../compress/uadk/uadk_compress_pmd_private.h |  5 +-
 drivers/compress/zlib/zlib_pmd_private.h      |  3 +-
 drivers/crypto/armv8/armv8_pmd_private.h      | 16 +++--
 drivers/crypto/bcmfs/bcmfs_logs.h             | 10 ++--
 drivers/crypto/caam_jr/caam_jr_log.h          |  8 +--
 drivers/crypto/dpaa2_sec/dpaa2_sec_logs.h     |  8 +--
 drivers/crypto/dpaa_sec/dpaa_sec_log.h        |  6 +-
 drivers/crypto/ipsec_mb/ipsec_mb_private.h    |  5 +-
 drivers/crypto/mvsam/mrvl_pmd_private.h       |  5 +-
 drivers/crypto/null/null_crypto_pmd_private.h |  5 +-
 drivers/crypto/openssl/openssl_pmd_private.h  |  5 +-
 .../crypto/scheduler/scheduler_pmd_private.h  |  5 +-
 drivers/crypto/uadk/uadk_crypto_pmd_private.h |  5 +-
 drivers/crypto/virtio/virtio_logs.h           | 30 ++++++----
 drivers/dma/dpaa/dpaa_qdma_logs.h             |  8 +--
 drivers/dma/dpaa2/dpaa2_qdma_logs.h           | 10 ++--
 drivers/dma/hisilicon/hisi_dmadev.c           | 17 +++---
 drivers/dma/idxd/idxd_internal.h              |  5 +-
 drivers/dma/ioat/ioat_internal.h              |  5 +-
 drivers/dma/odm/odm.h                         | 11 ++--
 drivers/dma/skeleton/skeleton_dmadev.c        |  3 +-
 drivers/event/dpaa/dpaa_eventdev.c            |  1 +
 drivers/event/dpaa/dpaa_eventdev.h            |  2 +-
 drivers/event/dpaa2/dpaa2_eventdev_logs.h     |  7 +--
 drivers/event/dsw/dsw_evdev.h                 |  2 +-
 drivers/event/octeontx/ssovf_evdev.h          |  5 +-
 drivers/event/octeontx/timvf_evdev.h          |  5 +-
 drivers/event/opdl/opdl_log.h                 |  9 +--
 drivers/event/skeleton/skeleton_eventdev.h    |  7 +--
 drivers/event/sw/sw_evdev_log.h               |  3 +-
 drivers/gpu/cuda/common.h                     |  3 +-
 drivers/mempool/dpaa/dpaa_mempool.h           |  3 +-
 drivers/mempool/dpaa2/dpaa2_hw_mempool_logs.h |  6 +-
 drivers/mempool/octeontx/octeontx_pool_logs.h |  5 +-
 drivers/net/af_packet/rte_eth_af_packet.c     |  9 +--
 drivers/net/af_xdp/rte_eth_af_xdp.c           |  2 +-
 drivers/net/atlantic/atl_logs.h               | 16 +++--
 drivers/net/avp/avp_logs.h                    |  6 +-
 drivers/net/axgbe/axgbe_logs.h                |  6 +-
 drivers/net/bnx2x/bnx2x_logs.h                | 25 ++++----
 drivers/net/bnxt/bnxt.h                       |  2 +-
 drivers/net/bnxt/bnxt_rxtx_vec_neon.c         |  4 +-
 drivers/net/bnxt/bnxt_rxtx_vec_sse.c          |  4 +-
 drivers/net/bnxt/bnxt_txr.c                   |  4 +-
 drivers/net/cpfl/cpfl_logs.h                  | 12 ++--
 drivers/net/dpaa/dpaa_ethdev.h                |  4 +-
 drivers/net/dpaa2/dpaa2_pmd_logs.h            | 10 ++--
 drivers/net/dpaa2/dpaa2_rxtx.c                | 30 +++++-----
 drivers/net/e1000/e1000_logs.h                | 14 ++---
 drivers/net/ena/ena_logs.h                    |  8 +--
 drivers/net/ena/ena_platform.h                |  2 +-
 drivers/net/enetc/enetc_logs.h                | 10 ++--
 drivers/net/enetfec/enet_pmd_logs.h           |  7 +--
 drivers/net/enic/enic_compat.h                |  5 +-
 drivers/net/failsafe/failsafe_private.h       |  7 +--
 drivers/net/fm10k/fm10k_logs.h                | 18 +++---
 drivers/net/gve/gve_logs.h                    |  4 +-
 drivers/net/hinic/base/hinic_compat.h         |  5 +-
 drivers/net/hns3/hns3_logs.h                  | 25 ++++----
 drivers/net/i40e/i40e_logs.h                  | 18 +++---
 drivers/net/iavf/iavf_log.h                   | 21 +++----
 drivers/net/ice/ice_logs.h                    | 18 +++---
 drivers/net/idpf/idpf_logs.h                  | 17 +++---
 drivers/net/igc/igc_logs.h                    | 12 ++--
 drivers/net/ipn3ke/ipn3ke_logs.h              |  4 +-
 drivers/net/ixgbe/ixgbe_logs.h                | 18 +++---
 drivers/net/mana/mana.h                       |  7 ++-
 drivers/net/memif/rte_eth_memif.h             |  5 +-
 drivers/net/mlx4/mlx4_utils.h                 |  9 +--
 drivers/net/mvneta/mvneta_ethdev.h            |  4 +-
 drivers/net/mvpp2/mrvl_ethdev.h               |  3 +-
 drivers/net/netvsc/hn_logs.h                  | 14 ++---
 drivers/net/netvsc/hn_rndis.c                 | 60 +++++++++----------
 drivers/net/nfb/nfb.h                         |  4 +-
 drivers/net/nfp/nfp_logs.h                    | 20 +++----
 drivers/net/ngbe/ngbe_logs.h                  | 20 ++++---
 drivers/net/null/rte_eth_null.c               |  5 +-
 drivers/net/octeon_ep/otx_ep_common.h         | 12 ++--
 drivers/net/octeon_ep/otx_ep_rxtx.c           |  4 +-
 drivers/net/octeontx/octeontx_logs.h          | 16 ++---
 drivers/net/pcap/pcap_osdep.h                 |  5 +-
 drivers/net/pfe/pfe_logs.h                    |  7 +--
 drivers/net/ring/rte_eth_ring.c               |  5 +-
 drivers/net/softnic/rte_eth_softnic.c         |  5 +-
 drivers/net/tap/tap_log.h                     |  3 +-
 drivers/net/thunderx/nicvf_logs.h             | 12 ++--
 drivers/net/txgbe/txgbe_logs.h                | 26 ++++----
 drivers/net/vdev_netvsc/vdev_netvsc.c         |  6 +-
 drivers/net/vhost/rte_eth_vhost.c             |  3 +-
 drivers/net/virtio/virtio_logs.h              | 13 ++--
 drivers/net/vmxnet3/vmxnet3_logs.h            | 14 ++---
 drivers/raw/cnxk_bphy/rte_pmd_bphy.h          |  4 +-
 drivers/raw/cnxk_gpio/cnxk_gpio.h             |  3 +-
 drivers/raw/dpaa2_cmdif/dpaa2_cmdif_logs.h    | 10 ++--
 drivers/raw/ifpga/ifpga_rawdev.h              |  3 +-
 drivers/raw/ntb/ntb.h                         |  3 +-
 drivers/raw/skeleton/skeleton_rawdev.h        |  3 +-
 drivers/raw/skeleton/skeleton_rawdev_test.c   |  2 +-
 drivers/vdpa/ifc/base/ifcvf.c                 | 10 ++--
 drivers/vdpa/ifc/ifcvf_vdpa.c                 |  5 +-
 drivers/vdpa/nfp/nfp_vdpa_log.h               | 10 ++--
 133 files changed, 596 insertions(+), 572 deletions(-)
devtools/checkpatches.sh +10 -1
index 8f245ebdab..0ab841bd5a 100755
@@ -53,7 +53,7 @@ print_usage () {
 check_forbidden_additions() { # <patch>
 	res=0
 
-	# refrain from new calls to RTE_LOG
+	# refrain from new calls to RTE_LOG in libraries
 	awk -v FOLDERS="lib" \
 		-v EXPRESSIONS="RTE_LOG\\\(" \
 		-v RET_ON_FAIL=1 \
@@ -61,6 +61,15 @@ check_forbidden_additions() { # <patch>
 		-f $(dirname $(readlink -f $0))/check-forbidden-tokens.awk \
 		"$1" || res=1
 
+	# refrain from new calls to RTE_LOG in drivers (but leave some leeway for base drivers)
+	awk -v FOLDERS="drivers" \
+		-v SKIP_FILES='osdep.h$' \
+		-v EXPRESSIONS="RTE_LOG\\\( RTE_LOG_DP\\\( rte_log\\\(" \
+		-v RET_ON_FAIL=1 \
+		-v MESSAGE='Prefer RTE_LOG_LINE/RTE_LOG_DP_LINE' \
+		-f $(dirname $(readlink -f $0))/check-forbidden-tokens.awk \
+		"$1" || res=1
+
 	# no output on stdout or stderr
 	awk -v FOLDERS="lib drivers" \
 		-v EXPRESSIONS="\\\<printf\\\> \\\<fprintf\\\(stdout, \\\<fprintf\\\(stderr," \
drivers/baseband/acc/acc100_pmd.h +5 -7
index aff1ef89f2..976593698e 100644
@@ -11,16 +11,14 @@
 #include "acc_common.h"
 
 /* Helper macro for logging */
-#define rte_bbdev_log(level, fmt, ...) \
-	rte_log(RTE_LOG_ ## level, acc100_logtype, fmt "\n", \
-		##__VA_ARGS__)
+#define rte_bbdev_log(level, ...) \
+	RTE_LOG_LINE(level, ACC100, __VA_ARGS__)
 
 #ifdef RTE_LIBRTE_BBDEV_DEBUG
-#define rte_bbdev_log_debug(fmt, ...) \
-		rte_bbdev_log(DEBUG, "acc100_pmd: " fmt, \
-		##__VA_ARGS__)
+#define rte_bbdev_log_debug(...) \
+	rte_bbdev_log(DEBUG, __VA_ARGS__)
 #else
-#define rte_bbdev_log_debug(fmt, ...)
+#define rte_bbdev_log_debug(...)
 #endif
 
 /* ACC100 PF and VF driver names */
drivers/baseband/acc/acc_common.h +3 -3
index e249f37e38..f8afa46e91 100644
@@ -151,11 +151,11 @@
 #define ACC_MAX_FFT_WIN      16
 
 extern int acc_common_logtype;
+#define RTE_LOGTYPE_ACC_COMMON acc_common_logtype
 
 /* Helper macro for logging */
-#define rte_acc_log(level, fmt, ...) \
-	rte_log(RTE_LOG_ ## level, acc_common_logtype, fmt "\n", \
-		##__VA_ARGS__)
+#define rte_acc_log(level, ...) \
+	RTE_LOG_LINE(level, ACC_COMMON, __VA_ARGS__)
 
 /* ACC100 DMA Descriptor triplet */
 struct acc_dma_triplet {
drivers/baseband/acc/rte_acc100_pmd.c +1 -0
index 5c91acab7e..2d021710a7 100644
@@ -30,6 +30,7 @@ RTE_LOG_REGISTER_SUFFIX(acc100_logtype, acc100, DEBUG);
 #else
 RTE_LOG_REGISTER_SUFFIX(acc100_logtype, acc100, NOTICE);
 #endif
+#define RTE_LOGTYPE_ACC100 acc100_logtype
 
 /* Calculate the offset of the enqueue register */
 static inline uint32_t
drivers/baseband/acc/rte_vrb_pmd.c +1 -0
index fad984ccc1..88075df8b4 100644
@@ -26,6 +26,7 @@ RTE_LOG_REGISTER_SUFFIX(vrb_logtype, vrb, DEBUG);
 #else
 RTE_LOG_REGISTER_SUFFIX(vrb_logtype, vrb, NOTICE);
 #endif
+#define RTE_LOGTYPE_VRB vrb_logtype
 
 /* Calculate the offset of the enqueue register. */
 static inline uint32_t
drivers/baseband/acc/vrb_pmd.h +5 -7
index 0371db9972..a4b81640e8 100644
@@ -13,16 +13,14 @@
 #include "vrb_cfg.h"
 
 /* Helper macro for logging */
-#define rte_bbdev_log(level, fmt, ...) \
-	rte_log(RTE_LOG_ ## level, vrb_logtype, fmt "\n", \
-		##__VA_ARGS__)
+#define rte_bbdev_log(level, ...) \
+	RTE_LOG_LINE(level, VRB, __VA_ARGS__)
 
 #ifdef RTE_LIBRTE_BBDEV_DEBUG
-#define rte_bbdev_log_debug(fmt, ...) \
-		rte_bbdev_log(DEBUG, "vrb_pmd: " fmt, \
-		##__VA_ARGS__)
+#define rte_bbdev_log_debug(...) \
+	rte_bbdev_log(DEBUG, __VA_ARGS__)
 #else
-#define rte_bbdev_log_debug(fmt, ...)
+#define rte_bbdev_log_debug(...)
 #endif
 
 /* VRB1 PF and VF driver names */
drivers/baseband/fpga_5gnr_fec/fpga_5gnr_fec.h +8 -7
index 2246849025..10a19e4dec 100644
@@ -11,17 +11,18 @@
 #include "agx100_pmd.h"
 #include "vc_5gnr_pmd.h"
 
+extern int fpga_5gnr_fec_logtype;
+#define RTE_LOGTYPE_FPGA_5GNR_FEC fpga_5gnr_fec_logtype
+
 /* Helper macro for logging */
-#define rte_bbdev_log(level, fmt, ...) \
-	rte_log(RTE_LOG_ ## level, fpga_5gnr_fec_logtype, fmt "\n", \
-		##__VA_ARGS__)
+#define rte_bbdev_log(level, ...) \
+	RTE_LOG_LINE(level, FPGA_5GNR_FEC, __VA_ARGS__)
 
 #ifdef RTE_LIBRTE_BBDEV_DEBUG
-#define rte_bbdev_log_debug(fmt, ...) \
-		rte_bbdev_log(DEBUG, "fpga_5gnr_fec: " fmt, \
-		##__VA_ARGS__)
+#define rte_bbdev_log_debug(...) \
+	rte_bbdev_log(DEBUG, __VA_ARGS__)
 #else
-#define rte_bbdev_log_debug(fmt, ...)
+#define rte_bbdev_log_debug(...)
 #endif
 
 /* FPGA 5GNR FEC driver names */
drivers/baseband/fpga_lte_fec/fpga_lte_fec.c +6 -7
index d9373a072d..eaffc35142 100644
@@ -25,18 +25,17 @@ RTE_LOG_REGISTER_DEFAULT(fpga_lte_fec_logtype, DEBUG);
 #else
 RTE_LOG_REGISTER_DEFAULT(fpga_lte_fec_logtype, NOTICE);
 #endif
+#define RTE_LOGTYPE_FPGA_LTE_FEC fpga_lte_fec_logtype
 
 /* Helper macro for logging */
-#define rte_bbdev_log(level, fmt, ...) \
-	rte_log(RTE_LOG_ ## level, fpga_lte_fec_logtype, fmt "\n", \
-		##__VA_ARGS__)
+#define rte_bbdev_log(level, ...) \
+	RTE_LOG_LINE(level, FPGA_LTE_FEC, __VA_ARGS__)
 
 #ifdef RTE_LIBRTE_BBDEV_DEBUG
-#define rte_bbdev_log_debug(fmt, ...) \
-		rte_bbdev_log(DEBUG, "fpga_lte_fec: " fmt, \
-		##__VA_ARGS__)
+#define rte_bbdev_log_debug(...) \
+	rte_bbdev_log(DEBUG, __VA_ARGS__)
 #else
-#define rte_bbdev_log_debug(fmt, ...)
+#define rte_bbdev_log_debug(...)
 #endif
 
 /* FPGA LTE FEC driver names */
drivers/baseband/la12xx/bbdev_la12xx_pmd_logs.h +7 -9
index 49c8d35d10..db935fb7f3 100644
@@ -8,22 +8,20 @@
 extern int bbdev_la12xx_logtype;
 #define RTE_LOGTYPE_BBDEV_LA12XX bbdev_la12xx_logtype
 
-#define rte_bbdev_log(level, fmt, ...) \
-	rte_log(RTE_LOG_ ## level, bbdev_la12xx_logtype, fmt "\n", \
-		##__VA_ARGS__)
+#define rte_bbdev_log(level, ...) \
+	RTE_LOG_LINE(level, BBDEV_LA12XX, __VA_ARGS__)
 
 #ifdef RTE_LIBRTE_BBDEV_DEBUG
-#define rte_bbdev_log_debug(fmt, ...) \
-		rte_bbdev_log(DEBUG, "la12xx_pmd: " fmt, \
-		##__VA_ARGS__)
+#define rte_bbdev_log_debug(...) \
+	rte_bbdev_log(DEBUG, __VA_ARGS__)
 #else
-#define rte_bbdev_log_debug(fmt, ...)
+#define rte_bbdev_log_debug(...)
 #endif
 
 #define PMD_INIT_FUNC_TRACE() rte_bbdev_log_debug(">>")
 
 /* DP Logs, toggled out at compile time if level lower than current level */
-#define rte_bbdev_dp_log(level, fmt, args...) \
-	RTE_LOG_DP(level, BBDEV_LA12XX, fmt, ## args)
+#define rte_bbdev_dp_log(level, ...) \
+	RTE_LOG_DP_LINE(level, BBDEV_LA12XX, __VA_ARGS__)
 
 #endif /* _BBDEV_LA12XX_PMD_LOGS_H_ */
drivers/baseband/null/bbdev_null.c +3 -2
index 75f78993fa..dab416aa41 100644
@@ -17,10 +17,11 @@
 #define DRIVER_NAME baseband_null
 
 RTE_LOG_REGISTER_DEFAULT(bbdev_null_logtype, NOTICE);
+#define RTE_LOGTYPE_BBDEV_NULL bbdev_null_logtype
 
 /* Helper macro for logging */
-#define rte_bbdev_log(level, fmt, ...) \
-	rte_log(RTE_LOG_ ## level, bbdev_null_logtype, fmt "\n", ##__VA_ARGS__)
+#define rte_bbdev_log(level, ...) \
+	RTE_LOG_LINE(level, BBDEV_NULL, __VA_ARGS__)
 
 #define rte_bbdev_log_debug(fmt, ...) \
 	rte_bbdev_log(DEBUG, RTE_STR(__LINE__) ":%s() " fmt, __func__, \
drivers/baseband/turbo_sw/bbdev_turbo_software.c +3 -3
index 1f661dd801..e527008524 100644
@@ -37,11 +37,11 @@
 #define DRIVER_NAME baseband_turbo_sw
 
 RTE_LOG_REGISTER_DEFAULT(bbdev_turbo_sw_logtype, NOTICE);
+#define RTE_LOGTYPE_BBDEV_TURBO_SW bbdev_turbo_sw_logtype
 
 /* Helper macro for logging */
-#define rte_bbdev_log(level, fmt, ...) \
-	rte_log(RTE_LOG_ ## level, bbdev_turbo_sw_logtype, fmt "\n", \
-		##__VA_ARGS__)
+#define rte_bbdev_log(level, ...) \
+	RTE_LOG_LINE(level, BBDEV_TURBO_SW, __VA_ARGS__)
 
 #define rte_bbdev_log_debug(fmt, ...) \
 	rte_bbdev_log(DEBUG, RTE_STR(__LINE__) ":%s() " fmt, __func__, \
drivers/bus/auxiliary/private.h +2 -3
index 3dee13e1d1..5f5b3b1bbf 100644
@@ -14,11 +14,10 @@
 #include "bus_auxiliary_driver.h"
 
 extern int auxiliary_bus_logtype;
+#define RTE_LOGTYPE_AUXILIARY_BUS auxiliary_bus_logtype
 
 #define AUXILIARY_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, auxiliary_bus_logtype, \
-		RTE_FMT("auxiliary bus: " RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
-			RTE_FMT_TAIL(__VA_ARGS__,)))
+	RTE_LOG_LINE(level, AUXILIARY_BUS, ## __VA_ARGS__)
 
 /*
  * Structure describing the auxiliary bus
drivers/bus/cdx/cdx_logs.h +3 -4
index 0ec39e9dd4..66d6967dc6 100644
@@ -6,15 +6,14 @@
 #define CDX_LOGS_H
 
 extern int cdx_logtype_bus;
+#define RTE_LOGTYPE_CDX_BUS cdx_logtype_bus
 
 #define CDX_BUS_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, cdx_logtype_bus, "cdx: " fmt "\n", \
-		##args)
+	RTE_LOG_LINE(level, CDX_BUS, fmt, ## args)
 
 /* Debug logs with Function names */
 #define CDX_BUS_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, cdx_logtype_bus, "cdx: %s(): " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(DEBUG, CDX_BUS, "%s(): " fmt, __func__, ## args)
 
 #define CDX_BUS_INFO(fmt, args...) \
 	CDX_BUS_LOG(INFO, fmt, ## args)
drivers/bus/dpaa/include/fman.h +1 -2
index 19f6132bba..f918836ec2 100644
@@ -403,8 +403,7 @@ extern int fman_ccsr_map_fd;
 #define FMAN_ERR(rc, fmt, args...) \
 	do { \
 		_errno = (rc); \
-		rte_log(RTE_LOG_ERR, dpaa_logtype_bus, "dpaa: " fmt "(%d)\n", \
-			##args, errno); \
+		RTE_LOG_LINE(ERR, DPAA_BUS, fmt "(%d)", ##args, errno); \
 	} while (0)
 
 #define FMAN_IP_REV_1	0xC30C4
drivers/bus/dpaa/rte_dpaa_logs.h +3 -3
index 149b127434..81b4e54f0e 100644
@@ -10,9 +10,10 @@
 #include <rte_log.h>
 
 extern int dpaa_logtype_bus;
+#define RTE_LOGTYPE_DPAA_BUS dpaa_logtype_bus
 
 #define DPAA_BUS_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_bus, "dpaa: " fmt "\n", ##args)
+	RTE_LOG_LINE(level, DPAA_BUS, fmt, ## args)
 
 #ifdef RTE_LIBRTE_DPAA_DEBUG_BUS
 #define DPAA_BUS_HWWARN(cond, fmt, args...) \
@@ -25,8 +26,7 @@ extern int dpaa_logtype_bus;
 #endif
 
 #define DPAA_BUS_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaa_logtype_bus, "dpaa: %s(): " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(DEBUG, DPAA_BUS, "%s(): " fmt, __func__, ## args)
 
 #define BUS_INIT_FUNC_TRACE() DPAA_BUS_DEBUG(" >>")
 
drivers/bus/fslmc/fslmc_logs.h +3 -4
index e15c603426..d34accf79f 100644
@@ -8,15 +8,14 @@
 #define _FSLMC_LOGS_H_
 
 extern int dpaa2_logtype_bus;
+#define RTE_LOGTYPE_DPAA2_BUS dpaa2_logtype_bus
 
 #define DPAA2_BUS_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa2_logtype_bus, "fslmc: " fmt "\n", \
-		##args)
+	RTE_LOG_LINE(level, DPAA2_BUS, fmt, ## args)
 
 /* Debug logs are with Function names */
 #define DPAA2_BUS_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaa2_logtype_bus, "fslmc: %s(): " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(DEBUG, DPAA2_BUS, "%s(): " fmt, __func__, ## args)
 
 #define DPAA2_BUS_INFO(fmt, args...) \
 	DPAA2_BUS_LOG(INFO, fmt, ## args)
drivers/bus/ifpga/ifpga_logs.h +2 -1
index 248bccba5d..f400bf85f1 100644
@@ -8,9 +8,10 @@
 #include <rte_log.h>
 
 extern int ifpga_bus_logtype;
+#define RTE_LOGTYPE_IFPGA_BUS ifpga_bus_logtype
 
 #define IFPGA_BUS_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ifpga_bus_logtype, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, IFPGA_BUS, "%s(): " fmt, \
 		__func__, ##args)
 
 #define IFPGA_BUS_FUNC_TRACE() IFPGA_BUS_LOG(DEBUG, ">>")
drivers/bus/platform/private.h +1 -2
index 72185aa457..d89ba0e4a5 100644
@@ -35,8 +35,7 @@ struct rte_platform_bus {
 extern int platform_bus_logtype;
 #define RTE_LOGTYPE_PLATFORM_BUS platform_bus_logtype
 #define PLATFORM_LOG_LINE(level, ...) \
-	RTE_LOG(level, PLATFORM_BUS, RTE_FMT(RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
-		RTE_FMT_TAIL(__VA_ARGS__,)))
+	RTE_LOG_LINE(level, PLATFORM_BUS, __VA_ARGS__)
 
 /*
  * Iterate registered platform devices and find one that matches provided string.
drivers/bus/uacce/uacce.c +2 -2
index 8b666c4e30..8a6b0f84c3 100644
@@ -59,9 +59,9 @@ static const char *const uacce_params_keys[] = {
 		RTE_TAILQ_FOREACH(p, &uacce_bus.driver_list, next)
 
 extern int uacce_bus_logtype;
+#define RTE_LOGTYPE_UACCE_BUS uacce_bus_logtype
 #define UACCE_BUS_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, uacce_bus_logtype, "uacce: " fmt "\n", \
-		##args)
+	RTE_LOG_LINE(level, UACCE_BUS, fmt, ##args)
 #define UACCE_BUS_ERR(fmt, args...) UACCE_BUS_LOG(ERR, fmt, ##args)
 #define UACCE_BUS_WARN(fmt, args...) UACCE_BUS_LOG(WARNING, fmt, ##args)
 #define UACCE_BUS_INFO(fmt, args...) UACCE_BUS_LOG(INFO, fmt, ##args)
drivers/bus/vdev/vdev_logs.h +2 -1
index 8759374193..f7ea09dd2c 100644
@@ -8,9 +8,10 @@
 #include <rte_log.h>
 
 extern int vdev_logtype_bus;
+#define RTE_LOGTYPE_VDEV_BUS vdev_logtype_bus
 
 #define VDEV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, vdev_logtype_bus, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, VDEV_BUS, "%s(): " fmt, \
 		__func__, ##args)
 
 #endif /* _VDEV_LOGS_H_ */
drivers/bus/vmbus/private.h +2 -1
index e33424675c..4585198375 100644
@@ -34,8 +34,9 @@ extern struct rte_vmbus_bus rte_vmbus_bus;
 	RTE_TAILQ_FOREACH(p, &(rte_vmbus_bus.driver_list), next)
 
 extern int vmbus_logtype_bus;
+#define RTE_LOGTYPE_VMBUS_BUS vmbus_logtype_bus
 #define VMBUS_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, vmbus_logtype_bus, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, VMBUS_BUS, "%s(): " fmt, \
 		__func__, ##args)
 
 struct vmbus_br {
drivers/common/cnxk/roc_platform.h +22 -9
index 658bafb935..882636ede6 100644
@@ -260,27 +260,41 @@ plt_thread_is_valid(plt_thread_t thr)
 
 /* Log */
 extern int cnxk_logtype_base;
+#define RTE_LOGTYPE_base cnxk_logtype_base
 extern int cnxk_logtype_mbox;
+#define RTE_LOGTYPE_mbox cnxk_logtype_mbox
 extern int cnxk_logtype_cpt;
+#define RTE_LOGTYPE_cpt cnxk_logtype_cpt
 extern int cnxk_logtype_ml;
+#define RTE_LOGTYPE_ml cnxk_logtype_ml
 extern int cnxk_logtype_npa;
+#define RTE_LOGTYPE_npa cnxk_logtype_npa
 extern int cnxk_logtype_nix;
+#define RTE_LOGTYPE_nix cnxk_logtype_nix
 extern int cnxk_logtype_npc;
+#define RTE_LOGTYPE_npc cnxk_logtype_npc
 extern int cnxk_logtype_sso;
+#define RTE_LOGTYPE_sso cnxk_logtype_sso
 extern int cnxk_logtype_tim;
+#define RTE_LOGTYPE_tim cnxk_logtype_tim
 extern int cnxk_logtype_tm;
+#define RTE_LOGTYPE_tm cnxk_logtype_tm
 extern int cnxk_logtype_ree;
+#define RTE_LOGTYPE_ree cnxk_logtype_ree
 extern int cnxk_logtype_dpi;
+#define RTE_LOGTYPE_dpi cnxk_logtype_dpi
 extern int cnxk_logtype_rep;
+#define RTE_LOGTYPE_rep cnxk_logtype_rep
 extern int cnxk_logtype_esw;
+#define RTE_LOGTYPE_esw cnxk_logtype_esw
 
 #define RTE_LOGTYPE_CNXK cnxk_logtype_base
 
 #define plt_err(fmt, args...)                                                  \
-	RTE_LOG(ERR, CNXK, "%s():%u " fmt "\n", __func__, __LINE__, ##args)
-#define plt_info(fmt, args...) RTE_LOG(INFO, CNXK, fmt "\n", ##args)
-#define plt_warn(fmt, args...) RTE_LOG(WARNING, CNXK, fmt "\n", ##args)
-#define plt_print(fmt, args...) RTE_LOG(INFO, CNXK, fmt "\n", ##args)
+	RTE_LOG_LINE(ERR, CNXK, "%s():%u " fmt, __func__, __LINE__, ##args)
+#define plt_info(fmt, args...) RTE_LOG_LINE(INFO, CNXK, fmt, ##args)
+#define plt_warn(fmt, args...) RTE_LOG_LINE(WARNING, CNXK, fmt, ##args)
+#define plt_print(fmt, args...) RTE_LOG_LINE(INFO, CNXK, fmt, ##args)
 #define plt_dump(fmt, ...)      fprintf(stderr, fmt "\n", ##__VA_ARGS__)
 #define plt_dump_no_nl(fmt, ...) fprintf(stderr, fmt, ##__VA_ARGS__)
 
@@ -288,8 +302,7 @@ extern int cnxk_logtype_esw;
  * Log debug message if given subsystem logging is enabled.
  */
 #define plt_dbg(subsystem, fmt, args...)                                       \
-	rte_log(RTE_LOG_DEBUG, cnxk_logtype_##subsystem,                       \
-		"[%s] %s():%u " fmt "\n", #subsystem, __func__, __LINE__,      \
+	RTE_LOG_LINE(DEBUG, subsystem,  "%s():%u " fmt, __func__, __LINE__,    \
 ##args)
 
 #define plt_base_dbg(fmt, ...)	plt_dbg(base, fmt, ##__VA_ARGS__)
@@ -309,11 +322,11 @@ extern int cnxk_logtype_esw;
 
 /* Datapath logs */
 #define plt_dp_err(fmt, args...)                                               \
-	RTE_LOG_DP(ERR, CNXK, "%s():%u " fmt "\n", __func__, __LINE__, ##args)
+	RTE_LOG_DP_LINE(ERR, CNXK, "%s():%u " fmt, __func__, __LINE__, ##args)
 #define plt_dp_info(fmt, args...)                                              \
-	RTE_LOG_DP(INFO, CNXK, "%s():%u " fmt "\n", __func__, __LINE__, ##args)
+	RTE_LOG_DP_LINE(INFO, CNXK, "%s():%u " fmt, __func__, __LINE__, ##args)
 #define plt_dp_dbg(fmt, args...)                                              \
-	RTE_LOG_DP(DEBUG, CNXK, "%s():%u " fmt "\n", __func__, __LINE__, ##args)
+	RTE_LOG_DP_LINE(DEBUG, CNXK, "%s():%u " fmt, __func__, __LINE__, ##args)
 
 #ifdef __cplusplus
 #define CNXK_PCI_ID(subsystem_dev, dev)                                        \
drivers/common/cpt/cpt_pmd_logs.h +7 -8
index 3c109c1983..21ef409102 100644
@@ -17,24 +17,23 @@
  */
 #define RTE_LOGTYPE_CPT CPT_LOGTYPE
 
-#define CPT_PMD_DRV_LOG_RAW(level, fmt, args...) \
-		rte_log(RTE_LOG_ ## level, CPT_LOGTYPE, \
-			"cpt: %s(): " fmt "\n", __func__, ##args)
+#define CPT_PMD_DRV_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, CPT, "%s(): " fmt, __func__, ## args)
 
-#define CPT_PMD_INIT_FUNC_TRACE() CPT_PMD_DRV_LOG_RAW(DEBUG, " >>")
+#define CPT_PMD_INIT_FUNC_TRACE() CPT_PMD_DRV_LOG(DEBUG, " >>")
 
 #define CPT_LOG_INFO(fmt, args...) \
-	CPT_PMD_DRV_LOG_RAW(INFO, fmt, ## args)
+	CPT_PMD_DRV_LOG(INFO, fmt, ## args)
 #define CPT_LOG_WARN(fmt, args...) \
-	CPT_PMD_DRV_LOG_RAW(WARNING, fmt, ## args)
+	CPT_PMD_DRV_LOG(WARNING, fmt, ## args)
 #define CPT_LOG_ERR(fmt, args...) \
-	CPT_PMD_DRV_LOG_RAW(ERR, fmt, ## args)
+	CPT_PMD_DRV_LOG(ERR, fmt, ## args)
 
 /*
  * DP logs, toggled out at compile time if level lower than current level.
  */
 #define CPT_LOG_DP(level, fmt, args...) \
-	RTE_LOG_DP(level, CPT, fmt "\n", ## args)
+	RTE_LOG_DP_LINE(level, CPT, fmt, ## args)
 
 #define CPT_LOG_DP_DEBUG(fmt, args...) \
 	CPT_LOG_DP(DEBUG, fmt, ## args)
drivers/common/dpaax/dpaax_logs.h +2 -4
index fe43bbc8f1..5ff1a10ce8 100644
@@ -21,13 +21,11 @@ extern int dpaax_logger;
 #endif
 
 #define DPAAX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaax_logger, "dpaax: " fmt "\n", \
-		##args)
+	RTE_LOG_LINE(level, DPAAX_LOGGER, fmt, ## args)
 
 /* Debug logs are with Function names */
 #define DPAAX_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaax_logger, "dpaax: %s():	 " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(DEBUG, DPAAX_LOGGER, "%s(): " fmt, __func__, ## args)
 
 #define DPAAX_INFO(fmt, args...) \
 	DPAAX_LOG(INFO, fmt, ## args)
drivers/common/idpf/idpf_common_logs.h +7 -19
index 561836760c..eb28039725 100644
@@ -11,35 +11,23 @@ extern int idpf_common_logtype;
 #define RTE_LOGTYPE_IDPF_COMMON idpf_common_logtype
 
 #define DRV_LOG(level, ...)					\
-	rte_log(RTE_LOG_ ## level,				\
-		idpf_common_logtype,				\
+	RTE_LOG_LINE(level,					\
+		IDPF_COMMON,					\
 		RTE_FMT("%s(): "				\
-			RTE_FMT_HEAD(__VA_ARGS__,) "\n",	\
+			RTE_FMT_HEAD(__VA_ARGS__,),		\
 			__func__,				\
 			RTE_FMT_TAIL(__VA_ARGS__,)))
 
 #ifdef RTE_LIBRTE_IDPF_DEBUG_RX
-#define RX_LOG(level, ...) \
-	RTE_LOG(level, \
-		IDPF_COMMON, \
-		RTE_FMT("%s(): " \
-			RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
-			__func__, \
-			RTE_FMT_TAIL(__VA_ARGS__,)))
+#define RX_LOG(...) DRV_LOG(__VA_ARGS__)
 #else
-#define RX_LOG(level, fmt, args...) do { } while (0)
+#define RX_LOG(...) do {} while (0)
 #endif
 
 #ifdef RTE_LIBRTE_IDPF_DEBUG_TX
-#define TX_LOG(level, ...) \
-	RTE_LOG(level, \
-		IDPF_COMMON, \
-		RTE_FMT("%s(): " \
-			RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
-			__func__, \
-			RTE_FMT_TAIL(__VA_ARGS__,)))
+#define TX_LOG(...) DRV_LOG(__VA_ARGS__)
 #else
-#define TX_LOG(level, fmt, args...) do { } while (0)
+#define TX_LOG(...) do {} while (0)
 #endif
 
 #endif /* _IDPF_COMMON_LOGS_H_ */
drivers/common/nfp/nfp_common_log.h +3 -2
index 066e38e688..4672e71a31 100644
@@ -9,8 +9,9 @@
 #include <rte_log.h>
 
 extern int nfp_logtype_common;
+#define RTE_LOGTYPE_NFP_COMMON nfp_logtype_common
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nfp_logtype_common, \
-			"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NFP_COMMON, \
+			"%s(): " fmt, __func__, ## args)
 
 #endif/* __NFP_COMMON_LOG_H__ */
drivers/common/nitrox/nitrox_logs.h +1 -1
index 67964447eb..596d77a96e 100644
@@ -8,6 +8,6 @@
 extern int nitrox_logtype;
 #define RTE_LOGTYPE_NITROX nitrox_logtype
 #define NITROX_LOG_LINE(level, fmt, args...) \
-	RTE_LOG(level, NITROX, "%s:%d " fmt "\n", __func__, __LINE__, ## args)
+	RTE_LOG_LINE(level, NITROX, "%s:%d " fmt, __func__, __LINE__, ## args)
 
 #endif /* _NITROX_LOGS_H_ */
drivers/common/octeontx/octeontx_mbox.h +3 -2
index ab4c010558..05255bc773 100644
@@ -18,8 +18,8 @@
 
 
 #define MBOX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, octeontx_logtype_mbox,\
-			"%s() line %u: " fmt "\n", __func__, __LINE__, ## args)
+	RTE_LOG_LINE(level, OCTEONTX_MBOX,\
+			"%s() line %u: " fmt, __func__, __LINE__, ## args)
 
 #define mbox_log_info(fmt, ...) MBOX_LOG(INFO, fmt, ##__VA_ARGS__)
 #define mbox_log_dbg(fmt, ...) MBOX_LOG(DEBUG, fmt, ##__VA_ARGS__)
@@ -27,6 +27,7 @@
 #define mbox_func_trace mbox_log_dbg
 
 extern int octeontx_logtype_mbox;
+#define RTE_LOGTYPE_OCTEONTX_MBOX octeontx_logtype_mbox
 
 struct octeontx_mbox_hdr {
 	uint16_t vfid;  /* VF index or pf resource index local to the domain */
drivers/common/qat/qat_logs.h +4 -4
index 2e4d3945cb..d7c796abe3 100644
@@ -6,15 +6,15 @@
 #define _QAT_LOGS_H_
 
 extern int qat_gen_logtype;
+#define RTE_LOGTYPE_QAT_GEN qat_gen_logtype
 extern int qat_dp_logtype;
+#define RTE_LOGTYPE_QAT_DP qat_dp_logtype
 
 #define QAT_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, qat_gen_logtype,		\
-			"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, QAT_GEN, "%s(): " fmt, __func__, ## args)
 
 #define QAT_DP_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, qat_dp_logtype,		\
-			"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, QAT_DP, "%s(): " fmt, __func__, ## args)
 
 #define QAT_DP_HEXDUMP_LOG(level, title, buf, len)		\
 	qat_hexdump_log(RTE_LOG_ ## level, qat_dp_logtype, title, buf, len)
drivers/common/sfc_efx/sfc_efx_log.h +2 -3
index 1519ebdc17..b41ef3490b 100644
@@ -12,11 +12,10 @@
 
 /** Generic driver log type */
 extern int sfc_efx_logtype;
+#define RTE_LOGTYPE_SFC_EFX sfc_efx_logtype
 
 /** Log message, add a prefix and a line break */
 #define SFC_EFX_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, sfc_efx_logtype,			\
-		RTE_FMT("sfc_efx: " RTE_FMT_HEAD(__VA_ARGS__ ,) "\n",	\
-			RTE_FMT_TAIL(__VA_ARGS__ ,)))
+	RTE_LOG_LINE(level, SFC_EFX, ## __VA_ARGS__)
 
 #endif /* _SFC_EFX_LOG_H_ */
drivers/compress/isal/isal_compress_pmd_private.h +2 -1
index c713a5bb6c..6d93c2a9c0 100644
@@ -9,8 +9,9 @@
 /**< ISA-L comp PMD device name */
 
 extern int isal_logtype_driver;
+#define RTE_LOGTYPE_ISAL_DRIVER isal_logtype_driver
 #define ISAL_PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, isal_logtype_driver, "%s(): "fmt "\n", \
+	RTE_LOG_LINE(level, ISAL_DRIVER, "%s(): "fmt, \
 			__func__, ##args)
 
 /* private data structure for each ISA-L compression device */
drivers/compress/octeontx/otx_zip.h +2 -3
index 7353fd4957..85547da8f8 100644
@@ -18,6 +18,7 @@
 #include <zip_regs.h>
 
 extern int octtx_zip_logtype_driver;
+#define RTE_LOGTYPE_OCTTX_ZIP_DRIVER octtx_zip_logtype_driver
 
 /* ZIP VF Control/Status registers (CSRs): */
 /* VF_BAR0: */
@@ -77,9 +78,7 @@ extern int octtx_zip_logtype_driver;
 #define COMPRESSDEV_NAME_ZIP_PMD	compress_octeontx
 
 #define ZIP_PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, \
-	octtx_zip_logtype_driver, "%s(): "fmt "\n", \
-	__func__, ##args)
+	RTE_LOG_LINE(level, OCTTX_ZIP_DRIVER, "%s(): "fmt, __func__, ## args)
 
 #define ZIP_PMD_INFO(fmt, args...) \
 	ZIP_PMD_LOG(INFO, fmt, ## args)
drivers/compress/uadk/uadk_compress_pmd_private.h +3 -2
index b09569fb94..227831dede 100644
@@ -27,10 +27,11 @@ struct  uadk_compress_xform {
 };
 
 extern int uadk_compress_logtype;
+#define RTE_LOGTYPE_UADK_COMPRESS uadk_compress_logtype
 
 #define UADK_LOG(level, fmt, ...)  \
-	rte_log(RTE_LOG_ ## level, uadk_compress_logtype,  \
-		"%s() line %u: " fmt "\n", __func__, __LINE__,  \
+	RTE_LOG_LINE(level, UADK_COMPRESS,  \
+		"%s() line %u: " fmt, __func__, __LINE__,  \
 		## __VA_ARGS__)
 
 #endif /* _UADK_COMPRESS_PMD_PRIVATE_H_ */
drivers/compress/zlib/zlib_pmd_private.h +2 -1
index 46a33d4d1b..6bd3da4354 100644
@@ -15,8 +15,9 @@
 #define DEF_MEM_LEVEL			8
 
 extern int zlib_logtype_driver;
+#define RTE_LOGTYPE_ZLIB_DRIVER zlib_logtype_driver
 #define ZLIB_PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, zlib_logtype_driver, "%s(): "fmt "\n", \
+	RTE_LOG_LINE(level, ZLIB_DRIVER, "%s(): "fmt, \
 			__func__, ##args)
 
 #define ZLIB_PMD_INFO(fmt, args...) \
drivers/crypto/armv8/armv8_pmd_private.h +7 -9
index c9bbcc2b74..e4955491b9 100644
@@ -11,23 +11,21 @@
 /**< ARMv8 Crypto PMD device name */
 
 extern int crypto_armv8_log_type;
+#define RTE_LOGTYPE_CRYPTO_ARMV8 crypto_armv8_log_type
 
 #define ARMV8_CRYPTO_LOG_ERR(fmt, args...)			\
-	rte_log(RTE_LOG_ERR, crypto_armv8_log_type,		\
-			"[%s] %s() line %u: " fmt "\n",		\
-			RTE_STR(CRYPTODEV_NAME_ARMV8_PMD),	\
+	RTE_LOG_LINE(ERR, CRYPTO_ARMV8,				\
+			"%s() line %u: " fmt,			\
 			__func__, __LINE__, ## args)
 
 #define ARMV8_CRYPTO_LOG_INFO(fmt, args...)			\
-	rte_log(RTE_LOG_INFO, crypto_armv8_log_type,		\
-			"[%s] %s() line %u: " fmt "\n",		\
-			RTE_STR(CRYPTODEV_NAME_ARMV8_PMD),	\
+	RTE_LOG_LINE(INFO, CRYPTO_ARMV8,			\
+			"%s() line %u: " fmt,			\
 			__func__, __LINE__, ## args)
 
 #define ARMV8_CRYPTO_LOG_DBG(fmt, args...)			\
-	rte_log(RTE_LOG_DEBUG, crypto_armv8_log_type,		\
-			"[%s] %s() line %u: " fmt "\n",		\
-			RTE_STR(CRYPTODEV_NAME_ARMV8_PMD),	\
+	RTE_LOG_LINE(DEBUG, CRYPTO_ARMV8,			\
+			"%s() line %u: " fmt,			\
 			__func__, __LINE__, ## args)
 
 #define NBBY		8		/* Number of bits in a byte */
drivers/crypto/bcmfs/bcmfs_logs.h +6 -4
index c03a49b75c..36b5fccb77 100644
@@ -9,15 +9,17 @@
 #include <rte_log.h>
 
 extern int bcmfs_conf_logtype;
+#define RTE_LOGTYPE_BCMFS_CONF bcmfs_conf_logtype
 extern int bcmfs_dp_logtype;
+#define RTE_LOGTYPE_BCMFS_DP bcmfs_dp_logtype
 
 #define BCMFS_LOG(level, fmt, args...)		\
-	rte_log(RTE_LOG_ ## level, bcmfs_conf_logtype,		\
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, BCMFS_CONF,		\
+		"%s(): " fmt, __func__, ## args)
 
 #define BCMFS_DP_LOG(level, fmt, args...)		\
-	rte_log(RTE_LOG_ ## level, bcmfs_dp_logtype,		\
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, BCMFS_DP,		\
+		"%s(): " fmt, __func__, ## args)
 
 #define BCMFS_DP_HEXDUMP_LOG(level, title, buf, len)	\
 	bcmfs_hexdump_log(RTE_LOG_ ## level, bcmfs_dp_logtype, title, buf, len)
drivers/crypto/caam_jr/caam_jr_log.h +3 -5
index 8f6aa50e2a..0198da5d4d 100644
@@ -11,12 +11,10 @@ extern int caam_jr_logtype;
 #define RTE_LOGTYPE_CAAM_JR caam_jr_logtype
 
 #define CAAM_JR_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, caam_jr_logtype, "caam_jr: " \
-		fmt "\n", ##args)
+	RTE_LOG_LINE(level, CAAM_JR, fmt, ## args)
 
 #define CAAM_JR_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, caam_jr_logtype, "caam_jr: %s(): " \
-		fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(DEBUG, CAAM_JR, "%s(): " fmt, __func__, ## args)
 
 #define PMD_INIT_FUNC_TRACE() CAAM_JR_DEBUG(" >>")
 
@@ -29,7 +27,7 @@ extern int caam_jr_logtype;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define CAAM_JR_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, CAAM_JR, fmt "\n", ## args)
+	RTE_LOG_DP_LINE(level, CAAM_JR, fmt, ## args)
 
 #define CAAM_JR_DP_DEBUG(fmt, args...) \
 	CAAM_JR_DP_LOG(DEBUG, fmt, ## args)
drivers/crypto/dpaa2_sec/dpaa2_sec_logs.h +3 -5
index ee69209504..2f17c07dc5 100644
@@ -12,12 +12,10 @@ extern int dpaa2_logtype_sec;
 #define RTE_LOGTYPE_DPAA2_SEC dpaa2_logtype_sec
 
 #define DPAA2_SEC_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa2_logtype_sec, "dpaa2_sec: " \
-		fmt "\n", ##args)
+	RTE_LOG_LINE(level, DPAA2_SEC, fmt, ## args)
 
 #define DPAA2_SEC_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaa2_logtype_sec, "dpaa2_sec: %s(): " \
-		fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(DEBUG, DPAA2_SEC, "%s(): " fmt, __func__, ## args)
 
 #define PMD_INIT_FUNC_TRACE() DPAA2_SEC_DEBUG(">>")
 
@@ -30,7 +28,7 @@ extern int dpaa2_logtype_sec;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define DPAA2_SEC_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, DPAA2_SEC, fmt, ## args)
+	RTE_LOG_DP_LINE(level, DPAA2_SEC, fmt, ## args)
 
 #define DPAA2_SEC_DP_DEBUG(fmt, args...) \
 	DPAA2_SEC_DP_LOG(DEBUG, fmt, ## args)
drivers/crypto/dpaa_sec/dpaa_sec_log.h +2 -4
index 60dbaee4ec..07ba73a7e0 100644
@@ -12,12 +12,10 @@ extern int dpaa_logtype_sec;
 #define RTE_LOGTYPE_DPAA_SEC dpaa_logtype_sec
 
 #define DPAA_SEC_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_sec, "dpaa_sec: " \
-		fmt "\n", ##args)
+	RTE_LOG_LINE(level, DPAA_SEC, fmt, ## args)
 
 #define DPAA_SEC_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaa_logtype_sec, "dpaa_sec: %s(): " \
-		fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(DEBUG, DPAA_SEC, "%s(): " fmt, __func__, ## args)
 
 #define PMD_INIT_FUNC_TRACE() DPAA_SEC_DEBUG(" >>")
 
drivers/crypto/ipsec_mb/ipsec_mb_private.h +3 -2
index d42acd913c..f0928ff14e 100644
@@ -59,9 +59,10 @@ extern RTE_DEFINE_PER_LCORE(IMB_MGR *, mb_mgr);
 
 /** PMD LOGTYPE DRIVER, common to all PMDs */
 extern int ipsec_mb_logtype_driver;
+#define RTE_LOGTYPE_IPSEC_MB ipsec_mb_logtype_driver
 #define IPSEC_MB_LOG(level, fmt, ...)                                         \
-	rte_log(RTE_LOG_##level, ipsec_mb_logtype_driver,                     \
-		"%s() line %u: " fmt "\n", __func__, __LINE__, ##__VA_ARGS__)
+	RTE_LOG_LINE(level, IPSEC_MB,                     \
+		"%s() line %u: " fmt, __func__, __LINE__, ##__VA_ARGS__)
 
 /** All supported device types */
 enum ipsec_mb_pmd_types {
drivers/crypto/mvsam/mrvl_pmd_private.h +3 -2
index 80ff229c1b..1f369a3164 100644
@@ -14,10 +14,11 @@
 
 /** MRVL PMD LOGTYPE DRIVER */
 extern int mrvl_logtype_driver;
+#define RTE_LOGTYPE_MRVL_DRIVER mrvl_logtype_driver
 
 #define MRVL_LOG(level, fmt, ...) \
-	rte_log(RTE_LOG_ ## level, mrvl_logtype_driver, \
-			"%s() line %u: " fmt "\n", __func__, __LINE__, \
+	RTE_LOG_LINE(level, MRVL_DRIVER, \
+			"%s() line %u: " fmt, __func__, __LINE__, \
 					## __VA_ARGS__)
 
 /**
drivers/crypto/null/null_crypto_pmd_private.h +3 -2
index 645a68d1da..57c33369e2 100644
@@ -9,10 +9,11 @@
 /**< Null crypto PMD device name */
 
 extern int null_logtype_driver;
+#define RTE_LOGTYPE_NULL_DRIVER null_logtype_driver
 
 #define NULL_LOG(level, fmt, ...)  \
-	rte_log(RTE_LOG_ ## level, null_logtype_driver,  \
-			"%s() line %u: "fmt "\n", __func__, __LINE__,  \
+	RTE_LOG_LINE(level, NULL_DRIVER,  \
+			"%s() line %u: "fmt, __func__, __LINE__,  \
 					## __VA_ARGS__)
 
 
drivers/crypto/openssl/openssl_pmd_private.h +3 -2
index a50e4d4918..e2bda1f1bc 100644
@@ -23,9 +23,10 @@
 
 /** OPENSSL PMD LOGTYPE DRIVER */
 extern int openssl_logtype_driver;
+#define RTE_LOGTYPE_OPENSSL_DRIVER openssl_logtype_driver
 #define OPENSSL_LOG(level, fmt, ...)  \
-	rte_log(RTE_LOG_ ## level, openssl_logtype_driver,  \
-			"%s() line %u: " fmt "\n", __func__, __LINE__,  \
+	RTE_LOG_LINE(level, OPENSSL_DRIVER,  \
+			"%s() line %u: " fmt, __func__, __LINE__,  \
 					## __VA_ARGS__)
 
 /* Maximum length for digest (SHA-512 needs 64 bytes) */
drivers/crypto/scheduler/scheduler_pmd_private.h +3 -2
index 0f0a6b4a85..81c27f9492 100644
@@ -15,10 +15,11 @@
 #define PER_WORKER_BUFF_SIZE			(256)
 
 extern int scheduler_logtype_driver;
+#define RTE_LOGTYPE_SCHEDULER_DRIVER scheduler_logtype_driver
 
 #define CR_SCHED_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, scheduler_logtype_driver,		\
-			"%s() line %u: "fmt "\n", __func__, __LINE__, ##args)
+	RTE_LOG_LINE(level, SCHEDULER_DRIVER,		\
+			"%s() line %u: "fmt, __func__, __LINE__, ##args)
 
 struct scheduler_worker {
 	uint8_t dev_id;
drivers/crypto/uadk/uadk_crypto_pmd_private.h +3 -2
index 7a35c94a4f..53f7c8a352 100644
@@ -71,10 +71,11 @@ struct __rte_cache_aligned uadk_crypto_priv {
 };
 
 extern int uadk_crypto_logtype;
+#define RTE_LOGTYPE_UADK_CRYPTO uadk_crypto_logtype
 
 #define UADK_LOG(level, fmt, ...)  \
-	rte_log(RTE_LOG_ ## level, uadk_crypto_logtype,  \
-		"%s() line %u: " fmt "\n", __func__, __LINE__,  \
+	RTE_LOG_LINE(level, UADK_CRYPTO,  \
+		"%s() line %u: " fmt, __func__, __LINE__,  \
 		## __VA_ARGS__)
 
 #endif /* _UADK_CRYPTO_PMD_PRIVATE_H_ */
drivers/crypto/virtio/virtio_logs.h +18 -12
index 1ee3819309..510be6624a 100644
@@ -8,18 +8,20 @@
 #include <rte_log.h>
 
 extern int virtio_crypto_logtype_init;
+#define RTE_LOGTYPE_VIRTIO_CRYPTO_INIT virtio_crypto_logtype_init
 
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, virtio_crypto_logtype_init, \
-		"PMD: %s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, VIRTIO_CRYPTO_INIT, \
+		"%s(): " fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 extern int virtio_crypto_logtype_init;
+#define RTE_LOGTYPE_VIRTIO_CRYPTO_INIT virtio_crypto_logtype_init
 
 #define VIRTIO_CRYPTO_INIT_LOG_IMPL(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, virtio_crypto_logtype_init, \
-		"INIT: %s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, VIRTIO_CRYPTO_INIT, \
+		"%s(): " fmt, __func__, ##args)
 
 #define VIRTIO_CRYPTO_INIT_LOG_INFO(fmt, args...) \
 	VIRTIO_CRYPTO_INIT_LOG_IMPL(INFO, fmt, ## args)
@@ -31,10 +33,11 @@ extern int virtio_crypto_logtype_init;
 	VIRTIO_CRYPTO_INIT_LOG_IMPL(ERR, fmt, ## args)
 
 extern int virtio_crypto_logtype_session;
+#define RTE_LOGTYPE_VIRTIO_CRYPTO_SESSION virtio_crypto_logtype_session
 
 #define VIRTIO_CRYPTO_SESSION_LOG_IMPL(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, virtio_crypto_logtype_session, \
-		"SESSION: %s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, VIRTIO_CRYPTO_SESSION, \
+		"%s(): " fmt, __func__, ##args)
 
 #define VIRTIO_CRYPTO_SESSION_LOG_INFO(fmt, args...) \
 	VIRTIO_CRYPTO_SESSION_LOG_IMPL(INFO, fmt, ## args)
@@ -46,10 +49,11 @@ extern int virtio_crypto_logtype_session;
 	VIRTIO_CRYPTO_SESSION_LOG_IMPL(ERR, fmt, ## args)
 
 extern int virtio_crypto_logtype_rx;
+#define RTE_LOGTYPE_VIRTIO_CRYPTO_RX virtio_crypto_logtype_rx
 
 #define VIRTIO_CRYPTO_RX_LOG_IMPL(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, virtio_crypto_logtype_rx, \
-		"RX: %s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, VIRTIO_CRYPTO_RX, \
+		"%s(): " fmt, __func__, ##args)
 
 #define VIRTIO_CRYPTO_RX_LOG_INFO(fmt, args...) \
 	VIRTIO_CRYPTO_RX_LOG_IMPL(INFO, fmt, ## args)
@@ -61,10 +65,11 @@ extern int virtio_crypto_logtype_rx;
 	VIRTIO_CRYPTO_RX_LOG_IMPL(ERR, fmt, ## args)
 
 extern int virtio_crypto_logtype_tx;
+#define RTE_LOGTYPE_VIRTIO_CRYPTO_TX virtio_crypto_logtype_tx
 
 #define VIRTIO_CRYPTO_TX_LOG_IMPL(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, virtio_crypto_logtype_tx, \
-		"TX: %s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, VIRTIO_CRYPTO_TX, \
+		"%s(): " fmt, __func__, ##args)
 
 #define VIRTIO_CRYPTO_TX_LOG_INFO(fmt, args...) \
 	VIRTIO_CRYPTO_TX_LOG_IMPL(INFO, fmt, ## args)
@@ -76,10 +81,11 @@ extern int virtio_crypto_logtype_tx;
 	VIRTIO_CRYPTO_TX_LOG_IMPL(ERR, fmt, ## args)
 
 extern int virtio_crypto_logtype_driver;
+#define RTE_LOGTYPE_VIRTIO_CRYPTO_DRIVER virtio_crypto_logtype_driver
 
 #define VIRTIO_CRYPTO_DRV_LOG_IMPL(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, virtio_crypto_logtype_driver, \
-		"DRIVER: %s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, VIRTIO_CRYPTO_DRIVER, \
+		"%s(): " fmt, __func__, ##args)
 
 #define VIRTIO_CRYPTO_DRV_LOG_INFO(fmt, args...) \
 	VIRTIO_CRYPTO_DRV_LOG_IMPL(INFO, fmt, ## args)
drivers/dma/dpaa/dpaa_qdma_logs.h +3 -5
index 95753dcd89..aa1249284b 100644
@@ -9,12 +9,10 @@ extern int dpaa_qdma_logtype;
 #define RTE_LOGTYPE_DPAA_QDMA dpaa_qdma_logtype
 
 #define DPAA_QDMA_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_qdma_logtype, "dpaa_qdma: " \
-		fmt "\n", ## args)
+	RTE_LOG_LINE(level, DPAA_QDMA, fmt, ## args)
 
 #define DPAA_QDMA_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaa_qdma_logtype, "dpaa_qdma: %s(): " \
-		fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(DEBUG, DPAA_QDMA, "%s(): " fmt, __func__, ## args)
 
 #define DPAA_QDMA_FUNC_TRACE() DPAA_QDMA_DEBUG(">>")
 
@@ -27,7 +25,7 @@ extern int dpaa_qdma_logtype;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define DPAA_QDMA_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, DPAA_QDMA, "dpaa_qdma: " fmt "\n", ## args)
+	RTE_LOG_DP_LINE(level, DPAA_QDMA, fmt, ## args)
 
 #define DPAA_QDMA_DP_DEBUG(fmt, args...) \
 	DPAA_QDMA_DP_LOG(DEBUG, fmt, ## args)
drivers/dma/dpaa2/dpaa2_qdma_logs.h +5 -5
index 37a5a5c6e9..af22786cda 100644
@@ -13,12 +13,12 @@ extern int dpaa2_qdma_logtype;
 #define RTE_LOGTYPE_DPAA2_QDMA dpaa2_qdma_logtype
 
 #define DPAA2_QDMA_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa2_qdma_logtype, "dpaa2_qdma: " \
-		fmt "\n", ## args)
+	RTE_LOG_LINE(level, DPAA2_QDMA, \
+		fmt, ## args)
 
 #define DPAA2_QDMA_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaa2_qdma_logtype, "dpaa2_qdma: %s(): " \
-		fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(DEBUG, DPAA2_QDMA, "%s(): " \
+		fmt, __func__, ## args)
 
 #define DPAA2_QDMA_FUNC_TRACE() DPAA2_QDMA_DEBUG(">>")
 
@@ -31,7 +31,7 @@ extern int dpaa2_qdma_logtype;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define DPAA2_QDMA_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, DPAA2_QDMA, "dpaa2_qdma: " fmt "\n", ## args)
+	RTE_LOG_DP_LINE(level, DPAA2_QDMA, fmt, ## args)
 
 #define DPAA2_QDMA_DP_DEBUG(fmt, args...) \
 	DPAA2_QDMA_DP_LOG(DEBUG, fmt, ## args)
drivers/dma/hisilicon/hisi_dmadev.c +8 -9
index bce4b4b277..8b548dd1d8 100644
@@ -18,21 +18,20 @@
 #include "hisi_dmadev.h"
 
 RTE_LOG_REGISTER_DEFAULT(hisi_dma_logtype, INFO);
+#define RTE_LOGTYPE_HISI_DMA hisi_dma_logtype
 #define HISI_DMA_LOG(level, fmt, args...) \
-		rte_log(RTE_LOG_ ## level, hisi_dma_logtype, \
-		"%s(): " fmt "\n", __func__, ##args)
-#define HISI_DMA_LOG_RAW(hw, level, fmt, args...) \
-		rte_log(RTE_LOG_ ## level, hisi_dma_logtype, \
-		"%s %s(): " fmt "\n", (hw)->data->dev_name, \
+	RTE_LOG_LINE(level, HISI_DMA, "%s(): " fmt, __func__, ##args)
+#define HISI_DMA_DEV_LOG(hw, level, fmt, args...) \
+	RTE_LOG_LINE(level, HISI_DMA, "%s %s(): " fmt, (hw)->data->dev_name, \
 		__func__, ##args)
 #define HISI_DMA_DEBUG(hw, fmt, args...) \
-		HISI_DMA_LOG_RAW(hw, DEBUG, fmt, ## args)
+	HISI_DMA_DEV_LOG(hw, DEBUG, fmt, ## args)
 #define HISI_DMA_INFO(hw, fmt, args...) \
-		HISI_DMA_LOG_RAW(hw, INFO, fmt, ## args)
+	HISI_DMA_DEV_LOG(hw, INFO, fmt, ## args)
 #define HISI_DMA_WARN(hw, fmt, args...) \
-		HISI_DMA_LOG_RAW(hw, WARNING, fmt, ## args)
+	HISI_DMA_DEV_LOG(hw, WARNING, fmt, ## args)
 #define HISI_DMA_ERR(hw, fmt, args...) \
-		HISI_DMA_LOG_RAW(hw, ERR, fmt, ## args)
+	HISI_DMA_DEV_LOG(hw, ERR, fmt, ## args)
 
 static uint32_t
 hisi_dma_queue_base(struct hisi_dma_dev *hw)
drivers/dma/idxd/idxd_internal.h +3 -2
index 537cf9b1cf..65ea7b6f67 100644
@@ -20,9 +20,10 @@
  */
 
 extern int idxd_pmd_logtype;
+#define RTE_LOGTYPE_IDXD_PMD idxd_pmd_logtype
 
-#define IDXD_PMD_LOG(level, fmt, args...) rte_log(RTE_LOG_ ## level, \
-		idxd_pmd_logtype, "IDXD: %s(): " fmt "\n", __func__, ##args)
+#define IDXD_PMD_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, IDXD_PMD, "%s(): " fmt, __func__, ##args)
 
 #define IDXD_PMD_DEBUG(fmt, args...)  IDXD_PMD_LOG(DEBUG, fmt, ## args)
 #define IDXD_PMD_INFO(fmt, args...)   IDXD_PMD_LOG(INFO, fmt, ## args)
drivers/dma/ioat/ioat_internal.h +3 -2
index f4285c50f0..8cdada9018 100644
@@ -35,9 +35,10 @@ struct ioat_dmadev {
 };
 
 extern int ioat_pmd_logtype;
+#define RTE_LOGTYPE_IOAT_PMD ioat_pmd_logtype
 
-#define IOAT_PMD_LOG(level, fmt, args...) rte_log(RTE_LOG_ ## level, \
-		ioat_pmd_logtype, "IOAT: %s(): " fmt "\n", __func__, ##args)
+#define IOAT_PMD_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, IOAT_PMD, "%s(): " fmt, __func__, ##args)
 
 #define IOAT_PMD_DEBUG(fmt, args...)  IOAT_PMD_LOG(DEBUG, fmt, ## args)
 #define IOAT_PMD_INFO(fmt, args...)   IOAT_PMD_LOG(INFO, fmt, ## args)
drivers/dma/odm/odm.h +6 -5
index 274c21ef8d..c63ceb9902 100644
@@ -13,8 +13,6 @@
 #include <rte_log.h>
 #include <rte_memzone.h>
 
-extern int odm_logtype;
-
 /* ODM VF register offsets from VF_BAR0 */
 #define ODM_VDMA_EN(x)		(0x00 | (x << 3))
 #define ODM_VDMA_REQQ_CTL(x)	(0x80 | (x << 3))
@@ -66,10 +64,13 @@ extern int odm_logtype;
 #define odm_read64(addr)       rte_read64_relaxed((volatile void *)(addr))
 #define odm_write64(val, addr) rte_write64_relaxed((val), (volatile void *)(addr))
 
+extern int odm_logtype;
+#define RTE_LOGTYPE_ODM odm_logtype
+
 #define ODM_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, odm_logtype, \
-		RTE_FMT("%s(): %u" RTE_FMT_HEAD(__VA_ARGS__,) "\n", __func__, __LINE__, \
-			RTE_FMT_TAIL(__VA_ARGS__, )))
+	RTE_LOG_LINE(level, ODM, \
+		RTE_FMT("%s(): %u" RTE_FMT_HEAD(__VA_ARGS__ ,), __func__, __LINE__, \
+			RTE_FMT_TAIL(__VA_ARGS__ ,)))
 
 /*
  * Structure odm_instr_hdr_s for ODM
drivers/dma/skeleton/skeleton_dmadev.c +2 -1
index 4b18fb3767..23dd305d09 100644
@@ -21,8 +21,9 @@
 #include "skeleton_dmadev.h"
 
 RTE_LOG_REGISTER_DEFAULT(skeldma_logtype, INFO);
+#define RTE_LOGTYPE_SKELDMA skeldma_logtype
 #define SKELDMA_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, skeldma_logtype, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, SKELDMA, "%s(): " fmt, \
 		__func__, ##args)
 
 static int
drivers/event/dpaa/dpaa_eventdev.c +1 -0
index f8cf48bd2e..85ccb586ef 100644
@@ -48,6 +48,7 @@
  * 1 Eventdev can have N Eventqueue
  */
 RTE_LOG_REGISTER_DEFAULT(dpaa_logtype_eventdev, NOTICE);
+#define RTE_LOGTYPE_DPAA_EVENTDEV dpaa_logtype_eventdev
 
 #define DISABLE_INTR_MODE "disable_intr"
 
drivers/event/dpaa/dpaa_eventdev.h +1 -1
index b4535c7b86..1d3f9036e9 100644
@@ -78,7 +78,7 @@ struct dpaa_eventdev {
 };
 
 #define DPAA_EVENTDEV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_eventdev, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, DPAA_EVENTDEV, "%s(): " fmt, \
 		__func__, ##args)
 
 #define EVENTDEV_INIT_FUNC_TRACE() DPAA_EVENTDEV_LOG(DEBUG, " >>")
drivers/event/dpaa2/dpaa2_eventdev_logs.h +3 -4
index b894fb3299..21a12f5cc2 100644
@@ -6,14 +6,13 @@
 #define _DPAA2_EVENTDEV_LOGS_H_
 
 extern int dpaa2_logtype_event;
+#define RTE_LOGTYPE_DPAA2_EVENT dpaa2_logtype_event
 
 #define DPAA2_EVENTDEV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa2_logtype_event, "dpaa2_event: " \
-		fmt "\n", ##args)
+	RTE_LOG_LINE(level, DPAA2_EVENT, fmt, ##args)
 
 #define DPAA2_EVENTDEV_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaa2_logtype_event, "dpaa2_event: %s(): " \
-		fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(DEBUG, DPAA2_EVENT, "%s():" fmt, __func__, ##args)
 
 #define EVENTDEV_INIT_FUNC_TRACE() DPAA2_EVENTDEV_DEBUG(" >>")
 
drivers/event/dsw/dsw_evdev.h +1 -1
index ca7aec575c..3372728f8b 100644
@@ -303,7 +303,7 @@ dsw_pmd_priv(const struct rte_eventdev *eventdev)
 }
 
 #define DSW_LOG_DP_LINE(level, fmt, args...)				\
-	RTE_LOG_DP(level, EVENTDEV, "[%s] %s() line %u: " fmt "\n",	\
+	RTE_LOG_DP_LINE(level, EVENTDEV, "[%s] %s() line %u: " fmt,	\
 		   DSW_PMD_NAME,					\
 		   __func__, __LINE__, ## args)
 
drivers/event/octeontx/ssovf_evdev.h +3 -2
index 293eb85a40..59fdc21b59 100644
@@ -20,8 +20,8 @@
 #define EVENTDEV_NAME_OCTEONTX_PMD event_octeontx
 
 #define SSOVF_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, otx_logtype_ssovf, \
-			"[%s] %s() " fmt "\n", \
+	RTE_LOG_LINE(level, OTX_SSOVF, \
+			"[%s] %s() " fmt, \
 			RTE_STR(EVENTDEV_NAME_OCTEONTX_PMD), __func__, ## args)
 
 #define ssovf_log_info(fmt, ...) SSOVF_LOG(INFO, fmt, ##__VA_ARGS__)
@@ -171,6 +171,7 @@ ssovf_pmd_priv(const struct rte_eventdev *eventdev)
 }
 
 extern int otx_logtype_ssovf;
+#define RTE_LOGTYPE_OTX_SSOVF otx_logtype_ssovf
 
 uint16_t ssows_enq(void *port, const struct rte_event *ev);
 uint16_t ssows_enq_burst(void *port,
drivers/event/octeontx/timvf_evdev.h +3 -2
index 3a2dc475e3..00ea9a8420 100644
@@ -27,8 +27,8 @@
 #include <octeontx_fpavf.h>
 
 #define timvf_log(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, otx_logtype_timvf, \
-			"[%s] %s() " fmt "\n", \
+	RTE_LOG_LINE(level, OTX_TIMVF, \
+			"[%s] %s() " fmt, \
 			RTE_STR(event_timer_octeontx), __func__, ## args)
 
 #define timvf_log_info(fmt, ...) timvf_log(INFO, fmt, ##__VA_ARGS__)
@@ -113,6 +113,7 @@
 #define TIMVF_ENABLE_STATS_ARG               ("timvf_stats")
 
 extern int otx_logtype_timvf;
+#define RTE_LOGTYPE_OTX_TIMVF otx_logtype_timvf
 static const uint16_t nb_chunk_slots = (TIM_CHUNK_SIZE / 16) - 1;
 
 enum timvf_clk_src {
drivers/event/opdl/opdl_log.h +2 -7
index ae5221c1e4..eefbace1ee 100644
@@ -8,14 +8,9 @@
 #include <rte_log.h>
 
 extern int opdl_logtype_driver;
-
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, opdl_logtype_driver, "%s(): " fmt, \
-			__func__, ## args)
+#define RTE_LOGTYPE_OPDL opdl_logtype_driver
 
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
-
-
+	RTE_LOG_LINE(level, OPDL, "%s(): " fmt, __func__, ## args)
 
 #endif /* _OPDL_LOGS_H_ */
drivers/event/skeleton/skeleton_eventdev.h +3 -4
index 283342ac19..96060b4048 100644
@@ -9,11 +9,11 @@
 #include <eventdev_pmd_vdev.h>
 
 extern int skeleton_eventdev_logtype;
+#define RTE_LOGTYPE_SKELETON_EVENTDEV skeleton_eventdev_logtype
 
 #ifdef RTE_LIBRTE_PMD_SKELETON_EVENTDEV_DEBUG
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, skeleton_eventdev_logtype, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, SKELETON_EVENTDEV, "%s(): " fmt, __func__, ## args)
 #define PMD_DRV_FUNC_TRACE() PMD_DRV_LOG(DEBUG, ">>")
 #else
 #define PMD_DRV_LOG(level, fmt, args...) do { } while (0)
@@ -21,8 +21,7 @@ extern int skeleton_eventdev_logtype;
 #endif
 
 #define PMD_DRV_ERR(fmt, args...) \
-	rte_log(RTE_LOG_ERR, skeleton_eventdev_logtype, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(ERR, SKELETON_EVENTDEV, "%s(): " fmt, __func__, ## args)
 
 struct __rte_cache_aligned skeleton_eventdev {
 	uintptr_t reg_base;
drivers/event/sw/sw_evdev_log.h +2 -1
index f76825abc5..a0fa9586b6 100644
@@ -6,9 +6,10 @@
 #define _SW_EVDEV_LOG_H_
 
 extern int eventdev_sw_log_level;
+#define RTE_LOGTYPE_EVENTDEV_SW_LOG_LEVEL eventdev_sw_log_level
 
 #define SW_LOG_IMPL(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, eventdev_sw_log_level, "%s" fmt "\n", \
+	RTE_LOG_LINE(level, EVENTDEV_SW_LOG_LEVEL, "%s" fmt, \
 			__func__, ##args)
 
 #define SW_LOG_INFO(fmt, args...) \
drivers/gpu/cuda/common.h +2 -1
index e809988503..e098418401 100644
@@ -13,10 +13,11 @@
 #include <rte_errno.h>
 
 extern int cuda_logtype;
+#define RTE_LOGTYPE_CUDA cuda_logtype
 
 /* Helper macro for logging */
 #define rte_cuda_log(level, fmt, ...) \
-	rte_log(RTE_LOG_ ## level, cuda_logtype, fmt "\n", ##__VA_ARGS__)
+	RTE_LOG_LINE(level, CUDA, fmt, ##__VA_ARGS__)
 
 #define rte_cuda_debug(fmt, ...) \
 	rte_cuda_log(DEBUG, RTE_STR(__LINE__) ":%s() " fmt, __func__, \
drivers/mempool/dpaa/dpaa_mempool.h +1 -2
index 153fefd507..c49f085424 100644
@@ -61,8 +61,7 @@ extern struct dpaa_bp_info *rte_dpaa_bpid_info;
 /* Mempool related logs */
 
 #define DPAA_MEMPOOL_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_mempool, "%s(): " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(level, DPAA_MEMPOOL, "%s(): " fmt, __func__, ## args)
 
 #define MEMPOOL_INIT_FUNC_TRACE() DPAA_MEMPOOL_LOG(DEBUG, " >>")
 
drivers/mempool/dpaa2/dpaa2_hw_mempool_logs.h +2 -4
index fbc8cb30a2..577f889abf 100644
@@ -9,13 +9,11 @@ extern int dpaa2_logtype_mempool;
 #define RTE_LOGTYPE_DPAA2_MEMPOOL dpaa2_logtype_mempool
 
 #define DPAA2_MEMPOOL_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa2_logtype_mempool, \
-		"mempool/dpaa2: " fmt "\n", ##args)
+	RTE_LOG_LINE(level, DPAA2_MEMPOOL, fmt, ##args)
 
 /* Debug logs are with Function names */
 #define DPAA2_MEMPOOL_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaa2_logtype_mempool, \
-		"mempool/dpaa2: %s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(DEBUG, DPAA2_MEMPOOL, "%s(): " fmt, __func__, ##args)
 
 #define DPAA2_MEMPOOL_INFO(fmt, args...) \
 	DPAA2_MEMPOOL_LOG(INFO, fmt, ## args)
drivers/mempool/octeontx/octeontx_pool_logs.h +3 -2
index 7b4e1b3877..8703891a8a 100644
@@ -8,8 +8,8 @@
 #include <rte_debug.h>
 
 #define FPAVF_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, octeontx_logtype_fpavf,\
-			"%s() line %u: " fmt "\n", __func__, __LINE__, ## args)
+	RTE_LOG_LINE(level, OCTEONTX_FPAVF,\
+			"%s() line %u: " fmt, __func__, __LINE__, ## args)
 
 #define fpavf_log_info(fmt, ...) FPAVF_LOG(INFO, fmt, ##__VA_ARGS__)
 #define fpavf_log_dbg(fmt, ...) FPAVF_LOG(DEBUG, fmt, ##__VA_ARGS__)
@@ -18,5 +18,6 @@
 
 
 extern int octeontx_logtype_fpavf;
+#define RTE_LOGTYPE_OCTEONTX_FPAVF octeontx_logtype_fpavf
 
 #endif /* __OCTEONTX_POOL_LOGS_H__*/
drivers/net/af_packet/rte_eth_af_packet.c +5 -4
index 6b7b16f348..9be27973f0 100644
@@ -102,14 +102,15 @@ static struct rte_eth_link pmd_link = {
 };
 
 RTE_LOG_REGISTER_DEFAULT(af_packet_logtype, NOTICE);
+#define RTE_LOGTYPE_AFPACKET af_packet_logtype
 
 #define PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, af_packet_logtype, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, AFPACKET, \
+		"%s(): " fmt, __func__, ##args)
 
 #define PMD_LOG_ERRNO(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, af_packet_logtype, \
-		"%s(): " fmt ":%s\n", __func__, ##args, strerror(errno))
+	RTE_LOG_LINE(level, AFPACKET, \
+		"%s(): " fmt ":%s", __func__, ##args, strerror(errno))
 
 static uint16_t
 eth_af_packet_rx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
drivers/net/af_xdp/rte_eth_af_xdp.c +1 -1
index 676006ce0d..8ac8ebe4d2 100644
@@ -66,7 +66,7 @@ RTE_LOG_REGISTER_DEFAULT(af_xdp_logtype, NOTICE);
 #define RTE_LOGTYPE_NET_AF_XDP af_xdp_logtype
 
 #define AF_XDP_LOG_LINE(level, fmt, args...) \
-	RTE_LOG(level, NET_AF_XDP, "%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, NET_AF_XDP, "%s(): " fmt, __func__, ##args)
 
 #define ETH_AF_XDP_FRAME_SIZE		2048
 #define ETH_AF_XDP_NUM_BUFFERS		4096
drivers/net/atlantic/atl_logs.h +7 -9
index 14a7a1de1d..2b962f61ea 100644
@@ -7,26 +7,24 @@
 #include <rte_log.h>
 
 extern int atl_logtype_init;
+#define RTE_LOGTYPE_ATL_INIT atl_logtype_init
 
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, atl_logtype_init, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, ATL_INIT, \
+		"%s(): " fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 #define PMD_RX_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, ATL_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_DP_LINE(level, ATL_DRIVER, "%s(): " fmt, __func__, ## args)
 
 #define PMD_TX_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, ATL_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_DP_LINE(level, ATL_DRIVER, "%s(): " fmt, __func__, ## args)
 
 extern int atl_logtype_driver;
 #define RTE_LOGTYPE_ATL_DRIVER atl_logtype_driver
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, atl_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG_LINE(level, ATL_DRIVER, "%s(): " fmt, \
+		__func__, ## args)
 
 #endif
drivers/net/avp/avp_logs.h +3 -3
index 3f2721df1a..2839f52865 100644
@@ -9,14 +9,14 @@
 
 #ifdef RTE_LIBRTE_AVP_DEBUG_RX
 #define PMD_RX_LOG_LINE(level, fmt, ...) \
-	RTE_LOG(level, AVP_DRIVER, "%s() rx: " fmt "\n", __func__, ## __VA_ARGS__)
+	RTE_LOG_LINE(level, AVP_DRIVER, "%s() rx: " fmt, __func__, ## __VA_ARGS__)
 #else
 #define PMD_RX_LOG_LINE(...) do { } while (0)
 #endif
 
 #ifdef RTE_LIBRTE_AVP_DEBUG_TX
 #define PMD_TX_LOG_LINE(level, fmt, ...) \
-	RTE_LOG(level, AVP_DRIVER, "%s() tx: " fmt "\n", __func__, ## __VA_ARGS__)
+	RTE_LOG_LINE(level, AVP_DRIVER, "%s() tx: " fmt, __func__, ## __VA_ARGS__)
 #else
 #define PMD_TX_LOG_LINE(...) do { } while (0)
 #endif
@@ -25,6 +25,6 @@ extern int avp_logtype_driver;
 #define RTE_LOGTYPE_AVP_DRIVER avp_logtype_driver
 
 #define PMD_DRV_LOG_LINE(level, fmt, ...) \
-	RTE_LOG(level, AVP_DRIVER, "%s(): " fmt "\n", __func__, ## __VA_ARGS__)
+	RTE_LOG_LINE(level, AVP_DRIVER, "%s(): " fmt, __func__, ## __VA_ARGS__)
 
 #endif /* _AVP_LOGS_H_ */
drivers/net/axgbe/axgbe_logs.h +3 -3
index 3962895c5a..1088f29b4f 100644
@@ -8,9 +8,9 @@
 #include <stdio.h>
 
 extern int axgbe_logtype_init;
+#define RTE_LOGTYPE_AXGBE_INIT axgbe_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, axgbe_logtype_init, "%s(): " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(level, AXGBE_INIT, "%s(): " fmt, __func__, ##args)
 
 #ifdef RTE_LIBRTE_AXGBE_PMD_DEBUG
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
@@ -21,6 +21,6 @@ extern int axgbe_logtype_init;
 extern int axgbe_logtype_driver;
 #define RTE_LOGTYPE_AXGBE_DRIVER axgbe_logtype_driver
 #define PMD_DRV_LOG_LINE(level, fmt, ...) \
-	RTE_LOG(level, AXGBE_DRIVER, "%s(): " fmt "\n", __func__, ## __VA_ARGS__)
+	RTE_LOG_LINE(level, AXGBE_DRIVER, "%s(): " fmt, __func__, ## __VA_ARGS__)
 
 #endif /* _AXGBE_LOGS_H_ */
drivers/net/bnx2x/bnx2x_logs.h +12 -13
index f0cf69c163..76e8eb9afd 100644
@@ -9,41 +9,40 @@
 #define _PMD_LOGS_H_
 
 extern int bnx2x_logtype_init;
+#define RTE_LOGTYPE_BNX2X_INIT bnx2x_logtype_init
 #define PMD_INIT_LOG(level, sc, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, bnx2x_logtype_init, \
-	"[bnx2x_pmd: %s] %s() " fmt "\n", (sc)->devinfo.name, __func__, ##args)
+	RTE_LOG_LINE(level, BNX2X_INIT, \
+	"[%s] %s() " fmt, (sc)->devinfo.name, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE(sc) PMD_INIT_LOG(DEBUG, sc, " >>")
 
 extern int bnx2x_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, sc, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, bnx2x_logtype_driver, \
+#define RTE_LOGTYPE_BNX2X_DRIVER bnx2x_logtype_driver
+#define PMD_DRV_LOG(level, sc, fmt, args...) \
+	RTE_LOG_LINE(level, BNX2X_DRIVER, \
 		"[%s:%d(%s)] " fmt,	__func__, __LINE__, \
 		(sc)->devinfo.name ? (sc)->devinfo.name : "", ## args)
 
-#define PMD_DRV_LOG(level, sc, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, sc, fmt "\n", ## args)
-
 #ifdef RTE_LIBRTE_BNX2X_DEBUG_RX
 #define PMD_RX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, bnx2x_logtype_driver, \
-	"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, BNX2X_DRIVER, \
+	"%s(): " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while(0)
 #endif
 
 #ifdef RTE_LIBRTE_BNX2X_DEBUG_TX
 #define PMD_TX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, bnx2x_logtype_driver, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, BNX2X_DRIVER, \
+		"%s(): " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while(0)
 #endif
 
 #ifdef RTE_LIBRTE_BNX2X_DEBUG_PERIODIC
 #define PMD_DEBUG_PERIODIC_LOG(level, sc, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, bnx2x_logtype_driver, \
-		"%s(%s): " fmt "\n", __func__, \
+	RTE_LOG_LINE(level, BNX2X_DRIVER, \
+		"%s(%s): " fmt, __func__, \
 		(sc)->devinfo.name ? (sc)->devinfo.name : "", ## args)
 #else
 #define PMD_DEBUG_PERIODIC_LOG(level, sc, fmt, args...) do { } while (0)
drivers/net/bnxt/bnxt.h +1 -1
index 8ac20961d9..65b6a37352 100644
@@ -1208,7 +1208,7 @@ extern const struct rte_flow_ops bnxt_flow_meter_ops;
 extern int bnxt_logtype_driver;
 #define RTE_LOGTYPE_BNXT bnxt_logtype_driver
 #define PMD_DRV_LOG_LINE(level, fmt, ...) \
-	RTE_LOG(level, BNXT, "%s(): " fmt "\n", __func__, ## __VA_ARGS__)
+	RTE_LOG_LINE(level, BNXT, "%s(): " fmt, __func__, ## __VA_ARGS__)
 
 #define BNXT_LINK_SPEEDS_V2_OPTIONS(f) \
 	((f) & HWRM_PORT_PHY_QCFG_OUTPUT_OPTION_FLAGS_SPEEDS2_SUPPORTED)
drivers/net/bnxt/bnxt_rxtx_vec_neon.c +2 -2
index 0ff1641c19..355d41bbd3 100644
@@ -357,8 +357,8 @@ bnxt_handle_tx_cp_vec(struct bnxt_tx_queue *txq)
 		if (likely(CMP_TYPE(txcmp) == TX_CMPL_TYPE_TX_L2))
 			nb_tx_pkts += txcmp->opaque;
 		else
-			RTE_LOG_DP(ERR, BNXT,
-				   "Unhandled CMP type %02x\n",
+			RTE_LOG_DP_LINE(ERR, BNXT,
+				   "Unhandled CMP type %02x",
 				   CMP_TYPE(txcmp));
 		raw_cons = NEXT_RAW_CMP(raw_cons);
 	} while (nb_tx_pkts < ring_mask);
drivers/net/bnxt/bnxt_rxtx_vec_sse.c +2 -2
index 9f1a02f0ab..c1c3e1ecaf 100644
@@ -578,8 +578,8 @@ bnxt_handle_tx_cp_vec(struct bnxt_tx_queue *txq)
 		if (likely(CMP_TYPE(txcmp) == TX_CMPL_TYPE_TX_L2))
 			nb_tx_pkts += txcmp->opaque;
 		else
-			RTE_LOG_DP(ERR, BNXT,
-				   "Unhandled CMP type %02x\n",
+			RTE_LOG_DP_LINE(ERR, BNXT,
+				   "Unhandled CMP type %02x",
 				   CMP_TYPE(txcmp));
 		raw_cons = NEXT_RAW_CMP(raw_cons);
 	} while (nb_tx_pkts < ring_mask);
drivers/net/bnxt/bnxt_txr.c +2 -2
index 6a38c7c6e4..9087fd4e6c 100644
@@ -548,8 +548,8 @@ static int bnxt_handle_tx_cp(struct bnxt_tx_queue *txq)
 		if (CMP_TYPE(txcmp) == TX_CMPL_TYPE_TX_L2)
 			nb_tx_pkts += opaque;
 		else
-			RTE_LOG_DP(ERR, BNXT,
-					"Unhandled CMP type %02x\n",
+			RTE_LOG_DP_LINE(ERR, BNXT,
+					"Unhandled CMP type %02x",
 					CMP_TYPE(txcmp));
 		raw_cons = NEXT_RAW_CMP(raw_cons);
 	} while (nb_tx_pkts < ring_mask);
drivers/net/cpfl/cpfl_logs.h +6 -6
index bdfa5c41a5..a45cc0cbc3 100644
@@ -8,21 +8,21 @@
 #include <rte_log.h>
 
 extern int cpfl_logtype_init;
+#define RTE_LOGTYPE_CPFL_INIT cpfl_logtype_init
 extern int cpfl_logtype_driver;
+#define RTE_LOGTYPE_CPFL_DRIVER cpfl_logtype_driver
 
 #define PMD_INIT_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, \
-		cpfl_logtype_init, \
+	RTE_LOG_LINE(level, CPFL_INIT, \
 		RTE_FMT("%s(): " \
-			RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
+			RTE_FMT_HEAD(__VA_ARGS__,), \
 			__func__, \
 			RTE_FMT_TAIL(__VA_ARGS__,)))
 
 #define PMD_DRV_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, \
-		cpfl_logtype_driver, \
+	RTE_LOG_LINE(level, CPFL_DRIVER, \
 		RTE_FMT("%s(): " \
-			RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
+			RTE_FMT_HEAD(__VA_ARGS__,), \
 			__func__, \
 			RTE_FMT_TAIL(__VA_ARGS__,)))
 
drivers/net/dpaa/dpaa_ethdev.h +2 -2
index b6c61b8b6b..e8dcd29a45 100644
@@ -217,7 +217,7 @@ extern int dpaa_logtype_pmd;
 #define RTE_LOGTYPE_DPAA_PMD dpaa_logtype_pmd
 
 #define DPAA_PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_pmd, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, DPAA_PMD, "%s(): " fmt, \
 		__func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() DPAA_PMD_LOG(DEBUG, " >>")
@@ -233,6 +233,6 @@ extern int dpaa_logtype_pmd;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define DPAA_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, DPAA_PMD, fmt, ## args)
+	RTE_LOG_DP_LINE(level, DPAA_PMD, fmt, ## args)
 
 #endif
drivers/net/dpaa2/dpaa2_pmd_logs.h +4 -6
index af895a6b6e..634b80bb1b 100644
@@ -6,15 +6,13 @@
 #define _DPAA2_PMD_LOGS_H_
 
 extern int dpaa2_logtype_pmd;
-#define RTE_LOGTYPE_DPAA2_PMD dpaa2_logtype_pmd
+#define RTE_LOGTYPE_DPAA2_NET dpaa2_logtype_pmd
 
 #define DPAA2_PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa2_logtype_pmd, "dpaa2_net: " \
-		fmt "\n", ##args)
+	RTE_LOG_LINE(level, DPAA2_NET, fmt, ##args)
 
 #define DPAA2_PMD_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaa2_logtype_pmd, "dpaa2_net: %s(): "\
-		fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(DEBUG, DPAA2_NET, "%s(): " fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() DPAA2_PMD_DEBUG(">>")
 
@@ -29,7 +27,7 @@ extern int dpaa2_logtype_pmd;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define DPAA2_PMD_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, DPAA2_PMD, fmt, ## args)
+	RTE_LOG_DP_LINE(level, DPAA2_NET, fmt, ## args)
 
 #define DPAA2_PMD_DP_DEBUG(fmt, args...) \
 	DPAA2_PMD_DP_LOG(DEBUG, fmt, ## args)
drivers/net/dpaa2/dpaa2_rxtx.c +15 -15
index b64232b88f..92e9dd40dc 100644
@@ -399,7 +399,7 @@ eth_fd_to_mbuf(const struct qbman_fd *fd,
 		mbuf->packet_type = dpaa2_dev_rx_parse(mbuf, hw_annot_addr);
 
 	DPAA2_PMD_DP_DEBUG("to mbuf - mbuf =%p, mbuf->buf_addr =%p, off = %d,"
-		"fd_off=%d fd =%" PRIx64 ", meta = %d  bpid =%d, len=%d\n",
+		"fd_off=%d fd =%" PRIx64 ", meta = %d  bpid =%d, len=%d",
 		mbuf, mbuf->buf_addr, mbuf->data_off,
 		DPAA2_GET_FD_OFFSET(fd), DPAA2_GET_FD_ADDR(fd),
 		rte_dpaa2_bpid_info[DPAA2_GET_FD_BPID(fd)].meta_data_size,
@@ -446,7 +446,7 @@ eth_mbuf_to_sg_fd(struct rte_mbuf *mbuf,
 	} else {
 		temp = rte_pktmbuf_alloc(dpaa2_tx_sg_pool);
 		if (temp == NULL) {
-			DPAA2_PMD_DP_DEBUG("No memory to allocate S/G table\n");
+			DPAA2_PMD_DP_DEBUG("No memory to allocate S/G table");
 			return -ENOMEM;
 		}
 		DPAA2_SET_ONLY_FD_BPID(fd, mempool_to_bpid(dpaa2_tx_sg_pool));
@@ -543,7 +543,7 @@ eth_mbuf_to_fd(struct rte_mbuf *mbuf,
 	DPAA2_MBUF_TO_CONTIG_FD(mbuf, fd, bpid);
 
 	DPAA2_PMD_DP_DEBUG("mbuf =%p, mbuf->buf_addr =%p, off = %d,"
-		"fd_off=%d fd =%" PRIx64 ", meta = %d  bpid =%d, len=%d\n",
+		"fd_off=%d fd =%" PRIx64 ", meta = %d  bpid =%d, len=%d",
 		mbuf, mbuf->buf_addr, mbuf->data_off,
 		DPAA2_GET_FD_OFFSET(fd), DPAA2_GET_FD_ADDR(fd),
 		rte_dpaa2_bpid_info[DPAA2_GET_FD_BPID(fd)].meta_data_size,
@@ -587,7 +587,7 @@ eth_copy_mbuf_to_fd(struct rte_mbuf *mbuf,
 
 	if (rte_dpaa2_mbuf_alloc_bulk(
 		rte_dpaa2_bpid_info[bpid].bp_list->mp, &mb, 1)) {
-		DPAA2_PMD_DP_DEBUG("Unable to allocated DPAA2 buffer\n");
+		DPAA2_PMD_DP_DEBUG("Unable to allocated DPAA2 buffer");
 		return -1;
 	}
 	m = (struct rte_mbuf *)mb;
@@ -609,7 +609,7 @@ eth_copy_mbuf_to_fd(struct rte_mbuf *mbuf,
 #endif
 	DPAA2_PMD_DP_DEBUG(
 		"mbuf: %p, BMAN buf addr: %p, fdaddr: %" PRIx64 ", bpid: %d,"
-		" meta: %d, off: %d, len: %d\n",
+		" meta: %d, off: %d, len: %d",
 		(void *)mbuf,
 		mbuf->buf_addr,
 		DPAA2_GET_FD_ADDR(fd),
@@ -656,7 +656,7 @@ dump_err_pkts(struct dpaa2_queue *dpaa2_q)
 
 	while (1) {
 		if (qbman_swp_pull(swp, &pulldesc)) {
-			DPAA2_PMD_DP_DEBUG("VDQ command is not issued.QBMAN is busy\n");
+			DPAA2_PMD_DP_DEBUG("VDQ command is not issued.QBMAN is busy");
 			/* Portal was busy, try again */
 			continue;
 		}
@@ -765,7 +765,7 @@ dpaa2_dev_prefetch_rx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 		while (1) {
 			if (qbman_swp_pull(swp, &pulldesc)) {
 				DPAA2_PMD_DP_DEBUG("VDQ command is not issued."
-						  " QBMAN is busy (1)\n");
+						  " QBMAN is busy (1)");
 				/* Portal was busy, try again */
 				continue;
 			}
@@ -861,7 +861,7 @@ dpaa2_dev_prefetch_rx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 	while (1) {
 		if (qbman_swp_pull(swp, &pulldesc)) {
 			DPAA2_PMD_DP_DEBUG("VDQ command is not issued."
-					  "QBMAN is busy (2)\n");
+					  "QBMAN is busy (2)");
 			continue;
 		}
 		break;
@@ -1002,7 +1002,7 @@ dpaa2_dev_rx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 		while (1) {
 			if (qbman_swp_pull(swp, &pulldesc)) {
 				DPAA2_PMD_DP_DEBUG(
-					"VDQ command is not issued.QBMAN is busy\n");
+					"VDQ command is not issued.QBMAN is busy");
 				/* Portal was busy, try again */
 				continue;
 			}
@@ -1126,7 +1126,7 @@ uint16_t dpaa2_dev_tx_conf(void *queue)
 		while (1) {
 			if (qbman_swp_pull(swp, &pulldesc)) {
 				DPAA2_PMD_DP_DEBUG("VDQ command is not issued."
-						   "QBMAN is busy\n");
+						   "QBMAN is busy");
 				/* Portal was busy, try again */
 				continue;
 			}
@@ -1263,7 +1263,7 @@ dpaa2_dev_tx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 	}
 	swp = DPAA2_PER_LCORE_PORTAL;
 
-	DPAA2_PMD_DP_DEBUG("===> eth_data =%p, fqid =%d\n",
+	DPAA2_PMD_DP_DEBUG("===> eth_data =%p, fqid =%d",
 			eth_data, dpaa2_q->fqid);
 
 #ifdef RTE_LIBRTE_IEEE1588
@@ -1598,7 +1598,7 @@ dpaa2_dev_tx_multi_txq_ordered(void **queue,
 			}
 		}
 
-		DPAA2_PMD_DP_DEBUG("===> eth_data =%p, fqid =%d\n",
+		DPAA2_PMD_DP_DEBUG("===> eth_data =%p, fqid =%d",
 				   eth_data, dpaa2_q[loop]->fqid);
 
 		/* Check if the queue is congested */
@@ -1754,7 +1754,7 @@ dpaa2_dev_tx_ordered(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 	}
 	swp = DPAA2_PER_LCORE_PORTAL;
 
-	DPAA2_PMD_DP_DEBUG("===> eth_data =%p, fqid =%d\n",
+	DPAA2_PMD_DP_DEBUG("===> eth_data =%p, fqid =%d",
 			   eth_data, dpaa2_q->fqid);
 
 	/* This would also handle normal and atomic queues as any type
@@ -1989,7 +1989,7 @@ dpaa2_dev_loopback_rx(void *queue,
 		while (1) {
 			if (qbman_swp_pull(swp, &pulldesc)) {
 				DPAA2_PMD_DP_DEBUG(
-					"VDQ command not issued.QBMAN busy\n");
+					"VDQ command not issued.QBMAN busy");
 				/* Portal was busy, try again */
 				continue;
 			}
@@ -2071,7 +2071,7 @@ dpaa2_dev_loopback_rx(void *queue,
 	while (1) {
 		if (qbman_swp_pull(swp, &pulldesc)) {
 			DPAA2_PMD_DP_DEBUG("VDQ command is not issued."
-					  "QBMAN is busy (2)\n");
+					  "QBMAN is busy (2)");
 			continue;
 		}
 		break;
drivers/net/e1000/e1000_logs.h +7 -7
index 30b5531069..afb840b601 100644
@@ -8,27 +8,27 @@
 #include <rte_log.h>
 
 extern int e1000_logtype_init;
+#define RTE_LOGTYPE_E1000_INIT e1000_logtype_init
 
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, e1000_logtype_init, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, E1000_INIT, "%s(): " fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 #ifdef RTE_ETHDEV_DEBUG_RX
 extern int e1000_logtype_rx;
+#define RTE_LOGTYPE_E1000_RX e1000_logtype_rx
 #define PMD_RX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, e1000_logtype_rx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, E1000_RX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_ETHDEV_DEBUG_TX
 extern int e1000_logtype_tx;
+#define RTE_LOGTYPE_E1000_TX e1000_logtype_tx
 #define PMD_TX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, e1000_logtype_tx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, E1000_TX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
@@ -36,7 +36,7 @@ extern int e1000_logtype_tx;
 extern int e1000_logtype_driver;
 #define RTE_LOGTYPE_E1000_DRIVER e1000_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	RTE_LOG(level, E1000_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, E1000_DRIVER, "%s(): " fmt, __func__, ## args)
 
 /* log init function shared by e1000 and igb drivers */
 void e1000_igb_init_log(void);
drivers/net/ena/ena_logs.h +4 -4
index 5c9ec1772b..6ebc08e09f 100644
@@ -9,13 +9,13 @@
 extern int ena_logtype_init;
 #define RTE_LOGTYPE_ENA_INIT ena_logtype_init
 #define PMD_INIT_LOG_LINE(level, fmt, ...) \
-	RTE_LOG(level, ENA_INIT, "%s(): " fmt "\n", __func__, ## __VA_ARGS__)
+	RTE_LOG_LINE(level, ENA_INIT, "%s(): " fmt, __func__, ## __VA_ARGS__)
 
 #ifdef RTE_ETHDEV_DEBUG_RX
 extern int ena_logtype_rx;
 #define RTE_LOGTYPE_ENA_RX ena_logtype_rx
 #define PMD_RX_LOG_LINE(level, fmt, ...)	\
-	RTE_LOG(level, ENA_RX, "%s(): " fmt "\n", __func__, ## __VA_ARGS__)
+	RTE_LOG_LINE(level, ENA_RX, "%s(): " fmt, __func__, ## __VA_ARGS__)
 #else
 #define PMD_RX_LOG_LINE(...) do { } while (0)
 #endif
@@ -24,7 +24,7 @@ extern int ena_logtype_rx;
 extern int ena_logtype_tx;
 #define RTE_LOGTYPE_ENA_TX ena_logtype_tx
 #define PMD_TX_LOG_LINE(level, fmt, ...)	\
-	RTE_LOG(level, ENA_TX, "%s(): " fmt "\n", __func__, ## __VA_ARGS__)
+	RTE_LOG_LINE(level, ENA_TX, "%s(): " fmt, __func__, ## __VA_ARGS__)
 #else
 #define PMD_TX_LOG_LINE(...) do { } while (0)
 #endif
@@ -32,6 +32,6 @@ extern int ena_logtype_tx;
 extern int ena_logtype_driver;
 #define RTE_LOGTYPE_ENA_DRIVER ena_logtype_driver
 #define PMD_DRV_LOG_LINE(level, fmt, ...) \
-	RTE_LOG(level, ENA_DRIVER, "%s(): " fmt "\n", __func__, ## __VA_ARGS__)
+	RTE_LOG_LINE(level, ENA_DRIVER, "%s(): " fmt, __func__, ## __VA_ARGS__)
 
 #endif /* _ENA_LOGS_H_ */
drivers/net/ena/ena_platform.h +1 -1
index 748928b2d9..71190b2932 100644
@@ -9,7 +9,7 @@
 #define ena_assert_msg(cond, msg)		\
 	do {					\
 		if (unlikely(!(cond))) {	\
-			rte_log(RTE_LOG_ERR, ena_logtype_driver, \
+			RTE_LOG_LINE(ERR, ENA_DRIVER, \
 				"Assert failed on %s:%s:%d: ",	\
 				__FILE__, __func__, __LINE__);	\
 			rte_panic(msg);		\
drivers/net/enetc/enetc_logs.h +4 -6
index 63f6ca4cf4..fd5bdeb16e 100644
@@ -6,15 +6,13 @@
 #define _ENETC_LOGS_H_
 
 extern int enetc_logtype_pmd;
-#define RTE_LOGTYPE_ENETC_PMD enetc_logtype_pmd
+#define RTE_LOGTYPE_ENETC_NET enetc_logtype_pmd
 
 #define ENETC_PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, enetc_logtype_pmd, "enetc_net: " \
-		fmt "\n", ##args)
+	RTE_LOG_LINE(level, ENETC_NET, fmt, ##args)
 
 #define ENETC_PMD_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, enetc_logtype_pmd, "enetc_net: %s(): "\
-		fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(DEBUG, ENETC_NET, "%s(): " fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() ENETC_PMD_DEBUG(">>")
 
@@ -31,7 +29,7 @@ extern int enetc_logtype_pmd;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define ENETC_PMD_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, ENETC_PMD, fmt, ## args)
+	RTE_LOG_DP_LINE(level, ENETC_NET, fmt, ## args)
 
 #define ENETC_PMD_DP_DEBUG(fmt, args...) \
 	ENETC_PMD_DP_LOG(DEBUG, fmt, ## args)
drivers/net/enetfec/enet_pmd_logs.h +3 -4
index 270981373f..9ff633cad8 100644
@@ -8,12 +8,11 @@
 #include <rte_log.h>
 
 extern int enetfec_logtype_pmd;
-#define RTE_LOGTYPE_ENETFEC_PMD enetfec_logtype_pmd
+#define RTE_LOGTYPE_ENETFEC_NET enetfec_logtype_pmd
 
 /* PMD related logs */
 #define ENETFEC_PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, enetfec_logtype_pmd, "\nfec_net: %s()" \
-		fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, ENETFEC_NET, "%s()" fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() ENET_PMD_LOG(DEBUG, " >>")
 
@@ -29,6 +28,6 @@ extern int enetfec_logtype_pmd;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define ENETFEC_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, ENETFEC_PMD, fmt, ## args)
+	RTE_LOG_DP_LINE(level, ENETFEC_NET, fmt, ## args)
 
 #endif /* _ENETFEC_LOGS_H_ */
drivers/net/enic/enic_compat.h +3 -2
index 7741273037..6ac245f7ab 100644
@@ -26,6 +26,7 @@
 #define __ALIGN_MASK(x, mask)    (((x)+(mask))&~(mask))
 
 extern int enic_pmd_logtype;
+#define RTE_LOGTYPE_ENIC_PMD enic_pmd_logtype
 
 #define dev_printk(level, fmt, args...)	\
 	rte_log(RTE_LOG_ ## level, enic_pmd_logtype, \
@@ -37,8 +38,8 @@ extern int enic_pmd_logtype;
 #define dev_debug(x, args...) dev_printk(DEBUG, args)
 
 #define ENICPMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, enic_pmd_logtype, \
-		"%s " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, ENIC_PMD, \
+		"%s " fmt, __func__, ##args)
 #define ENICPMD_FUNC_TRACE() ENICPMD_LOG(DEBUG, ">>")
 
 typedef         unsigned long long  dma_addr_t;
drivers/net/failsafe/failsafe_private.h +2 -5
index 53a451c1b1..babea6016e 100644
@@ -357,12 +357,9 @@ extern int failsafe_mac_from_arg;
 #endif
 
 extern int failsafe_logtype;
+#define RTE_LOGTYPE_NET_FAILSAFE failsafe_logtype
 
-#define LOG__(l, m, ...) \
-	rte_log(RTE_LOG_ ## l, failsafe_logtype, \
-		"net_failsafe: " m "%c", __VA_ARGS__)
-
-#define LOG_(level, ...) LOG__(level, __VA_ARGS__, '\n')
+#define LOG_(l, ...) RTE_LOG_LINE(l, NET_FAILSAFE, __VA_ARGS__)
 #define DEBUG(...) LOG_(DEBUG, __VA_ARGS__)
 #define INFO(...) LOG_(INFO, __VA_ARGS__)
 #define WARN(...) LOG_(WARNING, __VA_ARGS__)
drivers/net/fm10k/fm10k_logs.h +9 -9
index c4c7c977d9..d1a849ca79 100644
@@ -8,26 +8,26 @@
 #include <rte_log.h>
 
 extern int fm10k_logtype_init;
+#define RTE_LOGTYPE_FM10K_INIT fm10k_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, fm10k_logtype_init, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, FM10K_INIT, "%s(): " fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 #ifdef RTE_ETHDEV_DEBUG_RX
 extern int fm10k_logtype_rx;
-#define PMD_RX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, fm10k_logtype_rx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+#define RTE_LOGTYPE_FM10K_RX fm10k_logtype_rx
+#define PMD_RX_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, FM10K_RX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_ETHDEV_DEBUG_TX
 extern int fm10k_logtype_tx;
-#define PMD_TX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, fm10k_logtype_tx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+#define RTE_LOGTYPE_FM10K_TX fm10k_logtype_tx
+#define PMD_TX_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, FM10K_TX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
@@ -35,6 +35,6 @@ extern int fm10k_logtype_tx;
 extern int fm10k_logtype_driver;
 #define RTE_LOGTYPE_FM10K_DRIVER fm10k_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	RTE_LOG(level, FM10K_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, FM10K_DRIVER, "%s(): " fmt, __func__, ## args)
 
 #endif /* _FM10K_LOGS_H_ */
drivers/net/gve/gve_logs.h +2 -2
index 0d02da46e1..4a5baca6ff 100644
@@ -6,9 +6,9 @@
 #define _GVE_LOGS_H_
 
 extern int gve_logtype_driver;
+#define RTE_LOGTYPE_GVE_DRIVER gve_logtype_driver
 
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, gve_logtype_driver, "%s(): " fmt "\n", \
-		__func__, ## args)
+	RTE_LOG_LINE(level, GVE_DRIVER, "%s(): " fmt, __func__, ## args)
 
 #endif
drivers/net/hinic/base/hinic_compat.h +3 -2
index aea332046e..6cf5a6e43a 100644
@@ -84,10 +84,11 @@ typedef uint64_t  dma_addr_t;
 #define HINIC_DRIVER_NAME "net_hinic"
 
 extern int hinic_logtype;
+#define RTE_LOGTYPE_HINIC hinic_logtype
 
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, hinic_logtype, \
-		HINIC_DRIVER_NAME": " fmt "\n", ##args)
+	RTE_LOG_LINE(level, HINIC, \
+		HINIC_DRIVER_NAME": " fmt, ##args)
 
 /* common definition */
 #ifndef ETH_ALEN
drivers/net/hns3/hns3_logs.h +14 -11
index 47d3a13220..ef7a1ae3fd 100644
@@ -6,35 +6,37 @@
 #define HNS3_LOGS_H
 
 extern int hns3_logtype_init;
+#define RTE_LOGTYPE_HNS3_INIT hns3_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, hns3_logtype_init, "%s(): " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(level, HNS3_INIT, "%s(): " fmt, __func__, ##args)
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 extern int hns3_logtype_driver;
-#define PMD_DRV_LOG_RAW(hw, level, fmt, args...) \
-	rte_log(level, hns3_logtype_driver, "%s %s(): " fmt, \
+#define RTE_LOGTYPE_HNS3_DRIVER hns3_logtype_driver
+#define PMD_DRV_LOG(hw, level, fmt, args...) \
+	RTE_LOG_LINE(level, HNS3_DRIVER, "%s %s(): " fmt, \
 		(hw)->data->name, __func__, ## args)
 
 #define hns3_err(hw, fmt, args...) \
-	PMD_DRV_LOG_RAW(hw, RTE_LOG_ERR, fmt "\n", ## args)
+	PMD_DRV_LOG(hw, ERR, fmt, ## args)
 
 #define hns3_warn(hw, fmt, args...) \
-	PMD_DRV_LOG_RAW(hw, RTE_LOG_WARNING, fmt "\n", ## args)
+	PMD_DRV_LOG(hw, WARNING, fmt, ## args)
 
 #define hns3_notice(hw, fmt, args...) \
-	PMD_DRV_LOG_RAW(hw, RTE_LOG_NOTICE, fmt "\n", ## args)
+	PMD_DRV_LOG(hw, NOTICE, fmt, ## args)
 
 #define hns3_info(hw, fmt, args...) \
-	PMD_DRV_LOG_RAW(hw, RTE_LOG_INFO, fmt "\n", ## args)
+	PMD_DRV_LOG(hw, INFO, fmt, ## args)
 
 #define hns3_dbg(hw, fmt, args...) \
-	PMD_DRV_LOG_RAW(hw, RTE_LOG_DEBUG, fmt "\n", ## args)
+	PMD_DRV_LOG(hw, DEBUG, fmt, ## args)
 
 #ifdef RTE_ETHDEV_DEBUG_RX
 extern int hns3_logtype_rx;
+#define RTE_LOGTYPE_HNS3_RX hns3_logtype_rx
 #define PMD_RX_LOG(hw, level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, hns3_logtype_rx,	"%s %s(): " fmt "\n", \
+	RTE_LOG_LINE(level, HNS3_RX,	"%s %s(): " fmt, \
 		(hw)->data->name, __func__, ## args)
 #else
 #define PMD_RX_LOG(hw, level, fmt, args...) do { } while (0)
@@ -42,8 +44,9 @@ extern int hns3_logtype_rx;
 
 #ifdef RTE_ETHDEV_DEBUG_TX
 extern int hns3_logtype_tx;
+#define RTE_LOGTYPE_HNS3_TX hns3_logtype_tx
 #define PMD_TX_LOG(hw, level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, hns3_logtype_tx,	"%s %s(): " fmt "\n", \
+	RTE_LOG_LINE(level, HNS3_TX,	"%s %s(): " fmt, \
 		(hw)->data->name, __func__, ## args)
 #else
 #define PMD_TX_LOG(hw, level, fmt, args...) do { } while (0)
drivers/net/i40e/i40e_logs.h +9 -9
index fb1f3a4096..a756871dff 100644
@@ -6,25 +6,25 @@
 #define _I40E_LOGS_H_
 
 extern int i40e_logtype_init;
+#define RTE_LOGTYPE_I40E_INIT i40e_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, i40e_logtype_init, "%s(): " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(level, I40E_INIT, "%s(): " fmt, __func__, ##args)
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 #ifdef RTE_ETHDEV_DEBUG_RX
 extern int i40e_logtype_rx;
-#define PMD_RX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, i40e_logtype_rx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+#define RTE_LOGTYPE_I40E_RX i40e_logtype_rx
+#define PMD_RX_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, I40E_RX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_ETHDEV_DEBUG_TX
 extern int i40e_logtype_tx;
-#define PMD_TX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, i40e_logtype_tx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+#define RTE_LOGTYPE_I40E_TX i40e_logtype_tx
+#define PMD_TX_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, I40E_TX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
@@ -32,6 +32,6 @@ extern int i40e_logtype_tx;
 extern int i40e_logtype_driver;
 #define RTE_LOGTYPE_I40E_DRIVER i40e_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	RTE_LOG(level, I40E_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, I40E_DRIVER, "%s(): " fmt, __func__, ## args)
 
 #endif /* _I40E_LOGS_H_ */
drivers/net/iavf/iavf_log.h +11 -10
index ff66ab0ccf..c0013b8861 100644
@@ -6,35 +6,36 @@
 #define _IAVF_LOG_H_
 
 extern int iavf_logtype_init;
+#define RTE_LOGTYPE_IAVF_INIT iavf_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, iavf_logtype_init, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, IAVF_INIT, "%s(): " fmt, \
 		__func__, ## args)
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 extern int iavf_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, iavf_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
+#define RTE_LOGTYPE_IAVF_DRIVER iavf_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG_LINE(level, IAVF_DRIVER, "%s(): " fmt, \
+		__func__, ## args)
 #define PMD_DRV_FUNC_TRACE() PMD_DRV_LOG(DEBUG, " >>")
 
 
 #ifdef RTE_ETHDEV_DEBUG_RX
 extern int iavf_logtype_rx;
+#define RTE_LOGTYPE_IAVF_RX iavf_logtype_rx
 #define PMD_RX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, iavf_logtype_rx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, IAVF_RX,	\
+		"%s(): " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_ETHDEV_DEBUG_TX
 extern int iavf_logtype_tx;
+#define RTE_LOGTYPE_IAVF_TX iavf_logtype_tx
 #define PMD_TX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, iavf_logtype_tx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, IAVF_TX,	\
+		"%s(): " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
drivers/net/ice/ice_logs.h +9 -9
index a54e9d8b59..a84a5d453b 100644
@@ -6,34 +6,34 @@
 #define _ICE_LOGS_H_
 
 extern int ice_logtype_init;
+#define RTE_LOGTYPE_ICE_INIT ice_logtype_init
 extern int ice_logtype_driver;
 #define RTE_LOGTYPE_ICE_DRIVER ice_logtype_driver
 
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ice_logtype_init, "%s(): " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(level, ICE_INIT, "%s(): " fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 #ifdef RTE_ETHDEV_DEBUG_RX
 extern int ice_logtype_rx;
-#define PMD_RX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, ice_logtype_rx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+#define RTE_LOGTYPE_ICE_RX ice_logtype_rx
+#define PMD_RX_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, ICE_RX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_ETHDEV_DEBUG_TX
 extern int ice_logtype_tx;
-#define PMD_TX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, ice_logtype_tx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+#define RTE_LOGTYPE_ICE_TX ice_logtype_tx
+#define PMD_TX_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, ICE_TX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #define PMD_DRV_LOG(level, fmt, args...) \
-	RTE_LOG(level, ICE_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, ICE_DRIVER, "%s(): " fmt, __func__, ## args)
 
 #endif /* _ICE_LOGS_H_ */
drivers/net/idpf/idpf_logs.h +7 -10
index bf0774b8e4..c1629a0c48 100644
@@ -8,25 +8,22 @@
 #include <rte_log.h>
 
 extern int idpf_logtype_init;
+#define RTE_LOGTYPE_IDPF_INIT idpf_logtype_init
 extern int idpf_logtype_driver;
+#define RTE_LOGTYPE_IDPF_DRIVER idpf_logtype_driver
 
 #define PMD_INIT_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, \
-		idpf_logtype_init, \
+	RTE_LOG_LINE(level, IDPF_INIT, \
 		RTE_FMT("%s(): " \
-			RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
+			RTE_FMT_HEAD(__VA_ARGS__,), \
 			__func__, \
 			RTE_FMT_TAIL(__VA_ARGS__,)))
 
-#define PMD_DRV_LOG_RAW(level, ...) \
-	rte_log(RTE_LOG_ ## level, \
-		idpf_logtype_driver, \
+#define PMD_DRV_LOG(level, ...) \
+	RTE_LOG_LINE(level, IDPF_DRIVER, \
 		RTE_FMT("%s(): " \
-			RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
+			RTE_FMT_HEAD(__VA_ARGS__,), \
 			__func__, \
 			RTE_FMT_TAIL(__VA_ARGS__,)))
 
-#define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
-
 #endif /* _IDPF_LOGS_H_ */
drivers/net/igc/igc_logs.h +5 -7
index 4a574f10cb..1046b45297 100644
@@ -12,31 +12,29 @@ extern "C" {
 #endif
 
 extern int igc_logtype_init;
+#define RTE_LOGTYPE_IGC_INIT igc_logtype_init
 extern int igc_logtype_driver;
 #define RTE_LOGTYPE_IGC_DRIVER igc_logtype_driver
 
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, igc_logtype_init, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, IGC_INIT, "%s(): " fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 #ifdef RTE_ETHDEV_DEBUG_RX
-#define PMD_RX_LOG(level, fmt, args...) \
-	RTE_LOG(level, IGC_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+#define PMD_RX_LOG(...) PMD_DRV_LOG(__VA_ARGS__)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_ETHDEV_DEBUG_TX
-#define PMD_TX_LOG(level, fmt, args...) \
-	RTE_LOG(level, IGC_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+#define PMD_TX_LOG(...) PMD_DRV_LOG(__VA_ARGS__)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #define PMD_DRV_LOG(level, fmt, args...) \
-	RTE_LOG(level, IGC_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, IGC_DRIVER, "%s(): " fmt, __func__, ## args)
 
 #ifdef __cplusplus
 }
drivers/net/ipn3ke/ipn3ke_logs.h +2 -2
index 147fd8039e..c47a70ba9f 100644
@@ -8,10 +8,10 @@
 #include <rte_log.h>
 
 extern int ipn3ke_afu_logtype;
+#define RTE_LOGTYPE_IPN3KE_AFU ipn3ke_afu_logtype
 
 #define IPN3KE_AFU_PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ipn3ke_afu_logtype, "%s(): " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(level, IPN3KE_AFU, "%s(): " fmt, __func__, ##args)
 
 #define IPN3KE_AFU_PMD_FUNC_TRACE() IPN3KE_AFU_PMD_LOG(DEBUG, ">>")
 
drivers/net/ixgbe/ixgbe_logs.h +9 -9
index 5a2c5ccde0..44a8f40810 100644
@@ -6,26 +6,26 @@
 #define _IXGBE_LOGS_H_
 
 extern int ixgbe_logtype_init;
+#define RTE_LOGTYPE_IXGBE_INIT ixgbe_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ixgbe_logtype_init, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, IXGBE_INIT, "%s(): " fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 #ifdef RTE_ETHDEV_DEBUG_RX
 extern int ixgbe_logtype_rx;
-#define PMD_RX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, ixgbe_logtype_rx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+#define RTE_LOGTYPE_IXGBE_RX ixgbe_logtype_rx
+#define PMD_RX_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, IXGBE_RX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_ETHDEV_DEBUG_TX
 extern int ixgbe_logtype_tx;
-#define PMD_TX_LOG(level, fmt, args...)			\
-	rte_log(RTE_LOG_ ## level, ixgbe_logtype_tx,	\
-		"%s(): " fmt "\n", __func__, ## args)
+#define RTE_LOGTYPE_IXGBE_TX ixgbe_logtype_tx
+#define PMD_TX_LOG(level, fmt, args...) \
+	RTE_LOG_LINE(level, IXGBE_TX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
@@ -33,6 +33,6 @@ extern int ixgbe_logtype_tx;
 extern int ixgbe_logtype_driver;
 #define RTE_LOGTYPE_IXGBE_DRIVER ixgbe_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	RTE_LOG(level, IXGBE_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, IXGBE_DRIVER, "%s(): " fmt, __func__, ## args)
 
 #endif /* _IXGBE_LOGS_H_ */
drivers/net/mana/mana.h +4 -3
index 37f654f0e6..757d7a173f 100644
@@ -466,16 +466,17 @@ struct mana_rxq {
 extern int mana_logtype_driver;
 #define RTE_LOGTYPE_MANA_DRIVER mana_logtype_driver
 extern int mana_logtype_init;
+#define RTE_LOGTYPE_MANA_INIT mana_logtype_init
 
 #define DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, mana_logtype_driver, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, MANA_DRIVER, "%s(): " fmt, \
 		__func__, ## args)
 
 #define DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, MANA_DRIVER, fmt "\n", ## args)
+	RTE_LOG_DP_LINE(level, MANA_DRIVER, fmt, ## args)
 
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, mana_logtype_init, "%s(): " fmt "\n",\
+	RTE_LOG_LINE(level, MANA_INIT, "%s(): " fmt,\
 		__func__, ## args)
 
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
drivers/net/memif/rte_eth_memif.h +3 -2
index f21806c811..e0f19d1aca 100644
@@ -28,10 +28,11 @@
 #define MAX_PKT_BURST				32
 
 extern int memif_logtype;
+#define RTE_LOGTYPE_MEMIF memif_logtype
 
 #define MIF_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, memif_logtype, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, MEMIF, \
+		"%s(): " fmt, __func__, ##args)
 
 enum memif_role_t {
 	MEMIF_ROLE_SERVER,
drivers/net/mlx4/mlx4_utils.h +5 -4
index fca21fd79c..0cf972e607 100644
@@ -25,6 +25,7 @@
 #endif
 
 extern int mlx4_logtype;
+#define RTE_LOGTYPE_MLX4 mlx4_logtype
 
 #ifdef RTE_LIBRTE_MLX4_DEBUG
 
@@ -46,8 +47,8 @@ pmd_drv_log_basename(const char *s)
 }
 
 #define PMD_DRV_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, mlx4_logtype, \
-		RTE_FMT("%s:%u: %s(): " RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
+	RTE_LOG_LINE(level, MLX4, \
+		RTE_FMT("%s:%u: %s(): " RTE_FMT_HEAD(__VA_ARGS__,), \
 			pmd_drv_log_basename(__FILE__), \
 			__LINE__, \
 			__func__, \
@@ -63,9 +64,9 @@ pmd_drv_log_basename(const char *s)
  */
 
 #define PMD_DRV_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, mlx4_logtype, \
+	RTE_LOG_LINE(level, MLX4, \
 		RTE_FMT(MLX4_DRIVER_NAME ": " \
-			RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
+			RTE_FMT_HEAD(__VA_ARGS__,), \
 		RTE_FMT_TAIL(__VA_ARGS__,)))
 #define MLX4_ASSERT(exp) RTE_ASSERT(exp)
 #define claim_zero(...) (__VA_ARGS__)
drivers/net/mvneta/mvneta_ethdev.h +2 -2
index 9e711d8e5a..4bf6e8d54c 100644
@@ -83,9 +83,9 @@ struct mvneta_priv {
 
 /** Current log type. */
 extern int mvneta_logtype;
+#define RTE_LOGTYPE_MVNETA mvneta_logtype
 
 #define MVNETA_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, mvneta_logtype, "%s(): " fmt "\n", \
-		__func__, ##args)
+	RTE_LOG_LINE(level, MVNETA, "%s(): " fmt, __func__, ##args)
 
 #endif /* _MVNETA_ETHDEV_H_ */
drivers/net/mvpp2/mrvl_ethdev.h +2 -1
index 178b5103ba..35a5231824 100644
@@ -200,9 +200,10 @@ extern const struct rte_tm_ops mrvl_tm_ops;
 
 /** Current log type. */
 extern int mrvl_logtype;
+#define RTE_LOGTYPE_MRVL mrvl_logtype
 
 #define MRVL_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, mrvl_logtype, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, MRVL, "%s(): " fmt, \
 		__func__, ##args)
 
 extern struct pp2_bpool *dummy_pool[PP2_NUM_PKT_PROC];
drivers/net/netvsc/hn_logs.h +6 -8
index cddadef09c..6ce3209955 100644
@@ -6,31 +6,29 @@
 #include <rte_log.h>
 
 extern int hn_logtype_init;
+#define RTE_LOGTYPE_HN_INIT hn_logtype_init
 extern int hn_logtype_driver;
+#define RTE_LOGTYPE_HN_DRIVER hn_logtype_driver
 
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, hn_logtype_init, "%s(): " fmt "\n",\
-		__func__, ## args)
+	RTE_LOG_LINE(level, HN_INIT, "%s(): " fmt, __func__, ## args)
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 #ifdef RTE_LIBRTE_NETVSC_DEBUG_RX
 #define PMD_RX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, hn_logtype_driver, \
-		"%s() rx: " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, HN_DRIVER, "%s() rx: " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_LIBRTE_NETVSC_DEBUG_TX
 #define PMD_TX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, hn_logtype_driver, \
-		"%s() tx: " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, HN_DRIVER, "%s() tx: " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, hn_logtype_driver, "%s(): " fmt "\n", \
-		__func__, ## args)
+	RTE_LOG_LINE(level, HN_DRIVER, "%s(): " fmt, __func__, ## args)
 
 #endif /* _HN_LOGS_H_ */
drivers/net/netvsc/hn_rndis.c +30 -30

147 lines not on this page · raw message

drivers/net/nfb/nfb.h +2 -2
index ca0b647571..f318bc8b7b 100644
@@ -13,9 +13,9 @@
 #include <netcope/txmac.h>
 
 extern int nfb_logtype;
+#define RTE_LOGTYPE_NFB nfb_logtype
 #define NFB_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nfb_logtype, "%s(): " fmt "\n", \
-		__func__, ## args)
+	RTE_LOG_LINE(level, NFB, "%s(): " fmt, __func__, ## args)
 
 #include "nfb_rx.h"
 #include "nfb_tx.h"
drivers/net/nfp/nfp_logs.h +10 -10
index 690adabffd..e502ff863e 100644
@@ -9,36 +9,36 @@
 #include <rte_log.h>
 
 extern int nfp_logtype_init;
+#define RTE_LOGTYPE_NFP_INIT nfp_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nfp_logtype_init, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NFP_INIT, "%s(): " fmt, __func__, ## args)
 
 #ifdef RTE_ETHDEV_DEBUG_RX
 extern int nfp_logtype_rx;
+#define RTE_LOGTYPE_NFP_RX nfp_logtype_rx
 #define PMD_RX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nfp_logtype_rx, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NFP_RX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_ETHDEV_DEBUG_TX
 extern int nfp_logtype_tx;
+#define RTE_LOGTYPE_NFP_TX nfp_logtype_tx
 #define PMD_TX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nfp_logtype_tx, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NFP_TX, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 extern int nfp_logtype_cpp;
+#define RTE_LOGTYPE_NFP_CPP nfp_logtype_cpp
 #define PMD_CPP_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nfp_logtype_cpp, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NFP_CPP, "%s(): " fmt, __func__, ## args)
 
 extern int nfp_logtype_driver;
+#define RTE_LOGTYPE_NFP_DRIVER nfp_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nfp_logtype_driver, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NFP_DRIVER, "%s(): " fmt, __func__, ## args)
 
 #endif /* __NFP_LOGS_H__ */
drivers/net/ngbe/ngbe_logs.h +12 -8
index e5165ffd60..4f5e4c5757 100644
@@ -10,29 +10,33 @@
  * PMD_USER_LOG: for user
  */
 extern int ngbe_logtype_init;
+#define RTE_LOGTYPE_NGBE_INIT ngbe_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ngbe_logtype_init, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, NGBE_INIT, \
+		"%s(): " fmt, __func__, ##args)
 
 extern int ngbe_logtype_driver;
+#define RTE_LOGTYPE_NGBE_DRIVER ngbe_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ngbe_logtype_driver, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, NGBE_DRIVER, \
+		"%s(): " fmt, __func__, ##args)
 
 #ifdef RTE_ETHDEV_DEBUG_RX
 extern int ngbe_logtype_rx;
+#define RTE_LOGTYPE_NGBE_RX ngbe_logtype_rx
 #define PMD_RX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ngbe_logtype_rx,	\
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, NGBE_RX,	\
+		"%s(): " fmt, __func__, ##args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_ETHDEV_DEBUG_TX
 extern int ngbe_logtype_tx;
+#define RTE_LOGTYPE_NGBE_TX ngbe_logtype_tx
 #define PMD_TX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ngbe_logtype_tx,	\
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, NGBE_TX,	\
+		"%s(): " fmt, __func__, ##args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
drivers/net/null/rte_eth_null.c +3 -2
index f4ed3b8a7f..f5fec3d692 100644
@@ -76,10 +76,11 @@ static struct rte_eth_link pmd_link = {
 };
 
 RTE_LOG_REGISTER_DEFAULT(eth_null_logtype, NOTICE);
+#define RTE_LOGTYPE_ETH_NULL eth_null_logtype
 
 #define PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, eth_null_logtype, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, ETH_NULL, \
+		"%s(): " fmt, __func__, ##args)
 
 static uint16_t
 eth_null_rx(void *q, struct rte_mbuf **bufs, uint16_t nb_bufs)
drivers/net/octeon_ep/otx_ep_common.h +6 -6
index 7d5dd91a77..ea9788757e 100644
@@ -68,18 +68,18 @@
 #define OTX_CUST_DATA_LEN 0
 
 #define otx_ep_info(fmt, args...)				\
-	rte_log(RTE_LOG_INFO, otx_net_ep_logtype,		\
-		"%s():%u " fmt "\n",				\
+	RTE_LOG_LINE(INFO, OTX_NET_EP,		\
+		"%s():%u " fmt,				\
 		__func__, __LINE__, ##args)
 
 #define otx_ep_err(fmt, args...)				\
-	rte_log(RTE_LOG_ERR, otx_net_ep_logtype,		\
-		"%s():%u " fmt "\n",				\
+	RTE_LOG_LINE(ERR, OTX_NET_EP,		\
+		"%s():%u " fmt,				\
 		__func__, __LINE__, ##args)
 
 #define otx_ep_dbg(fmt, args...)				\
-	rte_log(RTE_LOG_DEBUG, otx_net_ep_logtype,		\
-		"%s():%u " fmt "\n",				\
+	RTE_LOG_LINE(DEBUG, OTX_NET_EP,		\
+		"%s():%u " fmt,				\
 		__func__, __LINE__, ##args)
 
 /* IO Access */
drivers/net/octeon_ep/otx_ep_rxtx.c +2 -2
index 9680a59797..09ed3c8da0 100644
@@ -916,9 +916,9 @@ otx_ep_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)
 		next_fetch = (pkts == new_pkts - 1) ? 0 : 1;
 		oq_pkt = otx_ep_droq_read_packet(otx_ep, droq, next_fetch);
 		if (!oq_pkt) {
-			RTE_LOG_DP(ERR, OTX_NET_EP,
+			RTE_LOG_DP_LINE(ERR, OTX_NET_EP,
 				   "DROQ read pkt failed pending %" PRIu64
-				    "last_pkt_count %" PRIu64 "new_pkts %d.\n",
+				    "last_pkt_count %" PRIu64 "new_pkts %d.",
 				   droq->pkts_pending, droq->last_pkt_count,
 				   new_pkts);
 			droq->stats.rx_err++;
drivers/net/octeontx/octeontx_logs.h +9 -7
index b58f296478..49ff18d8c4 100644
@@ -6,21 +6,21 @@
 #define __OCTEONTX_LOGS_H__
 
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, otx_net_logtype_init, \
-			"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, OTX_NET_INIT, \
+			"%s(): " fmt, __func__, ## args)
 
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, ">>")
 
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, otx_net_logtype_driver, \
-			"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, OTX_NET_DRIVER, \
+			"%s(): " fmt, __func__, ## args)
 
 #define PMD_MBOX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, otx_net_logtype_mbox, \
-			"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, OTX_NET_MBOX, \
+			"%s(): " fmt, __func__, ## args)
 
 #define octeontx_log_info(fmt, args...)			\
-	RTE_LOG(INFO, OTX_NET_DRIVER, fmt "\n", ## args)
+	RTE_LOG_LINE(INFO, OTX_NET_DRIVER, fmt, ## args)
 
 #define octeontx_log_err(s, ...) PMD_INIT_LOG(ERR, s, ##__VA_ARGS__)
 #define octeontx_log_dbg(s, ...) PMD_DRV_LOG(DEBUG, s, ##__VA_ARGS__)
@@ -30,8 +30,10 @@
 #define PMD_TX_LOG	PMD_DRV_LOG
 
 extern int otx_net_logtype_init;
+#define RTE_LOGTYPE_OTX_NET_INIT otx_net_logtype_init
 extern int otx_net_logtype_driver;
 #define RTE_LOGTYPE_OTX_NET_DRIVER otx_net_logtype_driver
 extern int otx_net_logtype_mbox;
+#define RTE_LOGTYPE_OTX_NET_MBOX otx_net_logtype_mbox
 
 #endif /* __OCTEONTX_LOGS_H__*/
drivers/net/pcap/pcap_osdep.h +3 -2
index bf41cba982..309a15bc80 100644
@@ -8,9 +8,10 @@
 #include <rte_ether.h>
 
 #define PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, eth_pcap_logtype, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, ETH_PCAP, \
+		"%s(): " fmt, __func__, ##args)
 extern int eth_pcap_logtype;
+#define RTE_LOGTYPE_ETH_PCAP eth_pcap_logtype
 
 int osdep_iface_index_get(const char *name);
 int osdep_iface_mac_get(const char *name, struct rte_ether_addr *mac);
drivers/net/pfe/pfe_logs.h +3 -4
index 369a50bec5..d0270caa60 100644
@@ -6,12 +6,11 @@
 #define _PFE_LOGS_H_
 
 extern int pfe_logtype_pmd;
-#define RTE_LOGTYPE_PFE_PMD pfe_logtype_pmd
+#define RTE_LOGTYPE_PFE_NET pfe_logtype_pmd
 
 /* PMD related logs */
 #define PFE_PMD_LOG(level, fmt, args...) \
-	 rte_log(RTE_LOG_ ## level, pfe_logtype_pmd, "pfe_net: %s()" \
-		 fmt "\n", __func__, ##args)
+	 RTE_LOG_LINE(level, PFE_NET, "%s()" fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() PFE_PMD_LOG(DEBUG, " >>")
 
@@ -27,6 +26,6 @@ extern int pfe_logtype_pmd;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define PFE_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, PFE_PMD, fmt, ## args)
+	RTE_LOG_DP_LINE(level, PFE_NET, fmt, ## args)
 
 #endif /* _PFE_LOGS_H_ */
drivers/net/ring/rte_eth_ring.c +3 -2
index 1346a0dba3..a206c40f4b 100644
@@ -68,10 +68,11 @@ static struct rte_eth_link pmd_link = {
 };
 
 RTE_LOG_REGISTER_DEFAULT(eth_ring_logtype, NOTICE);
+#define RTE_LOGTYPE_ETH_RING eth_ring_logtype
 
 #define PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, eth_ring_logtype, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, ETH_RING, \
+		"%s(): " fmt, __func__, ##args)
 
 static uint16_t
 eth_ring_rx(void *q, struct rte_mbuf **bufs, uint16_t nb_bufs)
drivers/net/softnic/rte_eth_softnic.c +3 -2
index 1b90cf7a21..5d569454b5 100644
@@ -51,10 +51,11 @@ static const struct softnic_conn_params conn_params_default = {
 };
 
 RTE_LOG_REGISTER_DEFAULT(pmd_softnic_logtype, NOTICE);
+#define RTE_LOGTYPE_PMD_SOFTNIC pmd_softnic_logtype
 
 #define PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, pmd_softnic_logtype, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, PMD_SOFTNIC, \
+		"%s(): " fmt, __func__, ##args)
 
 static int
 pmd_dev_infos_get(struct rte_eth_dev *dev __rte_unused,
drivers/net/tap/tap_log.h +2 -1
index fa06843a4c..23e992bf34 100644
@@ -4,7 +4,8 @@
  */
 
 extern int tap_logtype;
+#define RTE_LOGTYPE_TAP tap_logtype
 
 #define TAP_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, tap_logtype, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, TAP, "%s(): " fmt, \
 		__func__, ## args)
drivers/net/thunderx/nicvf_logs.h +6 -6
index 3c455b4288..4a1ad7af63 100644
@@ -20,25 +20,25 @@
 #endif
 
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nicvf_logtype_init, \
-			"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NICVF_INIT, "%s(): " fmt, __func__, ## args)
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, ">>")
 
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nicvf_logtype_driver, \
-			"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NICVF_DRIVER, "%s(): " fmt, __func__, ## args)
 #define PMD_DRV_FUNC_TRACE() PMD_DRV_LOG(DEBUG, ">>")
 
 #define PMD_MBOX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nicvf_logtype_mbox, \
-			"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NICVF_MBOX, "%s(): " fmt, __func__, ## args)
 #define PMD_MBOX_FUNC_TRACE() PMD_DRV_LOG(DEBUG, ">>")
 
 #define PMD_RX_LOG PMD_DRV_LOG
 #define PMD_TX_LOG PMD_DRV_LOG
 
 extern int nicvf_logtype_init;
+#define RTE_LOGTYPE_NICVF_INIT nicvf_logtype_init
 extern int nicvf_logtype_driver;
+#define RTE_LOGTYPE_NICVF_DRIVER nicvf_logtype_driver
 extern int nicvf_logtype_mbox;
+#define RTE_LOGTYPE_NICVF_MBOX nicvf_logtype_mbox
 
 #endif /* __THUNDERX_NICVF_LOGS__ */
drivers/net/txgbe/txgbe_logs.h +16 -10
index b5a5a9233f..f0fc23f65c 100644
@@ -12,38 +12,44 @@
  * PMD_USER_LOG: for user
  */
 extern int txgbe_logtype_init;
+#define RTE_LOGTYPE_TXGBE_INIT txgbe_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, txgbe_logtype_init, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, TXGBE_INIT, \
+		"%s(): " fmt, __func__, ##args)
 
 extern int txgbe_logtype_driver;
+#define RTE_LOGTYPE_TXGBE_DRIVER txgbe_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, txgbe_logtype_driver, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, TXGBE_DRIVER, \
+		"%s(): " fmt, __func__, ##args)
 
 #ifdef RTE_LIBRTE_TXGBE_DEBUG_RX
 extern int txgbe_logtype_rx;
+#define RTE_LOGTYPE_TXGBE_RX txgbe_logtype_rx
 #define PMD_RX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, txgbe_logtype_rx,	\
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, TXGBE_RX,	\
+		"%s(): " fmt, __func__, ##args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_LIBRTE_TXGBE_DEBUG_TX
 extern int txgbe_logtype_tx;
+#define RTE_LOGTYPE_TXGBE_TX txgbe_logtype_tx
 #define PMD_TX_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, txgbe_logtype_tx,	\
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, TXGBE_TX,	\
+		"%s(): " fmt, __func__, ##args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
 #ifdef RTE_LIBRTE_TXGBE_DEBUG_TX_FREE
 extern int txgbe_logtype_tx_free;
+#define RTE_LOGTYPE_TXGBE_TX_FREE txgbe_logtype_tx_free
+#define RTE_LOGTYPE_TXGBE_TX txgbe_logtype_tx
 #define PMD_TX_FREE_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, txgbe_logtype_tx_free,	\
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, TXGBE_TX_FREE,	\
+		"%s(): " fmt, __func__, ##args)
 #else
 #define PMD_TX_FREE_LOG(level, fmt, args...) do { } while (0)
 #endif
drivers/net/vdev_netvsc/vdev_netvsc.c +3 -3
index c3e045d892..9e7ab792ec 100644
@@ -49,12 +49,12 @@
 #define NETVSC_MAX_ROUTE_LINE_SIZE 300
 
 RTE_LOG_REGISTER_DEFAULT(vdev_netvsc_logtype, NOTICE);
+#define RTE_LOGTYPE_VDEV_NETVSC vdev_netvsc_logtype
 
 #define DRV_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, \
-		vdev_netvsc_logtype, \
+	RTE_LOG_LINE(level, VDEV_NETVSC, \
 		RTE_FMT(VDEV_NETVSC_DRIVER_NAME ": " \
-			RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
+			RTE_FMT_HEAD(__VA_ARGS__,), \
 		RTE_FMT_TAIL(__VA_ARGS__,)))
 
 /** Context structure for a vdev_netvsc instance. */
drivers/net/vhost/rte_eth_vhost.c +1 -2
index 6ccb228872..87c05caccd 100644
@@ -25,8 +25,7 @@ RTE_LOG_REGISTER_DEFAULT(vhost_logtype, NOTICE);
 #define RTE_LOGTYPE_VHOST vhost_logtype
 
 #define VHOST_LOG_LINE(level, ...) \
-	RTE_LOG(level, VHOST, RTE_FMT(RTE_FMT_HEAD(__VA_ARGS__ ,) "\n", \
-		RTE_FMT_TAIL(__VA_ARGS__ ,)))
+	RTE_LOG_LINE(level, VHOST, __VA_ARGS__)
 
 enum {VIRTIO_RXQ, VIRTIO_TXQ, VIRTIO_QNUM};
 
drivers/net/virtio/virtio_logs.h +7 -6
index 01911514bd..a31a975df4 100644
@@ -8,22 +8,23 @@
 #include <rte_log.h>
 
 extern int virtio_logtype_init;
+#define RTE_LOGTYPE_VIRTIO_INIT virtio_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, virtio_logtype_init, \
-		"%s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, VIRTIO_INIT, \
+		"%s(): " fmt, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 #ifdef RTE_LIBRTE_VIRTIO_DEBUG_RX
 #define PMD_RX_LOG(level, fmt, args...) \
-	RTE_LOG(level, VIRTIO_DRIVER, "%s() rx: " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, VIRTIO_DRIVER, "%s() rx: " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while(0)
 #endif
 
 #ifdef RTE_LIBRTE_VIRTIO_DEBUG_TX
 #define PMD_TX_LOG(level, fmt, args...) \
-	RTE_LOG(level, VIRTIO_DRIVER, "%s() tx: " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, VIRTIO_DRIVER, "%s() tx: " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while(0)
 #endif
@@ -31,7 +32,7 @@ extern int virtio_logtype_init;
 extern int virtio_logtype_driver;
 #define RTE_LOGTYPE_VIRTIO_DRIVER virtio_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, virtio_logtype_driver, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, VIRTIO_DRIVER, \
+		"%s(): " fmt, __func__, ## args)
 
 #endif /* _VIRTIO_LOGS_H_ */
drivers/net/vmxnet3/vmxnet3_logs.h +7 -7
index 5962325d62..e39ce30207 100644
@@ -6,28 +6,29 @@
 #define _VMXNET3_LOGS_H_
 
 extern int vmxnet3_logtype_init;
+#define RTE_LOGTYPE_VMXNET3_INIT vmxnet3_logtype_init
 #define PMD_INIT_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, vmxnet3_logtype_init, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, VMXNET3_INIT, \
+		"%s(): " fmt, __func__, ## args)
 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
 
 #ifdef RTE_LIBRTE_VMXNET3_DEBUG_RX
 #define PMD_RX_LOG(level, fmt, args...) \
-	RTE_LOG(level, VMXNET3_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, VMXNET3_DRIVER, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while(0)
 #endif
 
 #ifdef RTE_LIBRTE_VMXNET3_DEBUG_TX
 #define PMD_TX_LOG(level, fmt, args...) \
-	RTE_LOG(level, VMXNET3_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, VMXNET3_DRIVER, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while(0)
 #endif
 
 #ifdef RTE_LIBRTE_VMXNET3_DEBUG_TX_FREE
 #define PMD_TX_FREE_LOG(level, fmt, args...) \
-	RTE_LOG(level, VMXNET3_DRIVER, "%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, VMXNET3_DRIVER, "%s(): " fmt, __func__, ## args)
 #else
 #define PMD_TX_FREE_LOG(level, fmt, args...) do { } while(0)
 #endif
@@ -35,7 +36,6 @@ extern int vmxnet3_logtype_init;
 extern int vmxnet3_logtype_driver;
 #define RTE_LOGTYPE_VMXNET3_DRIVER vmxnet3_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, vmxnet3_logtype_driver, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, VMXNET3_DRIVER, "%s(): " fmt, __func__, ## args)
 
 #endif /* _VMXNET3_LOGS_H_ */
drivers/raw/cnxk_bphy/rte_pmd_bphy.h +2 -2
index 790b4d2a5a..0ab952bb84 100644
@@ -27,10 +27,10 @@ extern "C" {
 #endif
 
 extern int cnxk_logtype_bphy;
+#define RTE_LOGTYPE_CNXK_BPHY cnxk_logtype_bphy
 
 #define CNXK_BPHY_LOG(level, fmt, args...)	\
-	rte_log(RTE_LOG_ ## level, cnxk_logtype_bphy, \
-		"%s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, CNXK_BPHY, "%s(): " fmt, __func__, ## args)
 
 /** Available message types */
 enum cnxk_bphy_cgx_msg_type {
drivers/raw/cnxk_gpio/cnxk_gpio.h +2 -1
index 336d7ac373..1ee9d66912 100644
@@ -6,9 +6,10 @@
 #define _CNXK_GPIO_H_
 
 extern int cnxk_logtype_gpio;
+#define RTE_LOGTYPE_CNXK_GPIO cnxk_logtype_gpio
 
 #define CNXK_GPIO_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, cnxk_logtype_gpio, fmt "\n", ## args)
+	RTE_LOG_LINE(level, CNXK_GPIO, fmt, ## args)
 
 struct cnxk_gpiochip;
 
drivers/raw/dpaa2_cmdif/dpaa2_cmdif_logs.h +5 -5
index f5f2455413..746f02bb10 100644
@@ -13,12 +13,12 @@ extern int dpaa2_cmdif_logtype;
 #define RTE_LOGTYPE_DPAA2_CMDIF dpaa2_cmdif_logtype
 
 #define DPAA2_CMDIF_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa2_cmdif_logtype, "dpaa2_cmdif: " \
-		fmt "\n", ## args)
+	RTE_LOG_LINE(level, DPAA2_CMDIF, \
+		fmt, ## args)
 
 #define DPAA2_CMDIF_DEBUG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, dpaa2_cmdif_logtype, "dpaa2_cmdif: %s(): " \
-		fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(DEBUG, DPAA2_CMDIF, "%s(): " \
+		fmt, __func__, ## args)
 
 #define DPAA2_CMDIF_FUNC_TRACE() DPAA2_CMDIF_DEBUG(">>")
 
@@ -31,7 +31,7 @@ extern int dpaa2_cmdif_logtype;
 
 /* DP Logs, toggled out at compile time if level lower than current level */
 #define DPAA2_CMDIF_DP_LOG(level, fmt, args...) \
-	RTE_LOG_DP(level, DPAA2_CMDIF, "dpaa2_cmdif: " fmt "\n", ## args)
+	RTE_LOG_DP_LINE(level, DPAA2_CMDIF, fmt, ## args)
 
 #define DPAA2_CMDIF_DP_DEBUG(fmt, args...) \
 	DPAA2_CMDIF_DP_LOG(DEBUG, fmt, ## args)
drivers/raw/ifpga/ifpga_rawdev.h +2 -1
index 0fb66cbaae..973d83f6e9 100644
@@ -6,11 +6,12 @@
 #define _IFPGA_RAWDEV_H_
 
 extern int ifpga_rawdev_logtype;
+#define RTE_LOGTYPE_IFPGA_RAWDEV ifpga_rawdev_logtype
 
 #define IFPGA_RAWDEV_NAME_FMT "IFPGA:%02x:%02x.%x"
 
 #define IFPGA_RAWDEV_PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ifpga_rawdev_logtype, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, IFPGA_RAWDEV, "%s(): " fmt, \
 				__func__, ##args)
 
 #define IFPGA_RAWDEV_PMD_FUNC_TRACE() IFPGA_RAWDEV_PMD_LOG(DEBUG, ">>")
drivers/raw/ntb/ntb.h +2 -1
index 563ceddf18..784e6baa9b 100644
@@ -8,9 +8,10 @@
 #include <stdbool.h>
 
 extern int ntb_logtype;
+#define RTE_LOGTYPE_NTB ntb_logtype
 
 #define NTB_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ntb_logtype,	"%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, NTB,	"%s(): " fmt, \
 		__func__, ##args)
 
 /* Vendor ID */
drivers/raw/skeleton/skeleton_rawdev.h +2 -1
index c3f92e72ab..9e853633f0 100644
@@ -8,9 +8,10 @@
 #include <rte_rawdev.h>
 
 extern int skeleton_pmd_logtype;
+#define RTE_LOGTYPE_SKELETON_PMD skeleton_pmd_logtype
 
 #define SKELETON_PMD_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, skeleton_pmd_logtype, "%s(): " fmt "\n", \
+	RTE_LOG_LINE(level, SKELETON_PMD, "%s(): " fmt, \
 		__func__, ##args)
 
 #define SKELETON_PMD_FUNC_TRACE() SKELETON_PMD_LOG(DEBUG, ">>")
drivers/raw/skeleton/skeleton_rawdev_test.c +1 -1
index b7a7f623aa..00b77284d8 100644
@@ -19,7 +19,7 @@
 #define TEST_DEV_NAME "rawdev_skeleton"
 
 #define SKELDEV_LOGS(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, skeleton_pmd_logtype, fmt "\n", \
+	RTE_LOG_LINE(level, SKELETON_PMD, fmt, \
 		##args)
 
 #define SKELDEV_TEST_INFO(fmt, args...) \
drivers/vdpa/ifc/base/ifcvf.c +5 -5
index 8479172bfa..54067f94aa 100644
@@ -224,10 +224,10 @@ ifcvf_enable_mq(struct ifcvf_hw *hw)
 	if (mq_cfg) {
 		if (hw->device_type == IFCVF_BLK) {
 			*(u32 *)mq_cfg = nr_queue;
-			RTE_LOG(INFO, IFCVF_VDPA, "%d queues are enabled\n", nr_queue);
+			RTE_LOG_LINE(INFO, IFCVF_VDPA, "%d queues are enabled", nr_queue);
 		} else {
 			*(u32 *)mq_cfg = nr_queue / 2;
-			RTE_LOG(INFO, IFCVF_VDPA, "%d queue pairs are enabled\n",
+			RTE_LOG_LINE(INFO, IFCVF_VDPA, "%d queue pairs are enabled",
 				nr_queue / 2);
 		}
 	}
@@ -246,7 +246,7 @@ ifcvf_enable_vring_hw(struct ifcvf_hw *hw, int i)
 
 	cfg = hw->common_cfg;
 	if (!cfg) {
-		RTE_LOG(ERR, IFCVF_VDPA, "common_cfg in HW is NULL.\n");
+		RTE_LOG_LINE(ERR, IFCVF_VDPA, "common_cfg in HW is NULL.");
 		return -1;
 	}
 
@@ -258,7 +258,7 @@ ifcvf_enable_vring_hw(struct ifcvf_hw *hw, int i)
 		IFCVF_WRITE_REG16(i + 1, &cfg->queue_msix_vector);
 		msix_vector = IFCVF_READ_REG16(&cfg->queue_msix_vector);
 		if (msix_vector == IFCVF_MSI_NO_VECTOR) {
-			RTE_LOG(ERR, IFCVF_VDPA, "queue %d, msix vec alloc failed\n",
+			RTE_LOG_LINE(ERR, IFCVF_VDPA, "queue %d, msix vec alloc failed",
 				i);
 			return -1;
 		}
@@ -307,7 +307,7 @@ ifcvf_disable_vring_hw(struct ifcvf_hw *hw, int i)
 
 	cfg = hw->common_cfg;
 	if (!cfg) {
-		RTE_LOG(ERR, IFCVF_VDPA, "common_cfg in HW is NULL.\n");
+		RTE_LOG_LINE(ERR, IFCVF_VDPA, "common_cfg in HW is NULL.");
 		return;
 	}
 
drivers/vdpa/ifc/ifcvf_vdpa.c +3 -2
index 2958368813..8b61da5968 100644
@@ -33,9 +33,10 @@
 #define MIN(v1, v2)	((v1) < (v2) ? (v1) : (v2))
 
 RTE_LOG_REGISTER(ifcvf_vdpa_logtype, pmd.vdpa.ifcvf, NOTICE);
+#define RTE_LOGTYPE_IFCVF_VDPA ifcvf_vdpa_logtype
 #define DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ifcvf_vdpa_logtype, \
-		"IFCVF %s(): " fmt "\n", __func__, ##args)
+	RTE_LOG_LINE(level, IFCVF_VDPA, \
+		"%s(): " fmt, __func__, ##args)
 
 #define IFCVF_USED_RING_LEN(size) \
 	((size) * sizeof(struct vring_used_elem) + sizeof(uint16_t) * 3)
drivers/vdpa/nfp/nfp_vdpa_log.h +6 -4
index cf342329b1..e2b163ca7e 100644
@@ -9,13 +9,15 @@
 #include <rte_log.h>
 
 extern int nfp_logtype_vdpa;
+#define RTE_LOGTYPE_NFP_VDPA nfp_logtype_vdpa
 #define DRV_VDPA_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nfp_logtype_vdpa, \
-		"NFP_VDPA: %s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NFP_VDPA, \
+		"%s(): " fmt, __func__, ## args)
 
 extern int nfp_logtype_core;
+#define RTE_LOGTYPE_NFP_CORE nfp_logtype_core
 #define DRV_CORE_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, nfp_logtype_core, \
-		"NFP_CORE: %s(): " fmt "\n", __func__, ## args)
+	RTE_LOG_LINE(level, NFP_CORE, \
+		"%s(): " fmt, __func__, ## args)
 
 #endif /* __NFP_VDPA_LOG_H__ */
Signature · 1 line
2.46.0
#18 lore raw

Re: [PATCH 11/11] drivers: use per line logging in helpers

Quoted 3 lines · David Marchand

Use RTE_LOG_LINE in existing macros that append a \n.

[snip]

Quoted 5 lines
drivers/common/sfc_efx/sfc_efx_log.h +0 -0
index 1519ebdc17..b41ef3490b 100644

drivers/common/sfc_efx/sfc_efx_log.h line 19

Quoted 9 lines
drivers/common/sfc_efx/sfc_efx_log.h +1 -2
@@ -12,11 +12,10 @@
 
  /** Generic driver log type */
  extern int sfc_efx_logtype;
+#define RTE_LOGTYPE_SFC_EFX sfc_efx_logtype
 
  /** Log message, add a prefix and a line break */
  #define SFC_EFX_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, sfc_efx_logtype,			\
-		RTE_FMT("sfc_efx: " RTE_FMT_HEAD(__VA_ARGS__ ,) "\n",	\

Is "sfc_efx: " prefix dropped intentionally? Or should RTE_LOG_LINE_PREFIX be used?

Quoted 4 lines
drivers/common/sfc_efx/sfc_efx_log.h +1 -1
-			RTE_FMT_TAIL(__VA_ARGS__ ,)))
+	RTE_LOG_LINE(level, SFC_EFX, ## __VA_ARGS__)
 
  #endif /* _SFC_EFX_LOG_H_ */
#19 lore raw

Re: [PATCH 11/11] drivers: use per line logging in helpers

Quoted 18 lines · Andrew Rybchenko
Quoted 3 lines · David Marchand

Use RTE_LOG_LINE in existing macros that append a \n.

[snip]

Quoted 10 lines
drivers/common/sfc_efx/sfc_efx_log.h +1 -0
index 1519ebdc17..b41ef3490b 100644
@@ -12,11 +12,10 @@
 
  /** Generic driver log type */
  extern int sfc_efx_logtype;
+#define RTE_LOGTYPE_SFC_EFX sfc_efx_logtype
 
Quoted 7 lines

drivers/common/sfc_efx/sfc_efx_log.h line 19

Quoted 4 lines
drivers/common/sfc_efx/sfc_efx_log.h +0 -2
  /** Log message, add a prefix and a line break */
  #define SFC_EFX_LOG(level, ...) \
-     rte_log(RTE_LOG_ ## level, sfc_efx_logtype,                     \
-             RTE_FMT("sfc_efx: " RTE_FMT_HEAD(__VA_ARGS__ ,) "\n",   \

Is "sfc_efx: " prefix dropped intentionally? Or should RTE_LOG_LINE_PREFIX be used?

By moving to the RTE_LOG macro (and friends), a prefix is automatically appended via the log type.

#define RTE_LOG(l, t, ...)                                      \
         rte_log(RTE_LOG_ ## l,                                 \
                 RTE_LOGTYPE_ ## t, # t ": " __VA_ARGS__)

So here, the logs prefix is not dropped, but changed from sfc_efx: to SFC_EFX:

It is possible to keep it unchanged by defining RTE_LOGTYPE_sfc_efx is you want to stick to it.

Signature · 1 line
David Marchand
#20 lore raw

Re: [PATCH 11/11] drivers: use per line logging in helpers

Quoted 30 lines · David Marchand
Quoted 18 lines · Andrew Rybchenko
Quoted 3 lines · David Marchand

Use RTE_LOG_LINE in existing macros that append a \n.

[snip]

Quoted 10 lines
drivers/common/sfc_efx/sfc_efx_log.h +1 -0
index 1519ebdc17..b41ef3490b 100644
@@ -12,11 +12,10 @@
 
   /** Generic driver log type */
   extern int sfc_efx_logtype;
+#define RTE_LOGTYPE_SFC_EFX sfc_efx_logtype
 
Quoted 7 lines

drivers/common/sfc_efx/sfc_efx_log.h line 19

Quoted 4 lines
drivers/common/sfc_efx/sfc_efx_log.h +0 -2
   /** Log message, add a prefix and a line break */
   #define SFC_EFX_LOG(level, ...) \
-     rte_log(RTE_LOG_ ## level, sfc_efx_logtype,                     \
-             RTE_FMT("sfc_efx: " RTE_FMT_HEAD(__VA_ARGS__ ,) "\n",   \

Is "sfc_efx: " prefix dropped intentionally? Or should RTE_LOG_LINE_PREFIX be used?

By moving to the RTE_LOG macro (and friends), a prefix is automatically appended via the log type.

Quoted 8 lines
#define RTE_LOG(l, t, ...)                                      \
          rte_log(RTE_LOG_ ## l,                                 \
                  RTE_LOGTYPE_ ## t, # t ": " __VA_ARGS__)

So here, the logs prefix is not dropped, but changed from sfc_efx: to SFC_EFX:

It is possible to keep it unchanged by defining RTE_LOGTYPE_sfc_efx is you want to stick to it.

Many thanks for explanation. I've lost it from my view on reviewing.

for common/sfc_efx:

#22 lore raw

Re: [PATCH 11/11] drivers: use per line logging in helpers

In reply to David Marchand
Quoted 5 lines · David Marchand

Use RTE_LOG_LINE in existing macros that append a \n.

---

[snip]

Quoted 19 lines
drivers/net/octeon_ep/otx_ep_common.h +4 -4
index 7d5dd91a77..ea9788757e 100644
@@ -68,18 +68,18 @@
 #define OTX_CUST_DATA_LEN 0
 
 #define otx_ep_info(fmt, args...)                              \
-       rte_log(RTE_LOG_INFO, otx_net_ep_logtype,               \
-               "%s():%u " fmt "\n",                            \
+       RTE_LOG_LINE(INFO, OTX_NET_EP,          \
+               "%s():%u " fmt,                         \
                __func__, __LINE__, ##args)
 
 #define otx_ep_err(fmt, args...)                               \
-       rte_log(RTE_LOG_ERR, otx_net_ep_logtype,                \
-               "%s():%u " fmt "\n",                            \
+       RTE_LOG_LINE(ERR, OTX_NET_EP,           \
+               "%s():%u " fmt,                         \

drivers/net/octeon_ep/otx_ep_common.h line 85

Quoted 10 lines
drivers/net/octeon_ep/otx_ep_common.h +2 -2
                __func__, __LINE__, ##args)
 
 #define otx_ep_dbg(fmt, args...)                               \
-       rte_log(RTE_LOG_DEBUG, otx_net_ep_logtype,              \
-               "%s():%u " fmt "\n",                            \
+       RTE_LOG_LINE(DEBUG, OTX_NET_EP,         \
+               "%s():%u " fmt,                         \
                __func__, __LINE__, ##args)
 
 /* IO Access */

I am facing a strange warning with gcc 13 on Fedora 39 when compiler optimisations (O3) are on.
Looking at the CI reports, some other versions of gcc seem affected.

On the other hand, O0, O1, O2 are fine, at least with my gcc.

Here is the warning:

ccache cc -Idrivers/libtmp_rte_net_octeon_ep.a.p -Idrivers -I../drivers -Idrivers/net/octeon_ep -I../drivers/net/octeon_ep -Ilib/ethdev -I../lib/ethdev -I. -I.. -Iconfig -I../config -Ilib/eal/include -I../lib/eal/include -Ilib/eal/linux/include -I../lib/eal/linux/include -Ilib/eal/x86/include -I../lib/eal/x86/include -Ilib/eal/common -I../lib/eal/common -Ilib/eal -I../lib/eal -Ilib/kvargs -I../lib/kvargs -Ilib/log -I../lib/log -Ilib/metrics -I../lib/metrics -Ilib/telemetry -I../lib/telemetry -Ilib/net -I../lib/net -Ilib/mbuf -I../lib/mbuf -Ilib/mempool -I../lib/mempool -Ilib/ring -I../lib/ring -Ilib/meter -I../lib/meter -Idrivers/bus/pci -I../drivers/bus/pci -I../drivers/bus/pci/linux -Ilib/pci -I../lib/pci -Idrivers/bus/vdev -I../drivers/bus/vdev -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Werror -std=c11 -O3 -include rte_config.h -Wcast-qual -Wdeprecated -Wformat -Wformat-nonliteral -Wformat-security -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wold-style-definition -Wpointer-arith -Wsign-compare -Wstrict-prototypes -Wundef -Wwrite-strings -Wno-address-of-packed-member -Wno-packed-not-aligned -Wno-missing-field-initializers -Wno-zero-length-bounds -D_GNU_SOURCE -fPIC -march=native -mrtm -DALLOW_EXPERIMENTAL_API -DALLOW_INTERNAL_API -Wno-format-truncation -DCC_AVX2_SUPPORT -Wno-strict-aliasing -flax-vector-conversions -DRTE_LOG_DEFAULT_LOGTYPE=pmd.net.octeon_ep -MD -MQ drivers/libtmp_rte_net_octeon_ep.a.p/net_octeon_ep_otx_ep_ethdev.c.o -MF drivers/libtmp_rte_net_octeon_ep.a.p/net_octeon_ep_otx_ep_ethdev.c.o.d -o drivers/libtmp_rte_net_octeon_ep.a.p/net_octeon_ep_otx_ep_ethdev.c.o -c ../drivers/net/octeon_ep/otx_ep_ethdev.c ../drivers/net/octeon_ep/otx_ep_ethdev.c: In function ‘otx_ep_dev_mtu_set’:
../drivers/net/octeon_ep/otx_ep_ethdev.c:200:12: error:
‘devinfo.max_mtu’ may be used uninitialized [-Werror=maybe-uninitialized]
200 | if (mtu > devinfo.max_mtu) {
| ^
../drivers/net/octeon_ep/otx_ep_ethdev.c:186:33: note:
‘devinfo.max_mtu’ was declared here
186 | struct rte_eth_dev_info devinfo;
| ^~~~~~~
cc1: all warnings being treated as errors
ninja: build stopped: subcommand failed.

This warning only appears with the last patch of the series. Looking at the code, it seems incorrect, as devinfo.max_mtu is supposed to be initialised in otx_ep_dev_info_get() if this function returns 0.

A minimum reproducer is (it can be tested on origin/main):

$ git diff
(quoted diff) +0 -0

b/drivers/net/octeon_ep/otx_ep_ethdev.c
index c4a5a67c79..0a6dbcea0d 100644

drivers/net/octeon_ep/otx_ep_ethdev.c +1 -1
@@ -135,7 +135,7 @@ otx_ep_dev_info_get(struct rte_eth_dev *eth_dev,
 
        max_rx_pktlen = otx_ep_mbox_get_max_pkt_len(eth_dev);
        if (!max_rx_pktlen) {
-               otx_ep_err("Failed to get Max Rx packet length");
+               rte_log(RTE_LOG_ERR, otx_net_ep_logtype, "%u
%u\n%.0s", 1, 1, "");
                return -EINVAL;
        }

(FYI, the %.0s trick comes from expanding RTE_FMT())

After various tries, it seems hitting this error requires passing (at least) 2 arguments in addition to %.0s in the format string. Another observation is that removing __rte_cold from rte_log() declaration makes the warning go away.

I am a bit puzzled, it smells like a compiler (optimisation) bug to me.

A workaround is to memset(&devinfo, 0) or call rte_eth_dev_info_get() in otx_ep_dev_mtu_set.
But on the other hand we may have a deeper issue with RTE_FMT()...

Opinions?

Signature · 1 line
David Marchand
#23 lore raw

v2 cover Use RTE_LOG_LINE in drivers

In reply to David Marchand

This is a continuation of the cleanup effort in logging macros.

As a reminder of what this series is about, RTE_LOG_LINE() has been introduced to check that the format string does not contain a trailing \n. The goal was to prevent from:
- introducing multilines log messages (ugly and unhelpful for lambda users),
- introducing double \n in logs,
- introducing missing \n in logs,

I have built/maintained this series for fixing drivers/ since the beginning of the year and I hope we can merge this series early in 24.11.

Some drivers are not converted because of multiple inconsistencies. Those may be fixed later.

As for the changes on lib/, new macros have been introduced so that backports trigger a build error and force the backport to adjust the patches containing logs accordingly.

Most of the changes have been done with some scripting, but it is likely there are some errors and I hope driver maintainers will review in depth.

A check is added for drivers/ in the hope that new drivers don't introduce more mess.

Yet, sometimes it is not possible to fix macros (a good example is base/ drivers code...), so the check skips *osdep.h headers where calls to RTE_LOG() may be accepted.

Signature · 394 lines
David Marchand

Changes since v1:
- added a fix on event/dlb2 base/ driver logs,
- converted event/dsw to dynamic logtype,
- converted event/dlb2, net/bonding, event/dsw to RTE_LOG_LINE,
- added workaround in net/octeon_ep for issue report at
  https://inbox.dpdk.org/dev/CAJFAV8wKcNnu2X4K4x39339jMX1N5Vr5Nh5iC_MOCNr--Hayog@mail.gmail.com/T/#u
- when possible used RTE_LOG_LINE_PREFIX in last patch,

David Marchand (14):
  devtools: fix forbidden token check with multiple files
  devtools: report all warnings in forbidden token check
  net/dpaa: remove broken debug macros
  net/sfc: fix driver logtype token
  drivers: reuse default logtype for SFC drivers
  drivers: move log wrappers to Intel base drivers
  net/txgbe: move wrapper to base driver
  event/dlb2: fix base driver logs
  event/dsw: use a dynamic logtype
  drivers: replace logging helpers
  drivers: remove redundant newline from logs
  drivers: split multilines log messages
  net/octeon_ep: avoid warning on uninitialized variable
  drivers: use per line logging in helpers

 devtools/check-forbidden-tokens.awk           |  15 +-
 devtools/checkpatches.sh                      |  11 +-
 drivers/baseband/acc/acc100_pmd.h             |  12 +-
 drivers/baseband/acc/acc_common.h             |   6 +-
 drivers/baseband/acc/rte_acc100_pmd.c         |  21 +-
 drivers/baseband/acc/rte_vrb_pmd.c            |  27 +-
 drivers/baseband/acc/vrb_pmd.h                |  12 +-
 .../baseband/fpga_5gnr_fec/fpga_5gnr_fec.h    |  15 +-
 .../fpga_5gnr_fec/rte_fpga_5gnr_fec.c         | 267 ++++----
 drivers/baseband/fpga_lte_fec/fpga_lte_fec.c  |  37 +-
 drivers/baseband/la12xx/bbdev_la12xx.c        |   4 +-
 .../baseband/la12xx/bbdev_la12xx_pmd_logs.h   |  16 +-
 drivers/baseband/null/bbdev_null.c            |   5 +-
 .../baseband/turbo_sw/bbdev_turbo_software.c  |  10 +-
 drivers/bus/auxiliary/private.h               |   5 +-
 drivers/bus/cdx/cdx_logs.h                    |  11 +-
 drivers/bus/cdx/cdx_vfio.c                    |   8 +-
 drivers/bus/dpaa/include/fman.h               |   2 +-
 drivers/bus/dpaa/rte_dpaa_logs.h              |  10 +-
 drivers/bus/fslmc/fslmc_bus.c                 |   8 +-
 drivers/bus/fslmc/fslmc_logs.h                |  11 +-
 drivers/bus/fslmc/fslmc_vfio.c                |  10 +-
 drivers/bus/fslmc/portal/dpaa2_hw_dpci.c      |   4 +-
 drivers/bus/ifpga/ifpga_bus.c                 |   8 +-
 drivers/bus/ifpga/ifpga_logs.h                |   6 +-
 drivers/bus/platform/platform.c               |  28 +-
 drivers/bus/platform/platform_params.c        |   2 +-
 drivers/bus/platform/private.h                |   9 +-
 drivers/bus/uacce/uacce.c                     |   6 +-
 drivers/bus/vdev/vdev_logs.h                  |   6 +-
 drivers/bus/vdev/vdev_params.c                |   2 +-
 drivers/bus/vmbus/private.h                   |   6 +-
 drivers/bus/vmbus/vmbus_common.c              |   2 +-
 drivers/common/cnxk/roc_dev.c                 |   2 +-
 drivers/common/cnxk/roc_model.c               |   2 +-
 drivers/common/cnxk/roc_nix_ops.c             |  20 +-
 drivers/common/cnxk/roc_nix_tm.c              |   2 +-
 drivers/common/cnxk/roc_nix_tm_mark.c         |   2 +-
 drivers/common/cnxk/roc_nix_tm_ops.c          |   2 +-
 drivers/common/cnxk/roc_nix_tm_utils.c        |   2 +-
 drivers/common/cnxk/roc_platform.h            |  46 +-
 drivers/common/cnxk/roc_sso.c                 |   2 +-
 drivers/common/cnxk/roc_tim.c                 |   2 +-
 drivers/common/cpt/cpt_pmd_logs.h             |  41 +-
 drivers/common/cpt/cpt_ucode.h                |   4 +-
 drivers/common/dpaax/dpaax_logs.h             |  10 +-
 drivers/common/iavf/iavf_osdep.h              |   8 +-
 drivers/common/idpf/base/idpf_osdep.h         |  10 +-
 drivers/common/idpf/idpf_common_logs.h        |  32 +-
 drivers/common/nfp/nfp_common_log.h           |   6 +-
 drivers/common/nitrox/nitrox_hal.c            |   4 +-
 drivers/common/nitrox/nitrox_logs.h           |   8 +-
 drivers/common/nitrox/nitrox_qp.c             |  10 +-
 drivers/common/octeontx/octeontx_mbox.c       |   4 +-
 drivers/common/octeontx/octeontx_mbox.h       |   7 +-
 drivers/common/qat/qat_logs.h                 |  12 +-
 drivers/common/qat/qat_pf2vf.c                |   4 +-
 drivers/common/qat/qat_qp.c                   |   2 +-
 drivers/common/sfc_efx/sfc_efx_log.h          |   5 +-
 drivers/compress/isal/isal_compress_pmd.c     |  78 +--
 .../compress/isal/isal_compress_pmd_private.h |   6 +-
 drivers/compress/nitrox/nitrox_comp.c         |  44 +-
 drivers/compress/nitrox/nitrox_comp_reqmgr.c  | 170 +++---
 drivers/compress/octeontx/otx_zip.h           |  19 +-
 drivers/compress/octeontx/otx_zip_pmd.c       |  14 +-
 .../compress/uadk/uadk_compress_pmd_private.h |   8 +-
 drivers/compress/zlib/zlib_pmd.c              |  26 +-
 drivers/compress/zlib/zlib_pmd_ops.c          |   4 +-
 drivers/compress/zlib/zlib_pmd_private.h      |   6 +-
 drivers/crypto/armv8/armv8_pmd_private.h      |  29 +-
 drivers/crypto/bcmfs/bcmfs_logs.h             |  12 +-
 drivers/crypto/bcmfs/bcmfs_qp.c               |   2 +-
 drivers/crypto/bcmfs/bcmfs_sym_pmd.c          |   2 +-
 drivers/crypto/bcmfs/bcmfs_sym_session.c      |   2 +-
 drivers/crypto/caam_jr/caam_jr.c              |  39 +-
 drivers/crypto/caam_jr/caam_jr_log.h          |  14 +-
 drivers/crypto/caam_jr/caam_jr_uio.c          |   6 +-
 drivers/crypto/ccp/ccp_dev.c                  |   2 +-
 drivers/crypto/ccp/ccp_pmd_private.h          |  19 +-
 drivers/crypto/ccp/rte_ccp_pmd.c              |   2 +-
 drivers/crypto/cnxk/cnxk_se.h                 |   6 +-
 drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c   |  98 +--
 drivers/crypto/dpaa2_sec/dpaa2_sec_logs.h     |  14 +-
 drivers/crypto/dpaa2_sec/dpaa2_sec_raw_dp.c   |  16 +-
 drivers/crypto/dpaa_sec/dpaa_sec.c            |  27 +-
 drivers/crypto/dpaa_sec/dpaa_sec_log.h        |  14 +-
 drivers/crypto/dpaa_sec/dpaa_sec_raw_dp.c     |   6 +-
 drivers/crypto/ipsec_mb/ipsec_mb_private.c    |   4 +-
 drivers/crypto/ipsec_mb/ipsec_mb_private.h    |   9 +-
 drivers/crypto/ipsec_mb/pmd_aesni_mb.c        |  28 +-
 drivers/crypto/ipsec_mb/pmd_snow3g.c          |   4 +-
 drivers/crypto/mvsam/mrvl_pmd_private.h       |   8 +-
 drivers/crypto/nitrox/nitrox_sym.c            |  54 +-
 drivers/crypto/nitrox/nitrox_sym_reqmgr.c     |  12 +-
 drivers/crypto/null/null_crypto_pmd_private.h |   8 +-
 .../crypto/octeontx/otx_cryptodev_hw_access.h |   6 +-
 drivers/crypto/openssl/openssl_pmd_private.h  |   8 +-
 drivers/crypto/openssl/rte_openssl_pmd.c      |  42 +-
 drivers/crypto/openssl/rte_openssl_pmd_ops.c  |  44 +-
 drivers/crypto/qat/qat_asym.c                 |   2 +-
 drivers/crypto/qat/qat_sym_session.c          |  12 +-
 .../crypto/scheduler/scheduler_pmd_private.h  |   7 +-
 drivers/crypto/uadk/uadk_crypto_pmd.c         |   8 +-
 drivers/crypto/uadk/uadk_crypto_pmd_private.h |   8 +-
 drivers/crypto/virtio/virtio_cryptodev.c      |  12 +-
 drivers/crypto/virtio/virtio_logs.h           |  36 +-
 drivers/dma/dpaa/dpaa_qdma.c                  |  40 +-
 drivers/dma/dpaa/dpaa_qdma_logs.h             |  14 +-
 drivers/dma/dpaa2/dpaa2_qdma.c                |  10 +-
 drivers/dma/dpaa2/dpaa2_qdma_logs.h           |  14 +-
 drivers/dma/hisilicon/hisi_dmadev.c           |  35 +-
 drivers/dma/idxd/idxd_common.c                |   2 +-
 drivers/dma/idxd/idxd_internal.h              |   5 +-
 drivers/dma/idxd/idxd_pci.c                   |   6 +-
 drivers/dma/ioat/ioat_dmadev.c                |  14 +-
 drivers/dma/ioat/ioat_internal.h              |   5 +-
 drivers/dma/odm/odm.h                         |  19 +-
 drivers/dma/odm/odm_dmadev.c                  |  12 +-
 drivers/dma/skeleton/skeleton_dmadev.c        |   6 +-
 drivers/event/cnxk/cnxk_tim_evdev.c           |   2 +-
 drivers/event/dlb2/dlb2.c                     | 270 ++++-----
 drivers/event/dlb2/dlb2_log.h                 |  11 +-
 drivers/event/dlb2/dlb2_xstats.c              |   6 +-
 drivers/event/dlb2/pf/base/dlb2_osdep.h       |  16 +-
 drivers/event/dlb2/pf/base/dlb2_resource.c    |  18 +-
 drivers/event/dlb2/pf/dlb2_main.c             |  52 +-
 drivers/event/dlb2/pf/dlb2_pf.c               |  24 +-
 drivers/event/dpaa/dpaa_eventdev.c            |   1 +
 drivers/event/dpaa/dpaa_eventdev.h            |   5 +-
 drivers/event/dpaa2/dpaa2_eventdev.c          |  14 +-
 drivers/event/dpaa2/dpaa2_eventdev_logs.h     |  11 +-
 drivers/event/dsw/dsw_evdev.c                 |   1 +
 drivers/event/dsw/dsw_evdev.h                 |  11 +-
 drivers/event/dsw/dsw_event.c                 |  78 +--
 drivers/event/octeontx/ssovf_evdev.h          |   8 +-
 drivers/event/octeontx/timvf_evdev.c          |   2 +-
 drivers/event/octeontx/timvf_evdev.h          |   8 +-
 drivers/event/opdl/opdl_evdev.c               |  30 +-
 drivers/event/opdl/opdl_log.h                 |  11 +-
 drivers/event/opdl/opdl_test.c                | 116 ++--
 drivers/event/skeleton/skeleton_eventdev.h    |  13 +-
 drivers/event/sw/sw_evdev.c                   |  22 +-
 drivers/event/sw/sw_evdev_log.h               |   6 +-
 drivers/event/sw/sw_evdev_xstats.c            |   4 +-
 drivers/gpu/cuda/common.h                     |   3 +-
 drivers/mempool/dpaa/dpaa_mempool.h           |   5 +-
 drivers/mempool/dpaa2/dpaa2_hw_mempool.c      |   8 +-
 drivers/mempool/dpaa2/dpaa2_hw_mempool_logs.h |  10 +-
 drivers/mempool/octeontx/octeontx_fpavf.c     |  22 +-
 drivers/mempool/octeontx/octeontx_pool_logs.h |   7 +-
 .../mempool/octeontx/rte_mempool_octeontx.c   |   6 +-
 drivers/ml/cnxk/cn10k_ml_dev.c                |  32 +-
 drivers/ml/cnxk/cnxk_ml_ops.c                 |  20 +-
 drivers/net/af_packet/rte_eth_af_packet.c     |  12 +-
 drivers/net/af_xdp/rte_eth_af_xdp.c           | 212 +++----
 drivers/net/atlantic/atl_logs.h               |  22 +-
 drivers/net/atlantic/atl_rxtx.c               |   4 +-
 drivers/net/atlantic/hw_atl/hw_atl_utils.c    |  12 +-
 drivers/net/avp/avp_ethdev.c                  | 155 +++--
 drivers/net/avp/avp_logs.h                    |  17 +-
 drivers/net/axgbe/axgbe_dev.c                 |  34 +-
 drivers/net/axgbe/axgbe_ethdev.c              | 130 ++--
 drivers/net/axgbe/axgbe_i2c.c                 |  18 +-
 drivers/net/axgbe/axgbe_logs.h                |  12 +-
 drivers/net/axgbe/axgbe_mdio.c                |  36 +-
 drivers/net/axgbe/axgbe_phy_impl.c            |  50 +-
 drivers/net/axgbe/axgbe_rxtx.c                |  24 +-
 drivers/net/bnx2x/bnx2x.c                     |   8 +-
 drivers/net/bnx2x/bnx2x_logs.h                |  42 +-
 drivers/net/bnxt/bnxt.h                       |   8 +-
 drivers/net/bnxt/bnxt_cpr.c                   |  66 +-
 drivers/net/bnxt/bnxt_ethdev.c                | 570 +++++++++---------
 drivers/net/bnxt/bnxt_filter.c                |  18 +-
 drivers/net/bnxt/bnxt_flow.c                  | 126 ++--
 drivers/net/bnxt/bnxt_hwrm.c                  | 328 +++++-----
 drivers/net/bnxt/bnxt_irq.c                   |   4 +-
 drivers/net/bnxt/bnxt_reps.c                  |  86 +--
 drivers/net/bnxt/bnxt_ring.c                  |  18 +-
 drivers/net/bnxt/bnxt_rxq.c                   |  66 +-
 drivers/net/bnxt/bnxt_rxr.c                   |  32 +-
 drivers/net/bnxt/bnxt_rxtx_vec_avx2.c         |   2 +-
 drivers/net/bnxt/bnxt_rxtx_vec_neon.c         |   6 +-
 drivers/net/bnxt/bnxt_rxtx_vec_sse.c          |   6 +-
 drivers/net/bnxt/bnxt_stats.c                 |   6 +-
 drivers/net/bnxt/bnxt_txq.c                   |  16 +-
 drivers/net/bnxt/bnxt_txr.c                   |  20 +-
 drivers/net/bnxt/bnxt_vnic.c                  | 124 ++--
 drivers/net/bnxt/rte_pmd_bnxt.c               | 132 ++--
 .../net/bnxt/tf_core/tf_em_hash_internal.c    |   4 +-
 drivers/net/bnxt/tf_core/tf_em_internal.c     |   4 +-
 drivers/net/bnxt/tf_ulp/bnxt_tf_common.h      |   3 +-
 drivers/net/bnxt/tf_ulp/bnxt_tf_pmd_shim.c    |   6 +-
 drivers/net/bnxt/tf_ulp/bnxt_ulp.c            |   2 +-
 drivers/net/bnxt/tf_ulp/ulp_fc_mgr.c          |  22 +-
 drivers/net/bnxt/tf_ulp/ulp_ha_mgr.c          |   2 +-
 drivers/net/bonding/eth_bond_private.h        |   6 +-
 drivers/net/bonding/rte_eth_bond_8023ad.c     | 112 ++--
 drivers/net/bonding/rte_eth_bond_alb.c        |   2 +-
 drivers/net/bonding/rte_eth_bond_api.c        |   4 +-
 drivers/net/bonding/rte_eth_bond_pmd.c        |  10 +-
 drivers/net/cnxk/cn10k_ethdev.c               |   2 +-
 drivers/net/cnxk/cn9k_ethdev.c                |   2 +-
 drivers/net/cnxk/cnxk_eswitch_devargs.c       |   2 +-
 drivers/net/cnxk/cnxk_ethdev.c                |   4 +-
 drivers/net/cnxk/cnxk_ethdev_mcs.c            |  14 +-
 drivers/net/cnxk/cnxk_ethdev_ops.c            |   2 +-
 drivers/net/cnxk/cnxk_rep.c                   |   8 +-
 drivers/net/cnxk/cnxk_rep.h                   |   2 +-
 drivers/net/cpfl/cpfl_ethdev.c                |   2 +-
 drivers/net/cpfl/cpfl_flow_parser.c           |   2 +-
 drivers/net/cpfl/cpfl_fxp_rule.c              |   8 +-
 drivers/net/cpfl/cpfl_logs.h                  |  16 +-
 drivers/net/dpaa/dpaa_ethdev.c                |   9 +-
 drivers/net/dpaa/dpaa_ethdev.h                |   9 +-
 drivers/net/dpaa/fmlib/fm_ext.h               |  21 +-
 drivers/net/dpaa2/dpaa2_ethdev.c              |  16 +-
 drivers/net/dpaa2/dpaa2_flow.c                |  36 +-
 drivers/net/dpaa2/dpaa2_mux.c                 |   4 +-
 drivers/net/dpaa2/dpaa2_pmd_logs.h            |  16 +-
 drivers/net/dpaa2/dpaa2_recycle.c             |   6 +-
 drivers/net/dpaa2/dpaa2_rxtx.c                |  44 +-
 drivers/net/dpaa2/dpaa2_sparser.c             |   8 +-
 drivers/net/dpaa2/dpaa2_tm.c                  |  24 +-
 drivers/net/e1000/base/e1000_osdep.h          |   2 +-
 drivers/net/e1000/e1000_logs.h                |  32 +-
 drivers/net/e1000/igb_ethdev.c                |   2 +-
 drivers/net/ena/ena_ethdev.c                  | 348 +++++------
 drivers/net/ena/ena_logs.h                    |  28 +-
 drivers/net/ena/ena_platform.h                |   2 +-
 drivers/net/ena/ena_rss.c                     |  76 +--
 drivers/net/enetc/enetc_ethdev.c              |   4 +-
 drivers/net/enetc/enetc_logs.h                |  16 +-
 drivers/net/enetfec/enet_ethdev.c             |   4 +-
 drivers/net/enetfec/enet_pmd_logs.h           |  11 +-
 drivers/net/enetfec/enet_uio.c                |  10 +-
 drivers/net/enic/enic_compat.h                |   6 +-
 drivers/net/enic/enic_ethdev.c                |  20 +-
 drivers/net/enic/enic_flow.c                  |  20 +-
 drivers/net/enic/enic_vf_representor.c        |  16 +-
 drivers/net/failsafe/failsafe_args.c          |   2 +-
 drivers/net/failsafe/failsafe_eal.c           |   2 +-
 drivers/net/failsafe/failsafe_ether.c         |   4 +-
 drivers/net/failsafe/failsafe_intr.c          |   6 +-
 drivers/net/failsafe/failsafe_private.h       |   7 +-
 drivers/net/fm10k/base/fm10k_osdep.h          |   2 +-
 drivers/net/fm10k/fm10k_logs.h                |  31 +-
 drivers/net/gve/base/gve_adminq.c             |   4 +-
 drivers/net/gve/gve_logs.h                    |   6 +-
 drivers/net/gve/gve_rx.c                      |   2 +-
 drivers/net/gve/gve_tx.c                      |   2 +-
 drivers/net/hinic/base/hinic_compat.h         |   9 +-
 drivers/net/hinic/base/hinic_pmd_eqs.c        |   2 +-
 drivers/net/hinic/base/hinic_pmd_mbox.c       |   6 +-
 drivers/net/hinic/base/hinic_pmd_niccfg.c     |   8 +-
 drivers/net/hinic/hinic_pmd_ethdev.c          |   4 +-
 drivers/net/hns3/hns3_dump.c                  |  12 +-
 drivers/net/hns3/hns3_intr.c                  |  12 +-
 drivers/net/hns3/hns3_logs.h                  |  41 +-
 drivers/net/hns3/hns3_ptp.c                   |   2 +-
 drivers/net/hns3/hns3_regs.c                  |   4 +-
 drivers/net/i40e/base/i40e_osdep.h            |   6 +-
 drivers/net/i40e/i40e_ethdev.c                |  51 +-
 drivers/net/i40e/i40e_logs.h                  |  31 +-
 drivers/net/i40e/i40e_pf.c                    |   8 +-
 drivers/net/i40e/i40e_rxtx.c                  |  42 +-
 drivers/net/iavf/iavf_ethdev.c                |  12 +-
 drivers/net/iavf/iavf_log.h                   |  31 +-
 drivers/net/iavf/iavf_rxtx.c                  |  16 +-
 drivers/net/ice/base/ice_osdep.h              |   2 +-
 drivers/net/ice/ice_dcf_ethdev.c              |   4 +-
 drivers/net/ice/ice_dcf_vf_representor.c      |  14 +-
 drivers/net/ice/ice_ethdev.c                  |  50 +-
 drivers/net/ice/ice_fdir_filter.c             |   2 +-
 drivers/net/ice/ice_hash.c                    |   8 +-
 drivers/net/ice/ice_logs.h                    |  31 +-
 drivers/net/ice/ice_rxtx.c                    |  18 +-
 drivers/net/idpf/idpf_logs.h                  |  21 +-
 drivers/net/igc/base/igc_osdep.h              |   2 +-
 drivers/net/igc/igc_logs.h                    |  24 +-
 drivers/net/ipn3ke/ipn3ke_ethdev.c            |   4 +-
 drivers/net/ipn3ke/ipn3ke_flow.c              |  23 +-
 drivers/net/ipn3ke/ipn3ke_logs.h              |   6 +-
 drivers/net/ipn3ke/ipn3ke_representor.c       |  20 +-
 drivers/net/ipn3ke/ipn3ke_tm.c                |  10 +-
 drivers/net/ixgbe/base/ixgbe_osdep.h          |   2 +-
 drivers/net/ixgbe/ixgbe_ethdev.c              |   7 +-
 drivers/net/ixgbe/ixgbe_ipsec.c               |  24 +-
 drivers/net/ixgbe/ixgbe_logs.h                |  31 +-
 drivers/net/ixgbe/ixgbe_pf.c                  |  18 +-
 drivers/net/ixgbe/rte_pmd_ixgbe.c             |   8 +-
 drivers/net/mana/mana.h                       |  15 +-
 drivers/net/memif/rte_eth_memif.c             |   2 +-
 drivers/net/memif/rte_eth_memif.h             |   6 +-
 drivers/net/mlx4/mlx4.c                       |   4 +-
 drivers/net/mlx4/mlx4_mr.c                    |  18 +-
 drivers/net/mlx4/mlx4_utils.h                 |  15 +-
 drivers/net/mvneta/mvneta_ethdev.h            |   6 +-
 drivers/net/mvpp2/mrvl_ethdev.h               |   6 +-
 drivers/net/netvsc/hn_logs.h                  |  26 +-
 drivers/net/netvsc/hn_rndis.c                 |  60 +-
 drivers/net/netvsc/hn_rxtx.c                  |   4 +-
 drivers/net/nfb/nfb.h                         |   6 +-
 drivers/net/nfp/nfp_logs.h                    |  34 +-
 drivers/net/ngbe/base/ngbe_hw.c               |   2 +-
 drivers/net/ngbe/ngbe_ethdev.c                |   2 +-
 drivers/net/ngbe/ngbe_logs.h                  |  28 +-
 drivers/net/ngbe/ngbe_pf.c                    |  10 +-
 drivers/net/null/rte_eth_null.c               |   6 +-
 drivers/net/octeon_ep/cnxk_ep_tx.c            |   2 +-
 drivers/net/octeon_ep/cnxk_ep_vf.c            |  12 +-
 drivers/net/octeon_ep/otx2_ep_vf.c            |  18 +-
 drivers/net/octeon_ep/otx_ep_common.h         |  23 +-
 drivers/net/octeon_ep/otx_ep_ethdev.c         |  83 +--
 drivers/net/octeon_ep/otx_ep_mbox.c           |  30 +-
 drivers/net/octeon_ep/otx_ep_rxtx.c           |  78 +--
 drivers/net/octeon_ep/otx_ep_vf.c             |  20 +-
 drivers/net/octeontx/base/octeontx_pkovf.c    |   2 +-
 drivers/net/octeontx/octeontx_ethdev.c        |  26 +-
 drivers/net/octeontx/octeontx_logs.h          |  21 +-
 drivers/net/pcap/pcap_ethdev.c                |   4 +-
 drivers/net/pcap/pcap_osdep.h                 |   6 +-
 drivers/net/pfe/pfe_ethdev.c                  |  22 +-
 drivers/net/pfe/pfe_hif.c                     |  12 +-
 drivers/net/pfe/pfe_hif_lib.c                 |   2 +-
 drivers/net/pfe/pfe_logs.h                    |  11 +-
 drivers/net/qede/qede_rxtx.c                  |  66 +-
 drivers/net/ring/rte_eth_ring.c               |   6 +-
 drivers/net/sfc/sfc_ethdev.c                  |   2 +-
 drivers/net/sfc/sfc_log.h                     |   7 +-
 drivers/net/softnic/rte_eth_softnic.c         |   6 +-
 drivers/net/tap/tap_log.h                     |   6 +-
 drivers/net/thunderx/nicvf_ethdev.c           |   2 +-
 drivers/net/thunderx/nicvf_logs.h             |  18 +-
 drivers/net/txgbe/base/txgbe_osdep.h          |   8 +
 drivers/net/txgbe/txgbe_ethdev.c              |   4 +-
 drivers/net/txgbe/txgbe_ipsec.c               |  24 +-
 drivers/net/txgbe/txgbe_logs.h                |  44 +-
 drivers/net/txgbe/txgbe_pf.c                  |  20 +-
 drivers/net/vdev_netvsc/vdev_netvsc.c         |   7 +-
 drivers/net/vhost/rte_eth_vhost.c             |  75 +--
 drivers/net/virtio/virtio_cvq.c               |  19 +-
 drivers/net/virtio/virtio_logs.h              |  23 +-
 drivers/net/virtio/virtio_user/vhost_vdpa.c   |   2 +-
 .../net/virtio/virtio_user/virtio_user_dev.c  |  32 +-
 drivers/net/vmxnet3/vmxnet3_ethdev.c          |   4 +-
 drivers/net/vmxnet3/vmxnet3_logs.h            |  29 +-
 drivers/net/vmxnet3/vmxnet3_rxtx.c            |   2 +-
 drivers/raw/cnxk_bphy/cnxk_bphy.c             |   2 +-
 drivers/raw/cnxk_bphy/rte_pmd_bphy.h          |   6 +-
 drivers/raw/cnxk_gpio/cnxk_gpio.h             |   5 +-
 drivers/raw/dpaa2_cmdif/dpaa2_cmdif.c         |  14 +-
 drivers/raw/dpaa2_cmdif/dpaa2_cmdif_logs.h    |  14 +-
 drivers/raw/ifpga/afu_pmd_n3000.c             |   2 +-
 drivers/raw/ifpga/ifpga_rawdev.c              |  94 +--
 drivers/raw/ifpga/ifpga_rawdev.h              |   6 +-
 drivers/raw/ntb/ntb.h                         |   6 +-
 drivers/raw/skeleton/skeleton_rawdev.h        |   6 +-
 drivers/raw/skeleton/skeleton_rawdev_test.c   |   5 +-
 drivers/regex/cn9k/cn9k_regexdev.c            |   2 +-
 drivers/vdpa/ifc/base/ifcvf.c                 |  10 +-
 drivers/vdpa/ifc/ifcvf_vdpa.c                 |  16 +-
 drivers/vdpa/nfp/nfp_vdpa.c                   |   2 +-
 drivers/vdpa/nfp/nfp_vdpa_log.h               |  12 +-
 drivers/vdpa/sfc/sfc_vdpa_log.h               |   7 +-
 364 files changed, 4061 insertions(+), 4206 deletions(-)

-- 
2.46.0
#24 lore raw

PATCH v2 1/14 devtools: fix forbidden token check with multiple files

If a patch contains multiple files, it is possible to pass through the check because the count of token mentions is not reset between file evaluation.

Example with a fake patch:

  $ cat toto.patch
  --- a/drivers/plop1
  +++ b/drivers/plop1
  - RTE_LOG(
  - RTE_LOG(
  + RTE_LOG(
  --- a/drivers/plop2
  +++ b/drivers/plop2
  + RTE_LOG(
  $ awk -v FOLDERS='drivers' -v EXPRESSIONS='RTE_LOG\\('
    -v MESSAGE='Prefer RTE_LOG_LINE'
    -f devtools/check-forbidden-tokens.awk toto.patch

Besides, the expressions[] array is not used since commit b467d38284b1 ("devtools: add explicit warnings for forbidden tokens").

Fixes 42f4d724ec27 ("devtools: move awk script ckecking forbidden tokens")
---
 devtools/check-forbidden-tokens.awk | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)
devtools/check-forbidden-tokens.awk +3 -5
index 90d3a64f8e..807dad7f48 100755
@@ -32,14 +32,11 @@ BEGIN {
 		for (i in deny_expr) {
 			forbidden_added = "^\\+.*" deny_expr[i];
 			forbidden_removed="^-.*" deny_expr[i];
-			current = expressions[deny_expr[i]]
 			if ($0 ~ forbidden_added) {
-				count = count + 1;
-				expressions[deny_expr[i]] = current + 1
+				count = count + 1
 			}
 			if ($0 ~ forbidden_removed) {
-				count = count - 1;
-				expressions[deny_expr[i]] = current - 1
+				count = count - 1
 			}
 		}
 	}
@@ -55,6 +52,7 @@ BEGIN {
 	if (count > 0) {
 		exit;
 	}
+	count = 0
 	for (i in deny_folders) {
 		re = "^\\+\\+\\+ b/" deny_folders[i];
 		if ($0 ~ re) {
Signature · 1 line
2.46.0
Acked-by on v2 1/14
#25 lore raw

Re: [PATCH v2 01/14] devtools: fix forbidden token check with multiple files

12/09/2024 10:26, David Marchand:

devtools/check-forbidden-tokens.awk BEGIN {

Quoted 20 lines
devtools/check-forbidden-tokens.awk +2 -5
@@ -32,14 +32,11 @@ BEGIN {
 		for (i in deny_expr) {
 			forbidden_added = "^\\+.*" deny_expr[i];
 			forbidden_removed="^-.*" deny_expr[i];
-			current = expressions[deny_expr[i]]
 			if ($0 ~ forbidden_added) {
-				count = count + 1;
-				expressions[deny_expr[i]] = current + 1
+				count = count + 1
 			}
 			if ($0 ~ forbidden_removed) {
-				count = count - 1;
-				expressions[deny_expr[i]] = current - 1
+				count = count - 1
 			}
 		}
 	}
@@ -55,6 +52,7 @@ BEGIN {

While at it, you could insert a missing space in "previous filehad new additions" few lines above.

devtools/check-forbidden-tokens.awk BEGIN { · line 55

Quoted 4 lines
devtools/check-forbidden-tokens.awk +1 -0
 	if (count > 0) {
 		exit;
 	}
+	count = 0

I'm not an awk expert, but it looks simple enough. Thank you

#26 lore raw

PATCH v2 2/14 devtools: report all warnings in forbidden token check

In reply to David Marchand

Do not stop at the first file that got warnings.

---
 devtools/check-forbidden-tokens.awk | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
devtools/check-forbidden-tokens.awk +6 -1
index 807dad7f48..d72d244d3a 100755
@@ -13,6 +13,7 @@ BEGIN {
 	in_file=0;
 	in_comment=0;
 	count=0;
+	warned=0;
 	comment_start="/*"
 	comment_end="*/"
 }
@@ -50,7 +51,8 @@ BEGIN {
 ($0 ~ "^\\+\\+\\+ b/") {
 	in_file = 0;
 	if (count > 0) {
-		exit;
+		warned = warned + 1
+		print "Warning in " substr(last_file,7) ":"
 	}
 	count = 0
 	for (i in deny_folders) {
@@ -66,7 +68,10 @@ BEGIN {
 }
 END {
 	if (count > 0) {
+		warned = warned + 1
 		print "Warning in " substr(last_file,7) ":"
+	}
+	if (warned > 0) {
 		print MESSAGE
 		exit RET_ON_FAIL
 	}
Signature · 1 line
2.46.0
#28 lore raw

PATCH v2 3/14 net/dpaa: remove broken debug macros

In reply to David Marchand

Those debug macros never worked as existing callers never passed a 'level' argument.
Remove them.

---
 drivers/net/dpaa/fmlib/fm_ext.h | 21 ++-------------------
 1 file changed, 2 insertions(+), 19 deletions(-)
drivers/net/dpaa/fmlib/fm_ext.h +2 -19
index 8e7153bdaf..4666fa3b0b 100644
@@ -15,25 +15,8 @@
 #define MODULE_FM		0x00010000
 #define __ERR_MODULE__		MODULE_FM
 
-/* #define FM_LIB_DBG */
-
-#if defined(FM_LIB_DBG)
-	#define _fml_dbg(fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_pmd, "fmlib:%s(): " fmt "\n", \
-			__func__, ##args)
-#else
-	#define _fml_dbg(arg...)
-#endif
-
-/*#define FM_IOCTL_DBG*/
-
-#if defined(FM_IOCTL_DBG)
-	#define _fm_ioctl_dbg(fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_pmd, "fmioc:%s(): " fmt "\n", \
-				__func__, ##args)
-#else
-	#define _fm_ioctl_dbg(arg...)
-#endif
+#define _fml_dbg(...)
+#define _fm_ioctl_dbg(...)
 
 /*
  * @Group	lnx_ioctl_ncsw_grp	NetCommSw Linux User-Space (IOCTL) API
Signature · 1 line
2.46.0
#29 lore raw

Re: [PATCH v2 03/14] net/dpaa: remove broken debug macros

12/09/2024 10:26, David Marchand:

Quoted 28 lines

Those debug macros never worked as existing callers never passed a 'level' argument.
Remove them.

---
 drivers/net/dpaa/fmlib/fm_ext.h | 21 ++-------------------
 1 file changed, 2 insertions(+), 19 deletions(-)
drivers/net/dpaa/fmlib/fm_ext.h +0 -11
index 8e7153bdaf..4666fa3b0b 100644
@@ -15,25 +15,8 @@
 #define MODULE_FM		0x00010000
 #define __ERR_MODULE__		MODULE_FM
 
-/* #define FM_LIB_DBG */
-
-#if defined(FM_LIB_DBG)
-	#define _fml_dbg(fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_pmd, "fmlib:%s(): " fmt "\n", \
-			__func__, ##args)
-#else
-	#define _fml_dbg(arg...)
-#endif
-
-/*#define FM_IOCTL_DBG*/

drivers/net/dpaa/fmlib/fm_ext.h line 19

Quoted 10 lines
drivers/net/dpaa/fmlib/fm_ext.h +2 -8
-
-#if defined(FM_IOCTL_DBG)
-	#define _fm_ioctl_dbg(fmt, args...) \
-	rte_log(RTE_LOG_ ## level, dpaa_logtype_pmd, "fmioc:%s(): " fmt "\n", \
-				__func__, ##args)
-#else
-	#define _fm_ioctl_dbg(arg...)
-#endif
+#define _fml_dbg(...)
+#define _fm_ioctl_dbg(...)

Why not removing the calls to these macros?

#30 lore raw

Re: [PATCH v2 03/14] net/dpaa: remove broken debug macros

Quoted 8 lines · Thomas Monjalon

12/09/2024 10:26, David Marchand:

Quoted 5 lines

Those debug macros never worked as existing callers never passed a 'level' argument.
Remove them.

Why not removing the calls to these macros?

I was unclear if the fmlib enters the "base driver" category. So I simply removed macros from the header providing wrappers to dpdk API.

Relooking, I see other changes in this directory, so I agree I may as well remove those calls.

Hemant, opinion?

Signature · 1 line
David Marchand
Reviewed-by
#31 lore raw

Re: [PATCH v2 03/14] net/dpaa: remove broken debug macros

Quoted 7 lines · David Marchand
Quoted 6 lines · Thomas Monjalon

12/09/2024 10:26, David Marchand:

Quoted 5 lines

Those debug macros never worked as existing callers never passed a 'level' argument.
Remove them.

Quoted 9 lines
Quoted 1 line

Why not removing the calls to these macros?

I was unclear if the fmlib enters the "base driver" category. So I simply removed macros from the header providing wrappers to dpdk API.

Relooking, I see other changes in this directory, so I agree I may as well remove those calls.

Hemant, opinion?

Yes, fmlib is a common base library. So, it is better to not remove the calls.  Otherwise, we have to maintain the changes from base.

with that

#32 lore raw

PATCH v2 4/14 net/sfc: fix driver logtype token

In reply to David Marchand

The net/sfc driver logtype was registered under pmd.net.sfc."driver".

Fixes 0f39f32482a1 ("net/sfc: remove use of EAL logtype")
---
 drivers/net/sfc/sfc_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/sfc/sfc_ethdev.c +1 -1
index 24686a1eaf..3480a51642 100644
@@ -3616,4 +3616,4 @@ RTE_PMD_REGISTER_PARAM_STRING(net_sfc_efx,
 	SFC_KVARG_FW_VARIANT "=" SFC_KVARG_VALUES_FW_VARIANT " "
 	SFC_KVARG_RXD_WAIT_TIMEOUT_NS "=<long> "
 	SFC_KVARG_STATS_UPDATE_PERIOD_MS "=<long>");
-RTE_LOG_REGISTER_SUFFIX(sfc_logtype_driver, "driver", NOTICE);
+RTE_LOG_REGISTER_SUFFIX(sfc_logtype_driver, driver, NOTICE);
Signature · 1 line
2.46.0
#33 lore raw

PATCH v2 5/14 drivers: reuse default logtype for SFC drivers

In reply to David Marchand

Nothing is fixed here, just reuse the value coming from the build framework rather than use a fixed string that may get wrong in the future.

---
 drivers/net/sfc/sfc_log.h       | 7 ++-----
 drivers/vdpa/sfc/sfc_vdpa_log.h | 7 ++-----
 2 files changed, 4 insertions(+), 10 deletions(-)
drivers/net/sfc/sfc_log.h +2 -5
index 10a9ce6ced..b92b358927 100644
@@ -13,9 +13,6 @@
 /** Generic driver log type */
 extern int sfc_logtype_driver;
 
-/** Common log type name prefix */
-#define SFC_LOGTYPE_PREFIX	"pmd.net.sfc."
-
 /** Log PMD generic message, add a prefix and a line break */
 #define SFC_GENERIC_LOG(level, ...) \
 	rte_log(RTE_LOG_ ## level, sfc_logtype_driver,			\
@@ -23,10 +20,10 @@ extern int sfc_logtype_driver;
 			RTE_FMT_TAIL(__VA_ARGS__ ,)))
 
 /** Name prefix for the per-device log type used to report basic information */
-#define SFC_LOGTYPE_MAIN_STR	SFC_LOGTYPE_PREFIX "main"
+#define SFC_LOGTYPE_MAIN_STR	RTE_STR(RTE_LOG_DEFAULT_LOGTYPE) ".main"
 
 /** Device MCDI log type name prefix */
-#define SFC_LOGTYPE_MCDI_STR	SFC_LOGTYPE_PREFIX "mcdi"
+#define SFC_LOGTYPE_MCDI_STR	RTE_STR(RTE_LOG_DEFAULT_LOGTYPE) ".mcdi"
 
 #define SFC_LOG_PREFIX_MAX	32
 
drivers/vdpa/sfc/sfc_vdpa_log.h +2 -5
index 6c0101dbb4..1104e7de43 100644
@@ -8,9 +8,6 @@
 /** Generic driver log type */
 extern int sfc_vdpa_logtype_driver;
 
-/** Common log type name prefix */
-#define SFC_VDPA_LOGTYPE_PREFIX	"pmd.vdpa.sfc."
-
 /** Log PMD generic message, add a prefix and a line break */
 #define SFC_VDPA_GENERIC_LOG(level, ...) \
 	rte_log(RTE_LOG_ ## level, sfc_vdpa_logtype_driver,		\
@@ -18,10 +15,10 @@ extern int sfc_vdpa_logtype_driver;
 			RTE_FMT_TAIL(__VA_ARGS__ ,)))
 
 /** Name prefix for the per-device log type used to report basic information */
-#define SFC_VDPA_LOGTYPE_MAIN_STR	SFC_VDPA_LOGTYPE_PREFIX "main"
+#define SFC_VDPA_LOGTYPE_MAIN_STR	RTE_STR(RTE_LOG_DEFAULT_LOGTYPE) ".main"
 
 /** Device MCDI log type name prefix */
-#define SFC_VDPA_LOGTYPE_MCDI_STR	SFC_VDPA_LOGTYPE_PREFIX "mcdi"
+#define SFC_VDPA_LOGTYPE_MCDI_STR	RTE_STR(RTE_LOG_DEFAULT_LOGTYPE) ".mcdi"
 
 #define SFC_VDPA_LOG_PREFIX_MAX	32
 
Signature · 1 line
2.46.0
#34 lore raw

PATCH v2 6/14 drivers: move log wrappers to Intel base drivers

In reply to David Marchand

Remove _RAW macros and directly call RTE_LOG() where needed in headers providing wrappers for base drivers code.
This will help later when adding a check on RTE_LOG() use in drivers/.

---
 drivers/common/iavf/iavf_osdep.h      |  8 ++++----
 drivers/common/idpf/base/idpf_osdep.h | 10 +++++-----
 drivers/net/e1000/base/e1000_osdep.h  |  2 +-
 drivers/net/e1000/e1000_logs.h        |  8 ++------
 drivers/net/fm10k/base/fm10k_osdep.h  |  2 +-
 drivers/net/fm10k/fm10k_logs.h        |  7 ++-----
 drivers/net/i40e/base/i40e_osdep.h    |  6 +++---
 drivers/net/i40e/i40e_logs.h          |  7 ++-----
 drivers/net/ice/base/ice_osdep.h      |  2 +-
 drivers/net/ice/ice_logs.h            |  7 ++-----
 drivers/net/igc/base/igc_osdep.h      |  2 +-
 drivers/net/igc/igc_logs.h            |  6 +-----
 drivers/net/ixgbe/base/ixgbe_osdep.h  |  2 +-
 drivers/net/ixgbe/ixgbe_logs.h        |  7 ++-----
 14 files changed, 28 insertions(+), 48 deletions(-)
drivers/common/iavf/iavf_osdep.h +4 -4
index 263d92400c..1f2b7889cb 100644
@@ -143,16 +143,16 @@ writeq(uint64_t value, volatile void *addr)
 #define IAVF_WRITE_FLUSH(a) IAVF_READ_REG(a, IAVF_VFGEN_RSTAT)
 
 extern int iavf_common_logger;
+#define RTE_LOGTYPE_IAVF_COMMON iavf_common_logger
 
-#define DEBUGOUT(S)          rte_log(RTE_LOG_DEBUG, iavf_common_logger, S)
-#define DEBUGOUT2(S, A...)   rte_log(RTE_LOG_DEBUG, iavf_common_logger, S, ##A)
+#define DEBUGOUT(S, ...)     RTE_LOG(DEBUG, IAVF_COMMON, S, ## __VA_ARGS__)
+#define DEBUGOUT2(S, ...)    DEBUGOUT(S, ## __VA_ARGS__)
 #define DEBUGFUNC(F)         DEBUGOUT(F "\n")
 
 #define iavf_debug(h, m, s, ...)                                \
 do {                                                            \
 	if (((m) & (h)->debug_mask))                            \
-		rte_log(RTE_LOG_DEBUG, iavf_common_logger,      \
-			"iavf %02x.%x " s,                      \
+		DEBUGOUT("iavf %02x.%x " s,                      \
 			(h)->bus.device, (h)->bus.func,         \
 					##__VA_ARGS__);         \
 } while (0)
drivers/common/idpf/base/idpf_osdep.h +5 -5
index b2af8f443d..e042ef871c 100644
@@ -25,6 +25,8 @@
 #include <rte_io.h>
 #include <rte_compat.h>
 
+#include "../idpf_common_logs.h"
+
 #define INLINE inline
 #define STATIC static
 
@@ -108,16 +110,14 @@ typedef struct idpf_lock idpf_lock;
 #define FIELD_SIZEOF(t, f) (sizeof(((t *)0)->(f)))
 #define MAKEMASK(m, s) ((m) << (s))
 
-extern int idpf_common_logger;
-
-#define DEBUGOUT(S)		rte_log(RTE_LOG_DEBUG, idpf_common_logger, S)
-#define DEBUGOUT2(S, A...)	rte_log(RTE_LOG_DEBUG, idpf_common_logger, S, ##A)
+#define DEBUGOUT(S, ...)	RTE_LOG(DEBUG, IDPF_COMMON, S, ## __VA_ARGS__)
+#define DEBUGOUT2(S, ...)	DEBUGOUT(S, ## __VA_ARGS__)
 #define DEBUGFUNC(F)		DEBUGOUT(F "\n")
 
 #define idpf_debug(h, m, s, ...)					\
 	do {								\
 		if (((m) & (h)->debug_mask))				\
-			PMD_DRV_LOG_RAW(DEBUG, "idpf %02x.%x " s,       \
+			DEBUGOUT("idpf %02x.%x " s "\n",		\
 					(h)->bus.device, (h)->bus.func,	\
 					##__VA_ARGS__);			\
 	} while (0)
drivers/net/e1000/base/e1000_osdep.h +1 -1
index cd90228cef..6b5d58950f 100644
@@ -27,7 +27,7 @@
 #define msec_delay_irq(x) DELAY(1000*(x))
 
 #define DEBUGFUNC(F)            DEBUGOUT(F "\n");
-#define DEBUGOUT(S, args...)    PMD_DRV_LOG_RAW(DEBUG, S, ##args)
+#define DEBUGOUT(S, ...)        RTE_LOG(DEBUG, E1000_DRIVER, "%s(): " S, __func__, ## __VA_ARGS__)
 #define DEBUGOUT1(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT2(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT3(S, args...)   DEBUGOUT(S, ##args)
drivers/net/e1000/e1000_logs.h +2 -6
index 86f546b0f9..30b5531069 100644
@@ -34,13 +34,9 @@ extern int e1000_logtype_tx;
 #endif
 
 extern int e1000_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, e1000_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
+#define RTE_LOGTYPE_E1000_DRIVER e1000_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
-
+	RTE_LOG(level, E1000_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 /* log init function shared by e1000 and igb drivers */
 void e1000_igb_init_log(void);
drivers/net/fm10k/base/fm10k_osdep.h +1 -1
index 25f46c3908..d3e5528575 100644
@@ -24,7 +24,7 @@
 
 #define STATIC                  static
 #define DEBUGFUNC(F)            DEBUGOUT(F "\n");
-#define DEBUGOUT(S, args...)    PMD_DRV_LOG_RAW(DEBUG, S, ##args)
+#define DEBUGOUT(S, ...)        RTE_LOG(DEBUG, FM10K_DRIVER, "%s(): " S, __func__, ## __VA_ARGS__)
 #define DEBUGOUT1(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT2(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT3(S, args...)   DEBUGOUT(S, ##args)
drivers/net/fm10k/fm10k_logs.h +2 -5
index 4f039f8beb..c4c7c977d9 100644
@@ -33,11 +33,8 @@ extern int fm10k_logtype_tx;
 #endif
 
 extern int fm10k_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, fm10k_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
+#define RTE_LOGTYPE_FM10K_DRIVER fm10k_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG(level, FM10K_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 #endif /* _FM10K_LOGS_H_ */
drivers/net/i40e/base/i40e_osdep.h +3 -3
index aa5dc61841..8960206d8b 100644
@@ -82,8 +82,8 @@ typedef enum i40e_status_code i40e_status;
 
 #define FIELD_SIZEOF(t, f) (sizeof(((t*)0)->f))
 
-#define DEBUGOUT(S)        PMD_DRV_LOG_RAW(DEBUG, S)
-#define DEBUGOUT1(S, A...) PMD_DRV_LOG_RAW(DEBUG, S, ##A)
+#define DEBUGOUT(S, ...) RTE_LOG(DEBUG, I40E_DRIVER, "%s(): " S, __func__, ## __VA_ARGS__)
+#define DEBUGOUT1 DEBUGOUT
 
 #define DEBUGFUNC(F) DEBUGOUT(F "\n")
 #define DEBUGOUT2 DEBUGOUT1
@@ -94,7 +94,7 @@ typedef enum i40e_status_code i40e_status;
 #define i40e_debug(h, m, s, ...)                                \
 do {                                                            \
 	if (((m) & (h)->debug_mask))                            \
-		PMD_DRV_LOG_RAW(DEBUG, "i40e %02x.%x " s,       \
+		DEBUGOUT("i40e %02x.%x " s,			\
 			(h)->bus.device, (h)->bus.func,         \
 					##__VA_ARGS__);         \
 } while (0)
drivers/net/i40e/i40e_logs.h +2 -5
index eebe6c5559..fb1f3a4096 100644
@@ -30,11 +30,8 @@ extern int i40e_logtype_tx;
 #endif
 
 extern int i40e_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, i40e_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
+#define RTE_LOGTYPE_I40E_DRIVER i40e_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG(level, I40E_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 #endif /* _I40E_LOGS_H_ */
drivers/net/ice/base/ice_osdep.h +1 -1
index c17f1bf09f..5f7347023f 100644
@@ -149,7 +149,7 @@ writeq(uint64_t value, volatile void *addr)
 #define ice_debug(h, m, s, ...)					\
 do {								\
 	if (((m) & (h)->debug_mask))				\
-		PMD_DRV_LOG_RAW(DEBUG, "ice %02x.%x " s,	\
+		RTE_LOG(DEBUG, ICE_DRIVER, "ice %02x.%x " s,	\
 			(h)->bus.device, (h)->bus.func,		\
 					##__VA_ARGS__);		\
 } while (0)
drivers/net/ice/ice_logs.h +2 -5
index e79980fb63..a54e9d8b59 100644
@@ -7,6 +7,7 @@
 
 extern int ice_logtype_init;
 extern int ice_logtype_driver;
+#define RTE_LOGTYPE_ICE_DRIVER ice_logtype_driver
 
 #define PMD_INIT_LOG(level, fmt, args...) \
 	rte_log(RTE_LOG_ ## level, ice_logtype_init, "%s(): " fmt "\n", \
@@ -32,11 +33,7 @@ extern int ice_logtype_tx;
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ice_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG(level, ICE_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 #endif /* _ICE_LOGS_H_ */
drivers/net/igc/base/igc_osdep.h +1 -1
index 25090d65ea..4e479eb500 100644
@@ -27,7 +27,7 @@
 #define msec_delay_irq(x) DELAY(1000 * (x))
 
 #define DEBUGFUNC(F)            DEBUGOUT(F "\n")
-#define DEBUGOUT(S, args...)    PMD_DRV_LOG_RAW(DEBUG, S, ##args)
+#define DEBUGOUT(S, ...)        RTE_LOG(DEBUG, IGC_DRIVER, "%s(): " S, __func__, ## __VA_ARGS__)
 #define DEBUGOUT1(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT2(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT3(S, args...)   DEBUGOUT(S, ##args)
drivers/net/igc/igc_logs.h +1 -5
index cca5389eff..4a574f10cb 100644
@@ -35,12 +35,8 @@ extern int igc_logtype_driver;
 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
 #endif
 
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, igc_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG(level, IGC_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 #ifdef __cplusplus
 }
drivers/net/ixgbe/base/ixgbe_osdep.h +1 -1
index e832a7bec8..502f386b56 100644
@@ -33,7 +33,7 @@
 #define msec_delay(x) DELAY(1000*(x))
 
 #define DEBUGFUNC(F)            DEBUGOUT(F "\n");
-#define DEBUGOUT(S, args...)    PMD_DRV_LOG_RAW(DEBUG, S, ##args)
+#define DEBUGOUT(S, ...)        RTE_LOG(DEBUG, IXGBE_DRIVER, "%s(): " S, __func__, ## __VA_ARGS__)
 #define DEBUGOUT1(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT2(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT3(S, args...)   DEBUGOUT(S, ##args)
drivers/net/ixgbe/ixgbe_logs.h +2 -5
index 00ef797ca1..5a2c5ccde0 100644
@@ -31,11 +31,8 @@ extern int ixgbe_logtype_tx;
 #endif
 
 extern int ixgbe_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, ixgbe_logtype_driver, "%s(): " fmt, \
-		__func__, ## args)
-
+#define RTE_LOGTYPE_IXGBE_DRIVER ixgbe_logtype_driver
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
+	RTE_LOG(level, IXGBE_DRIVER, "%s(): " fmt "\n", __func__, ## args)
 
 #endif /* _IXGBE_LOGS_H_ */
Signature · 1 line
2.46.0
#35 lore raw

PATCH v2 7/14 net/txgbe: move wrapper to base driver

In reply to David Marchand

BP_LOG() is only used in the base driver.

---
 drivers/net/txgbe/base/txgbe_osdep.h | 8 ++++++++
 drivers/net/txgbe/txgbe_logs.h       | 7 -------
 2 files changed, 8 insertions(+), 7 deletions(-)
drivers/net/txgbe/base/txgbe_osdep.h +8 -0
index 62d16a6abb..91c8abf12e 100644
@@ -28,6 +28,14 @@
 #define TMZ_VADDR(mz)  ((mz)->addr)
 #define TDEV_NAME(eth_dev)  ((eth_dev)->device->name)
 
+extern int txgbe_logtype_bp;
+#define RTE_LOGTYPE_TXGBE_BP txgbe_logtype_bp
+#define BP_LOG(fmt, ...) \
+	RTE_LOG(DEBUG, TXGBE_BP, \
+		"[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
+		usec_stamp() / 1000000, usec_stamp() % 1000000, \
+		__func__, __LINE__, ## __VA_ARGS__)
+
 #define ASSERT(x) do {			\
 	if (!(x))			\
 		PMD_DRV_LOG(ERR, "TXGBE: %d", x);	\
drivers/net/txgbe/txgbe_logs.h +0 -7
index 74f49ab9ef..b5a5a9233f 100644
@@ -51,11 +51,4 @@ extern int txgbe_logtype_tx_free;
 #define DEBUGOUT(fmt, args...)    PMD_DRV_LOG(DEBUG, fmt, ##args)
 #define PMD_INIT_FUNC_TRACE()     PMD_DRV_LOG(DEBUG, ">>")
 
-extern int txgbe_logtype_bp;
-#define BP_LOG(fmt, args...) \
-	rte_log(RTE_LOG_DEBUG, txgbe_logtype_bp, \
-		"[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
-		usec_stamp() / 1000000, usec_stamp() % 1000000, \
-		__func__, __LINE__, ##args)
-
 #endif /* _TXGBE_LOGS_H_ */
Signature · 1 line
2.46.0
#36 lore raw

PATCH v2 8/14 event/dlb2: fix base driver logs

In reply to David Marchand

DLB2_(HW_)?(INFO|ERR|DEBUG) are defined in osdep.h for base/ driver code to log messages.
The base/ driver should not bypass those macros, directly calling DLB2_LOG_(INFO|ERR|DEBUG).

Besides, DLB2_LOG_* macros always append a \n, meaning that most of the logs coming from the base/ driver code have double \n.

This patch fixes osdep.h macro definition, then remove a few direct calls to DLB2_LOG_* (and adjust \n accordingly).

---
 drivers/event/dlb2/dlb2_log.h              |  7 +++----
 drivers/event/dlb2/pf/base/dlb2_osdep.h    | 16 +++++++++++++---
 drivers/event/dlb2/pf/base/dlb2_resource.c | 18 +++++++++---------
 3 files changed, 25 insertions(+), 16 deletions(-)
drivers/event/dlb2/dlb2_log.h +3 -4
index 54d6a3011f..81908af71f 100644
@@ -6,12 +6,11 @@
 #define _DLB2_EVDEV_LOG_H_
 
 extern int eventdev_dlb2_log_level;
-#define RTE_LOGTYPE_EVENTDEV_DLB2_LOG_LEVEL eventdev_dlb2_log_level
+#define RTE_LOGTYPE_EVENTDEV_DLB2 eventdev_dlb2_log_level
 
 /* Dynamic logging */
 #define DLB2_LOG_IMPL(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, eventdev_dlb2_log_level, "%s" fmt "\n", \
-		__func__, ##args)
+	RTE_LOG(level, EVENTDEV_DLB2, "%s" fmt "\n", __func__, ##args)
 
 #define DLB2_LOG_INFO(fmt, args...) \
 	DLB2_LOG_IMPL(INFO, fmt, ## args)
@@ -21,6 +20,6 @@ extern int eventdev_dlb2_log_level;
 
 /* remove debug logs at compile time unless actually debugging */
 #define DLB2_LOG_DBG(fmt, args...) \
-	RTE_LOG_DP(DEBUG, EVENTDEV_DLB2_LOG_LEVEL, fmt, ## args)
+	RTE_LOG_DP(DEBUG, EVENTDEV_DLB2, fmt, ## args)
 
 #endif /* _DLB2_EVDEV_LOG_H_ */
drivers/event/dlb2/pf/base/dlb2_osdep.h +13 -3
index 06d69f39b1..16c5e3b797 100644
@@ -41,13 +41,13 @@
 
 /* Map to PMDs logging interface */
 #define DLB2_ERR(dev, fmt, args...) \
-	DLB2_LOG_ERR(fmt, ## args)
+	RTE_LOG(ERR, EVENTDEV_DLB2, "%s" fmt, __func__, ## args)
 
 #define DLB2_INFO(dev, fmt, args...) \
-	DLB2_LOG_INFO(fmt, ## args)
+	RTE_LOG(INFO, EVENTDEV_DLB2, "%s" fmt, __func__, ## args)
 
 #define DLB2_DEBUG(dev, fmt, args...) \
-	DLB2_LOG_DBG(fmt, ## args)
+	RTE_LOG_DP(DEBUG, EVENTDEV_DLB2, fmt, ## args)
 
 /**
  * os_udelay() - busy-wait for a number of microseconds
@@ -139,6 +139,16 @@ static inline void os_fence_hcw(struct dlb2_hw *hw, u64 *pp_addr)
 	DLB2_ERR(dlb2, __VA_ARGS__);	\
 } while (0)
 
+/**
+ * DLB2_HW_INFO() - log an error message
+ * @dlb2: dlb2_hw handle for a particular device.
+ * @...: variable string args.
+ */
+#define DLB2_HW_INFO(dlb2, ...) do {	\
+	RTE_SET_USED(dlb2);		\
+	DLB2_INFO(dlb2, __VA_ARGS__);	\
+} while (0)
+
 /**
  * DLB2_HW_DBG() - log an info message
  * @dlb2: dlb2_hw handle for a particular device.
drivers/event/dlb2/pf/base/dlb2_resource.c +9 -9
index 7ce3e3531c..3004902118 100644
@@ -841,7 +841,7 @@ dlb2_get_pp_allocation(struct dlb2_hw *hw, int cpu, int port_type)
 
 	dlb2_dev->enqueue_four = dlb2_movdir64b;
 
-	DLB2_LOG_INFO(" for %s: cpu core used in pp profiling: %d\n",
+	DLB2_HW_INFO(hw, " for %s: cpu core used in pp profiling: %d\n",
 		      is_ldb ? "LDB" : "DIR", cpu);
 
 	memset(cos_cycles, 0, num_sort * sizeof(struct dlb2_pp_thread_data));
@@ -854,7 +854,7 @@ dlb2_get_pp_allocation(struct dlb2_hw *hw, int cpu, int port_type)
 
 		err = rte_thread_attr_init(&th_attr);
 		if (err != 0) {
-			DLB2_LOG_ERR(": thread attribute failed! err=%d", err);
+			DLB2_HW_ERR(hw, ": thread attribute failed! err=%d\n", err);
 			return;
 		}
 		CPU_SET(cpu, &th_attr.cpuset);
@@ -862,7 +862,7 @@ dlb2_get_pp_allocation(struct dlb2_hw *hw, int cpu, int port_type)
 		err = rte_thread_create(&thread, &th_attr,
 				&dlb2_pp_profile_func, &dlb2_thread_data[i]);
 		if (err) {
-			DLB2_LOG_ERR(": thread creation failed! err=%d", err);
+			DLB2_HW_ERR(hw, ": thread creation failed! err=%d\n", err);
 			return;
 		}
 
@@ -871,7 +871,7 @@ dlb2_get_pp_allocation(struct dlb2_hw *hw, int cpu, int port_type)
 
 		err = rte_thread_join(thread, NULL);
 		if (err) {
-			DLB2_LOG_ERR(": thread join failed! err=%d", err);
+			DLB2_HW_ERR(hw, ": thread join failed! err=%d\n", err);
 			return;
 		}
 
@@ -911,7 +911,7 @@ dlb2_get_pp_allocation(struct dlb2_hw *hw, int cpu, int port_type)
 
 	for (i = 0; i < num_ports; i++) {
 		port_allocations[i] = dlb2_thread_data[i].pp;
-		DLB2_LOG_INFO(": pp %d cycles %d", port_allocations[i],
+		DLB2_HW_INFO(hw, ": pp %d cycles %d\n", port_allocations[i],
 			      dlb2_thread_data[i].cycles);
 	}
 
@@ -929,7 +929,7 @@ dlb2_resource_probe(struct dlb2_hw *hw, const void *probe_args)
 	}
 
 	if (mask && rte_eal_parse_coremask(mask, cores)) {
-		DLB2_LOG_ERR(": Invalid producer coremask=%s", mask);
+		DLB2_HW_ERR(hw, ": Invalid producer coremask=%s\n", mask);
 		return -1;
 	}
 
@@ -956,7 +956,7 @@ dlb2_resource_probe(struct dlb2_hw *hw, const void *probe_args)
 				break;
 			}
 		} else if (is_pcore) {
-			DLB2_LOG_ERR("Producer coremask(%s) must be a subset of EAL coremask",
+			DLB2_HW_ERR(hw, "Producer coremask(%s) must be a subset of EAL coremask\n",
 				     mask);
 			return -1;
 		}
@@ -4599,7 +4599,7 @@ dlb2_verify_create_ldb_port_args(struct dlb2_hw *hw,
 		return -EINVAL;
 	}
 
-	DLB2_LOG_INFO(": LDB: cos=%d port:%d\n", id, port->id.phys_id);
+	DLB2_HW_INFO(hw, ": LDB: cos=%d port:%d\n", id, port->id.phys_id);
 
 	/* Check cache-line alignment */
 	if ((cq_dma_base & 0x3F) != 0) {
@@ -4826,7 +4826,7 @@ dlb2_verify_create_dir_port_args(struct dlb2_hw *hw,
 			resp->status = DLB2_ST_DIR_PORTS_UNAVAILABLE;
 			return -EINVAL;
 		}
-		DLB2_LOG_INFO(": DIR: port:%d is_producer=%d\n",
+		DLB2_HW_INFO(hw, ": DIR: port:%d is_producer=%d\n",
 			      pq->id.phys_id, args->is_producer);
 
 	}
Signature · 1 line
2.46.0
#37 lore raw

PATCH v2 9/14 event/dsw: use a dynamic logtype

In reply to David Marchand

Register a logtype for this driver and stop logging as EVENTDEV.

---
 drivers/event/dsw/dsw_evdev.c | 1 +
 drivers/event/dsw/dsw_evdev.h | 5 +++--
 2 files changed, 4 insertions(+), 2 deletions(-)
drivers/event/dsw/dsw_evdev.c +1 -0
index 0dea1091e3..8a1a2db8ac 100644
@@ -493,3 +493,4 @@ static struct rte_vdev_driver evdev_dsw_pmd_drv = {
 };
 
 RTE_PMD_REGISTER_VDEV(EVENTDEV_NAME_DSW_PMD, evdev_dsw_pmd_drv);
+RTE_LOG_REGISTER_DEFAULT(event_dsw_logtype, NOTICE);
drivers/event/dsw/dsw_evdev.h +3 -2
index c9bf4f8b6b..fe4ddb3e30 100644
@@ -302,9 +302,10 @@ dsw_pmd_priv(const struct rte_eventdev *eventdev)
 	return eventdev->data->dev_private;
 }
 
+extern int event_dsw_logtype;
+#define RTE_LOGTYPE_EVENT_DSW event_dsw_logtype
 #define DSW_LOG_DP(level, fmt, args...)					\
-	RTE_LOG_DP(level, EVENTDEV, "[%s] %s() line %u: " fmt,		\
-		   DSW_PMD_NAME,					\
+	RTE_LOG_DP(level, EVENT_DSW, "%s() line %u: " fmt,		\
 		   __func__, __LINE__, ## args)
 
 #define DSW_LOG_DP_PORT(level, port_id, fmt, args...)		\
Signature · 1 line
2.46.0
#38 lore raw

PATCH v2 10/14 drivers: replace logging helpers

In reply to David Marchand

Prepare for the conversion to RTE_LOG_LINE.
Some drivers currently add no \n in the logging macro and have the callers do it.

Let's invert this logic but again, thinking about backports, introduce the change in new macros.

---
Changes since v1:
- added changes to event/dlb2 and net/bonding,

---
 drivers/bus/platform/platform.c               |  28 +-
 drivers/bus/platform/platform_params.c        |   2 +-
 drivers/bus/platform/private.h                |  10 +-
 drivers/common/nitrox/nitrox_hal.c            |   4 +-
 drivers/common/nitrox/nitrox_logs.h           |   8 +-
 drivers/common/nitrox/nitrox_qp.c             |  10 +-
 drivers/compress/nitrox/nitrox_comp.c         |  44 +-
 drivers/compress/nitrox/nitrox_comp_reqmgr.c  | 170 +++---
 drivers/crypto/nitrox/nitrox_sym.c            |  54 +-
 drivers/crypto/nitrox/nitrox_sym_reqmgr.c     |  12 +-
 drivers/dma/odm/odm.h                         |  14 +-
 drivers/dma/odm/odm_dmadev.c                  |  12 +-
 drivers/event/dlb2/dlb2.c                     |  50 +-
 drivers/event/dlb2/dlb2_log.h                 |   4 +-
 drivers/event/dlb2/pf/dlb2_pf.c               |   4 +-
 drivers/event/dsw/dsw_evdev.h                 |   8 +-
 drivers/event/dsw/dsw_event.c                 |  78 +--
 drivers/net/af_xdp/rte_eth_af_xdp.c           | 212 +++----
 drivers/net/avp/avp_ethdev.c                  | 155 +++--
 drivers/net/avp/avp_logs.h                    |  17 +-
 drivers/net/axgbe/axgbe_dev.c                 |  34 +-
 drivers/net/axgbe/axgbe_ethdev.c              | 128 ++--
 drivers/net/axgbe/axgbe_i2c.c                 |  18 +-
 drivers/net/axgbe/axgbe_logs.h                |   6 +-
 drivers/net/axgbe/axgbe_mdio.c                |  36 +-
 drivers/net/axgbe/axgbe_phy_impl.c            |  50 +-
 drivers/net/axgbe/axgbe_rxtx.c                |  24 +-
 drivers/net/bnxt/bnxt.h                       |   8 +-
 drivers/net/bnxt/bnxt_cpr.c                   |  66 +-
 drivers/net/bnxt/bnxt_ethdev.c                | 570 +++++++++---------
 drivers/net/bnxt/bnxt_filter.c                |  18 +-
 drivers/net/bnxt/bnxt_flow.c                  | 126 ++--
 drivers/net/bnxt/bnxt_hwrm.c                  | 320 +++++-----
 drivers/net/bnxt/bnxt_irq.c                   |   4 +-
 drivers/net/bnxt/bnxt_reps.c                  |  86 +--
 drivers/net/bnxt/bnxt_ring.c                  |  18 +-
 drivers/net/bnxt/bnxt_rxq.c                   |  66 +-
 drivers/net/bnxt/bnxt_rxr.c                   |  32 +-
 drivers/net/bnxt/bnxt_rxtx_vec_avx2.c         |   2 +-
 drivers/net/bnxt/bnxt_rxtx_vec_neon.c         |   2 +-
 drivers/net/bnxt/bnxt_rxtx_vec_sse.c          |   2 +-
 drivers/net/bnxt/bnxt_stats.c                 |   6 +-
 drivers/net/bnxt/bnxt_txq.c                   |  16 +-
 drivers/net/bnxt/bnxt_txr.c                   |  16 +-
 drivers/net/bnxt/bnxt_vnic.c                  | 124 ++--
 drivers/net/bnxt/rte_pmd_bnxt.c               | 132 ++--
 .../net/bnxt/tf_core/tf_em_hash_internal.c    |   4 +-
 drivers/net/bnxt/tf_core/tf_em_internal.c     |   4 +-
 drivers/net/bnxt/tf_ulp/bnxt_tf_common.h      |   3 +-
 drivers/net/bnxt/tf_ulp/bnxt_tf_pmd_shim.c    |   6 +-
 drivers/net/bnxt/tf_ulp/bnxt_ulp.c            |   2 +-
 drivers/net/bnxt/tf_ulp/ulp_fc_mgr.c          |  22 +-
 drivers/net/bnxt/tf_ulp/ulp_ha_mgr.c          |   2 +-
 drivers/net/bonding/rte_eth_bond_8023ad.c     |  44 +-
 drivers/net/ena/ena_ethdev.c                  | 348 +++++------
 drivers/net/ena/ena_logs.h                    |  28 +-
 drivers/net/ena/ena_rss.c                     |  76 +--
 drivers/net/vhost/rte_eth_vhost.c             |  76 +--
 58 files changed, 1705 insertions(+), 1716 deletions(-)
drivers/bus/platform/platform.c +14 -14
index 7e24bb96a1..11892caa24 100644
@@ -97,7 +97,7 @@ dev_add(const char *dev_name)
 
 	FOREACH_DEVICE_ON_PLATFORM_BUS(tmp) {
 		if (!strcmp(tmp->name, pdev->name)) {
-			PLATFORM_LOG(INFO, "device %s already added\n", pdev->name);
+			PLATFORM_LOG_LINE(INFO, "device %s already added", pdev->name);
 
 			if (tmp->device.devargs != pdev->device.devargs)
 				rte_devargs_remove(pdev->device.devargs);
@@ -109,7 +109,7 @@ dev_add(const char *dev_name)
 
 	TAILQ_INSERT_HEAD(&platform_bus.device_list, pdev, next);
 
-	PLATFORM_LOG(INFO, "adding device %s to the list\n", dev_name);
+	PLATFORM_LOG_LINE(INFO, "adding device %s to the list", dev_name);
 
 	return 0;
 }
@@ -161,7 +161,7 @@ platform_bus_scan(void)
 
 	dp = opendir(PLATFORM_BUS_DEVICES_PATH);
 	if (dp == NULL) {
-		PLATFORM_LOG(INFO, "failed to open %s\n", PLATFORM_BUS_DEVICES_PATH);
+		PLATFORM_LOG_LINE(INFO, "failed to open %s", PLATFORM_BUS_DEVICES_PATH);
 		return -errno;
 	}
 
@@ -195,7 +195,7 @@ device_map_resource_offset(struct rte_platform_device *pdev, struct rte_platform
 	if (res->mem.addr == MAP_FAILED)
 		return -errno;
 
-	PLATFORM_LOG(DEBUG, "adding resource va = %p len = %"PRIu64" name = %s\n", res->mem.addr,
+	PLATFORM_LOG_LINE(DEBUG, "adding resource va = %p len = %"PRIu64" name = %s", res->mem.addr,
 		     res->mem.len, res->name);
 
 	return 0;
@@ -271,7 +271,7 @@ device_map_resources(struct rte_platform_device *pdev, unsigned int num)
 	int ret;
 
 	if (num == 0) {
-		PLATFORM_LOG(WARNING, "device %s has no resources\n", pdev->name);
+		PLATFORM_LOG_LINE(WARNING, "device %s has no resources", pdev->name);
 		return 0;
 	}
 
@@ -287,7 +287,7 @@ device_map_resources(struct rte_platform_device *pdev, unsigned int num)
 
 		ret = ioctl(pdev->dev_fd, VFIO_DEVICE_GET_REGION_INFO, &reg_info);
 		if (ret) {
-			PLATFORM_LOG(ERR, "failed to get region info at %d\n", i);
+			PLATFORM_LOG_LINE(ERR, "failed to get region info at %d", i);
 			ret = -errno;
 			goto out;
 		}
@@ -297,7 +297,7 @@ device_map_resources(struct rte_platform_device *pdev, unsigned int num)
 		res->mem.len = reg_info.size;
 		ret = device_map_resource_offset(pdev, res, reg_info.offset);
 		if (ret) {
-			PLATFORM_LOG(ERR, "failed to ioremap resource at %d\n", i);
+			PLATFORM_LOG_LINE(ERR, "failed to ioremap resource at %d", i);
 			goto out;
 		}
 
@@ -327,7 +327,7 @@ device_setup(struct rte_platform_device *pdev)
 
 	ret = rte_vfio_setup_device(PLATFORM_BUS_DEVICES_PATH, name, &pdev->dev_fd, &dev_info);
 	if (ret) {
-		PLATFORM_LOG(ERR, "failed to setup %s\n", name);
+		PLATFORM_LOG_LINE(ERR, "failed to setup %s", name);
 		return -ENODEV;
 	}
 
@@ -342,7 +342,7 @@ device_setup(struct rte_platform_device *pdev)
 	 */
 #ifdef VFIO_DEVICE_FLAGS_PLATFORM
 	if (!(dev_info.flags & VFIO_DEVICE_FLAGS_PLATFORM)) {
-		PLATFORM_LOG(ERR, "device not backed by vfio-platform\n");
+		PLATFORM_LOG_LINE(ERR, "device not backed by vfio-platform");
 		ret = -ENOTSUP;
 		goto out;
 	}
@@ -350,7 +350,7 @@ device_setup(struct rte_platform_device *pdev)
 
 	ret = device_map_resources(pdev, dev_info.num_regions);
 	if (ret) {
-		PLATFORM_LOG(ERR, "failed to setup platform resources\n");
+		PLATFORM_LOG_LINE(ERR, "failed to setup platform resources");
 		goto out;
 	}
 
@@ -389,7 +389,7 @@ driver_probe_device(struct rte_platform_driver *pdrv, struct rte_platform_device
 
 	iova_mode = rte_eal_iova_mode();
 	if (pdrv->drv_flags & RTE_PLATFORM_DRV_NEED_IOVA_AS_VA && iova_mode != RTE_IOVA_VA) {
-		PLATFORM_LOG(ERR, "driver %s expects VA IOVA mode but current mode is PA\n",
+		PLATFORM_LOG_LINE(ERR, "driver %s expects VA IOVA mode but current mode is PA",
 			     pdrv->driver.name);
 		return -EINVAL;
 	}
@@ -462,11 +462,11 @@ platform_bus_probe(void)
 	FOREACH_DEVICE_ON_PLATFORM_BUS(pdev) {
 		ret = device_attach(pdev);
 		if (ret == -EBUSY) {
-			PLATFORM_LOG(DEBUG, "device %s already probed\n", pdev->name);
+			PLATFORM_LOG_LINE(DEBUG, "device %s already probed", pdev->name);
 			continue;
 		}
 		if (ret)
-			PLATFORM_LOG(ERR, "failed to probe %s\n", pdev->name);
+			PLATFORM_LOG_LINE(ERR, "failed to probe %s", pdev->name);
 	}
 
 	return 0;
@@ -517,7 +517,7 @@ device_release_driver(struct rte_platform_device *pdev)
 	if (pdrv != NULL && pdrv->remove != NULL) {
 		ret = pdrv->remove(pdev);
 		if (ret)
-			PLATFORM_LOG(WARNING, "failed to remove %s\n", pdev->name);
+			PLATFORM_LOG_LINE(WARNING, "failed to remove %s", pdev->name);
 	}
 
 	pdev->device.driver = NULL;
drivers/bus/platform/platform_params.c +1 -1
index 0eb8eb56e7..8a6214b97c 100644
@@ -56,7 +56,7 @@ platform_bus_dev_iterate(const void *start, const char *str,
 	if (str != NULL) {
 		kvargs = rte_kvargs_parse(str, platform_params_keys);
 		if (!kvargs) {
-			PLATFORM_LOG(ERR, "cannot parse argument list %s", str);
+			PLATFORM_LOG_LINE(ERR, "cannot parse argument list %s", str);
 			rte_errno = EINVAL;
 			return NULL;
 		}
drivers/bus/platform/private.h +5 -5
index a7a4b0da56..72185aa457 100644
@@ -15,7 +15,6 @@
 #include "bus_platform_driver.h"
 
 extern struct rte_platform_bus platform_bus;
-extern int platform_bus_logtype;
 
 /* Platform bus iterators. */
 #define FOREACH_DEVICE_ON_PLATFORM_BUS(p) \
@@ -33,10 +32,11 @@ struct rte_platform_bus {
 	RTE_TAILQ_HEAD(, rte_platform_driver) driver_list; /* List of bus drivers */
 };
 
-#define PLATFORM_LOG(level, ...) \
-	rte_log(RTE_LOG_ ## level, platform_bus_logtype, \
-		RTE_FMT("platform bus: " RTE_FMT_HEAD(__VA_ARGS__,), \
-			RTE_FMT_TAIL(__VA_ARGS__,)))
+extern int platform_bus_logtype;
+#define RTE_LOGTYPE_PLATFORM_BUS platform_bus_logtype
+#define PLATFORM_LOG_LINE(level, ...) \
+	RTE_LOG(level, PLATFORM_BUS, RTE_FMT(RTE_FMT_HEAD(__VA_ARGS__,) "\n", \
+		RTE_FMT_TAIL(__VA_ARGS__,)))
 
 /*
  * Iterate registered platform devices and find one that matches provided string.
drivers/common/nitrox/nitrox_hal.c +2 -2
index 451549a664..9ef974409c 100644
@@ -190,7 +190,7 @@ zqmq_input_ring_disable(uint8_t *bar_addr, uint16_t ring)
 	}
 
 	if (zqmq_activity_stat.s.queue_active) {
-		NITROX_LOG(ERR, "Failed to disable zqmq ring %d\n", ring);
+		NITROX_LOG_LINE(ERR, "Failed to disable zqmq ring %d", ring);
 		return -EBUSY;
 	}
 
@@ -271,7 +271,7 @@ setup_zqmq_input_ring(uint8_t *bar_addr, uint16_t ring, uint32_t rsize,
 	}
 
 	if (!zqmq_en.s.queue_enable) {
-		NITROX_LOG(ERR, "Failed to enable zqmq ring %d\n", ring);
+		NITROX_LOG_LINE(ERR, "Failed to enable zqmq ring %d", ring);
 		err = -EFAULT;
 	} else {
 		err = 0;
drivers/common/nitrox/nitrox_logs.h +3 -5
index 50e52f396b..67964447eb 100644
@@ -5,11 +5,9 @@
 #ifndef _NITROX_LOGS_H_
 #define _NITROX_LOGS_H_
 
-#define LOG_PREFIX "NITROX: "
-#define NITROX_LOG(level, fmt, args...)					\
-	rte_log(RTE_LOG_ ## level, nitrox_logtype,			\
-		LOG_PREFIX "%s:%d " fmt, __func__, __LINE__, ## args)
-
 extern int nitrox_logtype;
+#define RTE_LOGTYPE_NITROX nitrox_logtype
+#define NITROX_LOG_LINE(level, fmt, args...) \
+	RTE_LOG(level, NITROX, "%s:%d " fmt "\n", __func__, __LINE__, ## args)
 
 #endif /* _NITROX_LOGS_H_ */
drivers/common/nitrox/nitrox_qp.c +5 -5
index 1665c3c40d..d6a5ddd641 100644
@@ -28,7 +28,7 @@ nitrox_setup_cmdq(struct nitrox_qp *qp, uint8_t *bar_addr,
 					 RTE_MEMZONE_256MB,
 					 CMDQ_PKT_IN_ALIGN);
 	if (!mz) {
-		NITROX_LOG(ERR, "cmdq memzone reserve failed for %s queue\n",
+		NITROX_LOG_LINE(ERR, "cmdq memzone reserve failed for %s queue",
 			   mz_name);
 		return -ENOMEM;
 	}
@@ -48,7 +48,7 @@ nitrox_setup_cmdq(struct nitrox_qp *qp, uint8_t *bar_addr,
 					    mz->iova);
 		break;
 	default:
-		NITROX_LOG(ERR, "Invalid queue type %d\n", qp->type);
+		NITROX_LOG_LINE(ERR, "Invalid queue type %d", qp->type);
 		err = -EINVAL;
 		break;
 	}
@@ -73,7 +73,7 @@ nitrox_setup_ridq(struct nitrox_qp *qp, int socket_id)
 				   RTE_CACHE_LINE_SIZE,
 				   socket_id);
 	if (!qp->ridq) {
-		NITROX_LOG(ERR, "Failed to create rid queue\n");
+		NITROX_LOG_LINE(ERR, "Failed to create rid queue");
 		return -ENOMEM;
 	}
 
@@ -112,8 +112,8 @@ nitrox_qp_setup(struct nitrox_qp *qp, uint8_t *bar_addr, const char *dev_name,
 
 	count = rte_align32pow2(nb_descriptors);
 	if (count > MAX_CMD_QLEN) {
-		NITROX_LOG(ERR, "%s: Number of descriptors too big %d,"
-			   " greater than max queue length %d\n",
+		NITROX_LOG_LINE(ERR, "%s: Number of descriptors too big %d,"
+			   " greater than max queue length %d",
 			   dev_name, count,
 			   MAX_CMD_QLEN);
 		return -EINVAL;
drivers/compress/nitrox/nitrox_comp.c +22 -22

162 lines not on this page · raw message

drivers/compress/nitrox/nitrox_comp_reqmgr.c +85 -85

329 lines not on this page · raw message

drivers/crypto/nitrox/nitrox_sym.c +27 -27

197 lines not on this page · raw message

drivers/crypto/nitrox/nitrox_sym_reqmgr.c +6 -6
index 973bb5f424..7751c1a9fc 100644
@@ -466,7 +466,7 @@ create_cipher_auth_sglist(struct nitrox_softreq *sr,
 	if (unlikely(
 		op->sym->cipher.data.offset + op->sym->cipher.data.length !=
 		op->sym->auth.data.offset + op->sym->auth.data.length)) {
-		NITROX_LOG(ERR, "Auth only data after cipher data not supported\n");
+		NITROX_LOG_LINE(ERR, "Auth only data after cipher data not supported");
 		return -ENOTSUP;
 	}
 
@@ -679,7 +679,7 @@ softreq_copy_salt(struct nitrox_softreq *sr)
 	uint8_t *addr;
 
 	if (unlikely(ctx->iv.length < AES_GCM_SALT_SIZE)) {
-		NITROX_LOG(ERR, "Invalid IV length %d\n", ctx->iv.length);
+		NITROX_LOG_LINE(ERR, "Invalid IV length %d", ctx->iv.length);
 		return -EINVAL;
 	}
 
@@ -829,8 +829,8 @@ nitrox_process_se_req(uint16_t qno, struct rte_crypto_op *op,
 	if (unlikely(op->sym->m_src->nb_segs > MAX_SUPPORTED_MBUF_SEGS ||
 		     (op->sym->m_dst &&
 		      op->sym->m_dst->nb_segs > MAX_SUPPORTED_MBUF_SEGS))) {
-		NITROX_LOG(ERR, "Mbuf segments not supported. "
-			   "Max supported %d\n", MAX_SUPPORTED_MBUF_SEGS);
+		NITROX_LOG_LINE(ERR, "Mbuf segments not supported. "
+			   "Max supported %d", MAX_SUPPORTED_MBUF_SEGS);
 		return -ENOTSUP;
 	}
 
@@ -865,7 +865,7 @@ nitrox_check_se_req(struct nitrox_softreq *sr, struct rte_crypto_op **op)
 		return -EAGAIN;
 
 	if (unlikely(err))
-		NITROX_LOG(ERR, "Request err 0x%x, orh 0x%"PRIx64"\n", err,
+		NITROX_LOG_LINE(ERR, "Request err 0x%x, orh 0x%"PRIx64, err,
 			   sr->resp.orh);
 
 	*op = sr->op;
@@ -901,7 +901,7 @@ nitrox_sym_req_pool_create(struct rte_cryptodev *cdev, uint32_t nobjs,
 				64, 0, NULL, NULL, req_pool_obj_init, NULL,
 				socket_id, 0);
 	if (unlikely(!mp))
-		NITROX_LOG(ERR, "Failed to create req pool, qid %d, err %d\n",
+		NITROX_LOG_LINE(ERR, "Failed to create req pool, qid %d, err %d",
 			   qp_id, rte_errno);
 
 	return mp;
drivers/dma/odm/odm.h +3 -11
index 7303aa2955..274c21ef8d 100644
@@ -66,17 +66,9 @@ extern int odm_logtype;
 #define odm_read64(addr)       rte_read64_relaxed((volatile void *)(addr))
 #define odm_write64(val, addr) rte_write64_relaxed((val), (volatile void *)(addr))
 
-#define odm_err(...)                                                                               \
-	rte_log(RTE_LOG_ERR, odm_logtype,                                                          \
-		RTE_FMT("%s(): %u" RTE_FMT_HEAD(__VA_ARGS__, ), __func__, __LINE__,                \
-			RTE_FMT_TAIL(__VA_ARGS__, )))
-#define odm_info(...)                                                                              \
-	rte_log(RTE_LOG_INFO, odm_logtype,                                                         \
-		RTE_FMT("%s(): %u" RTE_FMT_HEAD(__VA_ARGS__, ), __func__, __LINE__,                \
-			RTE_FMT_TAIL(__VA_ARGS__, )))
-#define odm_debug(...)                                                                             \
-	rte_log(RTE_LOG_DEBUG, odm_logtype,                                                        \
-		RTE_FMT("%s(): %u" RTE_FMT_HEAD(__VA_ARGS__, ), __func__, __LINE__,                \
+#define ODM_LOG(level, ...) \
+	rte_log(RTE_LOG_ ## level, odm_logtype, \
+		RTE_FMT("%s(): %u" RTE_FMT_HEAD(__VA_ARGS__,) "\n", __func__, __LINE__, \
 			RTE_FMT_TAIL(__VA_ARGS__, )))
 
 /*
drivers/dma/odm/odm_dmadev.c +6 -6
index 57bd6923f1..a2f4ed9a8e 100644
@@ -494,10 +494,10 @@ odm_dmadev_completed_status(void *dev_private, uint16_t vchan, const uint16_t nb
 	}
 
 #ifdef ODM_DEBUG
-	odm_debug("cring_head: 0x%" PRIx16, cring_head);
-	odm_debug("Submitted: 0x%" PRIx64, vq->stats.submitted);
-	odm_debug("Completed: 0x%" PRIx64, vq->stats.completed);
-	odm_debug("Hardware count: 0x%" PRIx64, odm_read64(odm->rbase + ODM_VDMA_CNT(vchan)));
+	ODM_LOG(DEBUG, "cring_head: 0x%" PRIx16, cring_head);
+	ODM_LOG(DEBUG, "Submitted: 0x%" PRIx64, vq->stats.submitted);
+	ODM_LOG(DEBUG, "Completed: 0x%" PRIx64, vq->stats.completed);
+	ODM_LOG(DEBUG, "Hardware count: 0x%" PRIx64, odm_read64(odm->rbase + ODM_VDMA_CNT(vchan)));
 #endif
 
 	for (cnt = 0; cnt < nb_cpls; cnt++) {
@@ -651,11 +651,11 @@ odm_dmadev_probe(struct rte_pci_driver *pci_drv __rte_unused, struct rte_pci_dev
 
 	dmadev = rte_dma_pmd_allocate(name, pci_dev->device.numa_node, sizeof(*odm));
 	if (dmadev == NULL) {
-		odm_err("DMA device allocation failed for %s", name);
+		ODM_LOG(ERR, "DMA device allocation failed for %s", name);
 		return -ENOMEM;
 	}
 
-	odm_info("DMA device %s probed", name);
+	ODM_LOG(INFO, "DMA device %s probed", name);
 	odm = dmadev->data->dev_private;
 
 	dmadev->device = &pci_dev->device;
drivers/event/dlb2/dlb2.c +25 -25

194 lines not on this page · raw message

drivers/event/dlb2/dlb2_log.h +2 -2
index 81908af71f..201c88a98b 100644
@@ -19,7 +19,7 @@ extern int eventdev_dlb2_log_level;
 	DLB2_LOG_IMPL(ERR, fmt, ## args)
 
 /* remove debug logs at compile time unless actually debugging */
-#define DLB2_LOG_DBG(fmt, args...) \
-	RTE_LOG_DP(DEBUG, EVENTDEV_DLB2, fmt, ## args)
+#define DLB2_LOG_LINE_DBG(fmt, args...) \
+	RTE_LOG_DP(DEBUG, EVENTDEV_DLB2, fmt "\n", ## args)
 
 #endif /* _DLB2_EVDEV_LOG_H_ */
drivers/event/dlb2/pf/dlb2_pf.c +2 -2
index 3d15250e11..b3576e5f42 100644
@@ -289,7 +289,7 @@ dlb2_alloc_coherent_aligned(const struct rte_memzone **mz, uintptr_t *phys,
 	*mz = rte_memzone_reserve_aligned(mz_name, size, socket_id,
 					 RTE_MEMZONE_IOVA_CONTIG, align);
 	if (*mz == NULL) {
-		DLB2_LOG_DBG("Unable to allocate DMA memory of size %zu bytes - %s\n",
+		DLB2_LOG_LINE_DBG("Unable to allocate DMA memory of size %zu bytes - %s",
 			     size, rte_strerror(rte_errno));
 		*phys = 0;
 		return NULL;
@@ -716,7 +716,7 @@ dlb2_eventdev_pci_init(struct rte_eventdev *eventdev)
 	int q;
 	const void *probe_args = NULL;
 
-	DLB2_LOG_DBG("Enter with dev_id=%d socket_id=%d",
+	DLB2_LOG_LINE_DBG("Enter with dev_id=%d socket_id=%d",
 		     eventdev->data->dev_id, eventdev->data->socket_id);
 
 	for (q = 0; q < DLB2_MAX_NUM_PORTS_ALL; q++)
drivers/event/dsw/dsw_evdev.h +4 -4
index fe4ddb3e30..01b7a99ba1 100644
@@ -304,11 +304,11 @@ dsw_pmd_priv(const struct rte_eventdev *eventdev)
 
 extern int event_dsw_logtype;
 #define RTE_LOGTYPE_EVENT_DSW event_dsw_logtype
-#define DSW_LOG_DP(level, fmt, args...)					\
-	RTE_LOG_DP(level, EVENT_DSW, "%s() line %u: " fmt,		\
+#define DSW_LOG_DP_LINE(level, fmt, args...)				\
+	RTE_LOG_DP(level, EVENT_DSW, "%s() line %u: " fmt "\n",		\
 		   __func__, __LINE__, ## args)
 
-#define DSW_LOG_DP_PORT(level, port_id, fmt, args...)		\
-	DSW_LOG_DP(level, "<Port %d> " fmt, port_id, ## args)
+#define DSW_LOG_DP_PORT_LINE(level, port_id, fmt, args...)		\
+	DSW_LOG_DP_LINE(level, "<Port %d> " fmt, port_id, ## args)
 
 #endif
drivers/event/dsw/dsw_event.c +39 -39

203 lines not on this page · raw message

drivers/net/af_xdp/rte_eth_af_xdp.c +106 -106

770 lines not on this page · raw message

drivers/net/avp/avp_ethdev.c +77 -78

566 lines not on this page · raw message

drivers/net/avp/avp_logs.h +8 -9
index 574b720b30..3f2721df1a 100644
@@ -8,24 +8,23 @@
 #include <rte_log.h>
 
 #ifdef RTE_LIBRTE_AVP_DEBUG_RX
-#define PMD_RX_LOG(level, fmt, args...) \
-	RTE_LOG(level, AVP_DRIVER, "%s() rx: " fmt, __func__, ## args)
+#define PMD_RX_LOG_LINE(level, fmt, ...) \
+	RTE_LOG(level, AVP_DRIVER, "%s() rx: " fmt "\n", __func__, ## __VA_ARGS__)
 #else
-#define PMD_RX_LOG(level, fmt, args...) do { } while (0)
+#define PMD_RX_LOG_LINE(...) do { } while (0)
 #endif
 
 #ifdef RTE_LIBRTE_AVP_DEBUG_TX
-#define PMD_TX_LOG(level, fmt, args...) \
-	RTE_LOG(level, AVP_DRIVER, "%s() tx: " fmt, __func__, ## args)
+#define PMD_TX_LOG_LINE(level, fmt, ...) \
+	RTE_LOG(level, AVP_DRIVER, "%s() tx: " fmt "\n", __func__, ## __VA_ARGS__)
 #else
-#define PMD_TX_LOG(level, fmt, args...) do { } while (0)
+#define PMD_TX_LOG_LINE(...) do { } while (0)
 #endif
 
 extern int avp_logtype_driver;
 #define RTE_LOGTYPE_AVP_DRIVER avp_logtype_driver
 
-#define PMD_DRV_LOG(level, fmt, args...) \
-	rte_log(RTE_LOG_ ## level, avp_logtype_driver, \
-		"%s(): " fmt, __func__, ## args)
+#define PMD_DRV_LOG_LINE(level, fmt, ...) \
+	RTE_LOG(level, AVP_DRIVER, "%s(): " fmt "\n", __func__, ## __VA_ARGS__)
 
 #endif /* _AVP_LOGS_H_ */
drivers/net/axgbe/axgbe_dev.c +17 -17
index ebe64295aa..9173a6fea6 100644
@@ -107,7 +107,7 @@ static int axgbe_write_ext_mii_regs(struct axgbe_port *pdata,
 			return 0;
 	}
 
-	PMD_DRV_LOG(ERR, "Mdio write operation timed out\n");
+	PMD_DRV_LOG_LINE(ERR, "Mdio write operation timed out");
 	return -ETIMEDOUT;
 }
 
@@ -154,7 +154,7 @@ static int axgbe_read_ext_mii_regs(struct axgbe_port *pdata,
 			goto success;
 	}
 
-	PMD_DRV_LOG(ERR, "Mdio read operation timed out\n");
+	PMD_DRV_LOG_LINE(ERR, "Mdio read operation timed out");
 	return -ETIMEDOUT;
 
 success:
@@ -272,7 +272,7 @@ static int axgbe_read_mmd_regs(struct axgbe_port *pdata, int prtad,
 {
 	switch (pdata->vdata->xpcs_access) {
 	case AXGBE_XPCS_ACCESS_V1:
-		PMD_DRV_LOG(ERR, "PHY_Version 1 is not supported\n");
+		PMD_DRV_LOG_LINE(ERR, "PHY_Version 1 is not supported");
 		return -1;
 	case AXGBE_XPCS_ACCESS_V2:
 	default:
@@ -285,7 +285,7 @@ static void axgbe_write_mmd_regs(struct axgbe_port *pdata, int prtad,
 {
 	switch (pdata->vdata->xpcs_access) {
 	case AXGBE_XPCS_ACCESS_V1:
-		PMD_DRV_LOG(ERR, "PHY_Version 1 is not supported\n");
+		PMD_DRV_LOG_LINE(ERR, "PHY_Version 1 is not supported");
 		return;
 	case AXGBE_XPCS_ACCESS_V2:
 	default:
@@ -369,7 +369,7 @@ static int axgbe_enable_tx_flow_control(struct axgbe_port *pdata)
 
 		AXGMAC_MTL_IOWRITE_BITS(pdata, i, MTL_Q_RQOMR, EHFC, ehfc);
 
-		PMD_DRV_LOG(DEBUG, "flow control %s for RXq%u\n",
+		PMD_DRV_LOG_LINE(DEBUG, "flow control %s for RXq%u",
 			    ehfc ? "enabled" : "disabled", i);
 	}
 
@@ -608,8 +608,8 @@ static int axgbe_update_vlan_hash_table(struct axgbe_port *pdata)
 		vid_valid = pdata->active_vlans[vid_idx];
 		vid_valid = (unsigned long)vid_valid >> (vid - (64 * vid_idx));
 		if (vid_valid & 1)
-			PMD_DRV_LOG(DEBUG,
-				    "vid:%d pdata->active_vlans[%ld]=0x%lx\n",
+			PMD_DRV_LOG_LINE(DEBUG,
+				    "vid:%d pdata->active_vlans[%ld]=0x%lx",
 				    vid, vid_idx, pdata->active_vlans[vid_idx]);
 		else
 			continue;
@@ -617,13 +617,13 @@ static int axgbe_update_vlan_hash_table(struct axgbe_port *pdata)
 		vid_le = rte_cpu_to_le_16(vid);
 		crc = bitrev32(~axgbe_vid_crc32_le(vid_le)) >> 28;
 		vlan_hash_table |= (1 << crc);
-		PMD_DRV_LOG(DEBUG, "crc = %d vlan_hash_table = 0x%x\n",
+		PMD_DRV_LOG_LINE(DEBUG, "crc = %d vlan_hash_table = 0x%x",
 			    crc, vlan_hash_table);
 	}
 	/* Set the VLAN Hash Table filtering register */
 	AXGMAC_IOWRITE_BITS(pdata, MAC_VLANHTR, VLHT, vlan_hash_table);
 	reg = AXGMAC_IOREAD(pdata, MAC_VLANHTR);
-	PMD_DRV_LOG(DEBUG, "vlan_hash_table reg val = 0x%x\n", reg);
+	PMD_DRV_LOG_LINE(DEBUG, "vlan_hash_table reg val = 0x%x", reg);
 	return 0;
 }
 
@@ -927,7 +927,7 @@ static int axgbe_config_rss(struct axgbe_port *pdata)
 					i % pdata->eth_dev->data->nb_rx_queues);
 		axgbe_rss_options(pdata);
 		if (axgbe_enable_rss(pdata)) {
-			PMD_DRV_LOG(ERR, "Error in enabling RSS support\n");
+			PMD_DRV_LOG_LINE(ERR, "Error in enabling RSS support");
 			return -1;
 		}
 	} else {
@@ -1012,7 +1012,7 @@ static int wrapper_rx_desc_init(struct axgbe_port *pdata)
 		for (j = 0; j < rxq->nb_desc; j++) {
 			mbuf = rte_mbuf_raw_alloc(rxq->mb_pool);
 			if (mbuf == NULL) {
-				PMD_DRV_LOG(ERR, "RX mbuf alloc failed queue_id = %u, idx = %d\n",
+				PMD_DRV_LOG_LINE(ERR, "RX mbuf alloc failed queue_id = %u, idx = %d",
 					    (unsigned int)rxq->queue_id, j);
 				axgbe_dev_rx_queue_release(pdata->eth_dev, i);
 				return -ENOMEM;
@@ -1138,7 +1138,7 @@ static void axgbe_config_rx_fifo_size(struct axgbe_port *pdata)
 	axgbe_calculate_flow_control_threshold(pdata);
 	axgbe_config_flow_control_threshold(pdata);
 
-	PMD_DRV_LOG(DEBUG, "%d Rx hardware queues, %d byte fifo per queue\n",
+	PMD_DRV_LOG_LINE(DEBUG, "%d Rx hardware queues, %d byte fifo per queue",
 		    pdata->rx_q_count, q_fifo_size);
 }
 
@@ -1164,7 +1164,7 @@ static void axgbe_config_tx_fifo_size(struct axgbe_port *pdata)
 	for (i = 0; i < pdata->tx_q_count; i++)
 		AXGMAC_MTL_IOWRITE_BITS(pdata, i, MTL_Q_TQOMR, TQS, p_fifo);
 
-	PMD_DRV_LOG(DEBUG, "%d Tx hardware queues, %d byte fifo per queue\n",
+	PMD_DRV_LOG_LINE(DEBUG, "%d Tx hardware queues, %d byte fifo per queue",
 		    pdata->tx_q_count, q_fifo_size);
 }
 
@@ -1181,12 +1181,12 @@ static void axgbe_config_queue_mapping(struct axgbe_port *pdata)
 
 	for (i = 0, queue = 0; i < pdata->hw_feat.tc_cnt; i++) {
 		for (j = 0; j < qptc; j++) {
-			PMD_DRV_LOG(DEBUG, "TXq%u mapped to TC%u\n", queue, i);
+			PMD_DRV_LOG_LINE(DEBUG, "TXq%u mapped to TC%u", queue, i);
 			AXGMAC_MTL_IOWRITE_BITS(pdata, queue, MTL_Q_TQOMR,
 						Q2TCMAP, i);
 		}
 		if (i < qptc_extra) {
-			PMD_DRV_LOG(DEBUG, "TXq%u mapped to TC%u\n", queue, i);
+			PMD_DRV_LOG_LINE(DEBUG, "TXq%u mapped to TC%u", queue, i);
 			AXGMAC_MTL_IOWRITE_BITS(pdata, queue, MTL_Q_TQOMR,
 						Q2TCMAP, i);
 		}
@@ -1254,7 +1254,7 @@ void axgbe_set_mac_hash_table(struct axgbe_port *pdata, u8 *addr, bool add)
 		pdata->uc_hash_table[htable_index] &= ~htable_bitmask;
 		pdata->uc_hash_mac_addr--;
 	}
-	PMD_DRV_LOG(DEBUG, "%s MAC hash table Bit %d at Index %#x\n",
+	PMD_DRV_LOG_LINE(DEBUG, "%s MAC hash table Bit %d at Index %#x",
 		    add ? "set" : "clear", (crc & 0x1f), htable_index);
 
 	AXGMAC_IOWRITE(pdata, MAC_HTR(htable_index),
@@ -1283,7 +1283,7 @@ void axgbe_set_mac_addn_addr(struct axgbe_port *pdata, u8 *addr, uint32_t index)
 		AXGMAC_SET_BITS(mac_addr_hi, MAC_MACA1HR, AE, 1);
 	}
 
-	PMD_DRV_LOG(DEBUG, "%s mac address at %#x\n",
+	PMD_DRV_LOG_LINE(DEBUG, "%s mac address at %#x",
 		    addr ? "set" : "clear", index);
 
 	AXGMAC_IOWRITE(pdata, MAC_MACAHR(index), mac_addr_hi);
drivers/net/axgbe/axgbe_ethdev.c +64 -64

88 lines not on this page · raw message

drivers/net/axgbe/axgbe_i2c.c +9 -9
index a2798f484e..484ee1b4e4 100644

Lines of this file are not shown. View the raw message.

drivers/net/axgbe/axgbe_logs.h +3 -3
index d148701716..3962895c5a 100644

Lines of this file are not shown. View the raw message.

drivers/net/axgbe/axgbe_mdio.c +18 -18
index 130a67479e..952a0add62 100644

Lines of this file are not shown. View the raw message.

drivers/net/axgbe/axgbe_phy_impl.c +25 -25

50 lines not on this page · raw message

drivers/net/axgbe/axgbe_rxtx.c +12 -12
index a9ff291cef..974ade9ab7 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt.h +2 -6
index aaa7ea00cc..8ac20961d9 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_cpr.c +33 -33

66 lines not on this page · raw message

drivers/net/bnxt/bnxt_ethdev.c +286 -284

570 lines not on this page · raw message

drivers/net/bnxt/bnxt_filter.c +9 -9
index ff563f08bb..7b90ba651f 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_flow.c +63 -63

126 lines not on this page · raw message

drivers/net/bnxt/bnxt_hwrm.c +160 -160

320 lines not on this page · raw message

drivers/net/bnxt/bnxt_irq.c +2 -2
index edf16bd33e..ac00ee1cbb 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_reps.c +43 -43

86 lines not on this page · raw message

drivers/net/bnxt/bnxt_ring.c +9 -9
index 9e512321d9..3d63956bd8 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_rxq.c +33 -33

66 lines not on this page · raw message

drivers/net/bnxt/bnxt_rxr.c +16 -16
index b59989b5a1..d51a66ae77 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_rxtx_vec_avx2.c +1 -1
index 976f258044..43d9528134 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_rxtx_vec_neon.c +1 -1
index 04864e0b95..0ff1641c19 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_rxtx_vec_sse.c +1 -1
index e367fbfbd1..9f1a02f0ab 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_stats.c +3 -3
index b9cce227d9..5e59afe79f 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_txq.c +8 -8
index 05032f7807..c864935992 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_txr.c +8 -8
index 83c003d258..6a38c7c6e4 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/bnxt_vnic.c +62 -62

124 lines not on this page · raw message

drivers/net/bnxt/rte_pmd_bnxt.c +66 -66

132 lines not on this page · raw message

drivers/net/bnxt/tf_core/tf_em_hash_internal.c +2 -2
index d72ac83295..9c527e152d 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_core/tf_em_internal.c +2 -2
index 46de63a9da..7f7a663789 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_ulp/bnxt_tf_common.h +2 -1
index cd4cd8ac74..747f1da557 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_ulp/bnxt_tf_pmd_shim.c +3 -3
index 96d61c3ed2..75a0b77ac2 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_ulp/bnxt_ulp.c +1 -1
index 33028c470f..361bed7b3e 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_ulp/ulp_fc_mgr.c +11 -11
index c39cde39aa..2360788f8f 100644

Lines of this file are not shown. View the raw message.

drivers/net/bnxt/tf_ulp/ulp_ha_mgr.c +1 -1
index 852deef3b4..074cb4ff45 100644

Lines of this file are not shown. View the raw message.

drivers/net/bonding/rte_eth_bond_8023ad.c +22 -22

44 lines not on this page · raw message

drivers/net/ena/ena_ethdev.c +174 -174

348 lines not on this page · raw message

drivers/net/ena/ena_logs.h +14 -14
index 43f16458ea..5c9ec1772b 100644

Lines of this file are not shown. View the raw message.

drivers/net/ena/ena_rss.c +38 -38

76 lines not on this page · raw message

drivers/net/vhost/rte_eth_vhost.c +39 -37

76 lines not on this page · raw message

The rest of this diff is not shown. View the raw message.

Signature · 1 line
2.46.0

Part of the diff is not shown here. View the raw message.