malloc: remove unused function to set limit
PATCH 1/1 malloc: remove unused function to set limit
This function was never implemented and has been deprecated for a long time. We can remove it.
Signed-off-by David Marchand <[email protected]>
--- doc/guides/rel_notes/release_22_11.rst | 2 ++ lib/eal/common/rte_malloc.c | 10 ---------- lib/eal/include/rte_malloc.h | 17 ----------------- lib/eal/version.map | 1 - 4 files changed, 2 insertions(+), 28 deletions(-)
doc/guides/rel_notes/release_22_11.rst +2 -0
@@ -112,6 +112,8 @@ API Changes in the future. Applications can use ``devtools/cocci/func_or_ret.cocci`` to update their code. +* mem: Removed not implemented and deprecated ``rte_malloc_set_limit``. + * mempool: Deprecated helper macro ``MEMPOOL_HEADER_SIZE()`` is removed. The replacement macro ``RTE_MEMPOOL_HEADER_SIZE()`` is internal only.
lib/eal/common/rte_malloc.c +0 -10
@@ -352,16 +352,6 @@ rte_malloc_dump_stats(FILE *f, __rte_unused const char *type)return ; } -/* -* TODO: Set limit to memory that can be allocated to memory type -*/ -int -rte_malloc_set_limit(__rte_unused const char *type, - __rte_unused size_t max) -{ -return 0 ; -} -/* * Return the IO address of a virtual address obtained through rte_malloc */
lib/eal/include/rte_malloc.h +0 -17
@@ -521,23 +521,6 @@ rte_malloc_dump_stats(FILE *f, const char *type);void rte_malloc_dump_heaps (FILE *f); -/** -* Set the maximum amount of allocated memory for this type. -* -* This is not yet implemented -* -* @param type -* A string identifying the type of allocated objects. -* @param max -* The maximum amount of allocated bytes for this type. -* @return -* - 0: Success. -* - (-1): Error. -*/ -__rte_deprecated -int -rte_malloc_set_limit (const char *type,size_t max); -/** * Return the IO address of a virtual address obtained through * rte_malloc
lib/eal/version.map +0 -1
@@ -165,7 +165,6 @@ DPDK_23 { rte_malloc_heap_memory_detach; rte_malloc_heap_memory_remove; rte_malloc_heap_socket_is_external; - rte_malloc_set_limit; rte_malloc_socket; rte_malloc_validate; rte_malloc_virt2iova;
Signature · 1 line
2.37.3
Thomas Monjalon
Applied27/09/2022 13:46, David Marchand:
Quoted 4 lines
This function was never implemented and has been deprecated for a long time. We can remove it.
Signed-off-by David Marchand <[email protected]>
Applied, thanks.