forked from koniifer/ableos
PCI: add INTEL_PIIX4_IDE device
This commit is contained in:
parent
b8f0074aa0
commit
ed68ef9fa0
|
@ -5,16 +5,24 @@
|
|||
*/
|
||||
|
||||
use super::vendors::Vendor::{self, *};
|
||||
|
||||
#[derive(PartialEq, Clone, Eq, Debug)]
|
||||
pub struct DeviceID {
|
||||
pub vendor: Vendor,
|
||||
pub id: u16,
|
||||
}
|
||||
|
||||
impl DeviceID {
|
||||
pub const fn new(vendor: Vendor, id: u16) -> Self {
|
||||
Self { vendor, id }
|
||||
}
|
||||
}
|
||||
|
||||
pub const VMWARE_SVGA2: DeviceID = DeviceID::new(VMware, 0x0405);
|
||||
// FIXME: Unknown class
|
||||
pub const S3INC_TRIO64V2: DeviceID = DeviceID::new(S3Inc, 0x8900);
|
||||
|
||||
// MassStorage_IDE (0x0101)
|
||||
pub const INTEL_PIIX4_IDE: DeviceID = DeviceID::new(Intel, 0x7111);
|
||||
|
||||
// Display_VGA (0x0300)
|
||||
pub const VMWARE_SVGA2: DeviceID = DeviceID::new(VMware, 0x0405);
|
||||
|
|
|
@ -8,8 +8,14 @@ use super::devices::*;
|
|||
|
||||
pub fn check_pci_support(device_id: DeviceID) -> bool {
|
||||
match device_id {
|
||||
VMWARE_SVGA2 => true,
|
||||
// FIXME: Unknown class
|
||||
S3INC_TRIO64V2 => true,
|
||||
|
||||
// MassStorage_IDE (0x0101)
|
||||
INTEL_PIIX4_IDE => true,
|
||||
|
||||
// Display_VGA (0x0300)
|
||||
VMWARE_SVGA2 => true,
|
||||
_ => false,
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue