NUC123 USB driver: fix off-by-one error when copying unaligned memory to/from USB SRAM buffer
This commit is contained in:
parent
6a5f58e1e5
commit
ad580f5b2f
|
@ -148,9 +148,9 @@ unaligned:
|
||||||
str r5, [r4, #16]
|
str r5, [r4, #16]
|
||||||
|
|
||||||
unaligned_loop_top:
|
unaligned_loop_top:
|
||||||
|
subs r2, r2, #1
|
||||||
ldrb r5, [r1, r2]
|
ldrb r5, [r1, r2]
|
||||||
strb r5, [r0, r2]
|
strb r5, [r0, r2]
|
||||||
subs r2, r2, #1
|
|
||||||
unaligned_loop_check:
|
unaligned_loop_check:
|
||||||
bne.n unaligned_loop_top
|
bne.n unaligned_loop_top
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue