Satyajit Desai | 66b6c45 | 2017-06-27 17:10:46 -0700 | [diff] [blame] | 1 | /* Copyright (c) 2015-2017, The Linux Foundation. All rights reserved. |
| 2 | * |
| 3 | * This program is free software; you can redistribute it and/or modify |
| 4 | * it under the terms of the GNU General Public License version 2 and |
| 5 | * only version 2 as published by the Free Software Foundation. |
| 6 | * |
| 7 | * This program is distributed in the hope that it will be useful, |
| 8 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 9 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 10 | * GNU General Public License for more details. |
| 11 | */ |
| 12 | |
| 13 | #ifndef __ASM_ETMV4X_H |
| 14 | #define __ASM_ETMV4X_H |
| 15 | |
| 16 | #include <linux/types.h> |
| 17 | |
| 18 | /* 32 bit register reads for AArch64 */ |
| 19 | #define trc_readl(reg) RSYSL_##reg() |
| 20 | /* 64 bit register reads for AArch64 */ |
| 21 | #define trc_readq(reg) RSYSQ_##reg() |
| 22 | /* 32 and 64 bit register writes for AArch64 */ |
| 23 | #define trc_write(val, reg) WSYS_##reg(val) |
| 24 | |
| 25 | #define MRSL(op0, op1, crn, crm, op2) \ |
| 26 | ({ \ |
| 27 | uint32_t val; \ |
| 28 | asm volatile("mrs %0, S"#op0"_"#op1"_"#crn"_"#crm"_"#op2 : "=r" (val)); \ |
| 29 | val; \ |
| 30 | }) |
| 31 | |
| 32 | #define MRSQ(op0, op1, crn, crm, op2) \ |
| 33 | ({ \ |
| 34 | uint64_t val; \ |
| 35 | asm volatile("mrs %0, S"#op0"_"#op1"_"#crn"_"#crm"_"#op2 : "=r" (val)); \ |
| 36 | val; \ |
| 37 | }) |
| 38 | |
| 39 | #define MSR(val, op0, op1, crn, crm, op2) \ |
| 40 | ({ \ |
| 41 | asm volatile("msr S"#op0"_"#op1"_"#crn"_"#crm"_"#op2", %0" : : "r" (val)); \ |
| 42 | }) |
| 43 | |
| 44 | /* Clock and Power Management Register */ |
| 45 | #define RSYSL_CPMR_EL1() MRSL(3, 7, c15, c0, 5) |
| 46 | #define WSYS_CPMR_EL1(val) MSR(val, 3, 7, c15, c0, 5) |
| 47 | |
| 48 | /* |
| 49 | * ETMv4 Registers |
| 50 | * |
| 51 | * Read only |
| 52 | * ETMAUTHSTATUS, ETMDEVARCH, ETMDEVID, ETMIDRn[0-13], ETMOSLSR, ETMSTATR |
| 53 | * |
| 54 | * Write only |
| 55 | * ETMOSLAR |
| 56 | */ |
| 57 | /* 32 bit registers */ |
| 58 | #define RSYSL_ETMAUTHSTATUS() MRSL(2, 1, c7, c14, 6) |
| 59 | #define RSYSL_ETMAUXCTLR() MRSL(2, 1, c0, c6, 0) |
| 60 | #define RSYSL_ETMCCCTLR() MRSL(2, 1, c0, c14, 0) |
| 61 | #define RSYSL_ETMCIDCCTLR0() MRSL(2, 1, c3, c0, 2) |
| 62 | #define RSYSL_ETMCNTCTLR0() MRSL(2, 1, c0, c4, 5) |
| 63 | #define RSYSL_ETMCNTCTLR1() MRSL(2, 1, c0, c5, 5) |
| 64 | #define RSYSL_ETMCNTCTLR2() MRSL(2, 1, c0, c6, 5) |
| 65 | #define RSYSL_ETMCNTCTLR3() MRSL(2, 1, c0, c7, 5) |
| 66 | #define RSYSL_ETMCNTRLDVR0() MRSL(2, 1, c0, c0, 5) |
| 67 | #define RSYSL_ETMCNTRLDVR1() MRSL(2, 1, c0, c1, 5) |
| 68 | #define RSYSL_ETMCNTRLDVR2() MRSL(2, 1, c0, c2, 5) |
| 69 | #define RSYSL_ETMCNTRLDVR3() MRSL(2, 1, c0, c3, 5) |
| 70 | #define RSYSL_ETMCNTVR0() MRSL(2, 1, c0, c8, 5) |
| 71 | #define RSYSL_ETMCNTVR1() MRSL(2, 1, c0, c9, 5) |
| 72 | #define RSYSL_ETMCNTVR2() MRSL(2, 1, c0, c10, 5) |
| 73 | #define RSYSL_ETMCNTVR3() MRSL(2, 1, c0, c11, 5) |
| 74 | #define RSYSL_ETMCONFIGR() MRSL(2, 1, c0, c4, 0) |
| 75 | #define RSYSL_ETMDEVARCH() MRSL(2, 1, c7, c15, 6) |
| 76 | #define RSYSL_ETMDEVID() MRSL(2, 1, c7, c2, 7) |
| 77 | #define RSYSL_ETMEVENTCTL0R() MRSL(2, 1, c0, c8, 0) |
| 78 | #define RSYSL_ETMEVENTCTL1R() MRSL(2, 1, c0, c9, 0) |
| 79 | #define RSYSL_ETMEXTINSELR() MRSL(2, 1, c0, c8, 4) |
| 80 | #define RSYSL_ETMIDR0() MRSL(2, 1, c0, c8, 7) |
| 81 | #define RSYSL_ETMIDR1() MRSL(2, 1, c0, c9, 7) |
| 82 | #define RSYSL_ETMIDR10() MRSL(2, 1, c0, c2, 6) |
| 83 | #define RSYSL_ETMIDR11() MRSL(2, 1, c0, c3, 6) |
| 84 | #define RSYSL_ETMIDR12() MRSL(2, 1, c0, c4, 6) |
| 85 | #define RSYSL_ETMIDR13() MRSL(2, 1, c0, c5, 6) |
| 86 | #define RSYSL_ETMIDR2() MRSL(2, 1, c0, c10, 7) |
| 87 | #define RSYSL_ETMIDR3() MRSL(2, 1, c0, c11, 7) |
| 88 | #define RSYSL_ETMIDR4() MRSL(2, 1, c0, c12, 7) |
| 89 | #define RSYSL_ETMIDR5() MRSL(2, 1, c0, c13, 7) |
| 90 | #define RSYSL_ETMIDR6() MRSL(2, 1, c0, c14, 7) |
| 91 | #define RSYSL_ETMIDR7() MRSL(2, 1, c0, c15, 7) |
| 92 | #define RSYSL_ETMIDR8() MRSL(2, 1, c0, c0, 6) |
| 93 | #define RSYSL_ETMIDR9() MRSL(2, 1, c0, c1, 6) |
| 94 | #define RSYSL_ETMIMSPEC0() MRSL(2, 1, c0, c0, 7) |
| 95 | #define RSYSL_ETMOSLSR() MRSL(2, 1, c1, c1, 4) |
| 96 | #define RSYSL_ETMPRGCTLR() MRSL(2, 1, c0, c1, 0) |
| 97 | #define RSYSL_ETMRSCTLR10() MRSL(2, 1, c1, c10, 0) |
| 98 | #define RSYSL_ETMRSCTLR11() MRSL(2, 1, c1, c11, 0) |
| 99 | #define RSYSL_ETMRSCTLR12() MRSL(2, 1, c1, c12, 0) |
| 100 | #define RSYSL_ETMRSCTLR13() MRSL(2, 1, c1, c13, 0) |
| 101 | #define RSYSL_ETMRSCTLR14() MRSL(2, 1, c1, c14, 0) |
| 102 | #define RSYSL_ETMRSCTLR15() MRSL(2, 1, c1, c15, 0) |
| 103 | #define RSYSL_ETMRSCTLR2() MRSL(2, 1, c1, c2, 0) |
| 104 | #define RSYSL_ETMRSCTLR3() MRSL(2, 1, c1, c3, 0) |
| 105 | #define RSYSL_ETMRSCTLR4() MRSL(2, 1, c1, c4, 0) |
| 106 | #define RSYSL_ETMRSCTLR5() MRSL(2, 1, c1, c5, 0) |
| 107 | #define RSYSL_ETMRSCTLR6() MRSL(2, 1, c1, c6, 0) |
| 108 | #define RSYSL_ETMRSCTLR7() MRSL(2, 1, c1, c7, 0) |
| 109 | #define RSYSL_ETMRSCTLR8() MRSL(2, 1, c1, c8, 0) |
| 110 | #define RSYSL_ETMRSCTLR9() MRSL(2, 1, c1, c9, 0) |
| 111 | #define RSYSL_ETMRSCTLR16() MRSL(2, 1, c1, c0, 1) |
| 112 | #define RSYSL_ETMRSCTLR17() MRSL(2, 1, c1, c1, 1) |
| 113 | #define RSYSL_ETMRSCTLR18() MRSL(2, 1, c1, c2, 1) |
| 114 | #define RSYSL_ETMRSCTLR19() MRSL(2, 1, c1, c3, 1) |
| 115 | #define RSYSL_ETMRSCTLR20() MRSL(2, 1, c1, c4, 1) |
| 116 | #define RSYSL_ETMRSCTLR21() MRSL(2, 1, c1, c5, 1) |
| 117 | #define RSYSL_ETMRSCTLR22() MRSL(2, 1, c1, c6, 1) |
| 118 | #define RSYSL_ETMRSCTLR23() MRSL(2, 1, c1, c7, 1) |
| 119 | #define RSYSL_ETMRSCTLR24() MRSL(2, 1, c1, c8, 1) |
| 120 | #define RSYSL_ETMRSCTLR25() MRSL(2, 1, c1, c9, 1) |
| 121 | #define RSYSL_ETMRSCTLR26() MRSL(2, 1, c1, c10, 1) |
| 122 | #define RSYSL_ETMRSCTLR27() MRSL(2, 1, c1, c11, 1) |
| 123 | #define RSYSL_ETMRSCTLR28() MRSL(2, 1, c1, c12, 1) |
| 124 | #define RSYSL_ETMRSCTLR29() MRSL(2, 1, c1, c13, 1) |
| 125 | #define RSYSL_ETMRSCTLR30() MRSL(2, 1, c1, c14, 1) |
| 126 | #define RSYSL_ETMRSCTLR31() MRSL(2, 1, c1, c15, 1) |
| 127 | #define RSYSL_ETMSEQEVR0() MRSL(2, 1, c0, c0, 4) |
| 128 | #define RSYSL_ETMSEQEVR1() MRSL(2, 1, c0, c1, 4) |
| 129 | #define RSYSL_ETMSEQEVR2() MRSL(2, 1, c0, c2, 4) |
| 130 | #define RSYSL_ETMSEQRSTEVR() MRSL(2, 1, c0, c6, 4) |
| 131 | #define RSYSL_ETMSEQSTR() MRSL(2, 1, c0, c7, 4) |
| 132 | #define RSYSL_ETMSTALLCTLR() MRSL(2, 1, c0, c11, 0) |
| 133 | #define RSYSL_ETMSTATR() MRSL(2, 1, c0, c3, 0) |
| 134 | #define RSYSL_ETMSYNCPR() MRSL(2, 1, c0, c13, 0) |
| 135 | #define RSYSL_ETMTRACEIDR() MRSL(2, 1, c0, c0, 1) |
| 136 | #define RSYSL_ETMTSCTLR() MRSL(2, 1, c0, c12, 0) |
| 137 | #define RSYSL_ETMVICTLR() MRSL(2, 1, c0, c0, 2) |
| 138 | #define RSYSL_ETMVIIECTLR() MRSL(2, 1, c0, c1, 2) |
| 139 | #define RSYSL_ETMVISSCTLR() MRSL(2, 1, c0, c2, 2) |
| 140 | #define RSYSL_ETMSSCCR0() MRSL(2, 1, c1, c0, 2) |
| 141 | #define RSYSL_ETMSSCCR1() MRSL(2, 1, c1, c1, 2) |
| 142 | #define RSYSL_ETMSSCCR2() MRSL(2, 1, c1, c2, 2) |
| 143 | #define RSYSL_ETMSSCCR3() MRSL(2, 1, c1, c3, 2) |
| 144 | #define RSYSL_ETMSSCCR4() MRSL(2, 1, c1, c4, 2) |
| 145 | #define RSYSL_ETMSSCCR5() MRSL(2, 1, c1, c5, 2) |
| 146 | #define RSYSL_ETMSSCCR6() MRSL(2, 1, c1, c6, 2) |
| 147 | #define RSYSL_ETMSSCCR7() MRSL(2, 1, c1, c7, 2) |
| 148 | #define RSYSL_ETMSSCSR0() MRSL(2, 1, c1, c8, 2) |
| 149 | #define RSYSL_ETMSSCSR1() MRSL(2, 1, c1, c9, 2) |
| 150 | #define RSYSL_ETMSSCSR2() MRSL(2, 1, c1, c10, 2) |
| 151 | #define RSYSL_ETMSSCSR3() MRSL(2, 1, c1, c11, 2) |
| 152 | #define RSYSL_ETMSSCSR4() MRSL(2, 1, c1, c12, 2) |
| 153 | #define RSYSL_ETMSSCSR5() MRSL(2, 1, c1, c13, 2) |
| 154 | #define RSYSL_ETMSSCSR6() MRSL(2, 1, c1, c14, 2) |
| 155 | #define RSYSL_ETMSSCSR7() MRSL(2, 1, c1, c15, 2) |
| 156 | #define RSYSL_ETMSSPCICR0() MRSL(2, 1, c1, c0, 3) |
| 157 | #define RSYSL_ETMSSPCICR1() MRSL(2, 1, c1, c1, 3) |
| 158 | #define RSYSL_ETMSSPCICR2() MRSL(2, 1, c1, c2, 3) |
| 159 | #define RSYSL_ETMSSPCICR3() MRSL(2, 1, c1, c3, 3) |
| 160 | #define RSYSL_ETMSSPCICR4() MRSL(2, 1, c1, c4, 3) |
| 161 | #define RSYSL_ETMSSPCICR5() MRSL(2, 1, c1, c5, 3) |
| 162 | #define RSYSL_ETMSSPCICR6() MRSL(2, 1, c1, c6, 3) |
| 163 | #define RSYSL_ETMSSPCICR7() MRSL(2, 1, c1, c7, 3) |
| 164 | |
| 165 | /* 64 bit registers */ |
| 166 | #define RSYSQ_ETMACATR0() MRSQ(2, 1, c2, c0, 2) |
| 167 | #define RSYSQ_ETMACATR1() MRSQ(2, 1, c2, c2, 2) |
| 168 | #define RSYSQ_ETMACATR2() MRSQ(2, 1, c2, c4, 2) |
| 169 | #define RSYSQ_ETMACATR3() MRSQ(2, 1, c2, c6, 2) |
| 170 | #define RSYSQ_ETMACATR4() MRSQ(2, 1, c2, c8, 2) |
| 171 | #define RSYSQ_ETMACATR5() MRSQ(2, 1, c2, c10, 2) |
| 172 | #define RSYSQ_ETMACATR6() MRSQ(2, 1, c2, c12, 2) |
| 173 | #define RSYSQ_ETMACATR7() MRSQ(2, 1, c2, c14, 2) |
| 174 | #define RSYSQ_ETMACATR8() MRSQ(2, 1, c2, c0, 3) |
| 175 | #define RSYSQ_ETMACATR9() MRSQ(2, 1, c2, c2, 3) |
| 176 | #define RSYSQ_ETMACATR10() MRSQ(2, 1, c2, c4, 3) |
| 177 | #define RSYSQ_ETMACATR11() MRSQ(2, 1, c2, c6, 3) |
| 178 | #define RSYSQ_ETMACATR12() MRSQ(2, 1, c2, c8, 3) |
| 179 | #define RSYSQ_ETMACATR13() MRSQ(2, 1, c2, c10, 3) |
| 180 | #define RSYSQ_ETMACATR14() MRSQ(2, 1, c2, c12, 3) |
| 181 | #define RSYSQ_ETMACATR15() MRSQ(2, 1, c2, c14, 3) |
| 182 | #define RSYSQ_ETMCIDCVR0() MRSQ(2, 1, c3, c0, 0) |
| 183 | #define RSYSQ_ETMCIDCVR1() MRSQ(2, 1, c3, c2, 0) |
| 184 | #define RSYSQ_ETMCIDCVR2() MRSQ(2, 1, c3, c4, 0) |
| 185 | #define RSYSQ_ETMCIDCVR3() MRSQ(2, 1, c3, c6, 0) |
| 186 | #define RSYSQ_ETMCIDCVR4() MRSQ(2, 1, c3, c8, 0) |
| 187 | #define RSYSQ_ETMCIDCVR5() MRSQ(2, 1, c3, c10, 0) |
| 188 | #define RSYSQ_ETMCIDCVR6() MRSQ(2, 1, c3, c12, 0) |
| 189 | #define RSYSQ_ETMCIDCVR7() MRSQ(2, 1, c3, c14, 0) |
| 190 | #define RSYSQ_ETMACVR0() MRSQ(2, 1, c2, c0, 0) |
| 191 | #define RSYSQ_ETMACVR1() MRSQ(2, 1, c2, c2, 0) |
| 192 | #define RSYSQ_ETMACVR2() MRSQ(2, 1, c2, c4, 0) |
| 193 | #define RSYSQ_ETMACVR3() MRSQ(2, 1, c2, c6, 0) |
| 194 | #define RSYSQ_ETMACVR4() MRSQ(2, 1, c2, c8, 0) |
| 195 | #define RSYSQ_ETMACVR5() MRSQ(2, 1, c2, c10, 0) |
| 196 | #define RSYSQ_ETMACVR6() MRSQ(2, 1, c2, c12, 0) |
| 197 | #define RSYSQ_ETMACVR7() MRSQ(2, 1, c2, c14, 0) |
| 198 | #define RSYSQ_ETMACVR8() MRSQ(2, 1, c2, c0, 1) |
| 199 | #define RSYSQ_ETMACVR9() MRSQ(2, 1, c2, c2, 1) |
| 200 | #define RSYSQ_ETMACVR10() MRSQ(2, 1, c2, c4, 1) |
| 201 | #define RSYSQ_ETMACVR11() MRSQ(2, 1, c2, c6, 1) |
| 202 | #define RSYSQ_ETMACVR12() MRSQ(2, 1, c2, c8, 1) |
| 203 | #define RSYSQ_ETMACVR13() MRSQ(2, 1, c2, c10, 1) |
| 204 | #define RSYSQ_ETMACVR14() MRSQ(2, 1, c2, c12, 1) |
| 205 | #define RSYSQ_ETMACVR15() MRSQ(2, 1, c2, c14, 1) |
| 206 | #define RSYSQ_ETMVMIDCVR0() MRSQ(2, 1, c3, c0, 1) |
| 207 | #define RSYSQ_ETMVMIDCVR1() MRSQ(2, 1, c3, c2, 1) |
| 208 | #define RSYSQ_ETMVMIDCVR2() MRSQ(2, 1, c3, c4, 1) |
| 209 | #define RSYSQ_ETMVMIDCVR3() MRSQ(2, 1, c3, c6, 1) |
| 210 | #define RSYSQ_ETMVMIDCVR4() MRSQ(2, 1, c3, c8, 1) |
| 211 | #define RSYSQ_ETMVMIDCVR5() MRSQ(2, 1, c3, c10, 1) |
| 212 | #define RSYSQ_ETMVMIDCVR6() MRSQ(2, 1, c3, c12, 1) |
| 213 | #define RSYSQ_ETMVMIDCVR7() MRSQ(2, 1, c3, c14, 1) |
| 214 | #define RSYSQ_ETMDVCVR0() MRSQ(2, 1, c2, c0, 4) |
| 215 | #define RSYSQ_ETMDVCVR1() MRSQ(2, 1, c2, c4, 4) |
| 216 | #define RSYSQ_ETMDVCVR2() MRSQ(2, 1, c2, c8, 4) |
| 217 | #define RSYSQ_ETMDVCVR3() MRSQ(2, 1, c2, c12, 4) |
| 218 | #define RSYSQ_ETMDVCVR4() MRSQ(2, 1, c2, c0, 5) |
| 219 | #define RSYSQ_ETMDVCVR5() MRSQ(2, 1, c2, c4, 5) |
| 220 | #define RSYSQ_ETMDVCVR6() MRSQ(2, 1, c2, c8, 5) |
| 221 | #define RSYSQ_ETMDVCVR7() MRSQ(2, 1, c2, c12, 5) |
| 222 | #define RSYSQ_ETMDVCMR0() MRSQ(2, 1, c2, c0, 6) |
| 223 | #define RSYSQ_ETMDVCMR1() MRSQ(2, 1, c2, c4, 6) |
| 224 | #define RSYSQ_ETMDVCMR2() MRSQ(2, 1, c2, c8, 6) |
| 225 | #define RSYSQ_ETMDVCMR3() MRSQ(2, 1, c2, c12, 6) |
| 226 | #define RSYSQ_ETMDVCMR4() MRSQ(2, 1, c2, c0, 7) |
| 227 | #define RSYSQ_ETMDVCMR5() MRSQ(2, 1, c2, c4, 7) |
| 228 | #define RSYSQ_ETMDVCMR6() MRSQ(2, 1, c2, c8, 7) |
| 229 | #define RSYSQ_ETMDVCMR7() MRSQ(2, 1, c2, c12, 7) |
| 230 | |
| 231 | /* 32 and 64 bit registers */ |
| 232 | #define WSYS_ETMAUXCTLR(val) MSR(val, 2, 1, c0, c6, 0) |
| 233 | #define WSYS_ETMACATR0(val) MSR(val, 2, 1, c2, c0, 2) |
| 234 | #define WSYS_ETMACATR1(val) MSR(val, 2, 1, c2, c2, 2) |
| 235 | #define WSYS_ETMACATR2(val) MSR(val, 2, 1, c2, c4, 2) |
| 236 | #define WSYS_ETMACATR3(val) MSR(val, 2, 1, c2, c6, 2) |
| 237 | #define WSYS_ETMACATR4(val) MSR(val, 2, 1, c2, c8, 2) |
| 238 | #define WSYS_ETMACATR5(val) MSR(val, 2, 1, c2, c10, 2) |
| 239 | #define WSYS_ETMACATR6(val) MSR(val, 2, 1, c2, c12, 2) |
| 240 | #define WSYS_ETMACATR7(val) MSR(val, 2, 1, c2, c14, 2) |
| 241 | #define WSYS_ETMACATR8(val) MSR(val, 2, 1, c2, c0, 3) |
| 242 | #define WSYS_ETMACATR9(val) MSR(val, 2, 1, c2, c2, 3) |
| 243 | #define WSYS_ETMACATR10(val) MSR(val, 2, 1, c2, c4, 3) |
| 244 | #define WSYS_ETMACATR11(val) MSR(val, 2, 1, c2, c6, 3) |
| 245 | #define WSYS_ETMACATR12(val) MSR(val, 2, 1, c2, c8, 3) |
| 246 | #define WSYS_ETMACATR13(val) MSR(val, 2, 1, c2, c10, 3) |
| 247 | #define WSYS_ETMACATR14(val) MSR(val, 2, 1, c2, c12, 3) |
| 248 | #define WSYS_ETMACATR15(val) MSR(val, 2, 1, c2, c14, 3) |
| 249 | #define WSYS_ETMACVR0(val) MSR(val, 2, 1, c2, c0, 0) |
| 250 | #define WSYS_ETMACVR1(val) MSR(val, 2, 1, c2, c2, 0) |
| 251 | #define WSYS_ETMACVR2(val) MSR(val, 2, 1, c2, c4, 0) |
| 252 | #define WSYS_ETMACVR3(val) MSR(val, 2, 1, c2, c6, 0) |
| 253 | #define WSYS_ETMACVR4(val) MSR(val, 2, 1, c2, c8, 0) |
| 254 | #define WSYS_ETMACVR5(val) MSR(val, 2, 1, c2, c10, 0) |
| 255 | #define WSYS_ETMACVR6(val) MSR(val, 2, 1, c2, c12, 0) |
| 256 | #define WSYS_ETMACVR7(val) MSR(val, 2, 1, c2, c14, 0) |
| 257 | #define WSYS_ETMACVR8(val) MSR(val, 2, 1, c2, c0, 1) |
| 258 | #define WSYS_ETMACVR9(val) MSR(val, 2, 1, c2, c2, 1) |
| 259 | #define WSYS_ETMACVR10(val) MSR(val, 2, 1, c2, c4, 1) |
| 260 | #define WSYS_ETMACVR11(val) MSR(val, 2, 1, c2, c6, 1) |
| 261 | #define WSYS_ETMACVR12(val) MSR(val, 2, 1, c2, c8, 1) |
| 262 | #define WSYS_ETMACVR13(val) MSR(val, 2, 1, c2, c10, 1) |
| 263 | #define WSYS_ETMACVR14(val) MSR(val, 2, 1, c2, c12, 1) |
| 264 | #define WSYS_ETMACVR15(val) MSR(val, 2, 1, c2, c14, 1) |
| 265 | #define WSYS_ETMCCCTLR(val) MSR(val, 2, 1, c0, c14, 0) |
| 266 | #define WSYS_ETMCIDCCTLR0(val) MSR(val, 2, 1, c3, c0, 2) |
| 267 | #define WSYS_ETMCIDCVR0(val) MSR(val, 2, 1, c3, c0, 0) |
| 268 | #define WSYS_ETMCIDCVR1(val) MSR(val, 2, 1, c3, c2, 0) |
| 269 | #define WSYS_ETMCIDCVR2(val) MSR(val, 2, 1, c3, c4, 0) |
| 270 | #define WSYS_ETMCIDCVR3(val) MSR(val, 2, 1, c3, c6, 0) |
| 271 | #define WSYS_ETMCIDCVR4(val) MSR(val, 2, 1, c3, c8, 0) |
| 272 | #define WSYS_ETMCIDCVR5(val) MSR(val, 2, 1, c3, c10, 0) |
| 273 | #define WSYS_ETMCIDCVR6(val) MSR(val, 2, 1, c3, c12, 0) |
| 274 | #define WSYS_ETMCIDCVR7(val) MSR(val, 2, 1, c3, c14, 0) |
| 275 | #define WSYS_ETMCNTCTLR0(val) MSR(val, 2, 1, c0, c4, 5) |
| 276 | #define WSYS_ETMCNTCTLR1(val) MSR(val, 2, 1, c0, c5, 5) |
| 277 | #define WSYS_ETMCNTCTLR2(val) MSR(val, 2, 1, c0, c6, 5) |
| 278 | #define WSYS_ETMCNTCTLR3(val) MSR(val, 2, 1, c0, c7, 5) |
| 279 | #define WSYS_ETMCNTRLDVR0(val) MSR(val, 2, 1, c0, c0, 5) |
| 280 | #define WSYS_ETMCNTRLDVR1(val) MSR(val, 2, 1, c0, c1, 5) |
| 281 | #define WSYS_ETMCNTRLDVR2(val) MSR(val, 2, 1, c0, c2, 5) |
| 282 | #define WSYS_ETMCNTRLDVR3(val) MSR(val, 2, 1, c0, c3, 5) |
| 283 | #define WSYS_ETMCNTVR0(val) MSR(val, 2, 1, c0, c8, 5) |
| 284 | #define WSYS_ETMCNTVR1(val) MSR(val, 2, 1, c0, c9, 5) |
| 285 | #define WSYS_ETMCNTVR2(val) MSR(val, 2, 1, c0, c10, 5) |
| 286 | #define WSYS_ETMCNTVR3(val) MSR(val, 2, 1, c0, c11, 5) |
| 287 | #define WSYS_ETMCONFIGR(val) MSR(val, 2, 1, c0, c4, 0) |
| 288 | #define WSYS_ETMEVENTCTL0R(val) MSR(val, 2, 1, c0, c8, 0) |
| 289 | #define WSYS_ETMEVENTCTL1R(val) MSR(val, 2, 1, c0, c9, 0) |
| 290 | #define WSYS_ETMEXTINSELR(val) MSR(val, 2, 1, c0, c8, 4) |
| 291 | #define WSYS_ETMIMSPEC0(val) MSR(val, 2, 1, c0, c0, 7) |
| 292 | #define WSYS_ETMOSLAR(val) MSR(val, 2, 1, c1, c0, 4) |
| 293 | #define WSYS_ETMPRGCTLR(val) MSR(val, 2, 1, c0, c1, 0) |
| 294 | #define WSYS_ETMRSCTLR10(val) MSR(val, 2, 1, c1, c10, 0) |
| 295 | #define WSYS_ETMRSCTLR11(val) MSR(val, 2, 1, c1, c11, 0) |
| 296 | #define WSYS_ETMRSCTLR12(val) MSR(val, 2, 1, c1, c12, 0) |
| 297 | #define WSYS_ETMRSCTLR13(val) MSR(val, 2, 1, c1, c13, 0) |
| 298 | #define WSYS_ETMRSCTLR14(val) MSR(val, 2, 1, c1, c14, 0) |
| 299 | #define WSYS_ETMRSCTLR15(val) MSR(val, 2, 1, c1, c15, 0) |
| 300 | #define WSYS_ETMRSCTLR2(val) MSR(val, 2, 1, c1, c2, 0) |
| 301 | #define WSYS_ETMRSCTLR3(val) MSR(val, 2, 1, c1, c3, 0) |
| 302 | #define WSYS_ETMRSCTLR4(val) MSR(val, 2, 1, c1, c4, 0) |
| 303 | #define WSYS_ETMRSCTLR5(val) MSR(val, 2, 1, c1, c5, 0) |
| 304 | #define WSYS_ETMRSCTLR6(val) MSR(val, 2, 1, c1, c6, 0) |
| 305 | #define WSYS_ETMRSCTLR7(val) MSR(val, 2, 1, c1, c7, 0) |
| 306 | #define WSYS_ETMRSCTLR8(val) MSR(val, 2, 1, c1, c8, 0) |
| 307 | #define WSYS_ETMRSCTLR9(val) MSR(val, 2, 1, c1, c9, 0) |
| 308 | #define WSYS_ETMRSCTLR16(val) MSR(val, 2, 1, c1, c0, 1) |
| 309 | #define WSYS_ETMRSCTLR17(val) MSR(val, 2, 1, c1, c1, 1) |
| 310 | #define WSYS_ETMRSCTLR18(val) MSR(val, 2, 1, c1, c2, 1) |
| 311 | #define WSYS_ETMRSCTLR19(val) MSR(val, 2, 1, c1, c3, 1) |
| 312 | #define WSYS_ETMRSCTLR20(val) MSR(val, 2, 1, c1, c4, 1) |
| 313 | #define WSYS_ETMRSCTLR21(val) MSR(val, 2, 1, c1, c5, 1) |
| 314 | #define WSYS_ETMRSCTLR22(val) MSR(val, 2, 1, c1, c6, 1) |
| 315 | #define WSYS_ETMRSCTLR23(val) MSR(val, 2, 1, c1, c7, 1) |
| 316 | #define WSYS_ETMRSCTLR24(val) MSR(val, 2, 1, c1, c8, 1) |
| 317 | #define WSYS_ETMRSCTLR25(val) MSR(val, 2, 1, c1, c9, 1) |
| 318 | #define WSYS_ETMRSCTLR26(val) MSR(val, 2, 1, c1, c10, 1) |
| 319 | #define WSYS_ETMRSCTLR27(val) MSR(val, 2, 1, c1, c11, 1) |
| 320 | #define WSYS_ETMRSCTLR28(val) MSR(val, 2, 1, c1, c12, 1) |
| 321 | #define WSYS_ETMRSCTLR29(val) MSR(val, 2, 1, c1, c13, 1) |
| 322 | #define WSYS_ETMRSCTLR30(val) MSR(val, 2, 1, c1, c14, 1) |
| 323 | #define WSYS_ETMRSCTLR31(val) MSR(val, 2, 1, c1, c15, 1) |
| 324 | #define WSYS_ETMSEQEVR0(val) MSR(val, 2, 1, c0, c0, 4) |
| 325 | #define WSYS_ETMSEQEVR1(val) MSR(val, 2, 1, c0, c1, 4) |
| 326 | #define WSYS_ETMSEQEVR2(val) MSR(val, 2, 1, c0, c2, 4) |
| 327 | #define WSYS_ETMSEQRSTEVR(val) MSR(val, 2, 1, c0, c6, 4) |
| 328 | #define WSYS_ETMSEQSTR(val) MSR(val, 2, 1, c0, c7, 4) |
| 329 | #define WSYS_ETMSTALLCTLR(val) MSR(val, 2, 1, c0, c11, 0) |
| 330 | #define WSYS_ETMSYNCPR(val) MSR(val, 2, 1, c0, c13, 0) |
| 331 | #define WSYS_ETMTRACEIDR(val) MSR(val, 2, 1, c0, c0, 1) |
| 332 | #define WSYS_ETMTSCTLR(val) MSR(val, 2, 1, c0, c12, 0) |
| 333 | #define WSYS_ETMVICTLR(val) MSR(val, 2, 1, c0, c0, 2) |
| 334 | #define WSYS_ETMVIIECTLR(val) MSR(val, 2, 1, c0, c1, 2) |
| 335 | #define WSYS_ETMVISSCTLR(val) MSR(val, 2, 1, c0, c2, 2) |
| 336 | #define WSYS_ETMVMIDCVR0(val) MSR(val, 2, 1, c3, c0, 1) |
| 337 | #define WSYS_ETMVMIDCVR1(val) MSR(val, 2, 1, c3, c2, 1) |
| 338 | #define WSYS_ETMVMIDCVR2(val) MSR(val, 2, 1, c3, c4, 1) |
| 339 | #define WSYS_ETMVMIDCVR3(val) MSR(val, 2, 1, c3, c6, 1) |
| 340 | #define WSYS_ETMVMIDCVR4(val) MSR(val, 2, 1, c3, c8, 1) |
| 341 | #define WSYS_ETMVMIDCVR5(val) MSR(val, 2, 1, c3, c10, 1) |
| 342 | #define WSYS_ETMVMIDCVR6(val) MSR(val, 2, 1, c3, c12, 1) |
| 343 | #define WSYS_ETMVMIDCVR7(val) MSR(val, 2, 1, c3, c14, 1) |
| 344 | #define WSYS_ETMDVCVR0(val) MSR(val, 2, 1, c2, c0, 4) |
| 345 | #define WSYS_ETMDVCVR1(val) MSR(val, 2, 1, c2, c4, 4) |
| 346 | #define WSYS_ETMDVCVR2(val) MSR(val, 2, 1, c2, c8, 4) |
| 347 | #define WSYS_ETMDVCVR3(val) MSR(val, 2, 1, c2, c12, 4) |
| 348 | #define WSYS_ETMDVCVR4(val) MSR(val, 2, 1, c2, c0, 5) |
| 349 | #define WSYS_ETMDVCVR5(val) MSR(val, 2, 1, c2, c4, 5) |
| 350 | #define WSYS_ETMDVCVR6(val) MSR(val, 2, 1, c2, c8, 5) |
| 351 | #define WSYS_ETMDVCVR7(val) MSR(val, 2, 1, c2, c12, 5) |
| 352 | #define WSYS_ETMDVCMR0(val) MSR(val, 2, 1, c2, c0, 6) |
| 353 | #define WSYS_ETMDVCMR1(val) MSR(val, 2, 1, c2, c4, 6) |
| 354 | #define WSYS_ETMDVCMR2(val) MSR(val, 2, 1, c2, c8, 6) |
| 355 | #define WSYS_ETMDVCMR3(val) MSR(val, 2, 1, c2, c12, 6) |
| 356 | #define WSYS_ETMDVCMR4(val) MSR(val, 2, 1, c2, c0, 7) |
| 357 | #define WSYS_ETMDVCMR5(val) MSR(val, 2, 1, c2, c4, 7) |
| 358 | #define WSYS_ETMDVCMR6(val) MSR(val, 2, 1, c2, c8, 7) |
| 359 | #define WSYS_ETMDVCMR7(val) MSR(val, 2, 1, c2, c12, 7) |
| 360 | #define WSYS_ETMSSCCR0(val) MSR(val, 2, 1, c1, c0, 2) |
| 361 | #define WSYS_ETMSSCCR1(val) MSR(val, 2, 1, c1, c1, 2) |
| 362 | #define WSYS_ETMSSCCR2(val) MSR(val, 2, 1, c1, c2, 2) |
| 363 | #define WSYS_ETMSSCCR3(val) MSR(val, 2, 1, c1, c3, 2) |
| 364 | #define WSYS_ETMSSCCR4(val) MSR(val, 2, 1, c1, c4, 2) |
| 365 | #define WSYS_ETMSSCCR5(val) MSR(val, 2, 1, c1, c5, 2) |
| 366 | #define WSYS_ETMSSCCR6(val) MSR(val, 2, 1, c1, c6, 2) |
| 367 | #define WSYS_ETMSSCCR7(val) MSR(val, 2, 1, c1, c7, 2) |
| 368 | #define WSYS_ETMSSCSR0(val) MSR(val, 2, 1, c1, c8, 2) |
| 369 | #define WSYS_ETMSSCSR1(val) MSR(val, 2, 1, c1, c9, 2) |
| 370 | #define WSYS_ETMSSCSR2(val) MSR(val, 2, 1, c1, c10, 2) |
| 371 | #define WSYS_ETMSSCSR3(val) MSR(val, 2, 1, c1, c11, 2) |
| 372 | #define WSYS_ETMSSCSR4(val) MSR(val, 2, 1, c1, c12, 2) |
| 373 | #define WSYS_ETMSSCSR5(val) MSR(val, 2, 1, c1, c13, 2) |
| 374 | #define WSYS_ETMSSCSR6(val) MSR(val, 2, 1, c1, c14, 2) |
| 375 | #define WSYS_ETMSSCSR7(val) MSR(val, 2, 1, c1, c15, 2) |
| 376 | #define WSYS_ETMSSPCICR0(val) MSR(val, 2, 1, c1, c0, 3) |
| 377 | #define WSYS_ETMSSPCICR1(val) MSR(val, 2, 1, c1, c1, 3) |
| 378 | #define WSYS_ETMSSPCICR2(val) MSR(val, 2, 1, c1, c2, 3) |
| 379 | #define WSYS_ETMSSPCICR3(val) MSR(val, 2, 1, c1, c3, 3) |
| 380 | #define WSYS_ETMSSPCICR4(val) MSR(val, 2, 1, c1, c4, 3) |
| 381 | #define WSYS_ETMSSPCICR5(val) MSR(val, 2, 1, c1, c5, 3) |
| 382 | #define WSYS_ETMSSPCICR6(val) MSR(val, 2, 1, c1, c6, 3) |
| 383 | #define WSYS_ETMSSPCICR7(val) MSR(val, 2, 1, c1, c7, 3) |
| 384 | |
| 385 | #endif |