Skip to main content

ControlAndStatusRegisterEncoding

Trait ControlAndStatusRegisterEncoding 

Source
pub trait ControlAndStatusRegisterEncoding {
    type Access: Accessible;

    const VALUE: u16;
    const VALID: ();
}
Expand description

Marker for a riscv64 CSR, expressing its encoding and access permissions.

Required Associated Constants§

Source

const VALUE: u16

The register’s 12-bit encoding value.

Source

const VALID: ()

Whether the encoding is valid.

Required Associated Types§

Source

type Access: Accessible

The register’s access permissions.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<const ENCODING: u16> ControlAndStatusRegisterEncoding for CsrEncoding<ENCODING, Ro>

Source§

const VALUE: u16 = ENCODING

Source§

const VALID: ()

Source§

type Access = (Read, NoWrite)

Source§

impl<const ENCODING: u16> ControlAndStatusRegisterEncoding for CsrEncoding<ENCODING, RwSafe>

Source§

const VALUE: u16 = ENCODING

Source§

const VALID: ()

Source§

type Access = (Read, SafeWrite)

Source§

impl<const ENCODING: u16> ControlAndStatusRegisterEncoding for CsrEncoding<ENCODING, RwUnsafe>

Source§

const VALUE: u16 = ENCODING

Source§

const VALID: ()

Source§

type Access = (Read, UnsafeWrite)

Source§

impl<const ENCODING: u16> ControlAndStatusRegisterEncoding for CsrEncoding<ENCODING, WoSafe>

Source§

const VALUE: u16 = ENCODING

Source§

const VALID: ()

Source§

type Access = (NoRead, SafeWrite)

Source§

impl<const ENCODING: u16> ControlAndStatusRegisterEncoding for CsrEncoding<ENCODING, WoUnsafe>

Source§

const VALUE: u16 = ENCODING

Source§

const VALID: ()

Source§

type Access = (NoRead, UnsafeWrite)