lib: add PCI bus info mapping to allow custom spoofing

- Including spoofing Maxwell and Pascal cards to Turing for 19.x use
This commit is contained in:
Matt Bilker
2025-11-08 13:51:03 +00:00
parent c0e94b1988
commit e8c1d1381e
2 changed files with 51 additions and 34 deletions

View File

@@ -1,5 +1,7 @@
// SPDX-License-Identifier: MIT
use std::collections::HashMap;
use serde::Deserialize;
struct Defaults;
@@ -22,6 +24,8 @@ pub struct Config {
pub unlock: bool,
#[serde(default = "Defaults::unlock_migration")]
pub unlock_migration: bool,
#[serde(default)]
pub pci_info_map: Option<HashMap<u32, u32>>,
}
impl Default for Config {
@@ -30,6 +34,7 @@ impl Default for Config {
Self {
unlock: Defaults::unlock(),
unlock_migration: Defaults::unlock_migration(),
pci_info_map: None,
}
}
}