Compare commits
2 Commits
5b1b69e467
...
abdf53368b
Author | SHA1 | Date | |
---|---|---|---|
abdf53368b | |||
1bc99bc05f |
@ -236,7 +236,10 @@ impl Xhci {
|
||||
let state = &self.port_states[port];
|
||||
|
||||
match state.state.swap(PortState::Disconnected, Ordering::Release) {
|
||||
PortState::Init => todo!(),
|
||||
PortState::Init => {
|
||||
log::warn!("USB device detach received while in init state");
|
||||
Ok(())
|
||||
}
|
||||
PortState::Running => {
|
||||
log::info!("Port {}: device detached", port);
|
||||
let address = state
|
||||
|
@ -123,8 +123,12 @@ impl InterruptHandler for HpetTimer {
|
||||
|
||||
impl Device for HpetTimer {
|
||||
unsafe fn init(self: Arc<Self>) -> Result<(), Error> {
|
||||
// TODO support arbitrary configurations
|
||||
assert!(self.bits64);
|
||||
if self.period > u32::MAX as u64 && !self.bits64 {
|
||||
log::error!(
|
||||
"HPET period is >32bit and the HPET itself does not support 64bit counters"
|
||||
);
|
||||
return Err(Error::InvalidArgument);
|
||||
}
|
||||
|
||||
let intc = external_interrupt_controller()?;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user