Skip to main content

IOMMU

Struct IOMMU 

Source
pub struct IOMMU { /* private fields */ }
Expand description

I/O Memory Management Unit

Implementations§

Source§

impl IOMMU

Source

pub const PTR: *const RegisterBlock

Pointer to the register block

Source

pub const fn ptr() -> *const RegisterBlock

Return the pointer to the register block

Source

pub unsafe fn steal() -> Self

Steal an instance of this peripheral

§Safety

Ensure that the new instance of the peripheral cannot be used in a way that may race with any existing instances, for example by only accessing read-only or write-only registers, or by consuming the original peripheral and using critical sections to coordinate access between multiple new instances.

Additionally, other software such as HALs may rely on only one peripheral instance existing to ensure memory safety; ensure no stolen instances are passed to such software.

Methods from Deref<Target = RegisterBlock>§

Source

pub fn iommu_reset(&self) -> &IOMMU_RESET

0x10 - IOMMU Reset Register

Source

pub fn iommu_enable(&self) -> &IOMMU_ENABLE

0x20 - IOMMU Enable Register

Source

pub fn iommu_bypass(&self) -> &IOMMU_BYPASS

0x30 - IOMMU Bypass Register

Source

pub fn iommu_auto_gating(&self) -> &IOMMU_AUTO_GATING

0x40 - IOMMU Auto Gating Register

Source

pub fn iommu_wbuf_ctrl(&self) -> &IOMMU_WBUF_CTRL

0x44 - IOMMU Write Buffer Control Register

Source

pub fn iommu_ooo_ctrl(&self) -> &IOMMU_OOO_CTRL

0x48 - IOMMU Out of Order Control Register

Source

pub fn iommu_4kb_bdy_prt_ctrl(&self) -> &IOMMU_4KB_BDY_PRT_CTRL

0x4c - IOMMU 4KB Boundary Protect Control Register

Source

pub fn iommu_ttb(&self) -> &IOMMU_TTB

0x50 - IOMMU Translation Table Base Register

Source

pub fn iommu_tlb_enable(&self) -> &IOMMU_TLB_ENABLE

0x60 - IOMMU TLB Enable Register

Source

pub fn iommu_tlb_prefetch(&self) -> &IOMMU_TLB_PREFETCH

0x70 - IOMMU TLB Prefetch Register

Source

pub fn iommu_tlb_flush_enable(&self) -> &IOMMU_TLB_FLUSH_ENABLE

0x80 - IOMMU TLB Flush Enable Register

Source

pub fn iommu_tlb_ivld_mode_sel(&self) -> &IOMMU_TLB_IVLD_MODE_SEL

0x84 - IOMMU TLB Invalidation Mode Select Register

Source

pub fn iommu_tlb_ivld_sta_addr(&self) -> &IOMMU_TLB_IVLD_STA_ADDR

0x88 - IOMMU TLB Invalidation Start Address Register

Source

pub fn iommu_tlb_ivld_end_addr(&self) -> &IOMMU_TLB_IVLD_END_ADDR

0x8c - IOMMU TLB Invalidation End Address Register

Source

pub fn iommu_tlb_ivld_addr(&self) -> &IOMMU_TLB_IVLD_ADDR

0x90 - IOMMU TLB Invalidation Address Register

Source

pub fn iommu_tlb_ivld_addr_mask(&self) -> &IOMMU_TLB_IVLD_ADDR_MASK

0x94 - IOMMU TLB Invalidation Address Mask Register

Source

pub fn iommu_tlb_ivld_enable(&self) -> &IOMMU_TLB_IVLD_ENABLE

0x98 - IOMMU TLB Invalidation Enable Register

Source

pub fn iommu_pc_ivld_mode_sel(&self) -> &IOMMU_PC_IVLD_MODE_SEL

0x9c - IOMMU PC Invalidation Mode Select Register

Source

pub fn iommu_pc_ivld_addr(&self) -> &IOMMU_PC_IVLD_ADDR

0xa0 - IOMMU PC Invalidation Address Register

Source

pub fn iommu_pc_ivld_sta_addr(&self) -> &IOMMU_PC_IVLD_STA_ADDR

0xa4 - IOMMU PC Invalidation Start Address Register

Source

pub fn iommu_pc_ivld_enable(&self) -> &IOMMU_PC_IVLD_ENABLE

0xa8 - IOMMU PC Invalidation Enable Register

Source

pub fn iommu_pc_ivld_end_addr(&self) -> &IOMMU_PC_IVLD_END_ADDR

0xac - IOMMU PC Invalidation End Address Register

Source

pub fn iommu_dm_aut_ctrl(&self, n: usize) -> &IOMMU_DM_AUT_CTRL

0xb0..0xd0 - IOMMU Domain Authority Control [i] Register

Software can set 15 different permission control types in IOMMU_DM_AUT_CTRL0-7. A default access control type is DOMAIN0. The read/write operation of DOMAIN1-15 is unlimited by default.

Software needs to set the index of the permission control domain corresponding to the page table item in the bit[7:4] of the Level2 page table, the default value is 0 (use domain 0), that is, the read/write operation is not controlled.

Setting REG_ARD_OVWT can mask the Domain control defined by IOMMU_DM_AUT_CTRL0-7. All Level2 page table type are covered by the type of REG_ARD_OVWT. The read/write operation is permitted by default.

Source

pub fn iommu_dm_aut_ovwt(&self) -> &IOMMU_DM_AUT_OVWT

0xd0 - IOMMU Domain Authority Overwrite Register

Source

pub fn iommu_int_enable(&self) -> &IOMMU_INT_ENABLE

0x100 - IOMMU Interrupt Enable Register

Source

pub fn iommu_int_clr(&self) -> &IOMMU_INT_CLR

0x104 - IOMMU Interrupt Clear Register

Source

pub fn iommu_int_sta(&self) -> &IOMMU_INT_STA

0x108 - IOMMU Interrupt Status Register

Source

pub fn iommu_int_err_addr_tlb(&self, n: usize) -> &IOMMU_INT_ERR_ADDR_TLB

0x110..0x12c - IOMMU Interrupt Error Address [i]

Source

pub fn iommu_int_err_addr_l(&self, n: usize) -> &IOMMU_INT_ERR_ADDR_L

0x130..0x138 - IOMMU Interrupt Error Address L[i]

Source

pub fn iommu_int_err_data_tlb(&self, n: usize) -> &IOMMU_INT_ERR_DATA_TLB

0x150..0x16c - IOMMU Interrupt Error Data [i] Register

Source

pub fn iommu_int_err_data_l(&self, n: usize) -> &IOMMU_INT_ERR_DATA_L

0x170..0x178 - IOMMU Interrupt Error Data L[i] Register

Source

pub fn iommu_lpg_int(&self, n: usize) -> &IOMMU_LPG_INT

0x180..0x188 - IOMMU L[i] Page Table Interrupt Register

Source

pub fn iommu_l0pg_int(&self) -> &IOMMU_LPG_INT

0x180 - IOMMU L[i] Page Table Interrupt Register

Source

pub fn iommu_l1pg_int(&self) -> &IOMMU_LPG_INT

0x184 - IOMMU L[i] Page Table Interrupt Register

Source

pub fn iommu_va(&self) -> &IOMMU_VA

0x190 - IOMMU Virtual Address Register

Source

pub fn iommu_va_data(&self) -> &IOMMU_VA_DATA

0x194 - IOMMU Virtual Address Data Register

Source

pub fn iommu_va_config(&self) -> &IOMMU_VA_CONFIG

0x198 - IOMMU Virtual Address Configuration Register

Source

pub fn iommu_pmu_enable(&self) -> &IOMMU_PMU_ENABLE

0x200 - IOMMU PMU Enable Register

Source

pub fn iommu_pmu_clr(&self) -> &IOMMU_PMU_CLR

0x210 - IOMMU PMU Clear Register

Source

pub fn iommu_pmu_access_low(&self, n: usize) -> &IOMMU_PMU_ACCESS_LOW

0x230..0x254 - IOMMU PMU Access Low [i] Register

Source

pub fn iommu_pmu_access_high(&self, n: usize) -> &IOMMU_PMU_ACCESS_HIGH

0x234..0x258 - IOMMU PMU Access High [i] Register

Source

pub fn iommu_pmu_hit_low(&self, n: usize) -> &IOMMU_PMU_HIT_LOW

0x238..0x25c - IOMMU PMU Hit Low [i] Register

Source

pub fn iommu_pmu_hit_high(&self, n: usize) -> &IOMMU_PMU_HIT_HIGH

0x23c..0x260 - IOMMU PMU Hit High [i] Register

Source

pub fn iommu_pmu_tl_low(&self, n: usize) -> &IOMMU_PMU_TL_LOW

0x300..0x31c - IOMMU Total Latency Low [i] Register

Source

pub fn iommu_pmu_tl_high(&self, n: usize) -> &IOMMU_PMU_TL_HIGH

0x304..0x320 - IOMMU Total Latency High [i] Register

Source

pub fn iommu_pmu_ml(&self, n: usize) -> &IOMMU_PMU_ML

0x308..0x324 - IOMMU Max Latency [i] Register

Trait Implementations§

Source§

impl Debug for IOMMU

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Deref for IOMMU

Source§

type Target = RegisterBlock

The resulting type after dereferencing.
Source§

fn deref(&self) -> &Self::Target

Dereferences the value.
Source§

impl Send for IOMMU

Auto Trait Implementations§

§

impl !Sync for IOMMU

§

impl Freeze for IOMMU

§

impl RefUnwindSafe for IOMMU

§

impl Unpin for IOMMU

§

impl UnsafeUnpin for IOMMU

§

impl UnwindSafe for IOMMU

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<P, T> Receiver for P
where P: Deref<Target = T> + ?Sized, T: ?Sized,

Source§

type Target = T

🔬This is a nightly-only experimental API. (arbitrary_self_types)
The target type on which the method may be called.
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.