Lines Matching +full:7 +full:- +full:9
1 /* SPDX-License-Identifier: GPL-2.0-only */
14 #include <linux/kasan-tags.h>
16 #include <asm/gpr-num.h>
22 * [20-19] : Op0
23 * [18-16] : Op1
24 * [15-12] : CRn
25 * [11-8] : CRm
26 * [7-5] : Op2
83 * As per Arm ARM for v8-A, Section "C.5.1.3 op0 == 0b00, architectural hints,
112 /* Register-based PAN access, for save/restore purposes */
118 #define SB_BARRIER_INSN __SYS_BARRIER_INSN(0, 7, 31)
120 #define SYS_DC_ISW sys_insn(1, 0, 7, 6, 2)
121 #define SYS_DC_IGSW sys_insn(1, 0, 7, 6, 4)
122 #define SYS_DC_IGDSW sys_insn(1, 0, 7, 6, 6)
123 #define SYS_DC_CSW sys_insn(1, 0, 7, 10, 2)
124 #define SYS_DC_CGSW sys_insn(1, 0, 7, 10, 4)
125 #define SYS_DC_CGDSW sys_insn(1, 0, 7, 10, 6)
126 #define SYS_DC_CISW sys_insn(1, 0, 7, 14, 2)
127 #define SYS_DC_CIGSW sys_insn(1, 0, 7, 14, 4)
128 #define SYS_DC_CIGDSW sys_insn(1, 0, 7, 14, 6)
130 #define SYS_IC_IALLUIS sys_insn(1, 0, 7, 1, 0)
131 #define SYS_IC_IALLU sys_insn(1, 0, 7, 5, 0)
132 #define SYS_IC_IVAU sys_insn(1, 3, 7, 5, 1)
134 #define SYS_DC_IVAC sys_insn(1, 0, 7, 6, 1)
135 #define SYS_DC_IGVAC sys_insn(1, 0, 7, 6, 3)
136 #define SYS_DC_IGDVAC sys_insn(1, 0, 7, 6, 5)
138 #define SYS_DC_CVAC sys_insn(1, 3, 7, 10, 1)
139 #define SYS_DC_CGVAC sys_insn(1, 3, 7, 10, 3)
140 #define SYS_DC_CGDVAC sys_insn(1, 3, 7, 10, 5)
142 #define SYS_DC_CVAU sys_insn(1, 3, 7, 11, 1)
144 #define SYS_DC_CVAP sys_insn(1, 3, 7, 12, 1)
145 #define SYS_DC_CGVAP sys_insn(1, 3, 7, 12, 3)
146 #define SYS_DC_CGDVAP sys_insn(1, 3, 7, 12, 5)
148 #define SYS_DC_CVADP sys_insn(1, 3, 7, 13, 1)
149 #define SYS_DC_CGVADP sys_insn(1, 3, 7, 13, 3)
150 #define SYS_DC_CGDVADP sys_insn(1, 3, 7, 13, 5)
152 #define SYS_DC_CIVAC sys_insn(1, 3, 7, 14, 1)
153 #define SYS_DC_CIGVAC sys_insn(1, 3, 7, 14, 3)
154 #define SYS_DC_CIGDVAC sys_insn(1, 3, 7, 14, 5)
157 #define SYS_DC_ZVA sys_insn(1, 3, 7, 4, 1)
158 #define SYS_DC_GVA sys_insn(1, 3, 7, 4, 3)
159 #define SYS_DC_GZVA sys_insn(1, 3, 7, 4, 4)
167 #include "asm/sysreg-defs.h"
180 #define SYS_DBGWCRn_EL1(n) sys_reg(2, 0, 0, n, 7)
191 #define SYS_DBGCLAIMSET_EL1 sys_reg(2, 0, 7, 8, 6)
192 #define SYS_DBGCLAIMCLR_EL1 sys_reg(2, 0, 7, 9, 6)
193 #define SYS_DBGAUTHSTATUS_EL1 sys_reg(2, 0, 7, 14, 6)
198 #define SYS_DBGVCR32_EL2 sys_reg(2, 4, 0, 7, 0)
201 #define SYS_BRBINFINJ_EL1 sys_reg(2, 1, 9, 1, 0)
203 #define SYS_BRBSRCINJ_EL1 sys_reg(2, 1, 9, 1, 1)
205 #define SYS_BRBTGTINJ_EL1 sys_reg(2, 1, 9, 1, 2)
206 #define SYS_BRBTS_EL1 sys_reg(2, 1, 9, 0, 2)
208 #define SYS_BRBCR_EL1 sys_reg(2, 1, 9, 0, 0)
209 #define SYS_BRBFCR_EL1 sys_reg(2, 1, 9, 0, 1)
210 #define SYS_BRBIDR0_EL1 sys_reg(2, 1, 9, 2, 0)
213 #define SYS_TRCACATR(m) sys_reg(2, 1, 2, ((m & 7) << 1), (2 | (m >> 3)))
214 #define SYS_TRCACVR(m) sys_reg(2, 1, 2, ((m & 7) << 1), (0 | (m >> 3)))
215 #define SYS_TRCAUTHSTATUS sys_reg(2, 1, 7, 14, 6)
221 #define SYS_TRCCIDCVR(m) sys_reg(2, 1, 3, ((m & 7) << 1), 0)
222 #define SYS_TRCCLAIMCLR sys_reg(2, 1, 7, 9, 6)
223 #define SYS_TRCCLAIMSET sys_reg(2, 1, 7, 8, 6)
228 #define SYS_TRCDEVARCH sys_reg(2, 1, 7, 15, 6)
229 #define SYS_TRCDEVID sys_reg(2, 1, 7, 2, 7)
231 #define SYS_TRCEVENTCTL1R sys_reg(2, 1, 0, 9, 0)
233 #define SYS_TRCIDR0 sys_reg(2, 1, 0, 8, 7)
238 #define SYS_TRCIDR1 sys_reg(2, 1, 0, 9, 7)
239 #define SYS_TRCIDR2 sys_reg(2, 1, 0, 10, 7)
240 #define SYS_TRCIDR3 sys_reg(2, 1, 0, 11, 7)
241 #define SYS_TRCIDR4 sys_reg(2, 1, 0, 12, 7)
242 #define SYS_TRCIDR5 sys_reg(2, 1, 0, 13, 7)
243 #define SYS_TRCIDR6 sys_reg(2, 1, 0, 14, 7)
244 #define SYS_TRCIDR7 sys_reg(2, 1, 0, 15, 7)
247 #define SYS_TRCIMSPEC(m) sys_reg(2, 1, 0, (m & 7), 7)
256 #define SYS_TRCSEQSTR sys_reg(2, 1, 0, 7, 4)
257 #define SYS_TRCSSCCR(m) sys_reg(2, 1, 1, (m & 7), 2)
258 #define SYS_TRCSSCSR(m) sys_reg(2, 1, 1, (8 | (m & 7)), 2)
259 #define SYS_TRCSSPCICR(m) sys_reg(2, 1, 1, (m & 7), 3)
271 #define SYS_TRCVMIDCVR(m) sys_reg(2, 1, 3, ((m & 7) << 1), 1)
276 #define SYS_BRBCR_EL2 sys_reg(2, 4, 9, 0, 0)
328 #define SYS_PAR_EL1 sys_reg(3, 0, 7, 4, 0)
334 #define SYS_PAR_EL1_S BIT(9)
340 #define SYS_PAR_EL1_F1_RES0 (BIT(7) | BIT(10) | GENMASK_ULL(47, 16))
343 #define SYS_PAR_EL1_SH GENMASK_ULL(8, 7)
344 #define SYS_PAR_EL1_NS BIT(9)
374 #define SYS_PMINTENSET_EL1 sys_reg(3, 0, 9, 14, 1)
375 #define SYS_PMINTENCLR_EL1 sys_reg(3, 0, 9, 14, 2)
377 #define SYS_PMMIR_EL1 sys_reg(3, 0, 9, 14, 6)
394 #define SYS_ICC_AP1Rn_EL1(n) sys_reg(3, 0, 12, 9, n)
403 #define SYS_ICC_SGI0R_EL1 sys_reg(3, 0, 12, 11, 7)
411 #define SYS_ICC_IGRPEN1_EL1 sys_reg(3, 0, 12, 12, 7)
417 #define SYS_AIDR_EL1 sys_reg(3, 1, 0, 0, 7)
422 #define SYS_PMCR_EL0 sys_reg(3, 3, 9, 12, 0)
423 #define SYS_PMCNTENSET_EL0 sys_reg(3, 3, 9, 12, 1)
424 #define SYS_PMCNTENCLR_EL0 sys_reg(3, 3, 9, 12, 2)
425 #define SYS_PMOVSCLR_EL0 sys_reg(3, 3, 9, 12, 3)
426 #define SYS_PMSWINC_EL0 sys_reg(3, 3, 9, 12, 4)
427 #define SYS_PMCEID0_EL0 sys_reg(3, 3, 9, 12, 6)
428 #define SYS_PMCEID1_EL0 sys_reg(3, 3, 9, 12, 7)
429 #define SYS_PMCCNTR_EL0 sys_reg(3, 3, 9, 13, 0)
430 #define SYS_PMXEVTYPER_EL0 sys_reg(3, 3, 9, 13, 1)
431 #define SYS_PMXEVCNTR_EL0 sys_reg(3, 3, 9, 13, 2)
432 #define SYS_PMUSERENR_EL0 sys_reg(3, 3, 9, 14, 0)
433 #define SYS_PMOVSSET_EL0 sys_reg(3, 3, 9, 14, 3)
439 #define SYS_SCXTNUM_EL0 sys_reg(3, 3, 13, 0, 7)
457 * n: 0-15
463 * n: 0-15
466 #define SYS_AMEVCNTR0_EL0(n) SYS_AM_EL0(4 + ((n) >> 3), (n) & 7)
467 #define SYS_AMEVTYPER0_EL0(n) SYS_AM_EL0(6 + ((n) >> 3), (n) & 7)
468 #define SYS_AMEVCNTR1_EL0(n) SYS_AM_EL0(12 + ((n) >> 3), (n) & 7)
469 #define SYS_AMEVTYPER1_EL0(n) SYS_AM_EL0(14 + ((n) >> 3), (n) & 7)
502 #define SYS_PMCCFILTR_EL0 sys_reg(3, 3, 14, 15, 7)
514 #define SYS_HACR_EL2 sys_reg(3, 4, 1, 1, 7)
556 #define SYS_MPAMVPM7_EL2 __SYS__MPAMVPMx_EL2(7)
568 #define __SYS__AP1Rx_EL2(x) sys_reg(3, 4, 12, 9, x)
574 #define SYS_ICH_VSEIR_EL2 sys_reg(3, 4, 12, 9, 4)
575 #define SYS_ICC_SRE_EL2 sys_reg(3, 4, 12, 9, 5)
581 #define SYS_ICH_VMCR_EL2 sys_reg(3, 4, 12, 11, 7)
591 #define SYS_ICH_LR7_EL2 __SYS__LR0_EL2(7)
601 #define SYS_ICH_LR15_EL2 __SYS__LR8_EL2(7)
605 #define SYS_SCXTNUM_EL2 sys_reg(3, 4, 13, 0, 7)
624 #define SYS_BRBCR_EL12 sys_reg(2, 5, 9, 0, 0)
642 #define SYS_PMSCR_EL12 sys_reg(3, 5, 9, 9, 0)
647 #define SYS_SCXTNUM_EL12 sys_reg(3, 5, 13, 0, 7)
660 #define AT_CRn 7
666 #define OP_AT_S1E1RP sys_insn(AT_Op0, 0, AT_CRn, 9, 0)
667 #define OP_AT_S1E1WP sys_insn(AT_Op0, 0, AT_CRn, 9, 1)
668 #define OP_AT_S1E1A sys_insn(AT_Op0, 0, AT_CRn, 9, 2)
674 #define OP_AT_S12E0W sys_insn(AT_Op0, 4, AT_CRn, 8, 7)
675 #define OP_AT_S1E2A sys_insn(AT_Op0, 4, AT_CRn, 9, 2)
684 #define TLBI_CRn_nXS 9 /* not Extra Slow (which nobody uses)*/
686 #define TLBI_CRm_IPAIS 0 /* S2 Inner-Shareable */
687 #define TLBI_CRm_nROS 1 /* non-Range, Outer-Sharable */
688 #define TLBI_CRm_RIS 2 /* Range, Inner-Sharable */
689 #define TLBI_CRm_nRIS 3 /* non-Range, Inner-Sharable */
690 #define TLBI_CRm_IPAONS 4 /* S2 Outer and Non-Shareable */
691 #define TLBI_CRm_ROS 5 /* Range, Outer-Sharable */
692 #define TLBI_CRm_RNS 6 /* Range, Non-Sharable */
693 #define TLBI_CRm_nRNS 7 /* non-Range, Non-Sharable */
700 #define OP_TLBI_VAALE1OS sys_insn(1, 0, 8, 1, 7)
704 #define OP_TLBI_RVAALE1IS sys_insn(1, 0, 8, 2, 7)
710 #define OP_TLBI_VAALE1IS sys_insn(1, 0, 8, 3, 7)
714 #define OP_TLBI_RVAALE1OS sys_insn(1, 0, 8, 5, 7)
718 #define OP_TLBI_RVAALE1 sys_insn(1, 0, 8, 6, 7)
719 #define OP_TLBI_VMALLE1 sys_insn(1, 0, 8, 7, 0)
720 #define OP_TLBI_VAE1 sys_insn(1, 0, 8, 7, 1)
721 #define OP_TLBI_ASIDE1 sys_insn(1, 0, 8, 7, 2)
722 #define OP_TLBI_VAAE1 sys_insn(1, 0, 8, 7, 3)
723 #define OP_TLBI_VALE1 sys_insn(1, 0, 8, 7, 5)
724 #define OP_TLBI_VAALE1 sys_insn(1, 0, 8, 7, 7)
725 #define OP_TLBI_VMALLE1OSNXS sys_insn(1, 0, 9, 1, 0)
726 #define OP_TLBI_VAE1OSNXS sys_insn(1, 0, 9, 1, 1)
727 #define OP_TLBI_ASIDE1OSNXS sys_insn(1, 0, 9, 1, 2)
728 #define OP_TLBI_VAAE1OSNXS sys_insn(1, 0, 9, 1, 3)
729 #define OP_TLBI_VALE1OSNXS sys_insn(1, 0, 9, 1, 5)
730 #define OP_TLBI_VAALE1OSNXS sys_insn(1, 0, 9, 1, 7)
731 #define OP_TLBI_RVAE1ISNXS sys_insn(1, 0, 9, 2, 1)
732 #define OP_TLBI_RVAAE1ISNXS sys_insn(1, 0, 9, 2, 3)
733 #define OP_TLBI_RVALE1ISNXS sys_insn(1, 0, 9, 2, 5)
734 #define OP_TLBI_RVAALE1ISNXS sys_insn(1, 0, 9, 2, 7)
735 #define OP_TLBI_VMALLE1ISNXS sys_insn(1, 0, 9, 3, 0)
736 #define OP_TLBI_VAE1ISNXS sys_insn(1, 0, 9, 3, 1)
737 #define OP_TLBI_ASIDE1ISNXS sys_insn(1, 0, 9, 3, 2)
738 #define OP_TLBI_VAAE1ISNXS sys_insn(1, 0, 9, 3, 3)
739 #define OP_TLBI_VALE1ISNXS sys_insn(1, 0, 9, 3, 5)
740 #define OP_TLBI_VAALE1ISNXS sys_insn(1, 0, 9, 3, 7)
741 #define OP_TLBI_RVAE1OSNXS sys_insn(1, 0, 9, 5, 1)
742 #define OP_TLBI_RVAAE1OSNXS sys_insn(1, 0, 9, 5, 3)
743 #define OP_TLBI_RVALE1OSNXS sys_insn(1, 0, 9, 5, 5)
744 #define OP_TLBI_RVAALE1OSNXS sys_insn(1, 0, 9, 5, 7)
745 #define OP_TLBI_RVAE1NXS sys_insn(1, 0, 9, 6, 1)
746 #define OP_TLBI_RVAAE1NXS sys_insn(1, 0, 9, 6, 3)
747 #define OP_TLBI_RVALE1NXS sys_insn(1, 0, 9, 6, 5)
748 #define OP_TLBI_RVAALE1NXS sys_insn(1, 0, 9, 6, 7)
749 #define OP_TLBI_VMALLE1NXS sys_insn(1, 0, 9, 7, 0)
750 #define OP_TLBI_VAE1NXS sys_insn(1, 0, 9, 7, 1)
751 #define OP_TLBI_ASIDE1NXS sys_insn(1, 0, 9, 7, 2)
752 #define OP_TLBI_VAAE1NXS sys_insn(1, 0, 9, 7, 3)
753 #define OP_TLBI_VALE1NXS sys_insn(1, 0, 9, 7, 5)
754 #define OP_TLBI_VAALE1NXS sys_insn(1, 0, 9, 7, 7)
778 #define OP_TLBI_RIPAS2LE1OS sys_insn(1, 4, 8, 4, 7)
783 #define OP_TLBI_ALLE2 sys_insn(1, 4, 8, 7, 0)
784 #define OP_TLBI_VAE2 sys_insn(1, 4, 8, 7, 1)
785 #define OP_TLBI_ALLE1 sys_insn(1, 4, 8, 7, 4)
786 #define OP_TLBI_VALE2 sys_insn(1, 4, 8, 7, 5)
787 #define OP_TLBI_VMALLS12E1 sys_insn(1, 4, 8, 7, 6)
788 #define OP_TLBI_IPAS2E1ISNXS sys_insn(1, 4, 9, 0, 1)
789 #define OP_TLBI_RIPAS2E1ISNXS sys_insn(1, 4, 9, 0, 2)
790 #define OP_TLBI_IPAS2LE1ISNXS sys_insn(1, 4, 9, 0, 5)
791 #define OP_TLBI_RIPAS2LE1ISNXS sys_insn(1, 4, 9, 0, 6)
792 #define OP_TLBI_ALLE2OSNXS sys_insn(1, 4, 9, 1, 0)
793 #define OP_TLBI_VAE2OSNXS sys_insn(1, 4, 9, 1, 1)
794 #define OP_TLBI_ALLE1OSNXS sys_insn(1, 4, 9, 1, 4)
795 #define OP_TLBI_VALE2OSNXS sys_insn(1, 4, 9, 1, 5)
796 #define OP_TLBI_VMALLS12E1OSNXS sys_insn(1, 4, 9, 1, 6)
797 #define OP_TLBI_RVAE2ISNXS sys_insn(1, 4, 9, 2, 1)
798 #define OP_TLBI_RVALE2ISNXS sys_insn(1, 4, 9, 2, 5)
799 #define OP_TLBI_ALLE2ISNXS sys_insn(1, 4, 9, 3, 0)
800 #define OP_TLBI_VAE2ISNXS sys_insn(1, 4, 9, 3, 1)
801 #define OP_TLBI_ALLE1ISNXS sys_insn(1, 4, 9, 3, 4)
802 #define OP_TLBI_VALE2ISNXS sys_insn(1, 4, 9, 3, 5)
803 #define OP_TLBI_VMALLS12E1ISNXS sys_insn(1, 4, 9, 3, 6)
804 #define OP_TLBI_IPAS2E1OSNXS sys_insn(1, 4, 9, 4, 0)
805 #define OP_TLBI_IPAS2E1NXS sys_insn(1, 4, 9, 4, 1)
806 #define OP_TLBI_RIPAS2E1NXS sys_insn(1, 4, 9, 4, 2)
807 #define OP_TLBI_RIPAS2E1OSNXS sys_insn(1, 4, 9, 4, 3)
808 #define OP_TLBI_IPAS2LE1OSNXS sys_insn(1, 4, 9, 4, 4)
809 #define OP_TLBI_IPAS2LE1NXS sys_insn(1, 4, 9, 4, 5)
810 #define OP_TLBI_RIPAS2LE1NXS sys_insn(1, 4, 9, 4, 6)
811 #define OP_TLBI_RIPAS2LE1OSNXS sys_insn(1, 4, 9, 4, 7)
812 #define OP_TLBI_RVAE2OSNXS sys_insn(1, 4, 9, 5, 1)
813 #define OP_TLBI_RVALE2OSNXS sys_insn(1, 4, 9, 5, 5)
814 #define OP_TLBI_RVAE2NXS sys_insn(1, 4, 9, 6, 1)
815 #define OP_TLBI_RVALE2NXS sys_insn(1, 4, 9, 6, 5)
816 #define OP_TLBI_ALLE2NXS sys_insn(1, 4, 9, 7, 0)
817 #define OP_TLBI_VAE2NXS sys_insn(1, 4, 9, 7, 1)
818 #define OP_TLBI_ALLE1NXS sys_insn(1, 4, 9, 7, 4)
819 #define OP_TLBI_VALE2NXS sys_insn(1, 4, 9, 7, 5)
820 #define OP_TLBI_VMALLS12E1NXS sys_insn(1, 4, 9, 7, 6)
823 #define OP_GCSPUSHX sys_insn(1, 0, 7, 7, 4)
824 #define OP_GCSPOPCX sys_insn(1, 0, 7, 7, 5)
825 #define OP_GCSPOPX sys_insn(1, 0, 7, 7, 6)
826 #define OP_GCSPUSHM sys_insn(1, 3, 7, 7, 0)
828 #define OP_BRB_IALL sys_insn(1, 1, 7, 2, 4)
829 #define OP_BRB_INJ sys_insn(1, 1, 7, 2, 5)
830 #define OP_CFP_RCTX sys_insn(1, 3, 7, 3, 4)
831 #define OP_DVP_RCTX sys_insn(1, 3, 7, 3, 5)
832 #define OP_COSP_RCTX sys_insn(1, 3, 7, 3, 6)
833 #define OP_CPP_RCTX sys_insn(1, 3, 7, 3, 7)
972 * only uses tags in the range 0xF0-0xFF, which we map to MTE tags 0x0-0xF.
1013 #define ICH_LR_VIRTUAL_ID_MASK ((1ULL << 32) - 1)
1044 #define ICH_VMCR_EOIM_SHIFT 9
1047 #define ICH_VMCR_BPR1_MASK (7 << ICH_VMCR_BPR1_SHIFT)
1049 #define ICH_VMCR_BPR0_MASK (7 << ICH_VMCR_BPR0_SHIFT)
1059 #define ICH_VTR_PRI_BITS_MASK (7 << ICH_VTR_PRI_BITS_SHIFT)
1061 #define ICH_VTR_ID_BITS_MASK (7 << ICH_VTR_ID_BITS_SHIFT)
1197 * set mask are set. Other bits are left as-is.