Artifact
f86d6e6c494fc5419080f60f1dd8bd7caf4f3ff2:
0000: 2f 2a 20 49 6e 73 74 72 75 63 74 69 6f 6e 20 63 /* Instruction c
0010: 61 63 68 65 20 66 6c 75 73 68 69 6e 67 20 66 6f ache flushing fo
0020: 72 20 61 72 6d 20 2a 2f 0a 0a 2f 2a 0a 20 2a 20 r arm */../*. *
0030: 43 6f 70 79 72 69 67 68 74 20 31 39 39 37 20 42 Copyright 1997 B
0040: 72 75 6e 6f 20 48 61 69 62 6c 65 2c 20 3c 62 72 runo Haible, <br
0050: 75 6e 6f 40 63 6c 69 73 70 2e 6f 72 67 3e 0a 20 uno@clisp.org>.
0060: 2a 0a 20 2a 20 54 68 69 73 20 69 73 20 66 72 65 *. * This is fre
0070: 65 20 73 6f 66 74 77 61 72 65 20 64 69 73 74 72 e software distr
0080: 69 62 75 74 65 64 20 75 6e 64 65 72 20 74 68 65 ibuted under the
0090: 20 47 4e 55 20 47 65 6e 65 72 61 6c 20 50 75 62 GNU General Pub
00a0: 6c 69 63 20 4c 69 63 65 6e 63 65 0a 20 2a 20 64 lic Licence. * d
00b0: 65 73 63 72 69 62 65 64 20 69 6e 20 74 68 65 20 escribed in the
00c0: 66 69 6c 65 20 43 4f 50 59 49 4e 47 2e 20 43 6f file COPYING. Co
00d0: 6e 74 61 63 74 20 74 68 65 20 61 75 74 68 6f 72 ntact the author
00e0: 20 69 66 20 79 6f 75 20 64 6f 6e 27 74 20 68 61 if you don't ha
00f0: 76 65 20 74 68 69 73 0a 20 2a 20 6f 72 20 63 61 ve this. * or ca
0100: 6e 27 74 20 6c 69 76 65 20 77 69 74 68 20 69 74 n't live with it
0110: 2e 20 54 68 65 72 65 20 69 73 20 41 42 53 4f 4c . There is ABSOL
0120: 55 54 45 4c 59 20 4e 4f 20 57 41 52 52 41 4e 54 UTELY NO WARRANT
0130: 59 2c 20 65 78 70 6c 69 63 69 74 20 6f 72 20 69 Y, explicit or i
0140: 6d 70 6c 69 65 64 2c 0a 20 2a 20 6f 6e 20 74 68 mplied,. * on th
0150: 69 73 20 73 6f 66 74 77 61 72 65 2e 0a 20 2a 2f is software.. */
0160: 0a 23 69 6e 63 6c 75 64 65 20 3c 6c 69 6e 75 78 .#include <linux
0170: 2f 75 6e 69 73 74 64 2e 68 3e 0a 0a 76 6f 69 64 /unistd.h>..void
0180: 20 5f 5f 54 52 5f 63 6c 65 61 72 5f 63 61 63 68 __TR_clear_cach
0190: 65 20 28 63 68 61 72 20 2a 66 69 72 73 74 5f 61 e (char *first_a
01a0: 64 64 72 2c 20 63 68 61 72 20 2a 6c 61 73 74 5f ddr, char *last_
01b0: 61 64 64 72 29 0a 7b 0a 20 20 61 73 6d 20 76 6f addr).{. asm vo
01c0: 6c 61 74 69 6c 65 20 28 22 73 77 69 20 25 30 22 latile ("swi %0"
01d0: 20 3a 20 3a 20 22 69 22 20 28 5f 5f 41 52 4d 5f : : "i" (__ARM_
01e0: 4e 52 5f 63 61 63 68 65 66 6c 75 73 68 29 29 3b NR_cacheflush));
01f0: 0a 7d 0a .}.