pcid: Replace get_capabilities with get_vendor_capabilities

While this stops returning raw MSI/MSI-X capabilities from
get_capabilities, the same info can be obtained using
fetch_all_features and feature_info.
This commit is contained in:
bjorn3
2024-06-11 19:18:30 +02:00
parent 8f98e28e97
commit 386a63df42
3 changed files with 13 additions and 20 deletions
+5 -2
View File
@@ -101,10 +101,13 @@ impl DriverHandler {
use driver_interface::*;
match request {
PcidClientRequest::RequestCapabilities => PcidClientResponse::Capabilities(
PcidClientRequest::RequestVendorCapabilities => PcidClientResponse::VendorCapabilities(
self.capabilities
.iter()
.map(|capability| capability.clone())
.filter_map(|capability| match capability {
PciCapability::Vendor(capability) => Some(capability.clone()),
_ => None,
})
.collect::<Vec<_>>(),
),
PcidClientRequest::RequestConfig => PcidClientResponse::Config(args.clone()),