Skip to content

Commit d981377

Browse files
committed
fix clippy messages
1 parent 1d28859 commit d981377

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

riscv/CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
2626

2727
- Fixed `sip::set_ssoft` and `sip::clear_ssoft` using wrong address
2828
- Fixed assignment in `mstatus` unit tests.
29+
- delay implementation does not use binary labels in inline assembly.
2930

3031
## [v0.11.1] - 2024-02-15
3132

riscv/src/asm.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -149,9 +149,9 @@ pub fn delay(cycles: u32) {
149149
() => unsafe {
150150
let real_cyc = 1 + cycles / 2;
151151
core::arch::asm!(
152-
"1:",
152+
"2:",
153153
"addi {0}, {0}, -1",
154-
"bne {0}, zero, 1b",
154+
"bne {0}, zero, 2b",
155155
inout(reg) real_cyc => _,
156156
options(nomem, nostack),
157157
)

0 commit comments

Comments
 (0)