Skip to content

Commit

Permalink
Merge pull request #1104 from mkroening/nightly-2024-03-15
Browse files Browse the repository at this point in the history
chore: upgrade to nightly-2024-03-15
  • Loading branch information
mkroening authored Mar 22, 2024
2 parents f4083eb + 9b680f2 commit 4b770fa
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[toolchain]
channel = "nightly-2024-03-01"
channel = "nightly-2024-03-15"
components = [
"llvm-tools",
"rust-src",
Expand Down
8 changes: 7 additions & 1 deletion src/arch/x86_64/kernel/apic.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
use alloc::vec::Vec;
#[cfg(feature = "smp")]
use core::arch::x86_64::_mm_mfence;
#[cfg(feature = "acpi")]
use core::fmt;
use core::hint::spin_loop;
use core::sync::atomic::Ordering;
use core::{cmp, fmt, mem, ptr, u32};
use core::{cmp, mem, ptr, u32};

use align_address::Align;
#[cfg(feature = "smp")]
Expand Down Expand Up @@ -160,13 +162,15 @@ struct AcpiMadtRecordHeader {
length: u8,
}

#[cfg(feature = "acpi")]
#[repr(C, packed)]
struct ProcessorLocalApicRecord {
acpi_processor_id: u8,
apic_id: u8,
flags: u32,
}

#[cfg(feature = "acpi")]
impl fmt::Display for ProcessorLocalApicRecord {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(f, "{{ acpi_processor_id: {}, ", { self.acpi_processor_id })?;
Expand All @@ -179,6 +183,7 @@ impl fmt::Display for ProcessorLocalApicRecord {
#[cfg(feature = "acpi")]
const CPU_FLAG_ENABLED: u32 = 1 << 0;

#[cfg(feature = "acpi")]
#[repr(C, packed)]
struct IoApicRecord {
id: u8,
Expand All @@ -187,6 +192,7 @@ struct IoApicRecord {
global_system_interrupt_base: u32,
}

#[cfg(feature = "acpi")]
impl fmt::Display for IoApicRecord {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(f, "{{ id: {}, ", { self.id })?;
Expand Down

0 comments on commit 4b770fa

Please sign in to comment.