Skip to content

Commit c0e7dcb

Browse files
committed
don't expose registers clidr, ctr, ccsidr, csselr to ARMv6-M targets
as these are only available on ARMv7-M devices closes #46
1 parent cba4bef commit c0e7dcb

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/peripheral/mod.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,12 +104,16 @@ pub struct Cpuid {
104104
pub isar: [RO<u32>; 5],
105105
reserved1: u32,
106106
/// Cache Level ID
107+
#[cfg(armv7m)]
107108
pub clidr: RO<u32>,
108109
/// Cache Type
110+
#[cfg(armv7m)]
109111
pub ctr: RO<u32>,
110112
/// Cache Size ID
113+
#[cfg(armv7m)]
111114
pub ccsidr: RO<u32>,
112115
/// Cache Size Selection
116+
#[cfg(armv7m)]
113117
pub csselr: RW<u32>,
114118
}
115119

0 commit comments

Comments
 (0)