FreeNOS
Public Member Functions
ARM64IO Class Reference

Input/Output operations specific to the ARM architecture. More...

#include <ARM64IO.h>

Inheritance diagram for ARM64IO:
IO

Public Member Functions

void write (u64 reg, u32 data)
 write to memory mapped I/O register
 
u32 read (u64 reg) const
 read from memory mapped I/O register
 
void read (Address addr, Size count, void *buf) const
 Read a number of 32-bit values.
 
void write (Address addr, Size count, const void *buf)
 Write a number of 32-bit values.
 
void set (Address addr, u32 data)
 Set bits in memory mapped register.
 
void unset (Address addr, u32 data)
 Unset bits in memory mapped register.
 
- Public Member Functions inherited from IO
 IO ()
 Constructor.
 
Address getBase () const
 Get memory I/O base offset.
 
void setBase (const Address base)
 Set memory I/O base offset.
 
Result map (Address phys, Size size=4096, Memory::Access access=Memory::Readable|Memory::Writable|Memory::User)
 Map I/O address space.
 
Result unmap ()
 Unmap I/O address space.
 

Additional Inherited Members

- Public Types inherited from IO
enum  Result { Success , MapFailure , OutOfMemory }
 Result codes. More...
 
- Protected Attributes inherited from IO
Address m_base
 memory I/O base offset is added to each I/O address.
 
Memory::Range m_range
 Memory range for performing I/O mappings.
 

Detailed Description

Input/Output operations specific to the ARM architecture.

Definition at line 40 of file ARM64IO.h.

Member Function Documentation

◆ read() [1/2]

void ARM64IO::read ( Address  addr,
Size  count,
void *  buf 
) const
inline

Read a number of 32-bit values.

Parameters
addrAddress of the starting 32-bit value.
countNumber of bytes to read.
bufOutput buffer.

Definition at line 80 of file ARM64IO.h.

References read().

◆ read() [2/2]

u32 ARM64IO::read ( u64  reg) const
inline

read from memory mapped I/O register

Parameters
regAddress to read
Returns
64-bit value

Definition at line 62 of file ARM64IO.h.

References dmb, and IO::m_base.

Referenced by read(), set(), and unset().

◆ set()

void ARM64IO::set ( Address  addr,
u32  data 
)
inline

Set bits in memory mapped register.

Parameters
addrAddress of the register to write.
data64-bit value containing the bits to set (bitwise or).

Definition at line 109 of file ARM64IO.h.

References read(), and write().

◆ unset()

void ARM64IO::unset ( Address  addr,
u32  data 
)
inline

Unset bits in memory mapped register.

Parameters
addrAddress of the register to write.
data64-bit value containing the bits to set (bitwise or).

Definition at line 122 of file ARM64IO.h.

References read(), and write().

◆ write() [1/2]

void ARM64IO::write ( Address  addr,
Size  count,
const void *  buf 
)
inline

Write a number of 32-bit values.

Parameters
addrAddress of the starting 32-bit value.
countNumber of bytes to write.
bufInput buffer.

Definition at line 95 of file ARM64IO.h.

References write().

◆ write() [2/2]

void ARM64IO::write ( u64  reg,
u32  data 
)
inline

write to memory mapped I/O register

Definition at line 46 of file ARM64IO.h.

References dmb, and IO::m_base.

Referenced by set(), unset(), and write().


The documentation for this class was generated from the following file: