History log of /dpdk/lib/eal/common/eal_common_memory.c (Results 1 – 11 of 11)
Revision Date Author Comments
# 17bb6004 10-Oct-2024 Gagandeep Singh <g.singh@nxp.com>

mem: add total memory size in dumps

This patch add total memory size dump in memzone and memory segments
dump APIs.

Signed-off-by: Gagandeep Singh <g.singh@nxp.com>
Acked-by: Stephen Hemminger <ste

mem: add total memory size in dumps

This patch add total memory size dump in memzone and memory segments
dump APIs.

Signed-off-by: Gagandeep Singh <g.singh@nxp.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>

show more ...


# ae67895b 08-Dec-2023 David Marchand <david.marchand@redhat.com>

lib: add more logging helpers

Add helpers for logging messages in libraries instead of calling
RTE_LOG() directly.
Those helpers take care of adding a \n: this will make the transition to
RTE_LOG_LI

lib: add more logging helpers

Add helpers for logging messages in libraries instead of calling
RTE_LOG() directly.
Those helpers take care of adding a \n: this will make the transition to
RTE_LOG_LINE trivial.

Note:
- for acl and sched libraries that still has some debug multilines
messages, a direct call to RTE_LOG is used: this will make it easier to
notice such special cases,

Signed-off-by: David Marchand <david.marchand@redhat.com>

show more ...


# 2054f31a 17-May-2023 Amit Prakash Shukla <amitprakashs@marvell.com>

mem: add memseg info in telemetry

Changes adds telemetry support to display memory occupancy
in memseg and the information of the elements allocated from
a memseg based on arguments provided by user

mem: add memseg info in telemetry

Changes adds telemetry support to display memory occupancy
in memseg and the information of the elements allocated from
a memseg based on arguments provided by user. This patch
adds following endpoints:

1. /eal/memseg_lists
The command displays the memseg list from which the memory
has been allocated.
Example:
--> /eal/memseg_lists
{
"/eal/memseg_lists": [
0
]
}

2. /eal/memseg_list_info,<memseg-list-id>
The command outputs the memsegs, from which the memory is
allocated, for the memseg_list given as input.
Example:
--> /eal/memseg_list_info,0
{
"/eal/memseg_list_info": [
0,
1,
2,
3,
4,
5
]
}

3. /eal/memseg_info,<memseg-list-id>,<memseg-id>
The command outputs the memseg information based on the
memseg-list and the memseg-id given as input.
Example:
--> /eal/memseg_info,0,5
{
"/eal/memseg_info": {
"Memseg_list_index": 0,
"Memseg_index": 5,
"IOVA_addr": "0x1c0000000",
"Start_addr": "0x1c0000000",
"End_addr": "0x1e0000000",
"Size": 536870912,
"Hugepage_size": 536870912,
"Socket_id": 0,
"flags": 0
}
}

--> /eal/memseg_info,0,1
{
"/eal/memseg_info": {
"Memseg_list_index": 0,
"Memseg_index": 1,
"IOVA_addr": "0x140000000",
"Start_addr": "0x140000000",
"End_addr": "0x160000000",
"Size": 536870912,
"Hugepage_size": 536870912,
"Socket_id": 0,
"flags": 0
}
}

4. /eal/mem_element_list,<heap-id>,<memseg-list-id>,<memseg-id>
The command outputs number of elements in a memseg based
on the heap-id, memseg-list-id and memseg-id given as input.
Example:
--> /eal/mem_element_list,0,0,5
{
"/eal/mem_element_list": {
"Element_count": 2
}
}

--> /eal/mem_element_list,0,0,1
{
"/eal/mem_element_list": {
"Element_count": 52
}
}

5. /eal/mem_element_info,<heap-id>,<memseg-list-id>,<memseg-id>, \
<elem-start-id>,<elem-end-id>
The command outputs element information like element start
address, end address, to which memseg it belongs, element
state, element size. User can give a range of elements to be
printed.
Example:
--> /eal/mem_element_info,0,0,4,1,2
{
"/eal/mem_element_info": {
"element_1": {
"msl_id": 0,
"ms_id": 4,
"memseg_start_addr": "0x1a0000000",
"memseg_end_addr": "0x1c0000000",
"element_start_addr": "0x1a01fe680",
"element_end_addr": "0x1a0bfe700",
"element_size": 10485888,
"element_state": "Busy"
},
"element_2": {
"msl_id": 0,
"ms_id": 4,
"memseg_start_addr": "0x1a0000000",
"memseg_end_addr": "0x1c0000000",
"element_start_addr": "0x1a0bfe700",
"element_end_addr": "0x1a15fe780",
"element_size": 10485888,
"element_state": "Busy"
},
"Element_count": 2
}
}

Signed-off-by: Amit Prakash Shukla <amitprakashs@marvell.com>
Acked-by: Anatoly Burakov <anatoly.burakov@intel.com>

show more ...


# 2e2f0272 04-Apr-2023 David Marchand <david.marchand@redhat.com>

mem: rework malloc heap init

rte_eal_memory_init() and rte_eal_malloc_heap_init() must be called in
a common section taking rte_mcfg_mem_read_lock().
Split rte_eal_malloc_heap_init() in two so that

mem: rework malloc heap init

rte_eal_memory_init() and rte_eal_malloc_heap_init() must be called in
a common section taking rte_mcfg_mem_read_lock().
Split rte_eal_malloc_heap_init() in two so that the mem lock is taken
in rte_eal_init() making lock checks trivial (once annotated in the next
patch).

Signed-off-by: David Marchand <david.marchand@redhat.com>

show more ...


# a9dc4888 22-Feb-2023 Huisong Li <lihuisong@huawei.com>

mem: fix heap ID in telemetry

The telemetry lib has added a allowed characters set for dictionary names.
Please see commit 2537fb0c5f34 ("telemetry: limit characters allowed in
dictionary names")

T

mem: fix heap ID in telemetry

The telemetry lib has added a allowed characters set for dictionary names.
Please see commit 2537fb0c5f34 ("telemetry: limit characters allowed in
dictionary names")

The space is not in this set, which cause the heap ID in /eal/heap_info
cannot be displayed. Additionally, 'heap' is also misspelling. So use
'Heap_id' to replace 'Head id'.

Fixes: e6732d0d6e26 ("mem: add telemetry infos")
Fixes: 2537fb0c5f34 ("telemetry: limit characters allowed in dictionary names")
Cc: stable@dpdk.org

Signed-off-by: Huisong Li <lihuisong@huawei.com>
Acked-by: Chengwen Feng <fengchengwen@huawei.com>
Reviewed-by: Morten Brørup <mb@smartsharesystems.com>

show more ...


# af0785a2 12-Jan-2023 Bruce Richardson <bruce.richardson@intel.com>

rename telemetry u64 functions to uint versions

Within the DPDK code-base, replace all occurrences of
"rte_tel_data_add_array_u64" with "rte_tel_data_add_array_uint", and
similarly replace all occur

rename telemetry u64 functions to uint versions

Within the DPDK code-base, replace all occurrences of
"rte_tel_data_add_array_u64" with "rte_tel_data_add_array_uint", and
similarly replace all occurrences of "rte_tel_data_add_dict_u64" with
"rte_tel_data_add_dict_uint". This allows us to later mark the older
functions as deprecated without hitting warnings.

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Ciara Power <ciara.power@intel.com>

show more ...


# 6243e36b 19-Dec-2022 Huisong Li <lihuisong@huawei.com>

mem: fix telemetry data truncation

The 'u32' and 'u64' data can not assigned to 'int' type variable.
They need to use the 'u64' APIs to add.

Fixes: e6732d0d6e26 ("mem: add telemetry infos")
Cc: sta

mem: fix telemetry data truncation

The 'u32' and 'u64' data can not assigned to 'int' type variable.
They need to use the 'u64' APIs to add.

Fixes: e6732d0d6e26 ("mem: add telemetry infos")
Cc: stable@dpdk.org

Signed-off-by: Huisong Li <lihuisong@huawei.com>
Acked-by: Morten Brørup <mb@smartsharesystems.com>
Acked-by: Chengwen Feng <fengchengwen@huawei.com>

show more ...


# 30a1de10 15-Feb-2022 Sean Morrissey <sean.morrissey@intel.com>

lib: remove unneeded header includes

These header includes have been flagged by the iwyu_tool
and removed.

Signed-off-by: Sean Morrissey <sean.morrissey@intel.com>


# 4042dc20 09-Nov-2020 Anatoly Burakov <anatoly.burakov@intel.com>

mem: quiet base address hint warning if not requested

Any EAL memory allocation often goes through eal_get_virtual_area()
function, which will print a warning whenever the resulting allocation
didn'

mem: quiet base address hint warning if not requested

Any EAL memory allocation often goes through eal_get_virtual_area()
function, which will print a warning whenever the resulting allocation
didn't match the specified address requirements. This is useful for
when we have requested a specific base virtual address, to let the user
know that the mapping has deviated from that address.

However, on Linux, we also have a default base address that's there to
ensure better chances of successful secondary process initialization,
as well as higher likelihood of the virtual areas to fit inside the
IOMMU address width. Because of this default base address, there are
warnings printed even when no base address was explicitly requested,
which can be confusing to the user.

Emit this warning with debug level unless base address was explicitly
requested by the user.

Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>

show more ...


# e6732d0d 08-Oct-2021 Harman Kalra <hkalra@marvell.com>

mem: add telemetry infos

Registering new telemetry callbacks to list named (memzones)
and unnamed (malloc) memory reserved and return information
based on arguments provided by user.

Example:
Conne

mem: add telemetry infos

Registering new telemetry callbacks to list named (memzones)
and unnamed (malloc) memory reserved and return information
based on arguments provided by user.

Example:
Connecting to /var/run/dpdk/rte/dpdk_telemetry.v2
{"version": "DPDK 21.11.0-rc0", "pid": 59754, "max_output_len": 16384}
Connected to application: "dpdk-testpmd"
-->
--> /eal/memzone_list
{"/eal/memzone_list": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]}
-->
-->
--> /eal/memzone_info,0
{"/eal/memzone_info": {"Zone": 0, "Name": "rte_eth_dev_data", \
"Length": 225408, "Address": "0x13ffc0280", "Socket": 0, "Flags": 0, \
"Hugepage_size": 536870912, "Hugepage_base": "0x120000000", \
"Hugepage_used": 1}}
-->
-->
--> /eal/memzone_info,6
{"/eal/memzone_info": {"Zone": 6, "Name": "MP_mb_pool_0_0", \
"Length": 669918336, "Address": "0x15811db80", "Socket": 0, \
"Flags": 0, "Hugepage_size": 536870912, "Hugepage_base": "0x140000000", \
"Hugepage_used": 2}}
-->
-->
--> /eal/memzone_info,14
{"/eal/memzone_info": null}
-->
-->
--> /eal/heap_list
{"/eal/heap_list": [0]}
-->
-->
--> /eal/heap_info,0
{"/eal/heap_info": {"Head id": 0, "Name": "socket_0", \
"Heap_size": 1610612736, "Free_size": 927645952, \
"Alloc_size": 682966784, "Greatest_free_size": 529153152, \
"Alloc_count": 482, "Free_count": 2}}

Signed-off-by: Harman Kalra <hkalra@marvell.com>
Acked-by: Ciara Power <ciara.power@intel.com>
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 ...