18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */ 28c2ecf20Sopenharmony_ci#ifndef __ASM_TLBEX_H 38c2ecf20Sopenharmony_ci#define __ASM_TLBEX_H 48c2ecf20Sopenharmony_ci 58c2ecf20Sopenharmony_ci#include <asm/uasm.h> 68c2ecf20Sopenharmony_ci 78c2ecf20Sopenharmony_ci/* 88c2ecf20Sopenharmony_ci * Write random or indexed TLB entry, and care about the hazards from 98c2ecf20Sopenharmony_ci * the preceding mtc0 and for the following eret. 108c2ecf20Sopenharmony_ci */ 118c2ecf20Sopenharmony_cienum tlb_write_entry { 128c2ecf20Sopenharmony_ci tlb_random, 138c2ecf20Sopenharmony_ci tlb_indexed 148c2ecf20Sopenharmony_ci}; 158c2ecf20Sopenharmony_ci 168c2ecf20Sopenharmony_ciextern int pgd_reg; 178c2ecf20Sopenharmony_ci 188c2ecf20Sopenharmony_civoid build_get_pmde64(u32 **p, struct uasm_label **l, struct uasm_reloc **r, 198c2ecf20Sopenharmony_ci unsigned int tmp, unsigned int ptr); 208c2ecf20Sopenharmony_civoid build_get_pgde32(u32 **p, unsigned int tmp, unsigned int ptr); 218c2ecf20Sopenharmony_civoid build_get_ptep(u32 **p, unsigned int tmp, unsigned int ptr); 228c2ecf20Sopenharmony_civoid build_update_entries(u32 **p, unsigned int tmp, unsigned int ptep); 238c2ecf20Sopenharmony_civoid build_tlb_write_entry(u32 **p, struct uasm_label **l, 248c2ecf20Sopenharmony_ci struct uasm_reloc **r, 258c2ecf20Sopenharmony_ci enum tlb_write_entry wmode); 268c2ecf20Sopenharmony_ci 278c2ecf20Sopenharmony_ciextern void handle_tlbl(void); 288c2ecf20Sopenharmony_ciextern char handle_tlbl_end[]; 298c2ecf20Sopenharmony_ci 308c2ecf20Sopenharmony_ciextern void handle_tlbs(void); 318c2ecf20Sopenharmony_ciextern char handle_tlbs_end[]; 328c2ecf20Sopenharmony_ci 338c2ecf20Sopenharmony_ciextern void handle_tlbm(void); 348c2ecf20Sopenharmony_ciextern char handle_tlbm_end[]; 358c2ecf20Sopenharmony_ci 368c2ecf20Sopenharmony_ci#endif /* __ASM_TLBEX_H */ 37