patch 'mempool: fix telemetry data truncation' has been queued to stable release 21.11.4
Kevin Traynor
ktraynor at redhat.com
Thu Feb 23 16:05:09 CET 2023
Hi,
FYI, your patch has been queued to stable release 21.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 02/28/23. So please
shout if anyone has objections.
Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.
Queued patches are on a temporary branch at:
https://github.com/kevintraynor/dpdk-stable
This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/119d73b152eca50244c3f99a26c5ee388dd0e01a
Thanks.
Kevin
---
>From 119d73b152eca50244c3f99a26c5ee388dd0e01a Mon Sep 17 00:00:00 2001
From: Huisong Li <lihuisong at huawei.com>
Date: Mon, 19 Dec 2022 15:06:43 +0800
Subject: [PATCH] mempool: fix telemetry data truncation
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
[ upstream commit 4eebfcf70a21b2b608e3bb9f20b5ee23338172ec ]
The 'u32' and 'u64' data can not assigned to 'int' type variable.
They need to use the 'u64' APIs to add.
Fixes: 2f5c4025abb3 ("mempool: add telemetry endpoint")
Signed-off-by: Huisong Li <lihuisong at huawei.com>
Acked-by: Morten Brørup <mb at smartsharesystems.com>
Acked-by: Chengwen Feng <fengchengwen at huawei.com>
---
lib/mempool/rte_mempool.c | 24 ++++++++++++------------
1 file changed, 12 insertions(+), 12 deletions(-)
diff --git a/lib/mempool/rte_mempool.c b/lib/mempool/rte_mempool.c
index 3c9a1ad71a..40e6d17409 100644
--- a/lib/mempool/rte_mempool.c
+++ b/lib/mempool/rte_mempool.c
@@ -1493,25 +1493,25 @@ mempool_info_cb(struct rte_mempool *mp, void *arg)
rte_tel_data_add_dict_string(info->d, "name", mp->name);
- rte_tel_data_add_dict_int(info->d, "pool_id", mp->pool_id);
- rte_tel_data_add_dict_int(info->d, "flags", mp->flags);
+ rte_tel_data_add_dict_u64(info->d, "pool_id", mp->pool_id);
+ rte_tel_data_add_dict_u64(info->d, "flags", mp->flags);
rte_tel_data_add_dict_int(info->d, "socket_id", mp->socket_id);
- rte_tel_data_add_dict_int(info->d, "size", mp->size);
- rte_tel_data_add_dict_int(info->d, "cache_size", mp->cache_size);
- rte_tel_data_add_dict_int(info->d, "elt_size", mp->elt_size);
- rte_tel_data_add_dict_int(info->d, "header_size", mp->header_size);
- rte_tel_data_add_dict_int(info->d, "trailer_size", mp->trailer_size);
- rte_tel_data_add_dict_int(info->d, "private_data_size",
+ rte_tel_data_add_dict_u64(info->d, "size", mp->size);
+ rte_tel_data_add_dict_u64(info->d, "cache_size", mp->cache_size);
+ rte_tel_data_add_dict_u64(info->d, "elt_size", mp->elt_size);
+ rte_tel_data_add_dict_u64(info->d, "header_size", mp->header_size);
+ rte_tel_data_add_dict_u64(info->d, "trailer_size", mp->trailer_size);
+ rte_tel_data_add_dict_u64(info->d, "private_data_size",
mp->private_data_size);
rte_tel_data_add_dict_int(info->d, "ops_index", mp->ops_index);
- rte_tel_data_add_dict_int(info->d, "populated_size",
+ rte_tel_data_add_dict_u64(info->d, "populated_size",
mp->populated_size);
mz = mp->mz;
rte_tel_data_add_dict_string(info->d, "mz_name", mz->name);
- rte_tel_data_add_dict_int(info->d, "mz_len", mz->len);
- rte_tel_data_add_dict_int(info->d, "mz_hugepage_sz",
+ rte_tel_data_add_dict_u64(info->d, "mz_len", mz->len);
+ rte_tel_data_add_dict_u64(info->d, "mz_hugepage_sz",
mz->hugepage_sz);
rte_tel_data_add_dict_int(info->d, "mz_socket_id", mz->socket_id);
- rte_tel_data_add_dict_int(info->d, "mz_flags", mz->flags);
+ rte_tel_data_add_dict_u64(info->d, "mz_flags", mz->flags);
}
--
2.39.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2023-02-23 14:46:24.288470907 +0000
+++ 0018-mempool-fix-telemetry-data-truncation.patch 2023-02-23 14:46:23.725235809 +0000
@@ -1 +1 @@
-From 4eebfcf70a21b2b608e3bb9f20b5ee23338172ec Mon Sep 17 00:00:00 2001
+From 119d73b152eca50244c3f99a26c5ee388dd0e01a Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit 4eebfcf70a21b2b608e3bb9f20b5ee23338172ec ]
+
@@ -13 +14,0 @@
-Cc: stable at dpdk.org
@@ -23 +24 @@
-index f33f455790..950d01ffac 100644
+index 3c9a1ad71a..40e6d17409 100644
@@ -26 +27 @@
-@@ -1501,25 +1501,25 @@ mempool_info_cb(struct rte_mempool *mp, void *arg)
+@@ -1493,25 +1493,25 @@ mempool_info_cb(struct rte_mempool *mp, void *arg)
More information about the stable
mailing list