1
0
Fork 0
mirror of synced 2025-03-06 20:59:54 +01:00
linux/tools
Sean Christopherson cd5a0c2f0f KVM: selftests: Manage CPUID array in Hyper-V CPUID test's core helper
Allocate, get, and free the CPUID array in the Hyper-V CPUID test in the
test's core helper, instead of copy+pasting code at each call site.  In
addition to deduplicating a small amount of code, restricting visibility
of the array to a single invocation of the core test prevents "leaking" an
array across test cases.  Passing in @vcpu to the helper will also allow
pivoting on VM-scoped information without needing to pass more booleans,
e.g. to conditionally assert on features that require an in-kernel APIC.

To avoid use-after-free bugs due to overzealous and careless developers,
opportunstically add a comment to explain that the system-scoped helper
caches the Hyper-V CPUID entries, i.e. that the caller is not responsible
for freeing the memory.

Cc: Vitaly Kuznetsov <vkuznets@redhat.com>
Reviewed-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Link: https://lore.kernel.org/r/20250118003454.2619573-4-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
2025-02-12 08:53:59 -08:00
..
accounting delayacct: add delay min to record delay peak 2025-01-12 20:21:16 -08:00
arch arm64/sysreg/tools: Move TRFCR definitions to sysreg 2025-01-12 12:50:11 +00:00
bootconfig tools/bootconfig: Fix the wrong format specifier 2025-01-28 23:27:01 +09:00
bpf perf-tools changes for v6.14 2025-01-24 05:45:40 -08:00
build perf tools: Expose quiet/verbose variables in Makefile.perf 2025-01-16 10:59:20 -08:00
certs
cgroup
counter
crypto crypto: tools/ccp - Remove unused variable 2024-08-30 18:22:30 +08:00
debugging
firewire tools/firewire: Fix several incorrect format specifiers 2024-11-14 09:12:04 +09:00
firmware
gpio tools: gpio: Fix several incorrect format specifiers 2024-11-13 16:30:05 +01:00
hv tools/hv: reduce resource usage in hv_kvp_daemon 2024-12-09 18:44:15 +00:00
iio iio: Add channel type for attention 2024-11-03 20:33:43 +00:00
include KVM/arm64 updates for 6.14 2025-01-28 09:01:36 -08:00
kvm/kvm_stat
laptop
leds
lib perf-tools changes for v6.14 2025-01-24 05:45:40 -08:00
memory-model tools/memory-model: simple.txt: Fix stale reference to recipes-pairs.txt 2024-09-13 23:56:44 -07:00
mm - The series "zram: optimal post-processing target selection" from 2024-11-23 09:58:07 -08:00
net tools: ynl: c: correct reverse decode of empty attrs 2025-01-27 14:30:23 -08:00
objtool Objtool changes for v6.14: 2025-01-21 10:13:11 -08:00
pcmcia
perf perf-tools fixes for 6.14 2025-01-30 17:38:20 -08:00
power Turbostat 2025.02.02 updates since 2024.11.30 2025-02-02 10:49:13 -08:00
rcu tools/rcu: Remove RCU Tasks Rude asynchronous APIs from rcu-updaters.sh 2024-07-29 07:39:32 +05:30
sched_ext sched_ext: Use time helpers in BPF schedulers 2025-01-10 08:04:40 -10:00
scripts perf tools: Create generic syscall table support 2025-01-09 12:49:49 -03:00
sound ASoC: dapm-graph: show path name for non-static routes 2024-08-23 11:03:00 +01:00
spi spi: spidev_test: add support for word delay 2024-11-07 15:25:50 +00:00
testing KVM: selftests: Manage CPUID array in Hyper-V CPUID test's core helper 2025-02-12 08:53:59 -08:00
thermal tools/thermal: Fix common realloc mistake 2024-11-15 14:29:03 +01:00
time
tracing rv: tools/rtla: Updates for 6.14 2025-01-26 14:25:58 -08:00
usb usbip: tools: Fix detach_port() invalid port error path 2024-10-29 04:23:23 +01:00
verification verification/dot2k: Implement event type detection 2024-12-27 14:41:01 -05:00
virtio Fix typo in vringh_test.c 2024-11-06 04:40:07 -05:00
wmi
workqueue
writeback
Makefile