WIP: x86: allow non-64bit counters in HPET
This commit is contained in:
parent
5b1b69e467
commit
1bc99bc05f
@ -123,8 +123,12 @@ impl InterruptHandler for HpetTimer {
|
|||||||
|
|
||||||
impl Device for HpetTimer {
|
impl Device for HpetTimer {
|
||||||
unsafe fn init(self: Arc<Self>) -> Result<(), Error> {
|
unsafe fn init(self: Arc<Self>) -> Result<(), Error> {
|
||||||
// TODO support arbitrary configurations
|
if self.period > u32::MAX as u64 && !self.bits64 {
|
||||||
assert!(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()?;
|
let intc = external_interrupt_controller()?;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user