Tom Rini | 10e4779 | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0+ */ |
David Feng | 85fd5f1 | 2013-12-14 11:47:35 +0800 | [diff] [blame] | 2 | /* |
| 3 | * (C) Copyright 2013 |
| 4 | * David Feng <fenghua@phytium.com.cn> |
David Feng | 85fd5f1 | 2013-12-14 11:47:35 +0800 | [diff] [blame] | 5 | */ |
| 6 | |
| 7 | #include <asm-offsets.h> |
| 8 | #include <config.h> |
David Feng | 85fd5f1 | 2013-12-14 11:47:35 +0800 | [diff] [blame] | 9 | #include <linux/linkage.h> |
| 10 | #include <asm/macro.h> |
| 11 | |
| 12 | /* |
| 13 | * void __asm_invalidate_tlb_all(void) |
| 14 | * |
| 15 | * invalidate all tlb entries. |
Philipp Tomsich | d15592f | 2017-07-04 10:04:54 +0200 | [diff] [blame] | 16 | */ |
| 17 | .pushsection .text.__asm_invalidate_tlb_all, "ax" |
David Feng | 85fd5f1 | 2013-12-14 11:47:35 +0800 | [diff] [blame] | 18 | ENTRY(__asm_invalidate_tlb_all) |
| 19 | switch_el x9, 3f, 2f, 1f |
| 20 | 3: tlbi alle3 |
| 21 | dsb sy |
| 22 | isb |
| 23 | b 0f |
| 24 | 2: tlbi alle2 |
| 25 | dsb sy |
| 26 | isb |
| 27 | b 0f |
| 28 | 1: tlbi vmalle1 |
| 29 | dsb sy |
| 30 | isb |
| 31 | 0: |
| 32 | ret |
| 33 | ENDPROC(__asm_invalidate_tlb_all) |
Philipp Tomsich | d15592f | 2017-07-04 10:04:54 +0200 | [diff] [blame] | 34 | .popsection |