numam-dpdk/lib/power
Hongbo Zheng 1fe00fd358 power: fix sanity checks for guest channel read
In function power_guest_channel_read_msg, 'lcore_id' is used before
validity check, which may cause buffer 'global_fds' accessed by index
'lcore_id' overflow.

This patch moves the validity check of 'lcore_id' before the 'lcore_id'
being used for the first time.

Fixes: 9dc843eb27 ("power: extend guest channel API for reading")
Cc: stable@dpdk.org

Signed-off-by: Hongbo Zheng <zhenghongbo3@huawei.com>
Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
Reviewed-by: Reshma Pattan <reshma.pattan@intel.com>
Acked-by: David Hunt <david.hunt@intel.com>
2021-05-12 17:18:38 +02:00
..
guest_channel.c power: fix sanity checks for guest channel read 2021-05-12 17:18:38 +02:00
guest_channel.h lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
meson.build build: fix formatting of Meson lists 2021-05-04 15:01:47 +02:00
power_acpi_cpufreq.c power: save original ACPI governor always 2021-05-05 12:29:12 +02:00
power_acpi_cpufreq.h lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
power_common.c lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
power_common.h lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
power_kvm_vm.c lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
power_kvm_vm.h lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
power_pstate_cpufreq.c lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
power_pstate_cpufreq.h lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
rte_power_empty_poll.c lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
rte_power_empty_poll.h lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
rte_power_guest_channel.h lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
rte_power_pmd_mgmt.c lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
rte_power_pmd_mgmt.h lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
rte_power.c lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
rte_power.h lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00
version.map lib: remove librte_ prefix from directory names 2021-04-21 14:04:09 +02:00