diff options
Diffstat (limited to 'results/classifier/deepseek-2/output/hypervisor/1571')
| -rw-r--r-- | results/classifier/deepseek-2/output/hypervisor/1571 | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/results/classifier/deepseek-2/output/hypervisor/1571 b/results/classifier/deepseek-2/output/hypervisor/1571 deleted file mode 100644 index edffa5c35..000000000 --- a/results/classifier/deepseek-2/output/hypervisor/1571 +++ /dev/null @@ -1,13 +0,0 @@ - -accel/hvf: Instance size not properly declared -Description of problem: -In [`include/sysemu/hvf.h`](https://gitlab.com/qemu-project/qemu/-/blob/master/include/sysemu/hvf.h#L36), `HVFState` is declared to have the QOM type `TYPE_HVF_ACCEL`; -However, when the type is registered, proper `instance_size` for it was [not declared](https://gitlab.com/qemu-project/qemu/-/blob/master/accel/hvf/hvf-accel-ops.c#L351). - -As a result, a bad workaround was introduced. That is, when [`hvf_accel_init`](https://gitlab.com/qemu-project/qemu/-/blob/master/accel/hvf/hvf-accel-ops.c#L329) is called from [`accel_init_machine`](https://gitlab.com/qemu-project/qemu/-/blob/master/accel/accel-softmmu.c#L33), an new instance of `HVFState` is allocated while we should have used the pre-allocated instance in `ms->accelerator` similar to [what KVM does](https://gitlab.com/qemu-project/qemu/-/blob/master/accel/kvm/kvm-all.c#L2381) (the code didn't do so since the allocated ([using `object_new_with_class`](https://gitlab.com/qemu-project/qemu/-/blob/master/softmmu/vl.c#L2218)) instance didn't allocate enough memory for `HVFState`). - -Eventhough the code wouldn't crash nor have any serious implication, this would leak an `AccelState` and attempts to manually manage accelerators would cause a buffer-overflow. -Steps to reproduce: -1. Run a HVF-accelerated VM -Additional information: - |