cortex_a/registers/
cntfrq_el0.rs

1// SPDX-License-Identifier: Apache-2.0 OR MIT
2//
3// Copyright (c) 2018-2022 by the author(s)
4//
5// Author(s):
6//   - Andre Richter <andre.o.richter@gmail.com>
7
8//! Counter-timer Frequency register - EL0
9//!
10//! This register is provided so that software can discover the frequency of the system counter. It
11//! must be programmed with this value as part of system initialization. The value of the register
12//! is not interpreted by hardware.
13
14use tock_registers::interfaces::Readable;
15
16pub struct Reg;
17
18impl Readable for Reg {
19    type T = u64;
20    type R = ();
21
22    sys_coproc_read_raw!(u64, "CNTFRQ_EL0", "x");
23}
24
25pub const CNTFRQ_EL0: Reg = Reg {};