Skip to content

Commit

Permalink
fix: naming of types in acpi-tables
Browse files Browse the repository at this point in the history
We were calling stuff "Cachable" instead of "Cacheable".

Signed-off-by: Babis Chalios <[email protected]>
  • Loading branch information
bchalios authored and roypat committed Oct 24, 2024
1 parent ffebf33 commit c9009f1
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/acpi-tables/src/aml.rs
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ enum AddressSpaceType {
}

#[derive(Copy, Clone)]
pub enum AddressSpaceCachable {
pub enum AddressSpaceCacheable {
NotCacheable,
Cacheable,
WriteCombining,
Expand All @@ -421,7 +421,7 @@ pub struct AddressSpace<T> {
}

impl<T> AddressSpace<T> {
pub fn new_memory(cacheable: AddressSpaceCachable, read_write: bool, min: T, max: T) -> Self {
pub fn new_memory(cacheable: AddressSpaceCacheable, read_write: bool, min: T, max: T) -> Self {
AddressSpace {
r#type: AddressSpaceType::Memory,
min,
Expand Down Expand Up @@ -1384,13 +1384,13 @@ mod tests {
"_CRS".try_into().unwrap(),
&ResourceTemplate::new(vec![
&AddressSpace::new_memory(
AddressSpaceCachable::Cacheable,
AddressSpaceCacheable::Cacheable,
true,
0xa_0000u32,
0xb_ffffu32
),
&AddressSpace::new_memory(
AddressSpaceCachable::NotCacheable,
AddressSpaceCacheable::NotCacheable,
true,
0xc000_0000u32,
0xfebf_ffffu32
Expand All @@ -1416,7 +1416,7 @@ mod tests {
Name::new(
"_CRS".try_into().unwrap(),
&ResourceTemplate::new(vec![&AddressSpace::new_memory(
AddressSpaceCachable::Cacheable,
AddressSpaceCacheable::Cacheable,
true,
0x8_0000_0000u64,
0xf_ffff_ffffu64
Expand Down Expand Up @@ -1984,7 +1984,7 @@ mod tests {
&Name::new(
"MR64".try_into().unwrap(),
&ResourceTemplate::new(vec![&AddressSpace::new_memory(
AddressSpaceCachable::Cacheable,
AddressSpaceCacheable::Cacheable,
true,
0x0000_0000_0000_0000u64,
0xFFFF_FFFF_FFFF_FFFEu64
Expand Down

0 comments on commit c9009f1

Please sign in to comment.