pcid: Explain why PciBar is used instead of pcid_types::Bar
This commit is contained in:
@@ -2,6 +2,8 @@ use std::convert::TryInto;
|
||||
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
// This type is used instead of [pci_types::Bar] in the driver interface as the
|
||||
// latter can't be serialized and is missing the convenience functions of [PciBar].
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Serialize, Deserialize)]
|
||||
pub enum PciBar {
|
||||
None,
|
||||
|
||||
@@ -199,7 +199,6 @@ impl PciEndpointHeader {
|
||||
}
|
||||
|
||||
/// Return the Headers BARs.
|
||||
// FIXME use pci_types::Bar instead
|
||||
pub fn bars(&self, access: &impl ConfigRegionAccess) -> [PciBar; 6] {
|
||||
let endpoint_header = self.endpoint_header(access);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user