numam-dpdk/examples/vm_power_manager
Hamza Khan 9c20d0fdc5 examples/vm_power_manager: use safe list iterator
Currently, when vm_power_manager exits, we are using a LIST_FOREACH
macro to iterate over VM info structures while freeing them. This
leads to use-after-free error. To address this, replace all usages of
LIST_* with TAILQ_* macros, and use the RTE_TAILQ_FOREACH_SAFE macro
to iterate and delete VM info structures.

Fixes: e8ae9b6625 ("examples/vm_power: channel manager and monitor in host")
Cc: stable@dpdk.org

Signed-off-by: Hamza Khan <hamza.khan@intel.com>
Signed-off-by: Reshma Pattan <reshma.pattan@intel.com>
Acked-by: David Hunt <david.hunt@intel.com>
2022-10-05 14:15:37 +02:00
..
guest_cli eal: remove unneeded includes from a public header 2022-09-21 15:31:03 +02:00
channel_manager.c examples/vm_power_manager: use safe list iterator 2022-10-05 14:15:37 +02:00
channel_manager.h examples: remove unneeded atomic header include 2021-10-19 17:16:57 +02:00
channel_monitor.c eal: remove unneeded includes from a public header 2022-09-21 15:31:03 +02:00
channel_monitor.h power: clean up includes 2021-01-29 11:25:40 +01:00
main.c ethdev: add namespace 2021-10-22 18:15:38 +02:00
Makefile examples: fix pkg-config override 2021-05-05 22:20:24 +02:00
meson.build examples: skip build when missing dependencies 2021-11-10 11:42:34 +01:00
oob_monitor_nop.c examples/vm_power_manager: fix build 2020-04-17 23:22:15 +02:00
oob_monitor_x86.c examples/vm_power: allow managing idle cores 2020-07-17 14:40:56 +02:00
oob_monitor.h examples/vm_power: add oob monitoring functions 2018-07-20 22:53:17 +02:00
parse.c eal: remove unneeded includes from a public header 2022-09-21 15:31:03 +02:00
parse.h examples/vm_power: make branch ratio threshold per core 2020-07-17 14:40:56 +02:00
power_manager.c examples/vm_power: respect core mask 2021-01-28 23:17:18 +01:00
power_manager.h fix spelling in comments and strings 2022-01-11 12:16:53 +01:00
vm_power_cli.c power: clean up includes 2021-01-29 11:25:40 +01:00
vm_power_cli.h replace unused attributes 2020-04-16 18:30:58 +02:00