Replace Location with PciDeviceLocation

This commit is contained in:
Yuke Peng
2023-07-05 06:39:27 -07:00
committed by Tate, Hongliang Tian
parent a47b98b160
commit 9bce8b879b
12 changed files with 68 additions and 139 deletions

View File

@ -2,11 +2,11 @@ use alloc::vec::Vec;
use log::debug;
use pod::Pod;
use crate::util::{CSpaceAccessMethod, Location, BAR};
use crate::util::{CSpaceAccessMethod, BAR};
use super::capability::msix::CapabilityMSIXData;
use jinux_frame::{offset_of, trap::IrqAllocateHandle};
use jinux_frame::{bus::pci::PciDeviceLocation, offset_of, trap::IrqAllocateHandle};
use jinux_util::frame_ptr::InFramePtr;
#[derive(Debug, Default)]
@ -37,7 +37,7 @@ impl MSIX {
pub fn new(
cap: &CapabilityMSIXData,
bars: [Option<BAR>; 6],
loc: Location,
loc: PciDeviceLocation,
cap_ptr: u16,
) -> Self {
let table_info = cap.table_info;