annotate target-utils/libbase/waitarm.S @ 479:f2a040324509

Makefile hierarchy: CFLAGS override-ability actually works now The original version was broken in that CFLAGS=${CFLAGS} passing was done without quotes, which breaks as soon as there is a space in the user-set CFLAGS. Changing it to CFLAGS="${CFLAGS}" makes it work as originally intended.
author Mychaela Falconia <falcon@freecalypso.org>
date Thu, 14 Feb 2019 04:59:23 +0000
parents 6228d27738d1
children 06ad5e30e8d0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
453
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 /*
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 * This assembly module provides a wait_ARM_cycles() function just like
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 * in TI's firmware; it is meant to gradually replace and phase out
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 * osmo_delay_ms(). One loop count for this function equals 5 ARM clock
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 * cycles when running out of IRAM.
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 */
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 .text
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9 .code 32
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 .globl wait_ARM_cycles
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 wait_ARM_cycles:
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 cmp r0, #0
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 bxeq lr
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 1: sub r0, r0, #1
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 cmp r0, #0
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16 bne 1b
6228d27738d1 target-utils: wait_ARM_cycles() added to libbase
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 bx lr