|
12 | 12 | #include <asm/types.h>
|
13 | 13 |
|
14 | 14 | /* Hyp Configuration Register (HCR) bits */
|
| 15 | + |
| 16 | +#define HCR_TID5 (UL(1) << 58) |
| 17 | +#define HCR_DCT (UL(1) << 57) |
15 | 18 | #define HCR_ATA_SHIFT 56
|
16 | 19 | #define HCR_ATA (UL(1) << HCR_ATA_SHIFT)
|
| 20 | +#define HCR_AMVOFFEN (UL(1) << 51) |
| 21 | +#define HCR_FIEN (UL(1) << 47) |
17 | 22 | #define HCR_FWB (UL(1) << 46)
|
18 | 23 | #define HCR_API (UL(1) << 41)
|
19 | 24 | #define HCR_APK (UL(1) << 40)
|
|
56 | 61 | #define HCR_PTW (UL(1) << 2)
|
57 | 62 | #define HCR_SWIO (UL(1) << 1)
|
58 | 63 | #define HCR_VM (UL(1) << 0)
|
| 64 | +#define HCR_RES0 ((UL(1) << 48) | (UL(1) << 39)) |
59 | 65 |
|
60 | 66 | /*
|
61 | 67 | * The bits we set in HCR:
|
|
277 | 283 | #define CPTR_EL2_TZ (1 << 8)
|
278 | 284 | #define CPTR_NVHE_EL2_RES1 0x000032ff /* known RES1 bits in CPTR_EL2 (nVHE) */
|
279 | 285 | #define CPTR_EL2_DEFAULT CPTR_NVHE_EL2_RES1
|
| 286 | +#define CPTR_NVHE_EL2_RES0 (GENMASK(63, 32) | \ |
| 287 | + GENMASK(29, 21) | \ |
| 288 | + GENMASK(19, 14) | \ |
| 289 | + BIT(11)) |
280 | 290 |
|
281 | 291 | /* Hyp Debug Configuration Register bits */
|
282 | 292 | #define MDCR_EL2_E2TB_MASK (UL(0x3))
|
283 | 293 | #define MDCR_EL2_E2TB_SHIFT (UL(24))
|
| 294 | +#define MDCR_EL2_HPMFZS (UL(1) << 36) |
| 295 | +#define MDCR_EL2_HPMFZO (UL(1) << 29) |
| 296 | +#define MDCR_EL2_MTPME (UL(1) << 28) |
| 297 | +#define MDCR_EL2_TDCC (UL(1) << 27) |
| 298 | +#define MDCR_EL2_HCCD (UL(1) << 23) |
284 | 299 | #define MDCR_EL2_TTRF (UL(1) << 19)
|
| 300 | +#define MDCR_EL2_HPMD (UL(1) << 17) |
285 | 301 | #define MDCR_EL2_TPMS (UL(1) << 14)
|
286 | 302 | #define MDCR_EL2_E2PB_MASK (UL(0x3))
|
287 | 303 | #define MDCR_EL2_E2PB_SHIFT (UL(12))
|
|
293 | 309 | #define MDCR_EL2_TPM (UL(1) << 6)
|
294 | 310 | #define MDCR_EL2_TPMCR (UL(1) << 5)
|
295 | 311 | #define MDCR_EL2_HPMN_MASK (UL(0x1F))
|
| 312 | +#define MDCR_EL2_RES0 (GENMASK(63, 37) | \ |
| 313 | + GENMASK(35, 30) | \ |
| 314 | + GENMASK(25, 24) | \ |
| 315 | + GENMASK(22, 20) | \ |
| 316 | + BIT(18) | \ |
| 317 | + GENMASK(16, 15)) |
296 | 318 |
|
297 | 319 | /* For compatibility with fault code shared with 32-bit */
|
298 | 320 | #define FSC_FAULT ESR_ELx_FSC_FAULT
|
|
0 commit comments