1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 04:57:45 +00:00

Kernel/VirtIO: Ignore the VIRTIO_PCI_CAP_PCI_CFG configuration type

This configuration exposes a suboptimal mechanism to access other
VirtIO device configurations. It is also the only configuration to use a
zero length for a configuration structure, and specify a valid BAR which
triggered a kernel panic when attaching a virtio-gpu-pci device before
95b15e4901 was applied.

The real solution for that problem is to ignore this configuration type
because we never actually use it. It means that we can VERIFY that all
other configuration types have a valid length, as being expected.
This commit is contained in:
Liav A 2023-03-10 09:13:05 +02:00 committed by Linus Groh
parent 1b260ab1f8
commit 657bc71247
2 changed files with 24 additions and 4 deletions

View file

@ -70,7 +70,7 @@ enum class ConfigurationType : u8 {
Notify = 2,
ISR = 3,
Device = 4,
PCI = 5
PCICapabilitiesAccess = 5
};
struct Configuration {