#
0f1dc8cb |
| 29-Feb-2024 |
Tyler Retzlaff <roretzla@linux.microsoft.com> |
lib: use log helper with prefix
Use RTE_LOG_LINE_PREFIX instead of RTE_LOG_LINE in macro expansions which allows a prefix and arguments to be inserted into the log line without the need to use the #
lib: use log helper with prefix
Use RTE_LOG_LINE_PREFIX instead of RTE_LOG_LINE in macro expansions which allows a prefix and arguments to be inserted into the log line without the need to use the ## args variadic argument pack extension.
Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Morten Brørup <mb@smartsharesystems.com> Acked-by: Stephen Hemminger <stephen@networkplumber.org> Acked-by: Konstantin Ananyev <konstantin.ananyev@huawei.com>
show more ...
|
#
97433132 |
| 17-Nov-2023 |
David Marchand <david.marchand@redhat.com> |
lib: use per line logging in helpers
Use RTE_LOG_LINE in existing macros that append a \n. This will help catching unwanted newline character or multilines in log messages.
Signed-off-by: David Mar
lib: use per line logging in helpers
Use RTE_LOG_LINE in existing macros that append a \n. This will help catching unwanted newline character or multilines in log messages.
Signed-off-by: David Marchand <david.marchand@redhat.com> Reviewed-by: Chengwen Feng <fengchengwen@huawei.com> Reviewed-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
show more ...
|
#
ae282b06 |
| 17-Nov-2023 |
David Marchand <david.marchand@redhat.com> |
lib: remove redundant newline from logs
Fix places where two newline characters may be logged.
Cc: stable@dpdk.org
Signed-off-by: David Marchand <david.marchand@redhat.com> Acked-by: Stephen Hemmi
lib: remove redundant newline from logs
Fix places where two newline characters may be logged.
Cc: stable@dpdk.org
Signed-off-by: David Marchand <david.marchand@redhat.com> Acked-by: Stephen Hemminger <stephen@networkplumber.org> Reviewed-by: Chengwen Feng <fengchengwen@huawei.com> Acked-by: Mattias Rönnblom <mattias.ronnblom@ericsson.com>
show more ...
|
#
1f6f9526 |
| 20-Jul-2023 |
Bruce Richardson <bruce.richardson@intel.com> |
doc: provide coding details for dynamic logging
While the section on dynamic logging in the contributors guide covered the details of the logging naming scheme, it failed to cover exactly how the co
doc: provide coding details for dynamic logging
While the section on dynamic logging in the contributors guide covered the details of the logging naming scheme, it failed to cover exactly how the component developer, i.e. the contributor, could actually use dynamic logging in their component.
Fix this by splitting the details of the naming scheme into a separate subsection, and adding to the introduction on logging, a recommendation (and example) to use RTE_LOG_REGISTER_DEFAULT.
Similarly, when discussing specialization, include a reference to the RTE_LOG_REGISTER_SUFFIX macro.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> Acked-by: Chengwen Feng <fengchengwen@huawei.com> Reviewed-by: David Marchand <david.marchand@redhat.com> Acked-by: Ferruh Yigit <ferruh.yigit@amd.com>
show more ...
|
#
eeded204 |
| 26-Apr-2021 |
David Marchand <david.marchand@redhat.com> |
log: register with standardized names
Let's try to enforce the convention where most drivers use a pmd. logtype with their class reflected in it, and libraries use a lib. logtype.
Introduce two new
log: register with standardized names
Let's try to enforce the convention where most drivers use a pmd. logtype with their class reflected in it, and libraries use a lib. logtype.
Introduce two new macros: - RTE_LOG_REGISTER_DEFAULT can be used when a single logtype is used in a component. It is associated to the default name provided by the build system, - RTE_LOG_REGISTER_SUFFIX can be used when multiple logtypes are used, and then the passed name is appended to the default name,
RTE_LOG_REGISTER is left untouched for existing external users and for components that do not comply with the convention.
There is a new Meson variable log_prefix to adapt the default name for baseband (pmd.bb.), bus (no pmd.) and mempool (no pmd.) classes.
Note: achieved with below commands + reverted change on net/bonding + edits on crypto/virtio, compress/mlx5, regex/mlx5
$ git grep -l RTE_LOG_REGISTER drivers/ | while read file; do pattern=${file##drivers/}; class=${pattern%%/*}; pattern=${pattern#$class/}; drv=${pattern%%/*}; case "$class" in baseband) pattern=pmd.bb.$drv;; bus) pattern=bus.$drv;; mempool) pattern=mempool.$drv;; *) pattern=pmd.$class.$drv;; esac sed -i -e 's/RTE_LOG_REGISTER(\(.*\), '$pattern',/RTE_LOG_REGISTER_DEFAULT(\1,/' $file; sed -i -e 's/RTE_LOG_REGISTER(\(.*\), '$pattern'\.\(.*\),/RTE_LOG_REGISTER_SUFFIX(\1, \2,/' $file; done
$ git grep -l RTE_LOG_REGISTER lib/ | while read file; do pattern=${file##lib/}; pattern=lib.${pattern%%/*}; sed -i -e 's/RTE_LOG_REGISTER(\(.*\), '$pattern',/RTE_LOG_REGISTER_DEFAULT(\1,/' $file; sed -i -e 's/RTE_LOG_REGISTER(\(.*\), '$pattern'\.\(.*\),/RTE_LOG_REGISTER_SUFFIX(\1, \2,/' $file; done
Signed-off-by: David Marchand <david.marchand@redhat.com> Signed-off-by: Thomas Monjalon <thomas@monjalon.net> Acked-by: Bruce Richardson <bruce.richardson@intel.com>
show more ...
|
#
99a2dd95 |
| 20-Apr-2021 |
Bruce Richardson <bruce.richardson@intel.com> |
lib: remove librte_ prefix from directory names
There is no reason for the DPDK libraries to all have 'librte_' prefix on the directory names. This prefix makes the directory names longer and also m
lib: remove librte_ prefix from directory names
There is no reason for the DPDK libraries to all have 'librte_' prefix on the directory names. This prefix makes the directory names longer and also makes it awkward to add features referring to individual libraries in the build - should the lib names be specified with or without the prefix. Therefore, we can just remove the library prefix and use the library's unique name as the directory name, i.e. 'eal' rather than 'librte_eal'
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
show more ...
|