diff options
author | Corvin Köhne <c.koehne@beckhoff.com> | 2024-11-08 13:49:04 +0100 |
---|---|---|
committer | Cédric Le Goater <clg@redhat.com> | 2024-11-18 08:40:06 +0100 |
commit | 66650fd0cc67e11f84521a114a7cbc8a8a5033ff (patch) | |
tree | ee217515d0b66f3a3dcfedd0c74b92a6c17ab8fd /module-common.c | |
parent | aff0c39c5bb5b45ebbf8f857cf8f546d4565f1bb (diff) | |
download | qemu-66650fd0cc67e11f84521a114a7cbc8a8a5033ff.zip qemu-66650fd0cc67e11f84521a114a7cbc8a8a5033ff.tar.gz qemu-66650fd0cc67e11f84521a114a7cbc8a8a5033ff.tar.bz2 |
vfio/igd: fix calculation of graphics stolen memory
When copying the calculation of the stolen memory size for Intels integrated
graphics device of gen 9 and later from the Linux kernel [1], we missed
subtracting 0xf0 from the graphics mode select value for values above 0xf0.
This leads to QEMU reporting a very large size of the graphics stolen memory
area. That's just a waste of memory. Additionally the guest firmware might be
unable to allocate such a large buffer.
[1] https://github.com/torvalds/linux/blob/7c626ce4bae1ac14f60076d00eafe71af30450ba/arch/x86/kernel/early-quirks.c#L455-L460
Signed-off-by: Corvin Köhne <c.koehne@beckhoff.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Fixes: 871922416683 ("vfio/igd: correctly calculate stolen memory size for gen 9 and later")
Reviewed-by: Alex Williamson <alex.williamson@redhat.com>
[ clg: Changed commit subject ]
Signed-off-by: Cédric Le Goater <clg@redhat.com>
Diffstat (limited to 'module-common.c')
0 files changed, 0 insertions, 0 deletions