Rust XHCI Implementation.
This commit is contained in:
parent
0b95098748
commit
a10c615b95
10 changed files with 438 additions and 30 deletions
|
|
@ -5,12 +5,28 @@ extern crate alloc;
|
|||
|
||||
mod xhci;
|
||||
|
||||
use mammoth::{debug, define_entry, zion::z_err_t};
|
||||
use mammoth::{cap::Capability, debug, define_entry, zion::z_err_t};
|
||||
use pci::PciDevice;
|
||||
use xhci::driver::XHCIDriver;
|
||||
|
||||
define_entry!();
|
||||
|
||||
#[unsafe(no_mangle)]
|
||||
extern "C" fn main() -> z_err_t {
|
||||
debug!("In Voyageurs");
|
||||
#[cfg(feature = "debug")]
|
||||
debug!("Voyageurs Starting.");
|
||||
|
||||
let yellowstone = yellowstone_yunq::from_init_endpoint();
|
||||
|
||||
let xhci_info = yellowstone
|
||||
.get_xhci_info()
|
||||
.expect("Failed to get XHCI info from yellowstone.");
|
||||
|
||||
let pci_device = PciDevice::from_cap(Capability::take(xhci_info.xhci_region)).unwrap();
|
||||
|
||||
let xhci_driver = XHCIDriver::from_pci_device(pci_device);
|
||||
|
||||
loop {}
|
||||
|
||||
0
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue